The providers endpoint returns a list of all active providers with their available chat and embedding models. Use this endpoint before making search requests to get the valid provider IDs and model keys.
Endpoint
http://localhost:3000/api/providers
Replace localhost:3000 with your Perplexica instance URL if running on a different host or port.
Response
A list of all active providers with their available models. The UUID of the provider. Use this as the providerId when making search requests.
The display name of the provider (e.g., “OpenAI”, “Ollama”).
Available chat models for this provider. The display name of the model (e.g., “GPT 4 Omni Mini”).
The model key/identifier (e.g., gpt-4o-mini). Use this value in the chatModel.key field when making search requests.
Available embedding models for this provider. The display name of the model (e.g., “Text Embedding 3 Large”).
The model key/identifier (e.g., text-embedding-3-large). Use this value in the embeddingModel.key field when making search requests.
Request example
curl http://localhost:3000/api/providers
Response example
{
"providers" : [
{
"id" : "550e8400-e29b-41d4-a716-446655440000" ,
"name" : "OpenAI" ,
"chatModels" : [
{
"name" : "GPT 4 Omni Mini" ,
"key" : "gpt-4o-mini"
},
{
"name" : "GPT 4 Omni" ,
"key" : "gpt-4o"
}
],
"embeddingModels" : [
{
"name" : "Text Embedding 3 Large" ,
"key" : "text-embedding-3-large"
}
]
}
]
}
Use the id field as the providerId and the key field from the models arrays when making search requests.
Error responses
Returned if an error occurs while fetching providers.