Linked accounts
Base URL: https://global.miridia.io. Read Authentication and Conventions before you call these operations.
| Method | Path | Operation |
|---|---|---|
| POST | /api/auth/linked-accounts/codes | Create code |
| GET | /api/auth/linked-accounts | Get linked accounts |
| PATCH | /api/auth/linked-accounts/{id} | Rename |
| DELETE | /api/auth/linked-accounts/{id} | Revoke |
Create code
POST/api/auth/linked-accounts/codes
Access. Send a bearer token or an API key. Any signed-in member can call this operation.
Request body
Send JSON with the shape CreateLinkedAccountCodeRequest.
| Field | Type | Required | Description |
|---|---|---|---|
channel | enum LinkedAccountChannel | Yes | One of: Telegram. |
businessId | string (uuid) | Yes | |
label | string | Yes |
Response
200. Returns a SingleResult envelope. The data field is LinkedAccountCodeResponse.
curl -X POST "https://global.miridia.io/api/auth/linked-accounts/codes" \
-H "Authorization: Bearer $MIRIDIA_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"channel": "Telegram",
"businessId": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"label": "string"
}'{
"data": {
"code": "string",
"deepLink": "string",
"expiresAt": "2026-09-29T08:00:00Z"
},
"statusCode": 0,
"messages": [
"string"
]
}Get linked accounts
GET/api/auth/linked-accounts
Access. Send a bearer token or an API key. Any signed-in member can call this operation.
Response
200. Returns a JSON array. Each item is LinkedAccountResponse.
curl -X GET "https://global.miridia.io/api/auth/linked-accounts" \
-H "Authorization: Bearer $MIRIDIA_TOKEN"[
{
"id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"channel": "Telegram",
"externalDisplayName": "string",
"label": "string",
"organizationId": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"businessId": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"dateCreated": "2026-09-29T08:00:00Z",
"lastUsedAt": "2026-09-29T08:00:00Z",
"expiresAt": "2026-09-29T08:00:00Z",
"revokedAt": "2026-09-29T08:00:00Z",
"revokedReason": "UserRemoved",
"status": "Active"
}
]Rename
PATCH/api/auth/linked-accounts/{id}
Access. Send a bearer token or an API key. Any signed-in member can call this operation.
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
id | path | string (uuid) | Yes |
Request body
Send JSON with the shape UpdateLinkedAccountRequest.
| Field | Type | Required | Description |
|---|---|---|---|
label | string | Yes |
Response
200. Returns a SingleResult envelope. The data field is LinkedAccountResponse.
curl -X PATCH "https://global.miridia.io/api/auth/linked-accounts/{id}" \
-H "Authorization: Bearer $MIRIDIA_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"label": "string"
}'{
"data": {
"id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"channel": "Telegram",
"externalDisplayName": "string",
"label": "string",
"organizationId": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"businessId": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"dateCreated": "2026-09-29T08:00:00Z",
"lastUsedAt": "2026-09-29T08:00:00Z",
"expiresAt": "2026-09-29T08:00:00Z",
"revokedAt": "2026-09-29T08:00:00Z",
"revokedReason": "UserRemoved",
"status": "Active"
},
"statusCode": 0,
"messages": [
"string"
]
}Revoke
DELETE/api/auth/linked-accounts/{id}
Access. Send a bearer token or an API key. Any signed-in member can call this operation.
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
id | path | string (uuid) | Yes |
Response
200. Returns a SingleResult envelope. The data field is boolean.
curl -X DELETE "https://global.miridia.io/api/auth/linked-accounts/{id}" \
-H "Authorization: Bearer $MIRIDIA_TOKEN"{
"data": true,
"statusCode": 0,
"messages": [
"string"
]
}Models
The operations on this page use these object types. Select a type to see its fields.
LinkedAccountCodeResponse
| Field | Type | Description |
|---|---|---|
code | string | |
deepLink | string | |
expiresAt | string (date-time) |
LinkedAccountResponse
| Field | Type | Description |
|---|---|---|
id | string (uuid) | |
channel | enum LinkedAccountChannel | One of: Telegram. |
externalDisplayName | string | |
label | string | |
organizationId | string (uuid) | |
businessId | string (uuid) | |
dateCreated | string (date-time) | |
lastUsedAt | string (date-time) | |
expiresAt | string (date-time) | |
revokedAt | string (date-time) | |
revokedReason | enum LinkedAccountRevokedReason | One of: UserRemoved, ChatUnlink, Replaced, StampChanged, UserDeactivated, MembershipRemoved. |
status | enum LinkedAccountStatus | One of: Active, Expired, Revoked. |