Configure the AI bot of the brand (credentials.manage). Fields not sent keep their value.
PUT
/v1/brands/{brand}/ai/bot
const url = 'https://api.replifier.com/v1/brands/brd_01hx0000000000000000000000/ai/bot';const options = { method: 'PUT', headers: {'Content-Type': 'application/json'}, body: '{"enabled":true,"instructions":"example","channels":["whatsapp"],"handoffKeywords":["example"],"monthlyBudgetUsd":1}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request PUT \ --url https://api.replifier.com/v1/brands/brd_01hx0000000000000000000000/ai/bot \ --header 'Content-Type: application/json' \ --data '{ "enabled": true, "instructions": "example", "channels": [ "whatsapp" ], "handoffKeywords": [ "example" ], "monthlyBudgetUsd": 1 }'Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”brand
required
string
Example
brd_01hx0000000000000000000000Request Bodyrequired
Section titled “Request Bodyrequired”Media typeapplication/json
object
enabled
boolean
instructions
string
channels
Array<string>
handoffKeywords
Array<string>
monthlyBudgetUsd
number
Responses
Section titled “Responses”Updated configuration
Media typeapplication/json
object
enabled
required
Off by default. The bot also turns itself off when the monthly budget is reached.
boolean
instructions
required
Free text, up to 4000 characters: tone, business information, policies.
string
channels
required
Only whatsapp in this version.
Array<string>
handoffKeywords
required
Words that hand the conversation to a person (besides “human”, “agent” and “person” in the 12 languages).
Array<string>
monthlyBudgetUsd
required
Monthly AI spend limit for the brand, in USD (10 by default).
number
spentUsdMonth
required
Estimated spend this month, in USD.
number
budgetWarning
required
The spend reached 80 % of the limit.
boolean
updatedAt
required
string
Example
{ "channels": [ "whatsapp" ]}Invalid data
Media typeapplication/json
object
error
required
object
code
required
string
message
required
string
cause
required
string
fix
required
string
requestId
required
string
Example
{ "error": { "code": "not_found" }}No session, expired session, or invalid, expired or revoked API key
Media typeapplication/json
object
error
required
object
code
required
string
message
required
string
cause
required
string
fix
required
string
requestId
required
string
Example
{ "error": { "code": "not_found" }}Not allowed, API key missing the scope, IP not allowed, or request rejected (csrf_rejected)
Media typeapplication/json
object
error
required
object
code
required
string
message
required
string
cause
required
string
fix
required
string
requestId
required
string
Example
{ "error": { "code": "not_found" }}Does not exist or is not visible to you
Media typeapplication/json
object
error
required
object
code
required
string
message
required
string
cause
required
string
fix
required
string
requestId
required
string
Example
{ "error": { "code": "not_found" }}Internal error
Media typeapplication/json
object
error
required
object
code
required
string
message
required
string
cause
required
string
fix
required
string
requestId
required
string
Example
{ "error": { "code": "not_found" }}