
Security Fundamentals
Turtles, Clams, and Cyber Threat Actors: Shell Usage
The Socket Threat Research Team uncovers how threat actors weaponize shell techniques across npm, PyPI, and Go ecosystems to maintain persistence and exfiltrate data.
zendesk-node-api
Advanced tools
A wrapper library for Zendesk using NodeJS
Install the package via npm
$ npm install zendesk-node-api
Create a new instance of Zendesk, passing in your Zendesk URL, email and API token.
var Zendesk = require('zendesk-node-api');
var zendesk = new Zendesk({
url: YOUR_ZENDESK_URL, // https://example.zendesk.com
email: YOUR_ZENDESK_EMAIL, // me@example.com
token: YOUR_ZENDESK_API_TOKEN // hfkUny3vgHCcV3UfuqMFZWDrLKms4z3W2f6ftjPT
});
These methods allow you to interact with tickets within Zendesk
Returns a promise containing an array of all tickets in your Zendesk
zendesk.tickets.list().then(function(tickets){
// Do something with tickets
});
Returns a promise containing an object of a specific ticket
zendesk.tickets.show(TICKET_ID).then(function(ticket){
// Do something with ticket
});
Create a ticket inside Zendesk
https://developer.zendesk.com/rest_api/docs/core/tickets#create-ticket
zendesk.tickets.create({
subject: 'A new ticket',
comment: {
body: 'A ticket created with zendesk-node-api'
}
}).then(function(){
console.log('Ticket created');
});
Update a ticket inside Zendesk
https://developer.zendesk.com/rest_api/docs/core/tickets#update-ticket
zendesk.tickets.update(TICKET_ID, {
comment: {
body: 'Updated this ticket with zendesk-node-api'
}
}).then(function(){
console.log('Ticket updated');
});
Delete a ticket inside Zendesk
zendesk.tickets.delete(TICKET_ID).then(function(){
console.log('Ticket deleted');
});
These methods allow you to interact with ticket fields within Zendesk
Returns a promise containing an array of all ticket fields in your Zendesk
zendesk.ticketFields.list().then(function(ticketFields){
// Do something with ticketFields
});
Returns a promise containing an object of a specific ticket field
zendesk.ticketFields.show(TICKET_FIELD_ID).then(function(ticketField){
// Do something with ticketField
});
Create a ticket field inside Zendesk
https://developer.zendesk.com/rest_api/docs/core/ticket_fields#create-ticket-fields
zendesk.ticketFields.create({
type: 'text',
title: 'Title for the Ticket Field'
}).then(function(){
console.log('Ticket field created!');
});
Update a ticket field inside Zendesk
https://developer.zendesk.com/rest_api/docs/core/ticket_fields#update-ticket-fields
zendesk.ticketFields.update(TICKET_FIELD_ID, {
type: 'text',
title: 'Updated Ticket Field Title'
}).then(function(){
console.log('Ticket field updated!');
});
Delete a ticket field inside Zendesk
zendesk.ticketFields.delete(TICKET_FIELD_ID).then(function(){
console.log('Ticket field deleted');
});
These methods allow you to interact with users within Zendesk
Returns a promise containing an array of all users in your Zendesk
zendesk.users.list().then(function(users){
// Do something with users
});
Returns a promise containing an object of a specific user
zendesk.users.show(USER_ID).then(function(user){
// Do something with user
});
Create a user inside Zendesk
https://developer.zendesk.com/rest_api/docs/core/users#create-user
zendesk.users.create({
name: 'API User',
email: 'user@zendesknodeapi.com'
}).then(function(){
console.log('User created');
});
Update a user inside Zendesk
https://developer.zendesk.com/rest_api/docs/core/users#update-user
zendesk.users.update(USER_ID, {
email: 'updatedemail@zendesknodeapi.com'
}).then(function(){
console.log('User updated');
});
Delete a user inside Zendesk
zendesk.users.delete(USER_ID).then(function(){
console.log('User deleted');
});
These methods allow you to interact with ticket fields within Zendesk
Returns a promise containing an array of all user fields in your Zendesk
zendesk.userFields.list().then(function(userFields){
// Do something with userFields
});
Returns a promise containing an object of a specific user field
zendesk.userFields.show(USER_FIELD_ID).then(function(userField){
// Do something with ticketField
});
Create a user field inside Zendesk
https://developer.zendesk.com/rest_api/docs/core/user_fields#create-user-fields
zendesk.userFields.create({
type: 'text',
title: 'User field',
key: 'user_field'
}).then(function(){
console.log('User field created!');
});
Update a user field inside Zendesk
https://developer.zendesk.com/rest_api/docs/core/user_fields#update-user-fields
zendesk.userFields.update(USER_FIELD_ID, {
title: 'Updated User field title',
}).then(function(){
console.log('User field updated!');
});
Delete a user field inside Zendesk
zendesk.userFields.delete(USER_FIELD_ID).then(function(){
console.log('User field deleted');
});
FAQs
A wrapper library for Zendesk API using NodeJS
The npm package zendesk-node-api receives a total of 899 weekly downloads. As such, zendesk-node-api popularity was classified as not popular.
We found that zendesk-node-api demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security Fundamentals
The Socket Threat Research Team uncovers how threat actors weaponize shell techniques across npm, PyPI, and Go ecosystems to maintain persistence and exfiltrate data.
Security News
At VulnCon 2025, NIST scrapped its NVD consortium plans, admitted it can't keep up with CVEs, and outlined automation efforts amid a mounting backlog.
Product
We redesigned our GitHub PR comments to deliver clear, actionable security insights without adding noise to your workflow.