# List providers List all AI providers configured for an organization. ## Path parameters **`organization_id`** string required Organization ID (org_ prefixed string). ## Query parameters **`active_only`** boolean optional Only return active providers. Default: `false`. ## Returns Array of [Provider](#provider-object) objects. ```bash curl "https://api.aitronos.com/v1/organizations/org_abc123/providers" \ -H "X-API-Key: $FREDDY_API_KEY" ``` ```python import os import requests api_key = os.environ["FREDDY_API_KEY"] org_id = "org_abc123" response = requests.get( f"https://api.aitronos.com/v1/organizations/{org_id}/providers", headers={"X-API-Key": api_key} ) providers = response.json() for provider in providers: status = "Active" if provider['is_active'] else "Inactive" print(f"{provider['provider_name']}: {status}") ``` ```javascript const orgId = "org_abc123"; const response = await fetch( `https://api.aitronos.com/v1/organizations/${orgId}/providers`, { headers: { "X-API-Key": process.env.FREDDY_API_KEY } } ); const providers = await response.json(); providers.forEach(provider => { const status = provider.is_active ? "Active" : "Inactive"; console.log(`${provider.provider_name}: ${status}`); }); ``` **Response:** 200 OK ```json [ { "provider_name": "openai", "is_active": true, "has_credentials": true, "provider_org_id": "org-xyz", "provider_project_id": "proj-abc", "created_at": "2025-01-15T10:30:00Z", "updated_at": "2025-12-07T14:20:00Z" }, { "provider_name": "anthropic", "is_active": true, "has_credentials": false, "provider_org_id": null, "provider_project_id": null, "created_at": "2025-01-15T10:30:00Z", "updated_at": "2025-12-07T14:20:00Z" }, { "provider_name": "google", "is_active": false, "has_credentials": false, "provider_org_id": null, "provider_project_id": null, "created_at": "2025-01-15T10:30:00Z", "updated_at": "2025-12-07T14:20:00Z" } ] ``` 401 Unauthorized ```json { "success": false, "error": { "code": "AUTHENTICATION_REQUIRED", "message": "Authentication required", "system_message": "User authentication required", "type": "client_error", "status": 401, "trace_id": "abc-123-def", "timestamp": "2025-12-07T10:30:00Z" } } ``` 403 Forbidden ```json { "success": false, "error": { "code": "ORGANIZATION_ACCESS_DENIED", "message": "You are not a member of this organization", "system_message": "Organization access denied", "type": "client_error", "status": 403, "details": { "organization_id": "org_abc123" }, "trace_id": "abc-123-def", "timestamp": "2025-12-07T10:30:00Z" } } ``` ## Provider object ```json { "provider_name": "openai", "is_active": true, "has_credentials": true, "provider_org_id": "org-xyz", "provider_project_id": "proj-abc", "created_at": "2025-01-15T10:30:00Z", "updated_at": "2025-12-07T14:20:00Z" } ```