curl --request GET \
--url https://api.yourapp.com/api/ai/user-models \
--header 'Authorization: Bearer <token>'
{
"success": true,
"ai_models": [
{
"id": "user_model_123",
"modelId": "gpt-4o",
"provider": "OpenAI",
"apiKey": "sk-...xyz",
"isDefault": true,
"createdAt": "2024-01-15T10:30:00Z"
},
{
"id": "user_model_456",
"modelId": "claude-3-5-sonnet-20241022",
"provider": "Anthropic",
"apiKey": "sk-ant-...xyz",
"isDefault": false,
"createdAt": "2024-01-14T09:20:00Z"
}
],
"embeddings": [
{
"id": "user_embed_789",
"modelId": "text-embedding-3-large",
"provider": "OpenAI",
"apiKey": "sk-...xyz",
"isDefault": true,
"createdAt": "2024-01-15T10:30:00Z"
}
]
}
Retrieves the current user’s configured AI models and credentials
curl --request GET \
--url https://api.yourapp.com/api/ai/user-models \
--header 'Authorization: Bearer <token>'
{
"success": true,
"ai_models": [
{
"id": "user_model_123",
"modelId": "gpt-4o",
"provider": "OpenAI",
"apiKey": "sk-...xyz",
"isDefault": true,
"createdAt": "2024-01-15T10:30:00Z"
},
{
"id": "user_model_456",
"modelId": "claude-3-5-sonnet-20241022",
"provider": "Anthropic",
"apiKey": "sk-ant-...xyz",
"isDefault": false,
"createdAt": "2024-01-14T09:20:00Z"
}
],
"embeddings": [
{
"id": "user_embed_789",
"modelId": "text-embedding-3-large",
"provider": "OpenAI",
"apiKey": "sk-...xyz",
"isDefault": true,
"createdAt": "2024-01-15T10:30:00Z"
}
]
}
curl --request GET \
--url https://api.yourapp.com/api/ai/user-models \
--header 'Authorization: Bearer <token>'
{
"success": true,
"ai_models": [
{
"id": "user_model_123",
"modelId": "gpt-4o",
"provider": "OpenAI",
"apiKey": "sk-...xyz",
"isDefault": true,
"createdAt": "2024-01-15T10:30:00Z"
},
{
"id": "user_model_456",
"modelId": "claude-3-5-sonnet-20241022",
"provider": "Anthropic",
"apiKey": "sk-ant-...xyz",
"isDefault": false,
"createdAt": "2024-01-14T09:20:00Z"
}
],
"embeddings": [
{
"id": "user_embed_789",
"modelId": "text-embedding-3-large",
"provider": "OpenAI",
"apiKey": "sk-...xyz",
"isDefault": true,
"createdAt": "2024-01-15T10:30:00Z"
}
]
}