A job spec defines which ZIS flow should run when a trigger event occurs. It contains an event source and type, and a reference to the flow to run when the event occurs.

A job spec is scoped to a ZIS integration and its related account.

For more information about job specs, see Understanding Zendesk Integration Services.

JSON format

JobSpecs are represented as JSON objects with the following properties:

NameTypeRead-onlyMandatoryDescription
job_specsarrayfalsefalse
metaobjectfalsefalse

Install Job Spec

  • POST /api/services/zis/registry/job_specs/install?job_spec_name={job_spec_name}

Installs a job spec for a ZIS integration.

Authentication

You can authorize requests using basic authentication, an API token, or a ZIS OAuth access token. A Zendesk app can also authorize requests to this endpoint using an admin's browser session. See Making API requests from a Zendesk app.

Allowed for

  • Admins

Parameters

NameTypeInRequiredDescription
job_spec_namestringQuerytrueThe name of the job spec

Code Samples

cURL
curl https://{subdomain}.zendesk.com/api/services/zis/registry/job_specs/install?job_spec_name={job_spec_name} \-u {email_address}:{password} \-X POST
Go
import (	"fmt"	"io"	"net/http")
func main() {	url := "https://support.zendesk.com/api/services/zis/registry/job_specs/install?job_spec_name=my_job_spec"	method := "POST"	req, err := http.NewRequest(method, url, nil)
	if err != nil {		fmt.Println(err)		return	}	req.Header.Add("Content-Type", "application/json")	req.Header.Add("Authorization", "Basic <auth-value>") // Base64 encoded "username:password"
	client := &http.Client {}	res, err := client.Do(req)	if err != nil {		fmt.Println(err)		return	}	defer res.Body.Close()
	body, err := io.ReadAll(res.Body)	if err != nil {		fmt.Println(err)		return	}	fmt.Println(string(body))}
Java
import com.squareup.okhttp.*;OkHttpClient client = new OkHttpClient();HttpUrl.Builder urlBuilder = HttpUrl.parse("https://support.zendesk.com/api/services/zis/registry/job_specs/install")		.newBuilder()		.addQueryParameter("job_spec_name", "my_job_spec");RequestBody body = RequestBody.create(MediaType.parse("application/json"),		"""""");
Request request = new Request.Builder()		.url(urlBuilder.build())		.method("POST", body)		.addHeader("Content-Type", "application/json")		.addHeader("Authorization", Credentials.basic("your-email", "your-password"))		.build();Response response = client.newCall(request).execute();
Nodejs
var axios = require('axios');
var config = {  method: 'POST',  url: 'https://support.zendesk.com/api/services/zis/registry/job_specs/install',  headers: {	'Content-Type': 'application/json',	'Authorization': 'Basic <auth-value>', // Base64 encoded "username:password"  },  params: {    'job_spec_name': 'my_job_spec',  },};
axios(config).then(function (response) {  console.log(JSON.stringify(response.data));}).catch(function (error) {  console.log(error);});
Python
import requests
url = "https://support.zendesk.com/api/services/zis/registry/job_specs/install?job_spec_name=my_job_spec"headers = {	"Content-Type": "application/json",}
response = requests.request(	"POST",	url,	auth=('<username>', '<password>'),	headers=headers)
print(response.text)
Ruby
require "net/http"uri = URI("https://support.zendesk.com/api/services/zis/registry/job_specs/install")uri.query = URI.encode_www_form("job_spec_name": "my_job_spec")request = Net::HTTP::Post.new(uri, "Content-Type": "application/json")request.basic_auth "username", "password"response = Net::HTTP.start uri.hostname, uri.port, use_ssl: true do |http|	http.request(request)end

Example response(s)

200 OK
// Status 200 OK
null
400 Bad Request
// Status 400 Bad Request
{  "errors": [    {      "code": "1010",      "detail": "error message",      "status": "400"    }  ],  "message": "Unauthorized"}
401 Unauthorized
// Status 401 Unauthorized
{  "errors": [    {      "code": "1001",      "detail": "error message",      "status": "401"    }  ],  "message": "Unauthorized"}
500 Internal Server Error
// Status 500 Internal Server Error
{  "errors": [    {      "code": "1050",      "detail": "error message",      "status": "500"    }  ],  "message": "Server Error"}

Uninstall Job Spec

  • DELETE /api/services/zis/registry/job_specs/install?job_spec_name={job_spec_name}

Uninstalls a job spec for a ZIS integration.

Authentication

You can authorize requests using basic authentication, an API token, or a ZIS OAuth access token. A Zendesk app can also authorize requests to this endpoint using an admin's browser session. See Making API requests from a Zendesk app.

Allowed for

  • Admins

Parameters

NameTypeInRequiredDescription
job_spec_namestringQuerytrueThe name of the job spec

Code Samples

cURL
curl https://{subdomain}.zendesk.com/api/services/zis/registry/job_specs/install?job_spec_name={job_spec_name} \-u {email_address}:{password} \-X DELETE
Go
import (	"fmt"	"io"	"net/http")
func main() {	url := "https://support.zendesk.com/api/services/zis/registry/job_specs/install?job_spec_name=my_job_spec"	method := "DELETE"	req, err := http.NewRequest(method, url, nil)
	if err != nil {		fmt.Println(err)		return	}	req.Header.Add("Content-Type", "application/json")	req.Header.Add("Authorization", "Basic <auth-value>") // Base64 encoded "username:password"
	client := &http.Client {}	res, err := client.Do(req)	if err != nil {		fmt.Println(err)		return	}	defer res.Body.Close()
	body, err := io.ReadAll(res.Body)	if err != nil {		fmt.Println(err)		return	}	fmt.Println(string(body))}
Java
import com.squareup.okhttp.*;OkHttpClient client = new OkHttpClient();HttpUrl.Builder urlBuilder = HttpUrl.parse("https://support.zendesk.com/api/services/zis/registry/job_specs/install")		.newBuilder()		.addQueryParameter("job_spec_name", "my_job_spec");
Request request = new Request.Builder()		.url(urlBuilder.build())		.method("DELETE", null)		.addHeader("Content-Type", "application/json")		.addHeader("Authorization", Credentials.basic("your-email", "your-password"))		.build();Response response = client.newCall(request).execute();
Nodejs
var axios = require('axios');
var config = {  method: 'DELETE',  url: 'https://support.zendesk.com/api/services/zis/registry/job_specs/install',  headers: {	'Content-Type': 'application/json',	'Authorization': 'Basic <auth-value>', // Base64 encoded "username:password"  },  params: {    'job_spec_name': 'my_job_spec',  },};
axios(config).then(function (response) {  console.log(JSON.stringify(response.data));}).catch(function (error) {  console.log(error);});
Python
import requests
url = "https://support.zendesk.com/api/services/zis/registry/job_specs/install?job_spec_name=my_job_spec"headers = {	"Content-Type": "application/json",}
response = requests.request(	"DELETE",	url,	auth=('<username>', '<password>'),	headers=headers)
print(response.text)
Ruby
require "net/http"uri = URI("https://support.zendesk.com/api/services/zis/registry/job_specs/install")uri.query = URI.encode_www_form("job_spec_name": "my_job_spec")request = Net::HTTP::Delete.new(uri, "Content-Type": "application/json")request.basic_auth "username", "password"response = Net::HTTP.start uri.hostname, uri.port, use_ssl: true do |http|	http.request(request)end

Example response(s)

204 No Content
// Status 204 No Content
null
400 Bad Request
// Status 400 Bad Request
{  "errors": [    {      "code": "1010",      "detail": "error message",      "status": "400"    }  ],  "message": "Unauthorized"}
401 Unauthorized
// Status 401 Unauthorized
{  "errors": [    {      "code": "1001",      "detail": "error message",      "status": "401"    }  ],  "message": "Unauthorized"}
404 Not Found
// Status 404 Not Found
{  "errors": [    {      "code": "1020",      "detail": "error message",      "status": "400"    }  ],  "message": "Missing Resource"}
500 Internal Server Error
// Status 500 Internal Server Error
{  "errors": [    {      "code": "1050",      "detail": "error message",      "status": "500"    }  ],  "message": "Server Error"}

List JobSpecs

  • GET /api/services/zis/registry/{integration}/job_specs

Returns a list of JobSpecs. The response includes JobSpecs that are installed and those that are available to install as indicated by the installed field.

Authentication

You can authorize requests using basic authentication, an API token, or a ZIS OAuth access token. A Zendesk app can also authorize requests to this endpoint using an admin's browser session. See Making API requests from a Zendesk app.

Allowed for

  • Admins

Pagination

  • Cursor pagination

See Pagination. Returns a maximum of 100 records per page. Defaults to 20 records per page.

Parameters

NameTypeInRequiredDescription
integrationstringPathtrueThe name of the integration. integration can be up to 64 characters long. It can only include lower-case letters (a-z), numbers, dash (-), and underscore (_) characters

Code Samples

cURL
curl https://{subdomain}.zendesk.com/api/services/zis/registry/{integration}/job_specs \-H "Authorization: Bearer {access_token}"
Go
import (	"fmt"	"io"	"net/http")
func main() {	url := "https://support.zendesk.com/api/services/zis/registry/my_integration/job_specs"	method := "GET"	req, err := http.NewRequest(method, url, nil)
	if err != nil {		fmt.Println(err)		return	}	req.Header.Add("Content-Type", "application/json")	req.Header.Add("Authorization", "Basic <auth-value>") // Base64 encoded "username:password"
	client := &http.Client {}	res, err := client.Do(req)	if err != nil {		fmt.Println(err)		return	}	defer res.Body.Close()
	body, err := io.ReadAll(res.Body)	if err != nil {		fmt.Println(err)		return	}	fmt.Println(string(body))}
Java
import com.squareup.okhttp.*;OkHttpClient client = new OkHttpClient();HttpUrl.Builder urlBuilder = HttpUrl.parse("https://support.zendesk.com/api/services/zis/registry/my_integration/job_specs")		.newBuilder();
Request request = new Request.Builder()		.url(urlBuilder.build())		.method("GET", null)		.addHeader("Content-Type", "application/json")		.addHeader("Authorization", Credentials.basic("your-email", "your-password"))		.build();Response response = client.newCall(request).execute();
Nodejs
var axios = require('axios');
var config = {  method: 'GET',  url: 'https://support.zendesk.com/api/services/zis/registry/my_integration/job_specs',  headers: {	'Content-Type': 'application/json',	'Authorization': 'Basic <auth-value>', // Base64 encoded "username:password"  },};
axios(config).then(function (response) {  console.log(JSON.stringify(response.data));}).catch(function (error) {  console.log(error);});
Python
import requests
url = "https://support.zendesk.com/api/services/zis/registry/my_integration/job_specs"headers = {	"Content-Type": "application/json",}
response = requests.request(	"GET",	url,	auth=('<username>', '<password>'),	headers=headers)
print(response.text)
Ruby
require "net/http"uri = URI("https://support.zendesk.com/api/services/zis/registry/my_integration/job_specs")request = Net::HTTP::Get.new(uri, "Content-Type": "application/json")request.basic_auth "username", "password"response = Net::HTTP.start uri.hostname, uri.port, use_ssl: true do |http|	http.request(request)end

Example response(s)

200 OK
// Status 200 OK
{  "job_specs": [    {      "description": "example job spec",      "event_source": "support",      "event_type": "ticket.TicketCreated",      "flow_name": "my_flow",      "installed": true,      "integration": "my_integration",      "name": "my_job_spec",      "uuid": "eacd79f1-acf5-4f1c-939c-0bd941378ed8"    }  ],  "meta": {    "after": "first_jobspec",    "before": "twentieth_jobspec",    "has_more": true  }}
400 Bad Request
// Status 400 Bad Request
{  "errors": [    {      "code": "1010",      "detail": "error message",      "status": "400"    }  ],  "message": "Unauthorized"}
401 Unauthorized
// Status 401 Unauthorized
{  "errors": [    {      "code": "1001",      "detail": "error message",      "status": "401"    }  ],  "message": "Unauthorized"}
500 Internal Server Error
// Status 500 Internal Server Error
{  "errors": [    {      "code": "1050",      "detail": "error message",      "status": "500"    }  ],  "message": "Server Error"}