Create Knowledgebase Tag
Create a new knowledgebase tag for organizing training sources. If a tag with the same name already exists in the project, the existing tag is returned. **Permission required:** Training > Write
Create a new knowledgebase tag for organizing training sources. If a tag with the same name already exists in the project, the existing tag is returned.
Permission required: Training > Write
Authorization
bearerToken
AuthorizationBearer <token>
API token for YourGPT Public APIs. Create tokens in Settings > API Tokens in your YourGPT dashboard.
In: header
Request Body
application/json
project_uid*string
Project identifier.
name*string
Tag name (auto-lowercased).
Response Body
application/json
application/json
application/json
curl -X POST "https://api.yourgpt.ai/chatbot/v1/addKnowledgebaseTag" \ -H "Content-Type: application/json" \ -d '{ "project_uid": "a1b2c3d4-e5f6-7890-abcd-ef1234567890", "name": "pricing" }'{
"type": "RXSUCCESS",
"message": "Tag added successfully",
"data": {
"id": 101,
"name": "pricing",
"project_id": 12345,
"createdAt": "2025-01-15T10:30:00.000Z",
"updatedAt": "2025-01-15T10:30:00.000Z"
}
}{
"type": "RXERROR",
"message": "string"
}{
"type": "RXERROR",
"message": "Invalid or expired API token"
}