PATCH
/
v0
/
chatbots
/
{chatbotId}
/
threads
/
{threadId}
curl --request PATCH \
  --url https://sitegpt.ai/api/v0/chatbots/{chatbotId}/threads/{threadId} \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "mode": "AI",
  "webhookUrl": "https://example.com",
  "webhookToken": "xyz",
  "chatUser": {
    "email": "abc@gmail.com",
    "name": "ABC",
    "phoneNumber": "XXXXXXXXXXX"
  }
}'
{
  "success": true,
  "message": "Updated the chatbot thread successfully",
  "data": null
}

Authorizations

Authorization
string
headerrequired

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

chatbotId
string
required

Id of the chatbot

threadId
string
required

Id of the chatbot thread

Body

application/json
mode
enum<string>

Chat mode of the thread

Available options:
AI,
AGENT
webhookUrl
string

Webhook url for the thread where all messages are forwarded to

webhookToken
string

This token will be sent in headers to the webhook url for all the messages

chatUser
object

Details of the user chatting in the thread

Response

200 - application/json
success
boolean

Indicates whether this is success response or error response

message
string

Overall message regarding the operation performed

data
object | null

Data returned from the server