HTTP connectors

Not every API has an MCP server. An HTTP connector connects to an HTTP API and turns its endpoints into tools that agents and workflows can call. You import the OpenAPI specification of the API into Studio, and Studio creates one tool per supported operation.

This page creates an HTTP connector for the Spotify Web API as an example.

Before you start

Before you start

Gather this information about the API:

  1. Server URL: the base URL of the API, for example https://api.spotify.com/v1.
  2. Authentication method: none, an API key, or OAuth. For OAuth, find the OAuth server metadata of the API, often published at /.well-known/oauth-authorization-server, or collect the authorization endpoint, the token endpoint, and the required scopes.
  3. OpenAPI specification: a file or a public URL, in JSON or YAML. Studio supports OpenAPI 3.0, 3.1, and 3.2, not Swagger 2.0. For example, Spotify publishes its specification at https://developer.spotify.com/reference/web-api/open-api-schema.yaml.
Warning

Check the OAuth scopes before you create the connector. With wrong scopes, the OAuth consent screen fails, and the import skips the operations that need a scope missing from the connector. When the API documents its required scopes, make sure that they match the scopes_supported field of the OAuth server metadata.

Create the HTTP connector

Create the HTTP connector

  1. In Studio, go to Connectors and click + Add connector.

  2. Choose Add a custom connector.

  3. Select the HTTP protocol and enter the server URL, for example https://api.spotify.com/v1.

  4. Select the authentication method:

    • None: the API requires no authentication.

    • API key: enter the key name and value.

    • OAuth: the Advanced OAuth Settings panel opens. Fill in each field, such as the authorization endpoint, the token endpoint, and the scopes, or paste the OAuth server metadata of the API. Pasting the metadata fills in all the OAuth fields at once. For Spotify, the metadata looks like this:

      {
        "issuer": "https://accounts.spotify.com",
        "authorization_endpoint": "https://accounts.spotify.com/authorize",
        "token_endpoint": "https://accounts.spotify.com/api/token",
        "revocation_endpoint": "https://accounts.spotify.com/oauth2/revoke/v1",
        "device_authorization_endpoint": "https://accounts.spotify.com/oauth2/device/authorize",
        "response_types_supported": ["code"],
        "grant_types_supported": [
          "authorization_code",
          "refresh_token",
          "client_credentials"
        ],
        "code_challenge_methods_supported": ["S256"],
        "token_endpoint_auth_methods_supported": [
          "none",
          "client_secret_basic",
          "client_secret_post"
        ],
        "scopes_supported": [
          "user-read-email",
          "user-read-private",
          "user-read-playback-state",
          "user-modify-playback-state",
          "playlist-read-private",
          "playlist-modify-public"
        ]
      }
  5. Click Create. With OAuth, Studio redirects you to the consent screen of the API to authorize the connection.

Import the OpenAPI specification

Import the OpenAPI specification

An HTTP connector gets its tools from the OpenAPI specification. Until you import one, the connector page shows a file input and a URL input instead of the tools list.

  1. Open the page of the connector.
  2. Upload the specification file, or enter its URL, for example https://developer.spotify.com/reference/web-api/open-api-schema.yaml. The URL must be public, without authentication.
  3. In the Importing tools from OpenAPI dialog, review:
    • An extract of the specification.
    • The errors, if Studio can't process the specification.
    • The operations that become tools, and the ones that Studio can't convert, with the reason.
  4. Click Validate and add tools.
Use the connector

Use the connector

After the import, you can:

  • Use the HTTP connector in agents and workflows, like an MCP connector.
  • Turn individual tools on or off from the page of the connector.
Going further

Going further