Skip to content
Skip to Content
Coder Docs

Authenticate agent on Azure instance

POST
/api/v2/workspaceagents/azure-instance-identity

Authorization

CoderSessionToken
headerCoder-Session-Token<token>

Request Body

Instance identity token. The optional agent_name field disambiguates when multiple agents share the same instance ID.

application/json
  1. body
agent_name?string

AgentName optionally selects a specific agent when multiple agents share the same instance identity. An empty string is treated as unspecified.

encoding*string
signature*string

Response Body

OK

application/json
  1. response
session_token?string

The samples read CODER_URL and CODER_SESSION_TOKEN: set up your environment.

curl -X POST \	"$CODER_URL/api/v2/workspaceagents/azure-instance-identity" \	-H "Coder-Session-Token: $CODER_SESSION_TOKEN" \	-H "Content-Type: application/json" \	-d '{  "encoding": "string",  "signature": "string"}'
Example Response200
{  "session_token": "string"}