> For clean Markdown of any page, append .md to the page URL. > For a complete documentation index, see https://docs.airweave.ai/api-reference/source-connections/get-source-connections-source-connection-id-get/llms.txt. > For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.airweave.ai/_mcp/server. # Get Source Connection GET https://api.airweave.ai/source-connections/{source_connection_id} Retrieve details of a specific source connection. Returns complete information about the connection including: - Configuration settings - Authentication status - Sync schedule and history - Entity statistics Reference: https://docs.airweave.ai/api-reference/source-connections/get-source-connections-source-connection-id-get ## Authentication - `x-api-key` header (required) — API Key authentication via header ## Servers - `https://api.airweave.ai` (Production, default) - `http://localhost:8001` (Local) ## Request ### Path parameters - `source_connection_id` (string, required) — Unique identifier of the source connection (UUID) ## Response ### 200 Source connection details - `id` (string, required) — Unique identifier of the source connection - `organization_id` (string, required) — Organization this connection belongs to - `name` (string, required) — Display name of the connection - `short_name` (string, required) — Source type identifier - `readable_collection_id` (string, required) — Collection this connection belongs to - `status` (enum, required) — Current operational status of the connection - Allowed values: `active`, `pending_auth`, `syncing`, `error`, `needs_reauth`, `inactive`, `pending_sync` - `created_at` (string, required) — When the connection was created (ISO 8601) - `modified_at` (string, required) — When the connection was last modified (ISO 8601) - `auth` (AuthenticationDetails, required) — Authentication status and details - `description` (string, optional, nullable) — Optional description of the connection's purpose - `config` (map from string to any, optional, nullable) — Source-specific configuration values - `schedule` (ScheduleDetails, optional, nullable) — Sync schedule configuration - `sync` (SyncDetails, optional, nullable) — Sync execution history and statistics - `sync_id` (string, optional, nullable) — ID of the associated sync (internal use) - `entities` (EntitySummary, optional, nullable) — Summary of synced entities by type - `error_category` (enum, optional, nullable) — Error category when status is needs_reauth (e.g. oauth_credentials_expired) - Allowed values: `oauth_credentials_expired`, `api_key_invalid`, `auth_provider_account_gone`, `auth_provider_credentials_invalid`, `usage_limit_exceeded`, `rate_limited` - `error_message` (string, optional, nullable) — Human-readable error message when status is needs_reauth - `provider_settings_url` (string, optional, nullable) — URL to the auth provider's settings dashboard (for auth_provider errors) - `provider_short_name` (string, optional, nullable) — Auth provider short_name (e.g. 'composio', 'pipedream') for display - `federated_search` (boolean, optional, default: false) — Whether this source uses federated (real-time) search instead of syncing ## Errors ### 404 Not Found Error Source Connection Not Found - `detail` (string, required) — Error message describing what was not found ### 422 Unprocessable Entity Error Validation Error - `detail` (list of ValidationError, optional) ### 429 Too Many Requests Error Rate Limit Exceeded - `detail` (string, required) — Error message explaining the rate limit ## Types ### AuthenticationDetails Authentication information. - `method` (enum, required) — Authentication methods for source connections. - Allowed values: `direct`, `oauth_browser`, `oauth_token`, `oauth_byoc`, `auth_provider` - `authenticated` (boolean, required) - `authenticated_at` (string, optional, nullable) - `expires_at` (string, optional, nullable) - `auth_url` (string, optional, nullable) — For pending OAuth flows - `auth_url_expires` (string, optional, nullable) - `redirect_url` (string, optional, nullable) - `claim_token` (string, optional, nullable) — One-time token to verify OAuth flow ownership. Only returned when creating an OAuth browser connection. - `provider_readable_id` (string, optional, nullable) - `provider_id` (string, optional, nullable) ### ScheduleDetails Schedule information. - `cron` (string, optional, nullable) - `next_run` (string, optional, nullable) - `continuous` (boolean, optional, default: false) - `cursor_field` (string, optional, nullable) ### SyncDetails Sync execution details. - `total_runs` (integer, optional, default: 0) - `successful_runs` (integer, optional, default: 0) - `failed_runs` (integer, optional, default: 0) - `last_job` (SyncJobDetails, optional, nullable) — Sync job details. ### EntitySummary Entity state summary. - `total_entities` (integer, optional, default: 0) - `by_type` (map from string to EntityTypeStats, optional) - `entity_id` (string, optional) - `name` (string, optional) - `entity_type` (string, optional) - `source_name` (string, optional) - `relevance_score` (double, optional, nullable) ### ValidationError - `loc` (list of ValidationErrorLocItems, required) - `msg` (string, required) - `type` (string, required) ### SyncJobDetails Sync job details. - `id` (string, required) - `status` (enum, required) — Sync job status enum. - Allowed values: `created`, `pending`, `running`, `completed`, `failed`, `cancelling`, `cancelled` - `started_at` (string, optional, nullable) - `completed_at` (string, optional, nullable) - `duration_seconds` (double, optional, nullable) - `entities_inserted` (integer, optional, default: 0) - `entities_updated` (integer, optional, default: 0) - `entities_deleted` (integer, optional, default: 0) - `entities_failed` (integer, optional, default: 0) - `error` (string, optional, nullable) - `error_category` (enum, optional, nullable) — Error categories for credential/auth failures on source connections. - Allowed values: `oauth_credentials_expired`, `api_key_invalid`, `auth_provider_account_gone`, `auth_provider_credentials_invalid`, `usage_limit_exceeded`, `rate_limited` ### EntityTypeStats Statistics for a specific entity type. - `count` (integer, required) - `last_updated` (string, optional, nullable) ### ValidationErrorLocItems ## Examples **Response** ```json { "id": "550e8400-e29b-41d4-a716-446655440000", "organization_id": "123e4567-e89b-12d3-a456-426614174000", "name": "GitHub Docs Repo", "short_name": "github", "readable_collection_id": "documentation-ab123", "status": "active", "created_at": "2024-03-15T09:30:00Z", "modified_at": "2024-03-15T14:22:15Z", "auth": { "method": "direct", "authenticated": true, "authenticated_at": "2024-03-15T09:30:00Z" }, "description": "Main documentation repository", "config": { "branch": "main", "repo_name": "company/docs" }, "schedule": { "cron": "0 */6 * * *", "next_run": "2024-03-15T18:00:00Z" }, "sync": { "total_runs": 15, "successful_runs": 14, "failed_runs": 1, "last_job": { "id": "770e8400-e29b-41d4-a716-446655440002", "status": "created", "started_at": "2024-03-15T12:00:00Z", "completed_at": "2024-03-15T12:05:32Z", "duration_seconds": 332, "entities_inserted": 45, "entities_updated": 12 } }, "entities": { "total_entities": 1250, "by_type": { "file": { "count": 1250 } } }, "federated_search": false } ``` **SDK Code** ```python import requests url = "https://api.airweave.ai/source-connections/550e8400-e29b-41d4-a716-446655440000" headers = {"x-api-key": ""} response = requests.get(url, headers=headers) print(response.json()) ``` ```typescript import { AirweaveSDKClient } from "@airweave/sdk"; const client = new AirweaveSDKClient({ apiKey: "YOUR_API_KEY" }); await client.sourceConnections.get("550e8400-e29b-41d4-a716-446655440000"); ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api.airweave.ai/source-connections/550e8400-e29b-41d4-a716-446655440000" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("x-api-key", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api.airweave.ai/source-connections/550e8400-e29b-41d4-a716-446655440000") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["x-api-key"] = '' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api.airweave.ai/source-connections/550e8400-e29b-41d4-a716-446655440000") .header("x-api-key", "") .asString(); ``` ```php request('GET', 'https://api.airweave.ai/source-connections/550e8400-e29b-41d4-a716-446655440000', [ 'headers' => [ 'x-api-key' => '', ], ]); echo $response->getBody(); ``` ```csharp using RestSharp; var client = new RestClient("https://api.airweave.ai/source-connections/550e8400-e29b-41d4-a716-446655440000"); var request = new RestRequest(Method.GET); request.AddHeader("x-api-key", ""); IRestResponse response = client.Execute(request); ``` ```swift import Foundation let headers = ["x-api-key": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api.airweave.ai/source-connections/550e8400-e29b-41d4-a716-446655440000")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ```