Skip to content

Instantly share code, notes, and snippets.

@AlexMikhalev
Created November 25, 2025 12:35
Show Gist options
  • Select an option

  • Save AlexMikhalev/e1c39022bdf7eeb6c7557e9b8cce571a to your computer and use it in GitHub Desktop.

Select an option

Save AlexMikhalev/e1c39022bdf7eeb6c7557e9b8cce571a to your computer and use it in GitHub Desktop.
co-agent-log

curl -X POST http://localhost:3000/api/v1/providers
-H "Content-Type: application/json"
-d '{ "name": "My OpenAI Provider", "type": "openai", "api_key": "sk-your-api-key-here", "available_models": ["gpt-4", "gpt-3.5-turbo", "gpt-4-turbo"], "custom_url": null }'

The endpoint supported in the coagent server and accepts a JSON body with:

id (optional): UUID identifier - auto-generated if not provided name (required): Display name for the provider type (required): Provider type (e.g., "openai", "anthropic", "azure") api_key (optional): API authentication key available_models (optional): Array of model identifiers available from this provider custom_url (optional): Custom endpoint URL for the provider

Successful response (201 Created): { "id": "550e8400-e29b-41d4-a716-446655440000", "name": "My OpenAI Provider", "message": "Provider created successfully" }

Other useful endpoints:

List all providers: curl http://localhost:3000/api/v1/providers

Get specific provider: curl http://localhost:3000/api/v1/providers/%7Bprovider-id%7D

Get available models for a provider: curl http://localhost:3000/api/v1/providers/%7Bprovider-id%7D/models

Update provider: curl -X PUT http://localhost:3000/api/v1/providers/%7Bprovider-id%7D
-H "Content-Type: application/json"
-d '{...}'

Delete provider: curl -X DELETE http://localhost:3000/api/v1/providers/%7Bprovider-id%7D Deb — 18/11/2025, 16:16 @Alexander Mikhalev - @Alan (Infinyon) has added the docs on the logging API in the examples - https://github.com/coa-dev/try-coagent/blob/main/examples/logging-api-tutorial.hurl

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment