Skip to main content
Cohere

Search documentation

Type to search this documentation.

Authorize with oAuth

POST/v1/connectors/{id}/oauth/authorizeAuthorize with oAuth

Authorize the connector with the given ID for the connector oauth app. See 'Connector Authentication' for more information.

Parameters

idstringpathrequired

The ID of the connector to authorize.

after_token_redirectstringquery

The URL to redirect to after the connector has been authorized.

X-Client-Namestringheader

The name of the project that is making the request.

Responses

200OKapplication/json
objectOAuthAuthorizeResponse
redirect_urlstring

The OAuth 2.0 redirect url. Redirect the user to this url to authorize the connector.

Example response
{
  "redirect_url": "string"
}
400This error is returned when the request is not well formed. This could be because: - JSON is invalid - The request is missing required fields - The request contains an invalid combination of fields application/json
object
idstring
messagestring
Example response
{
  "id": "string",
  "message": "string"
}
401This error indicates that the operation attempted to be performed is not allowed. This could be because: - The api token is invalid - The user does not have the necessary permissions application/json
object
idstring
messagestring
Example response
{
  "id": "string",
  "message": "string"
}
403This error indicates that the operation attempted to be performed is not allowed. This could be because: - The api token is invalid - The user does not have the necessary permissions application/json
object
idstring
messagestring
Example response
{
  "id": "string",
  "message": "string"
}
404This error is returned when a resource is not found. This could be because: - The endpoint does not exist - The resource does not exist eg model id, dataset id application/json
object
idstring
messagestring
Example response
{
  "id": "string",
  "message": "string"
}
422This error is returned when the request is not well formed. This could be because: - JSON is invalid - The request is missing required fields - The request contains an invalid combination of fields application/json
object
idstring
messagestring
Example response
{
  "id": "string",
  "message": "string"
}
429Too many requestsapplication/json
object
idstring
messagestring
Example response
{
  "id": "string",
  "message": "string"
}
498This error is returned when a request or response contains a deny-listed token. application/json
object
idstring
messagestring
Example response
{
  "id": "string",
  "message": "string"
}
499This error is returned when a request is cancelled by the user. application/json
object
idstring
messagestring
Example response
{
  "id": "string",
  "message": "string"
}
500This error is returned when an uncategorised internal server error occurs. application/json
object
idstring
messagestring
Example response
{
  "id": "string",
  "message": "string"
}
501This error is returned when the requested feature is not implemented. application/json
object
idstring
messagestring
Example response
{
  "id": "string",
  "message": "string"
}
503This error is returned when the service is unavailable. This could be due to: - Too many users trying to access the service at the same time application/json
object
idstring
messagestring
Example response
{
  "id": "string",
  "message": "string"
}
504This error is returned when a request to the server times out. This could be due to: - An internal services taking too long to respond application/json
object
idstring
messagestring
Example response
{
  "id": "string",
  "message": "string"
}
Documentation menu