Skip to content

Depot mdmenrollmentlinks

Registers the enrollment link routes.

This page is generated from the Depot route table. Every operation carries the permission it needs and the anchor an agent can link to.

GETmdm:readtenant facehosteditmspremoteIdempotent

From an MSP console, prefix the path with /api/v1/clients/{clientID} to reach one client.

Source: [object Object]

listMdmEnrollmentLinks lists enrollment links, newest first.

Revoked links are included with includeRevoked=true.

NameInTypeRequiredDescription
includeRevokedquerystringNo
pagequeryintegerNoOne-based page number. Defaults to 1.
pageSizequeryintegerNoRows per page, 1 to 200. Defaults to 50.
StatusBodyDescription
200application/json, PagedResultEnrollmentLinkViewSuccess.
400application/problem+json, ProblemDetailsOne or more validation errors occurred.
401application/problem+json, ProblemDetailsNo signed-in identity.
403application/problem+json, ProblemDetailsThe identity does not hold mdm:read.
500application/problem+json, ProblemDetailsNo client context in request.

200 response body

FieldTypeDescription
itemsrequiredarray of EnrollmentLinkView
items[].createdAtrequiredstring (date-time)
items[].expiresAtstring (date-time) or null
items[].idpConnectionIdstring or null
items[].maxUsesinteger or null
items[].namerequiredstring
items[].ownershiprequiredstring
items[].publicIdrequiredstring
items[].purposerequiredstring
items[].qrPngstring
items[].revokedAtstring (date-time) or null
items[].siteIdstring or null
items[].urlstring
items[].usedCountrequiredinteger
pagerequiredinteger
pageSizerequiredinteger
totalrequiredinteger
Terminal window
# Sign in first. outpost_console is a session cookie, so send it with every request.
# This operation is idempotent. Repeating it does not repeat its effect.
curl -X GET 'https://depot.example.com/api/v1/mdm/enrollment-links?includeRevoked=<includeRevoked>&page=0&pageSize=0' \
-H 'X-CSRF-Token: <csrf-token>' \
-H 'Accept: application/json' \
-b 'outpost_console=<console-session>'

POSTmdm:enrolltenant facehosteditmspremote

From an MSP console, prefix the path with /api/v1/clients/{clientID} to reach one client.

Source: [object Object]

createMdmEnrollmentLink creates an enrollment link and returns its URL and QR code.

They are shown only once. A personal-device link needs an identity provider; a link without one must expire. Automated Device Enrollment starts in Setup Assistant, so a link for it is refused (422).

Required, sent as application/json.

FieldTypeDescription
expiresAtstring (date-time) or null
idpConnectionIdstring or null
maxUsesinteger or null
namerequiredstring
ownershiprequiredstring
purposerequiredstring
siteIdstring or null
StatusBodyDescription
201application/json, EnrollmentLinkViewCreated.
400application/problem+json, ProblemDetailsThe request body is not valid JSON.
401application/problem+json, ProblemDetailsNo signed-in identity.
403application/problem+json, ProblemDetailsThe identity does not hold mdm:enroll.
404application/problem+json, ProblemDetailsNo resource matches.
409application/problem+json, ProblemDetailsThe enrollment link could not be saved.
500application/problem+json, ProblemDetailsNo client context in request.
503application/problem+json, ProblemDetailsThe public device management address is not configured on this Depot, so enrollment links cannot be made yet.

201 response body

FieldTypeDescription
createdAtrequiredstring (date-time)
expiresAtstring (date-time) or null
idpConnectionIdstring or null
maxUsesinteger or null
namerequiredstring
ownershiprequiredstring
publicIdrequiredstring
purposerequiredstring
qrPngstring
revokedAtstring (date-time) or null
siteIdstring or null
urlstring
usedCountrequiredinteger
Terminal window
# Sign in first. outpost_console is a session cookie, so send it with every request.
curl -X POST 'https://depot.example.com/api/v1/mdm/enrollment-links' \
-H 'X-CSRF-Token: <csrf-token>' \
-H 'Accept: application/json' \
-H 'Content-Type: application/json' \
-b 'outpost_console=<console-session>' \
--data '{
"expiresAt": "2026-01-01T00:00:00Z",
"idpConnectionId": "string",
"maxUses": 0,
"name": "string",
"ownership": "string",
"purpose": "string",
"siteId": "string"
}'
Section titled “DELETE /api/v1/mdm/enrollment-links/{publicId}”

DELETEmdm:enrolltenant facehosteditmspremoteIdempotent

From an MSP console, prefix the path with /api/v1/clients/{clientID} to reach one client.

Source: [object Object]

revokeMdmEnrollmentLink turns a link off.

Devices already enrolled stay enrolled.

NameInTypeRequiredDescription
publicIdpathstringYesA uuid.
StatusBodyDescription
204NoneSuccess, with no body.
400application/problem+json, ProblemDetailsOne or more validation errors occurred.
401application/problem+json, ProblemDetailsNo signed-in identity.
403application/problem+json, ProblemDetailsThe identity does not hold mdm:enroll.
404application/problem+json, ProblemDetailsNo resource matches that id.
500application/problem+json, ProblemDetailsNo client context in request.
Terminal window
# Sign in first. outpost_console is a session cookie, so send it with every request.
# This operation is idempotent. Repeating it does not repeat its effect.
curl -X DELETE 'https://depot.example.com/api/v1/mdm/enrollment-links/<publicId>' \
-H 'X-CSRF-Token: <csrf-token>' \
-H 'Accept: application/json' \
-b 'outpost_console=<console-session>'

Content is licensed CC BY 4.0. Code samples are MIT. Outpost and the Outpost mark are trademarks of Outpost Business Solutions, PBC and are not covered by either license.