Skip to main content
POST
/
v1
/
embed
/
sessions
/
refresh
Refresh an embed session
curl --request POST \
  --url https://api.craftkit.dev/v1/embed/sessions/refresh \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "renewToken": "rt_abc123"
}
'
{
  "session_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "session_token": "<string>",
  "iframe_url": "<string>",
  "expires_at": "2023-11-07T05:31:56Z",
  "renew_token": "<string>"
}

Authorizations

Authorization
string
header
required

Project API key (ck_live_… or ck_test_…) presented as a bearer token. For embed partner endpoints this is the partner secret key, which is the same credential type.

Body

application/json
renewToken
string
required
Minimum string length: 8

Response

Session rotated.

snake_case response from session mint/refresh.

session_id
string<uuid>
required
session_token
string
required
iframe_url
string<uri>
required
expires_at
string<date-time>
required
renew_token
string
required