Skip to content

Identities

View as Markdown

Create an identity under a domain the workspace may use: an active platform domain (domain_id), one of its own live custom domains (custom_domain, Team and Enterprise), or the default; it answers nobody until the owner’s wallet certifies it

Section titled “Create an identity under a domain the workspace may use: an active platform domain (domain_id), one of its own live custom domains (custom_domain, Team and Enterprise), or the default; it answers nobody until the owner’s wallet certifies it”

POST /v1/identities · operation createIdentity

Requires the batondeck:identities:manage permission (action identity:create).

Refused while the workspace is paused, suspended or on deletion hold.

Accepts an Idempotency-Key header. A repeat within 24 hours returns the first answer; the same key with different arguments is refused with idempotency_mismatch.

Parameters

Name In Type Required Notes
Idempotency-Key header string Repeat this value to retry the call without repeating its effect. ≤ 255 chars

Request body (application/json)

Field Type Required Notes
slug string yes ≥ 1 chars, ≤ 63 chars
display_name string ≤ 64 chars
domain_id string ≥ 1 chars, ≤ 64 chars
custom_domain string ≥ 1 chars, ≤ 253 chars
Request schema
{
"type": "object",
"properties": {
"slug": {
"type": "string",
"minLength": 1,
"maxLength": 63
},
"display_name": {
"type": "string",
"maxLength": 64
},
"domain_id": {
"type": "string",
"minLength": 1,
"maxLength": 64
},
"custom_domain": {
"type": "string",
"minLength": 1,
"maxLength": 253
}
},
"required": [
"slug"
],
"additionalProperties": false
}

Responses

Status Meaning
201 Create an identity under a domain the workspace may use: an active platform domain (domain_id), one of its own live custom domains (custom_domain, Team and Enterprise), or the default; it answers nobody until the owner’s wallet certifies it
400 The arguments did not validate.
401 No portal session, and no live API key.
403 The policy refused, or the request was cross-site.
404 No such resource, or none this session may see.
422 That Idempotency-Key was used with different arguments.
201 response schema
{
"type": "object",
"properties": {
"identity": {
"type": "object",
"properties": {
"account_id": {
"type": "string"
},
"slug": {
"type": "string"
},
"address": {
"type": "string"
},
"domain": {
"anyOf": [
{
"type": "object",
"properties": {
"kind": {
"type": "string",
"const": "platform"
},
"id": {
"type": "string"
},
"name": {
"type": "string"
}
},
"required": [
"kind",
"id",
"name"
],
"additionalProperties": false
},
{
"type": "object",
"properties": {
"kind": {
"type": "string",
"const": "custom"
},
"hostname": {
"type": "string"
}
},
"required": [
"kind",
"hostname"
],
"additionalProperties": false
}
]
}
},
"required": [
"account_id",
"slug",
"address",
"domain"
],
"additionalProperties": false
}
},
"required": [
"identity"
],
"additionalProperties": false
}
Terminal window
curl -X POST 'https://api.batondeck.com/v1/identities' \
-H "Authorization: Bearer $BATONDECK_API_KEY" \
-H 'content-type: application/json' \
-d @body.json

GET /v1/identities · operation listIdentities

Requires the batondeck:identities:read permission (action identity:list).

Responses

Status Meaning
200 The identities in the signed-in workspace
401 No portal session, and no live API key.
403 The policy refused, or the request was cross-site.
404 No such resource, or none this session may see.
200 response schema
{
"type": "object",
"properties": {
"identities": {
"type": "array",
"items": {
"type": "object",
"properties": {
"slug": {
"type": "string"
},
"account_id": {
"type": "string"
},
"fingerprint": {
"type": "string"
},
"status": {
"type": "string"
},
"hostname": {
"type": "string"
},
"certified": {
"type": "boolean"
},
"created_at": {
"type": "number"
}
},
"required": [
"slug",
"account_id",
"fingerprint",
"status",
"hostname",
"certified",
"created_at"
],
"additionalProperties": false
}
}
},
"required": [
"identities"
],
"additionalProperties": false
}
Terminal window
curl -X GET 'https://api.batondeck.com/v1/identities' \
-H "Authorization: Bearer $BATONDECK_API_KEY"

One identity: its key fingerprint, hostname and card

Section titled “One identity: its key fingerprint, hostname and card”

GET /v1/identities/{slug} · operation getIdentity

Requires the batondeck:identities:read permission (action identity:read).

Parameters

Name In Type Required Notes
slug path string yes

Responses

Status Meaning
200 One identity: its key fingerprint, hostname and card
401 No portal session, and no live API key.
403 The policy refused, or the request was cross-site.
404 No such resource, or none this session may see.
200 response schema
{
"type": "object",
"properties": {
"slug": {
"type": "string"
},
"account_id": {
"type": "string"
},
"fingerprint": {
"type": "string"
},
"status": {
"type": "string"
},
"hostname": {
"type": "string"
},
"certified": {
"type": "boolean"
},
"created_at": {
"type": "number"
},
"card": {
"type": "string"
}
},
"required": [
"slug",
"account_id",
"fingerprint",
"status",
"hostname",
"certified",
"created_at",
"card"
],
"additionalProperties": false
}
Terminal window
curl -X GET 'https://api.batondeck.com/v1/identities/:slug' \
-H "Authorization: Bearer $BATONDECK_API_KEY"

Erase one identity: its object and its media; its address is kept for the workspace for 24 hours

Section titled “Erase one identity: its object and its media; its address is kept for the workspace for 24 hours”

DELETE /v1/identities/{slug} · operation deleteIdentity

Requires the batondeck:identities:manage permission (action identity:delete).

Over the owner MCP, taken only after the owner approves the call in the portal. Through this API, with a session or a key, it is taken as asked.

Refused while the workspace is paused, suspended or on deletion hold.

Parameters

Name In Type Required Notes
slug path string yes

Responses

Status Meaning
204 Done. No body.
401 No portal session, and no live API key.
403 The policy refused, or the request was cross-site.
404 No such resource, or none this session may see.
Terminal window
curl -X DELETE 'https://api.batondeck.com/v1/identities/:slug' \
-H "Authorization: Bearer $BATONDECK_API_KEY"

PrivacyThis site uses analytics; see Privacy.