Agents in an organization can subscribe to be notified whenever someone in their organization submits a ticket. The agents will be notified as long as they're allowed to see all tickets or the organization's tickets. See Setting agent privileges and defining ticket access in the Zendesk Support knowledge base.

End users can also subscribe to be notified if they're members of a shared organization. See Setting up a shared organization for end-users and Viewing and editing a user's profile in the knowledge base.

JSON Format

Organization Subscriptions are represented as JSON objects with the following properties:

Name Type Read-only Mandatory Description
created_at string false false The date the organization subscription was created
id integer false false The ID of the organization subscription
organization_id integer false false The ID of the organization
user_id integer false false The ID of the user

Example

{  "created_at": "2009-07-20T22:55:29Z",  "id": 1234,  "organization_id": 32,  "user_id": 482}

List Organization Subscriptions

  • GET /api/v2/organization_subscriptions
  • GET /api/v2/organizations/{organization_id}/subscriptions
  • GET /api/v2/users/{user_id}/organization_subscriptions

Pagination

  • Cursor pagination (recommended)
  • Offset pagination

See Pagination.

Returns a maximum of 100 records per page.

Allowed For:

  • Agents
  • End users

For end users, the response will only list the subscriptions created by the requesting end user.

Using cURL

curl https://{subdomain}.zendesk.com/api/v2/organization_subscriptions.json \  -v -u {email_address}:{password}

Example Response

Status 200 OK
{  "organization_subscriptions": [    {      "created_at": "2009-07-20T22:55:29Z",      "id": 1234,      "organization_id": 32,      "user_id": 482    },    {      "created_at": "2011-08-22T21:12:09Z",      "id": 43681,      "organization_id": 334,      "user_id": 49471    }  ]}

Show Organization Subscription

  • GET /api/v2/organization_subscriptions/{organization_subscription_id}

Allowed For:

  • Agents
  • End users

For end users, the response will only list the subscriptions created by the requesting end user.

Parameters

Name Type In Required Description
organization_subscription_id integer Path true The ID of the organization subscription

Using cURL

curl https://{subdomain}.zendesk.com/api/v2/organization_subscriptions/{organization_subscription_id}.json \  -v -u {email_address}:{password}

Example Response

Status 200 OK
{  "organization_subscription": {    "created_at": "2009-07-20T22:55:29Z",    "id": 1234,    "organization_id": 32,    "user_id": 482  }}

Create Organization Subscription

  • POST /api/v2/organization_subscriptions

Allowed For:

  • Agents
  • End users

End users can only subscribe to shared organizations in which they're members.

Example Body

{  "organization_subscription": {    "organization_id": 32,    "user_id": 482  }}

Using cURL

curl https://{subdomain}.zendesk.com/api/v2/organization_subscriptions.json \  -d '{"organization_subscription": {"user_id": 772, "organization_id": 881}}' \  -v -u {email_address}:{password} -H "Content-Type: application/json" -X POST

Example Response

Status 200 OK
{  "organization_subscription": {    "created_at": "2009-07-20T22:55:29Z",    "id": 1234,    "organization_id": 32,    "user_id": 482  }}

Delete Organization Subscription

  • DELETE /api/v2/organization_subscriptions/{organization_subscription_id}

Allowed For:

  • Agents
  • End users

Parameters

Name Type In Required Description
organization_subscription_id integer Path true The ID of the organization subscription

Using cURL

curl https://{subdomain}.zendesk.com/api/v2/organization_subscriptions/{organization_subscription_id}.json \-v -u {email_address}:{password} -X DELETE

Example Response

Status 204 No Content