API reference

Approve/deny push

Set up the per-tenant secret that lets a Microsoft Authenticator push show Approve and Deny instead of a number.

A push with method: "entra_push" and mode: "approve" shows Approve / Deny in Microsoft Authenticator instead of a number to match. Microsoft accepts these requests only when they are signed with a secret on its built-in Azure Multi-Factor Auth Client app (app id 981f26a1-7f43-403b-a875-f8b09b8cd720) inside the client's tenant. The request does not go through your own Entra app.

  • The secret is created once per client tenant, stored encrypted and used for every approve push to that tenant.
  • Where automatic setup is permitted, Scute renews the secret 30 days before it expires.
  • A stored secret is checked with Microsoft before a client is reported ready.

There are two sets of calls. A Master or MSP sets up every client under it with the client setup calls. A single workspace can read and set up its own tenant with the workspace calls.

Client setup#

These calls run against a Master or MSP workspace. Authenticate with its workspace key in Authorization and an M2M token from an app in that workspace (or a member JWT) in X-Authorization. See Authentication.

:client is a client workspace UUID or slug, a client app id or public id, or the client's Microsoft tenant ID. It must sit under the path workspace.

A client with no tenant on Scute yet is connected when you send tenant_id in the body of the setup command, provision or secret call. On a client that is already connected, tenant_id must match.

Errors on every client setup call:

Statuserror_codeWhen
403entra_approve_not_enabledApprove/deny push is not enabled for this workspace.
403integrator_workspace_requiredThe path workspace is not a Master or MSP.
404client_not_found:client is not a client under this workspace.
409tenant_mismatchtenant_id differs from the tenant the client is connected to.
422client_not_connectedThe client has no tenant and no tenant_id was sent.
422invalid_tenant_idtenant_id is not a tenant GUID.
422master_has_no_entra_appThe Master above the client has no Entra app, so the client cannot be connected.

List clients#

Every client under the workspace that is connected to a tenant, with its approve/deny state.

GET/v1/workspaces/:workspace_id/entra/approve-setup/clientsWorkspace key + M2M token
workspace_idstringrequired
Master or MSP workspace UUID or slug.
qstring
Query. Matches the client's slug, name, tenant ID or display name, and the MSP's slug or name.
limitinteger
Query. 1 to 200. Default 200.
refreshboolean
Query. Ask Microsoft again instead of reusing the answer from the last few seconds.
include_unconnectedboolean
Query. Also list clients with no tenant yet, as not_connected rows. Default false.
Requestbash
curl "https://api.scute.io/v1/workspaces/$SCUTE_WORKSPACE_ID/entra/approve-setup/clients?q=contoso" \  -H "Authorization: Bearer $SCUTE_WORKSPACE_KEY" \  -H "X-Authorization: Bearer $SCUTE_M2M_TOKEN"
Response 200json
{  "feature_enabled": true,  "summary": { "total": 240, "ready": 230, "not_set_up": 7, "expired": 2, "invalid": 1, "expiring_soon": 5, "not_connected": 12 },  "clients": [    {      "workspace_id": "0193f8aa-5555-7666-8777-888888888888",      "slug": "contoso",      "name": "Contoso",      "workspace_type": "msp_client",      "msp": { "workspace_id": "0193f8aa-1111-7222-8333-444444444444", "slug": "acme-msp", "name": "Acme MSP" },      "tenant_id": "c87af060-e83b-4ed4-bf27-1d6ac3584c90",      "display_name": "Contoso",      "apps": [{ "id": "0193f8aa-5555-7666-8777-999999999999", "public_id": "app_3mxZRrzWxhPZ08dXvqq6", "name": "Contoso" }],      "status": "not_set_up",      "status_detail": null,      "checked_at": null,      "enabled": false,      "expires_at": null    }  ],  "truncated": false}
FieldMeaning
summary.totalClients connected to a tenant. not_connected counts the others and is not part of total. expiring_soon counts ready clients within 30 days of expiry.
clients[].statusready, not_set_up, expired, invalid (Microsoft refuses the stored secret, for example deleted in the tenant), or not_connected.
clients[].status_detailWhy a stored secret is not accepted, otherwise null.
clients[].checked_atWhen Microsoft last answered for the secret.
clients[].expires_atWhen the stored secret expires.
clients[].gdapOnly for a client reached through an MSP's GDAP connection: the MSP, partner_tenant_id (Scute's row id, not Microsoft's GUID), connection_status, linked, approve_deny_consented and, while not ready, next_step.
truncatedtrue when more clients matched than limit.

Get a client#

One client, plus whether automatic setup can work in its tenant now.

GET/v1/workspaces/:workspace_id/entra/approve-setup/clients/:clientWorkspace key + M2M token
workspace_idstringrequired
Master or MSP workspace UUID or slug.
clientstringrequired
Client workspace, client app or tenant ID.
refreshboolean
Query. Ask Microsoft again.
Requestbash
curl https://api.scute.io/v1/workspaces/$SCUTE_WORKSPACE_ID/entra/approve-setup/clients/contoso \  -H "Authorization: Bearer $SCUTE_WORKSPACE_KEY" \  -H "X-Authorization: Bearer $SCUTE_M2M_TOKEN"
Response 200json
{  "feature_enabled": true,  "client": { "slug": "contoso", "tenant_id": "c87af060-e83b-4ed4-bf27-1d6ac3584c90", "status": "not_set_up" },  "auto_setup": { "available": true, "permission": "Application.ReadWrite.All" }}

client has the fields of a list row (a subset is shown). auto_setup.available is null when Microsoft could not be asked. A GDAP client also gets auto_setup.next_step.

Provision automatically#

Scute creates the secret through Microsoft Graph with the Entra app the client resolves to. The app needs Application.ReadWrite.All consented in the client tenant.

The call is idempotent: a client that is ready, accepted by Microsoft and more than 30 days from expiry is left as it is and the call answers unchanged: true. A secret that expires within 30 days, has expired or is refused is rotated.

POST/v1/workspaces/:workspace_id/entra/approve-setup/clients/:client/provisionWorkspace key + M2M token
workspace_idstringrequired
Master or MSP workspace UUID or slug.
clientstringrequired
Client workspace, client app or tenant ID.
forceboolean
Query. Rotate the secret in every case.
tenant_idstring
The client's tenant GUID, for a client with no tenant yet.
Requestbash
curl -X POST https://api.scute.io/v1/workspaces/$SCUTE_WORKSPACE_ID/entra/approve-setup/clients/contoso/provision \  -H "Authorization: Bearer $SCUTE_WORKSPACE_KEY" \  -H "X-Authorization: Bearer $SCUTE_M2M_TOKEN"
Response 200json
{ "ok": true, "client": { "slug": "contoso", "status": "ready", "expires_at": "2027-11-19T10:00:00Z" } }
Statuserror_codeWhen
422needs_manualThe app may not create the secret in this tenant. Use the setup command or send a secret. A GDAP client also gets next_step, the setup run that creates it.
422provision_failedMicrosoft refused. error says why.

Get a setup command#

Returns a one-time PowerShell command for an admin of the client tenant to paste into Azure Cloud Shell. It creates the secret and posts it to Scute. It is pinned to the tenant, works once and is valid for 30 minutes. Poll Get a client until status is ready.

POST/v1/workspaces/:workspace_id/entra/approve-setup/clients/:client/setup-commandWorkspace key + M2M token
workspace_idstringrequired
Master or MSP workspace UUID or slug.
clientstringrequired
Client workspace, client app or tenant ID.
tenant_idstring
The client's tenant GUID, for a client with no tenant yet.
Requestbash
curl -X POST https://api.scute.io/v1/workspaces/$SCUTE_WORKSPACE_ID/entra/approve-setup/clients/contoso/setup-command \  -H "Authorization: Bearer $SCUTE_WORKSPACE_KEY" \  -H "X-Authorization: Bearer $SCUTE_M2M_TOKEN"
Response 200json
{  "client": { "slug": "contoso", "status": "not_set_up" },  "command": "$ErrorActionPreference=\"Stop\"; Connect-MgGraph -Scopes Application.ReadWrite.All -NoWelcome -TenantId \"c87af060-...\"; ...",  "callback_url": "https://api.scute.io/v1/auth/entra/mfa-approve-callback",  "setup_token": "...",  "expires_in": 1800}

Store a secret#

Stores a secret you created yourself: a password credential on the service principal of the Azure Multi-Factor Auth Client app in the tenant. Scute checks it with Microsoft first.

PUT/v1/workspaces/:workspace_id/entra/approve-setup/clients/:client/secretWorkspace key + M2M token
workspace_idstringrequired
Master or MSP workspace UUID or slug.
clientstringrequired
Client workspace, client app or tenant ID.
secretstringrequired
The secret value.
expires_atstring
ISO 8601 expiry of the secret.
tenant_idstring
The client's tenant GUID, for a client with no tenant yet.
Requestbash
curl -X PUT https://api.scute.io/v1/workspaces/$SCUTE_WORKSPACE_ID/entra/approve-setup/clients/contoso/secret \  -H "Authorization: Bearer $SCUTE_WORKSPACE_KEY" \  -H "X-Authorization: Bearer $SCUTE_M2M_TOKEN" \  -H "Content-Type: application/json" \  -d '{ "secret": "...", "expires_at": "2027-10-06T00:00:00Z" }'
Response 200json
{ "ok": true, "client": { "slug": "contoso", "status": "ready" } }
Statuserror_codeWhen
422missing_secretNo secret.
422invalid_expires_atexpires_at is not an ISO 8601 timestamp.
422secret_rejectedMicrosoft refused the secret. The stored one is kept. details.microsoft_code may say why.

Connect a client to its tenant#

Links a client to its tenant without creating the secret, the same link the first user synced with a tid makes. When the tenant has already consented to Application.ReadWrite.All, automatic setup starts in the background. Calling it again for the same tenant changes nothing.

PUT/v1/workspaces/:workspace_id/entra/approve-setup/clients/:client/tenantWorkspace key + M2M token
workspace_idstringrequired
Master or MSP workspace UUID or slug.
clientstringrequired
Client workspace or client app.
tenant_idstringrequired
The client's tenant GUID.
Requestbash
curl -X PUT https://api.scute.io/v1/workspaces/$SCUTE_WORKSPACE_ID/entra/approve-setup/clients/contoso/tenant \  -H "Authorization: Bearer $SCUTE_WORKSPACE_KEY" \  -H "X-Authorization: Bearer $SCUTE_M2M_TOKEN" \  -H "Content-Type: application/json" \  -d '{ "tenant_id": "c87af060-e83b-4ed4-bf27-1d6ac3584c90" }'
Response 200json
{ "ok": true, "connected": true, "auto_setup_queued": true, "client": { "slug": "contoso", "status": "not_set_up", "tenant_id": "c87af060-e83b-4ed4-bf27-1d6ac3584c90" } }
Statuserror_codeWhen
422missing_tenant_idNo tenant_id.

Workspace calls#

These calls act on the workspace in the path and its own tenant. They take an app key or workspace key in Authorization and an M2M token from an app in that workspace in X-Authorization. With a member JWT instead, provisioning and the setup command take an owner or admin.

Get approve/deny status#

GET/v1/workspaces/:workspace_id/entra/mfa-approveAPI key + M2M token
workspace_idstringrequired
Workspace UUID or slug.
refreshboolean
Query. Ask Microsoft again instead of reusing the last answer.
Requestbash
curl https://api.scute.io/v1/workspaces/$SCUTE_WORKSPACE_ID/entra/mfa-approve \  -H "Authorization: Bearer $SCUTE_WORKSPACE_KEY" \  -H "X-Authorization: Bearer $SCUTE_M2M_TOKEN"
Response 200json
{  "feature_enabled": true,  "ready": true,  "status_detail": null,  "enabled": true,  "expires_at": "2027-10-06T00:00:00Z",  "renews_at": "2027-09-06T00:00:00Z",  "checked_at": "2026-11-19T08:00:00Z",  "last_error": null,  "last_error_at": null}

While the feature is off: { "feature_enabled": false, "ready": false, "enabled": false }. A workspace with no tenant (a Master or MSP) answers ready: false with the other fields null.

Provision the workspace's secret#

POST/v1/workspaces/:workspace_id/entra/mfa-approve/provisionAPI key + M2M token
workspace_idstringrequired
Workspace UUID or slug.
Requestbash
curl -X POST https://api.scute.io/v1/workspaces/$SCUTE_WORKSPACE_ID/entra/mfa-approve/provision \  -H "Authorization: Bearer $SCUTE_WORKSPACE_KEY" \  -H "X-Authorization: Bearer $SCUTE_M2M_TOKEN"
Response 200json
{ "ok": true, "ready": true }
StatusWhen
404The workspace is not connected (errors: "Not connected").
422needs_manual: true: the app may not create the secret. Otherwise error and microsoft_code say what Microsoft refused.

Get the workspace's setup command#

GET/v1/workspaces/:workspace_id/entra/mfa-approve/setup-commandAPI key + M2M token
workspace_idstringrequired
Workspace UUID or slug.
Requestbash
curl https://api.scute.io/v1/workspaces/$SCUTE_WORKSPACE_ID/entra/mfa-approve/setup-command \  -H "Authorization: Bearer $SCUTE_WORKSPACE_KEY" \  -H "X-Authorization: Bearer $SCUTE_M2M_TOKEN"
Response 200json
{  "command": "$ErrorActionPreference=\"Stop\"; Connect-MgGraph -Scopes Application.ReadWrite.All -NoWelcome -TenantId \"c87af060-...\"; ...",  "callback_url": "https://api.scute.io/v1/auth/entra/mfa-approve-callback",  "setup_token": "...",  "expires_in": 1800}
StatusWhen
404The workspace is not connected (errors: "Not connected").