Creates a new question-and-answer pair for a chatbot agent's knowledge base.
Authorization
bearerAuth AuthorizationBearer <token>
API key with fp_ prefix. Generate keys in your Fetchply dashboard under Settings > API Keys.
In: header
Path Parameters
id*string
The chatbot agent ID.
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
curl -X POST "https://fetchply.com/api/v1/agents/string/qa-pairs" \ -H "Content-Type: application/json" \ -d '{ "question": "string", "answer": "string" }'{
"success": true,
"data": {
"id": 0,
"question": "string",
"answer": "string"
}
}{
"success": false,
"error": "Invalid or missing API key"
}{
"success": false,
"error": "Resource not found"
}{
"success": false,
"error": "Rate limit exceeded"
}