Portal sessions
A short-lived token for one buyer or publisher, for your own web page to use
Needs no scope. About scopes
Needs buyers:read (or publishers:read) on the key, and :write for read_write. The token works only on that party’s Buyer or Publisher API, only from the origins named, for at most 15 minutes.
keyheader
AuthorizationBearer <traki_account_…>application/json- body
party*stringMatch
^(buyer|publisher):[0-9a-f-]{36}$origins*array<>Items
1 <= items <= 5access?stringDefault
"read"Value in
"read""read_write"ttlSeconds?integerRange
60 <= value <= 900Default
900Success
application/json- response
id*stringFormat
uuidtoken*stringparty*stringaccess*stringValue in
"read""read_write"origins*array<string>expiresAt*stringcurl -X POST 'https://api.traki.io/v1/account/portal-sessions' \ -H "Authorization: Bearer $TRAKI_KEY" \ -H 'Content-Type: application/json' \ -H 'Idempotency-Key: a-unique-id-for-this-change' \ -d '{ "party": "string", "origins": [ "string" ]}'Example Response
{ "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "token": "string", "party": "string", "access": "read", "origins": [ "string" ], "expiresAt": "string"}