---
title: "Register a connector"
method: POST
path: "/v1/connectors"
tags: ["Connectors"]
---

# Register a connector

`POST /v1/connectors`

## Request

- Base URL: `https://api.spacefast.com`
- URL: `https://api.spacefast.com/v1/connectors`
- Auth: one of:
  - HTTP bearer
  - OAuth 2 (authorization code, authorization URL `https://api.spacefast.com/v1/auth/oauth2/authorize`, token URL `https://api.spacefast.com/v1/auth/oauth2/token`; client credentials, token URL `https://api.spacefast.com/v1/auth/oauth2/token`, scopes: `connectors:write`)

Fetches the source, parses it, dispatches to the plugin that owns it, and syncs the tool catalog — one call. Passing a `presetId` from the catalog resolves the source for you. GraphQL catalog registration preserves credential headers; an explicit API-key method on a custom GraphQL source uses Authorization: Bearer. An MCP endpoint is asked how it authenticates, so a server that wants OAuth gets an OAuth connector; `authMethods` overrides what it answers.

## Query parameters

- `team` string: Team id or slug to act for. Required only when the credential could act for more than one team.

## Request body

- object
  - `slug` string, required: Team-unique slug. Also the namespace its tools hang off, so keep it short.
  - `title` string, required: Display name. Defaults to whatever the source calls itself.
  - `description` string: What this connector reaches, in one line. Agent-visible.
  - `presetId` string: Catalog row supplying the source and authentication recipe. An explicit source overrides its endpoint and must use the same kind.
  - `source` union: Required unless `presetId` names a catalog row that carries it.
    - object
      - `kind` 'openapi', required
      - `specUrl` string, uri: URL of the OpenAPI document to fetch.
      - `spec` object: Inline OpenAPI document, when there is no URL to fetch.
      - `baseUrl` string, uri: Override the server URL the spec declares.
    - object
      - `kind` 'graphql', required
      - `endpoint` string, uri, required: GraphQL endpoint to introspect.
    - object
      - `kind` 'mcp', required
      - `endpoint` string, uri, required: Remote MCP endpoint. stdio servers cannot be reached from a hosted product.
  - `authMethods` union[]: Omit to derive authentication from the source's own declared security schemes.
    - union: One way to authenticate a connector. A connector may offer several, so a connect call names the one it means.
      - object
        - `kind` 'api_key', required
        - `slug` string, required: Names this method when a connector offers more than one.
        - `label` string, required: What to call it in a connect form, in the provider's own words.
      - object
        - `kind` 'oauth2', required
        - `slug` string, required: Names this method when a connector offers more than one.
        - `label` string, required: What to call it in a connect form, in the provider's own words.
        - `scopes` string[], required: Scopes requested at authorization unless the caller narrows them.
        - `clientIdMetadataDocument` boolean: Whether the provider supports public clients identified by a metadata-document URL.
        - `dynamicRegistration` boolean, required: Whether the provider supports RFC 7591 dynamic client registration, so no client has to be pre-created.
      - object
        - `kind` 'none', required
        - `slug` string, required: Names this method when a connector offers more than one.
        - `label` string, required: What to call it in a connect form.
      - object
        - `kind` 'first_party', required
        - `slug` string, required: Names this method when a connector offers more than one.
        - `label` string, required: What to call it in a connect form.
        - `provider` string, required: Existing Spacefast credential this connector borrows, e.g. the GitHub App installation. Nothing to enter.
  - `specOverrides` object[]: RFC 6902 JSON Patch operations applied to the fetched spec before tools are built.

## Response `201`

Response for status 201

- object
  - `$schema` string, uri: Canonical JSON Schema URL for this response body. The server also sends it in the `Link: rel="describedby"` response header.
  - `data` object, required: A tool source registered for one team.
    - `slug` string, required: Stable, team-unique connector slug. Also the namespace tools hang off.
    - `title` string, required: Display name, seeded from the source spec.
    - `description` string, nullable, required: What this connector reaches, in one line. Agent-visible.
    - `source` 'openapi' | 'graphql' | 'mcp', required: The kind of tool source a connector reads: an OpenAPI spec, a GraphQL endpoint, or a remote MCP server.
    - `catalogSource` union: Stored spec or endpoint for execution catalog discovery. No credentials.
      - object
        - `kind` 'openapi', required
        - `spec` string, required
        - `baseUrl` string
      - object
        - `kind` 'graphql', required
        - `endpoint` string, required
      - object
        - `kind` 'mcp', required
        - `endpoint` string, required
    - `sourceUrl` string, nullable, required: Spec, endpoint, or MCP URL this connector was built from; null when it was registered from an inline spec.
    - `firstParty` boolean, required: Built into Spacefast. First-party connectors cannot be edited or removed.
    - `presetId` string, nullable, required: Curated preset this connector was created from, when it came from the catalog.
    - `authMethods` union[], required: Every way this connector can be authenticated.
      - union: One way to authenticate a connector. A connector may offer several, so a connect call names the one it means.
        - object
          - `kind` 'api_key', required
          - `slug` string, required: Names this method when a connector offers more than one.
          - `label` string, required: What to call it in a connect form, in the provider's own words.
        - object
          - `kind` 'oauth2', required
          - `slug` string, required: Names this method when a connector offers more than one.
          - `label` string, required: What to call it in a connect form, in the provider's own words.
          - `scopes` string[], required: Scopes requested at authorization unless the caller narrows them.
          - `clientIdMetadataDocument` boolean: Whether the provider supports public clients identified by a metadata-document URL.
          - `dynamicRegistration` boolean, required: Whether the provider supports RFC 7591 dynamic client registration, so no client has to be pre-created.
        - object
          - `kind` 'none', required
          - `slug` string, required: Names this method when a connector offers more than one.
          - `label` string, required: What to call it in a connect form.
        - object
          - `kind` 'first_party', required
          - `slug` string, required: Names this method when a connector offers more than one.
          - `label` string, required: What to call it in a connect form.
          - `provider` string, required: Existing Spacefast credential this connector borrows, e.g. the GitHub App installation. Nothing to enter.
    - `toolCount` integer, required: Tools this connector exposes after the last spec sync.
    - `connections` object[], required: Connections the calling credential may use — not every connection that exists on this connector.
      - `id` string, required: Connection id (`cxn_`). This is also the first segment of every tool address it owns.
      - `connector` string, required: Slug of the connector this connection authenticates.
      - `owner` 'team' | 'personal', required: `team` is shared with everyone on the team; `personal` is yours, and only within this team — connecting the same account for another team is another connection.
      - `serving` boolean, required
      - `displayName` string, required: What people call this connection, e.g. "Linear (support)".
      - `description` string, nullable, required: Agent-visible note on what this connection is for. Shown to models choosing between several.
      - `status` 'pending_authorization' | 'active' | 'degraded' | 'needs_reauth' | 'revoked', required: Derived connection state. Never stored, so it cannot drift from the credential it describes.
      - `identityLabel` string, nullable, required: Account label reported by the provider, when it identifies itself. Null until the first successful probe.
      - `credentialConfigured` boolean, required: Whether a usable credential is stored. The credential itself is never returned by any endpoint.
      - `authMethod` string, nullable, required: Slug of the connector auth method this connection used.
      - `scopes` string[], required: Scopes actually granted, when the provider reports them.
      - `scopesKnown` boolean: False when the provider did not report the granted scope set.
      - `isDefault` boolean, required: Whether this is the connection an agent gets when it names the connector alone.
      - `toolCount` integer, required: Tools reachable through this connection at the last sync.
      - `createdBy` string, nullable, required: User who connected it; null for first-party connections Spacefast owns.
      - `lastCheckedAt` string, date-time, nullable, required: Last health probe.
      - `revokedAt` string, date-time, nullable, required: When it was disconnected. The credential is purged; the row tombstones.
      - `createdAt` string, date-time, required
      - `updatedAt` string, date-time, required
    - `specSyncedAt` string, date-time, nullable, required: Last time the source was fetched and tools rebuilt.
    - `createdAt` string, date-time, required
    - `updatedAt` string, date-time, required

## Other responses

- `default`: Problem details (RFC 9457). Any 4xx/5xx response is one `application/problem+json` document.

---

[API](https://skmtc.dev/spacefast/apis/spacefast-api.md) · [All operations](https://skmtc.dev/spacefast/apis/spacefast-api/llms.txt) · [OpenAPI document](https://skmtc.dev/spacefast/apis/spacefast-api/revisions/bd165bc7c983?raw)
