Skip to main content
POST
Toggle AI on/off for a phone number (superadmin)

Authorizations

Authorization
string
header
required

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

Body

application/json
userId
string
required

User whose voicePhoneNumbers entry is being toggled.

phoneNumber
string
required

Exact phone number string to match against voicePhoneNumbers.phoneNumber.

aiEnabled
boolean
required
aiAgentId
string

Prompt._id to link when enabling AI. Required to switch agents on an already-AI-enabled number.

Response

Toggle applied

success
enum<boolean>
required
Available options:
true
message
string