D
Druckling
Docs

Revoke an embedded editor session

DELETE
/embed_sessions/{id}

Ends the session right away, e.g. when the user signs out of your product. The open editor reports session_revoked on its next request. Revoking twice is fine.

Authorization

headerAuthorizationBearer <token>

Authorization: Bearer dr_live_… or dr_test_…

Path Parameters

id*string

Response Body

OK

application/json
  1. response
id*string
object*unknown
url*|

Load this URL in an iframe (or pass it to mountEditor from @druckling/embed). Returned only when the session is created. The session token sits in the fragment (#token=…), which browsers never send to servers; Druckling keeps only a hash of it. Hand the URL to the signed-in user's browser only, never log or cache it.

template*string

Slug of the template the session edits.

permissions*

What the editor offers beyond editing the draft.

user*|

Your user, as you described them.

theme*
status*string
Value in"active""expired""revoked"
expires_at*string
Formatdate-time
revoked_at*|null
test_mode*boolean
created_at*string
Formatdate-time
Example Request
curl -X DELETE 'https://druckling-nine.vercel.app/v1/embed_sessions/string'
Example Response200
{  "id": "string",  "object": "embed_session",  "url": "string",  "template": "string",  "permissions": {    "publish": true,    "assistant": true  },  "user": {    "id": "string",    "name": "string"  },  "theme": {    "mode": "light",    "accent": "string"  },  "status": "active",  "expires_at": "2019-08-24T14:15:22Z",  "revoked_at": "2019-08-24T14:15:22Z",  "test_mode": true,  "created_at": "2019-08-24T14:15:22Z"}