Skip to main content
POST
/
api
/
local
/
link-token
Local linking
curl --request POST \
  --url https://api.compose.market/api/local/link-token \
  --header 'Content-Type: application/json' \
  --header 'x-session-user-address: <x-session-user-address>' \
  --data '
{
  "userAddress": "<string>",
  "agentWallet": "<string>",
  "agentCardCid": "<string>",
  "chainId": 123,
  "deviceId": "<string>",
  "token": "<string>",
  "connectedUserAddress": "<string>"
}
'

Documentation Index

Fetch the complete documentation index at: https://docs.compose.market/llms.txt

Use this file to discover all available pages before exploring further.

Local linking routes bind the web session, local device, agent wallet, and active session context.

Routes

MethodPathDescription
POST/api/local/link-tokenCreates a short-lived local link token.
POST/api/local/link-token/redeemRedeems a local link token from a device.
POST/api/local/deployments/registerRegisters a local deployment for an active session.
userAddress
string
required
Wallet address. Must match x-session-user-address.
agentWallet
string
Agent wallet address.
agentCardCid
string
Agent card CID-like identifier.
chainId
number
Chain ID. Defaults to the active chain.
deviceId
string
Optional local device ID. When present, the link token is local-first and bound to the device.

Redeem body

token
string
required
Link token returned by /api/local/link-token.
deviceId
string
required
Local device ID.
connectedUserAddress
string
Optional connected wallet check.

Headers

x-session-user-address
string
required
Must match the userAddress body field.
Authorization
string
Optional for link-token creation, required for deployment registration. When present, it must be a valid active session Compose Key.