Skip to documentation content
Docs
Documentation navigation

Previous version v1

You are viewing an earlier version of the API documentation: v1. View the current documentation

API
v1
6 min read
Deprecated

Create a Website text session token

Historical v1 endpoint for creating a short-lived Website text session token.

UpdatedByTalkIt Docs team
Removed in v2
On this page

This historical endpoint accepted Website integration credentials through HTTP Basic authentication and created a token for the text channel. Use the current v2 session-grant contract for new integrations.

Contract source

Generated from content/docs/sources/openapi/website-session-grants/v1.openapi.yaml.

Download the OpenAPI specification

POST /channels-text/public/session-tokens

Create a short-lived token for a Website text WebSocket connection.

Authentication

Send the Website integration client ID and client secret using HTTP Basic authentication.

cURL example

BASH
curl --request POST \
  --url https://your-dedicated-domain.example/channels-text/public/session-tokens \
  --user "$TALKIT_CLIENT_ID:$TALKIT_CLIENT_SECRET"

Request body

This operation has no request body.

Responses

StatusDescription
200The text session token was created.
401The HTTP Basic credentials are missing or invalid.
403The Website integration or linked text agent is unavailable.
404The Website integration or linked resource does not exist.
500TalkIt could not create the token.

Response example

JSON
{
  "success": true,
  "data": {
    "sessionToken": "short-lived-one-use-token",
    "websocketUrl": "wss://your-dedicated-domain.example/channels-text/public/_ws",
    "expiresAt": "2026-08-03T12:00:00.000Z"
  }
}

Schemas

WebsiteTextSessionToken

FieldTypeRequiredDescription
sessionTokenstringYesShort-lived token for one text WebSocket connection.
websocketUrlstring (uri)YesWebSocket URL for the public text channel.
expiresAtstring (date-time)YesISO 8601 expiration time for the token.

SuccessEnvelope

FieldTypeRequiredDescription
successtrueYesIndicates that the request succeeded.
dataWebsiteTextSessionTokenYesThe newly issued text session token.

Was this page helpful?

Page feedback is not available right now.