Overview
PUT
/persona/provider-templates/{id}personaUpdate a provider template; optional full model-set sync (admin)
Replace a record in provider-templates by id.
Auth: bearerAuth — calls run as the authenticated user.
Parameters
- idpathstring
Request body
application/json · optional
- providerKindoptional"openai" | "anthropic" | "gemini"
- nameoptionalstring
- baseUrloptionalstring
- documentationUrloptionalstring?
- statusUrloptionalstring?
- connectionSpecoptionalProviderConnectionSpec
- modelsoptionalstring[]
Model names. On create: the initial model list. On update: the FULL desired set (matching rows kept, missing inserted, absent deleted); omit to leave models unchanged.
Example
{
"providerKind": "openai",
"name": "string",
"baseUrl": "string",
"documentationUrl": "string",
"statusUrl": "string",
"connectionSpec": {
"specVersion": 1,
"urlVars": [
{
"name": "string",
"label": "string",
"example": "string",
"secret": true
}
],
"headerVars": [
{
"header": "string",
"label": "string",
"example": "string",
"secret": true
}
],
"auth": {
"type": "bearer",
"header": "string",
"scheme": "bearer",
"region": "string",
"tokenUrl": "string"
},
"defaultQuery": {},
"extraHeaders": {}
},
"models": [
"string"
]
}Responses
200
Updated template
- idstring
- providerKind"openai" | "anthropic" | "gemini"
- namestring
- baseUrlstring
- documentationUrlstring?
- statusUrlstring?
- connectionSpecProviderConnectionSpec
- createdAtstring
- updatedAtstring
- modelsProviderTemplateModel[]
Example
{
"id": "string",
"providerKind": "openai",
"name": "string",
"baseUrl": "string",
"documentationUrl": "string",
"statusUrl": "string",
"connectionSpec": {
"specVersion": 1,
"urlVars": [
{
"name": "string",
"label": "string",
"example": "string",
"secret": true
}
],
"headerVars": [
{
"header": "string",
"label": "string",
"example": "string",
"secret": true
}
],
"auth": {
"type": "bearer",
"header": "string",
"scheme": "bearer",
"region": "string",
"tokenUrl": "string"
},
"defaultQuery": {},
"extraHeaders": {}
},
"createdAt": "string",
"updatedAt": "string",
"models": [
{
"id": "string",
"name": "string",
"createdAt": "string"
}
]
}400
Error
- erroroptionalobject
Example
{
"error": {
"message": "string",
"code": "string"
}
}401
Error
- erroroptionalobject
Example
{
"error": {
"message": "string",
"code": "string"
}
}403
Error
- erroroptionalobject
Example
{
"error": {
"message": "string",
"code": "string"
}
}404
Error
- erroroptionalobject
Example
{
"error": {
"message": "string",
"code": "string"
}
}409
Error
- erroroptionalobject
Example
{
"error": {
"message": "string",
"code": "string"
}
}Code examples
cURL
curl -X PUT "https://api.agenticdeveloperhub.com/persona/provider-templates/{id}" \
-H "Authorization: Bearer YOUR_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"providerKind": "openai",
"name": "string",
"baseUrl": "string",
"documentationUrl": "string",
"statusUrl": "string",
"connectionSpec": {
"specVersion": 1,
"urlVars": [
{
"name": "string",
"label": "string",
"example": "string",
"secret": true
}
],
"headerVars": [
{
"header": "string",
"label": "string",
"example": "string",
"secret": true
}
],
"auth": {
"type": "bearer",
"header": "string",
"scheme": "bearer",
"region": "string",
"tokenUrl": "string"
},
"defaultQuery": {},
"extraHeaders": {}
},
"models": [
"string"
]
}'JavaScript
const res = await fetch("https://api.agenticdeveloperhub.com/persona/provider-templates/{id}", {
method: "PUT",
headers: {
"Authorization": "Bearer YOUR_TOKEN",
"Content-Type": "application/json"
},
body: "{\n \"providerKind\": \"openai\",\n \"name\": \"string\",\n \"baseUrl\": \"string\",\n \"documentationUrl\": \"string\",\n \"statusUrl\": \"string\",\n \"connectionSpec\": {\n \"specVersion\": 1,\n \"urlVars\": [\n {\n \"name\": \"string\",\n \"label\": \"string\",\n \"example\": \"string\",\n \"secret\": true\n }\n ],\n \"headerVars\": [\n {\n \"header\": \"string\",\n \"label\": \"string\",\n \"example\": \"string\",\n \"secret\": true\n }\n ],\n \"auth\": {\n \"type\": \"bearer\",\n \"header\": \"string\",\n \"scheme\": \"bearer\",\n \"region\": \"string\",\n \"tokenUrl\": \"string\"\n },\n \"defaultQuery\": {},\n \"extraHeaders\": {}\n },\n \"models\": [\n \"string\"\n ]\n}",
});
const data = await res.json();