The Clients API is used to store and manage an OAuth2 client for your integration.

JSON Format

Clients are represented as JSON objects with the following properties:

Name Type Read-only Mandatory Description
auth_url string false false The authorization URL of the OAuth provider
client_id string false false The client secret obtained from your OAuth provider
client_secret string false false The client secret obtained from your OAuth Provider
created_by string false false User who created the connection
default_scopes string false false A set of case-sensitive and space-delimited OAuth scopes
integration string false false The name of the integration.
token_url string false false The token URL of the OAuth provider to exchange for an access token
uuid string false false The UUID of the OAuth client

Create OAuth Client

  • POST /api/services/zis/connections/oauth/clients/{integration}

Creates an OAuth client.

Parameters

Name Type In Required Description
integration string Path true Name of the integration

Example Body

{  "auth_url": "https://client.int/auth",  "client_id": "my_client_id",  "client_secret": "my_client_secret",  "default_scopes": "read write",  "name": "my_oauth_client_name",  "token_url": "https://client.int/tokens"}

Using cURL

curl https://{subdomain}.zendesk.com/api/services/zis/connections/oauth/clients/{integration} \-H "Authorization: Bearer {access_token}" \-X POST \-H 'content-type: application/json' \-d '{  "auth_url": "https://client.int/auth",  "client_id": "my_client_id",  "client_secret": "my_client_secret",  "default_scopes": "read write",  "name": "my_oauth_client",  "token_url": "https://client.int/tokens"}'

Example Response

Status 200 OK
{  "uuid": "2fea765a-5ae4-4e3b-b457-a4f7836d041b"}

Show OAuth Client

  • GET /api/services/zis/connections/oauth/clients/{integration}/{client_uuid}

Return details for an OAuth client.

Parameters

Name Type In Required Description
client_uuid string Path true The UUID of the OAuth client
integration string Path true Name of the integration

Using cURL

curl https://{subdomain}.zendesk.com/api/services/zis/connections/oauth/clients/{integration}/{client_uuid} \-H "Authorization: Bearer {access_token}"

Example Response

Status 200 OK
{  "auth_url": "https://client.int/auth",  "client_id": "my_client_id",  "client_secret": "my_client_secret",  "created_by": "test_user",  "default_scopes": "read write",  "integration": "my_integration",  "token_url": "https://client.int/tokens",  "uuid": "2fea765a-5ae4-4e3b-b457-a4f7836d041b"}

Update OAuth Client

  • PATCH /api/services/zis/connections/oauth/clients/{integration}/{client_uuid}

Updates an OAuth client details.

Parameters

Name Type In Required Description
client_uuid string Path true The UUID of the OAuth client
integration string Path true Name of the integration

Example Body

{  "auth_url": "https://client.int/auth",  "client_id": "my_client_id",  "client_secret": "my_client_secret",  "default_scopes": "read write",  "token_url": "https://client.int/tokens"}

Using cURL

curl https://{subdomain}.zendesk.com/api/services/zis/connections/oauth/clients/{integration}/{client_uuid} \-H "Authorization: Bearer {access_token}" \-X PATCH \-H 'content-type: application/json' \-d '{  "auth_url": "https://client.int/auth",  "client_id": "my_client_id",  "client_secret": "my_client_secret",  "default_scopes": "read write",  "token_url": "https://client.int/tokens"}'

Example Response

Status 200 OK

Delete OAuth Client

  • DELETE /api/services/zis/connections/oauth/clients/{integration}/{client_uuid}

Deletes an OAuth client.

Parameters

Name Type In Required Description
client_uuid string Path true The UUID of the OAuth client
integration string Path true Name of the integration

Using cURL

curl https://{subdomain}.zendesk.com/api/services/zis/connections/oauth/clients/{integration}/{client_uuid} \-H "Authorization: Bearer {access_token}" \-X DELETE

Example Response

Status 204 No Content