Skip to content
Leadtime
English
Esc
navigateopen⌘Jpreview

Create an OAuth connect URL for a Claude Managed custom MCP server

POST/agents/{id}/claude/managed-mcp/oauth-connect-url
Authorization
AuthorizationOAuth2 access token · headerrequired
Scopes:api:write
or
AuthorizationBearer token (JWT) · headerrequired
Path parameters
idstringrequired
Request body
requiredapplication/json
serverClaudeManagedMcpServerDtorequired
Show properties
authModestring
Authentication mode for this MCP server.
Allowed:nonebeareroauth
bearerTokenstring | null
Bearer token to store for bearer-token MCP servers.
credentialConfiguredboolean
Whether Leadtime already has a stored credential for this MCP server.
idstring
Stable local id for an existing MCP row.
namestring
Display name for the MCP server. If omitted, Leadtime derives one from the URL.
oauthCredentialobject | null
OAuth credential details for an OAuth MCP server.
Show properties
accessTokenstring | null
clientIdstring | null
clientSecretstring | null
expiresAtstring | null
refreshTokenstring | null
scopestring | null
tokenEndpointstring | null
tokenEndpointAuthTypestring | null
Allowed:noneclient_secret_basicclient_secret_post
urlstringrequired
Hosted MCP server URL.
Responses
201
401Unauthorized - Invalid or missing authentication token
403Forbidden - Insufficient API scopes or permissions
Request
curl -X POST "https://leadtime.app/api/public/agents/string/claude/managed-mcp/oauth-connect-url" \
  -H "Authorization: Bearer YOUR_ACCESS_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
  "server": {
    "authMode": "none",
    "bearerToken": "string",
    "credentialConfigured": true,
    "id": "string",
    "name": "string",
    "oauthCredential": {
      "accessToken": "string",
      "clientId": "string",
      "clientSecret": "string",
      "expiresAt": "string",
      "refreshToken": "string",
      "scope": "string",
      "tokenEndpoint": "string",
      "tokenEndpointAuthType": "none"
    },
    "url": "string"
  }
}'
Response
No example response.