MetorialDocs

Provider Auth Methods

An auth method defines one way to authenticate with a provider (OAuth, API token, or custom credentials). A provider version may support multiple auth methods.

The Provider Auth Method object

provider_auth_method.json
{
  "object": "provider.capabilities.auth_method",
  "id": "pam_2mNpQrStUvWxYzAb",
  "type": "oauth",
  "key": "oauth2",
  "name": "OAuth 2.0",
  "description": "Authenticate using OAuth 2.0",
  "capabilities": {},
  "input_schema": {
    "type": "json_schema",
    "schema": {}
  },
  "output_schema": {
    "type": "json_schema",
    "schema": {}
  },
  "scopes": [
    {
      "object": "provider.capabilities.auth_method.scope",
      "id": "pams_8tUvWxYzAbCdEfGh",
      "scope": "repo",
      "name": "Repository Access",
      "description": "Full control of private repositories"
    },
    {
      "object": "provider.capabilities.auth_method.scope",
      "id": "pams_8tUvWxYzAbCdEfGh",
      "scope": "repo",
      "name": "Repository Access",
      "description": "Full control of private repositories"
    }
  ],
  "adapters": [
    "example_adapters"
  ],
  "provider_id": "pro_5gHjKlMnPqRsTuVw",
  "provider_specification_id": "psp_9gHjKlMnPqRsTuVw",
  "created_at": "2025-09-15T10:30:00.000Z",
  "updated_at": "2026-01-10T14:45:00.000Z"
}
object"provider.capabilities.auth_method"required
idstringrequired
type"oauth" | "token" | "custom"required
keystringrequired
namestringrequired
descriptionstringrequirednullable
capabilitiesRecord<string, any>required
adaptersstring[]requirednullable
provider_idstringrequired
provider_specification_idstringrequired
created_atdaterequired
updated_atdaterequired

Endpoints

List provider auth methods

GET/provider-auth-methods

Returns a paginated list of provider auth methods.

Query parameters

provider_version_idstringrequired
adapterstringoptional

Example request

curl -X GET "https://api.metorial.com/provider-auth-methods" \
  -H "Authorization: Bearer metorial_sk_io2h4..."

Get provider auth method

GET/provider-auth-methods/:provider_auth_method_id

Retrieves a specific provider auth method by ID.

Path parameters

provider_auth_method_idstringrequired

The unique identifier for the provider_auth_method

Example request

curl -X GET "https://api.metorial.com/provider-auth-methods/pro_Rm4Mnheq2bfEPhBhP7SY" \
  -H "Authorization: Bearer metorial_sk_io2h4..."