ZenduONE API Integration Guide

ZenduONE API Integration Guide

Introduction

Overview

The ZenduONE public REST API and SDK provide a robust set of tools for automating tasks and working with ZenduIoT data. At Zenduit, we recognize the value of APIs, using them extensively within our systems to automate processes and facilitate communication between components. We offer several APIs that developers can leverage to interact with the raw data accessible in the ZenduIoT application, including devices, video feeds, exceptions, and dispatch data.

Purpose

The purpose of this integration guide is to walk you through utilizing the data available via APIs and the SDK. This guide will help you create your user interface or integrate ZenduIoT data with your tools.

Getting Started

Setting up Your Testing Environment

The ZenduONE APIs documentation is available at ZenduONE API Docs. You can test all of the APIs in Postman by clicking the "Run in Postman" button at the top right of the page.



API Authentication & Access

Username, Password, and Database

To access the API endpoints, you must authenticate using the Auth endpoint (the first endpoint in the API documentation). The Auth endpoint requires the following parameters in the request body:

  • Database
  • Username
  • Password

Contact us at servicedesk@zenduit.com to obtain these parameters and authenticate to use the APIs. The Auth endpoint will provide a session ID in response, which you will use for all other API endpoints. Please note that this session ID needs to be regenerated every 14 days.

Endpoints Available

ZenduONE offers a comprehensive list of endpoints for your development needs:

  • Jobs: Endpoints for CRUD operations on the Jobs module and submitting work orders.
  • Device: Endpoints to retrieve device information, including the latest status.
  • Forms: Endpoints to manage forms, including retrieval and deletion.
  • Products: Endpoints for CRUD operations on the Products module.
  • Zone: Endpoints for CRUD operations on Locations.
  • Users: Endpoints for CRUD operations on the Users module and resetting user passwords.
  • Groups: Endpoints for CRUD operations on the Groups module.
  • Exception: Endpoint to retrieve device exceptions.
  • Logs: Endpoint to retrieve GPS log records for a device.
  • Trips: Endpoint to retrieve trips for a device within a given date range.
  • Rules: Endpoint to retrieve all system-configured rules.
  • Media: Endpoints related to cameras, allowing you to get live streams, historical streams, wake up the camera, or request snapshots or videos.
  • Custom Data: Endpoint for CRUD operations on custom data, allowing you to store key/value pairs.
  • File: Endpoint to store files in cloud storage and retrieve them later using a provided URL.
  • Tracker Types: Endpoint to retrieve all tracker types available in ZenduIoT.

Sample Use Cases

Fetching Vehicle Information

Once authenticated, use the following code snippet to retrieve device details:

curl --location 'https://one-service.zenduit.com/api/' \ --header 'Content-Type: application/x-www-form-urlencoded' \ --data-urlencode 'JSON-RPC={ "method": "Get", "params": { "typeName": "Device", "search": { "deviceSearch": { "id": "deviceId" } }, "credentials": { "sessionId": "" } }, "type": "trax" }'

Live Stream Video Access

To access a live stream from a device, use the following code snippet:

curl --location 'https://one-service.zenduit.com/api/' \ --header 'Content-Type: application/x-www-form-urlencoded' \ --data-urlencode 'JSON-RPC={ "method": "Get", "params": { "typeName": "LiveMedia", "search": { "device": { "id": "deviceId" } }, "credentials": { "sessionId": "sessionId" } }, "type": "trax" }'

Other Development Resources

SDK

ZenduONE also provides an SDK that you can use in your application development. The SDK includes functions that can be directly used in your JavaScript application. Access the SDK documentation on NPM. To install the SDK, use the following command:

npm i zen-open-api

Developer Support Channels

Start building your application now. Contact us at servicedesk@zenduit.com to obtain your credentials and start building using the ZenduONE API Docs. For any other questions, feel free to email us at integrations@zenduit.com.

Slide has been added to for the reference.




    • Related Articles

    • ZenduONE Custom Integrations Implementation Guide

      Zenduit boasts 14 years of expertise in developing customer-centric solutions within the Geotab ecosystem, focusing on innovation and consultation. Our deep experience has led to numerous custom apps and integrations, designed to empower Geotab ...
    • Geotab Integrations: Software Technical Toolkit

      Overview The MyGeotab SDK (Software Development Kit) is a comprehensive set of tools designed to facilitate the automation of tasks and the effective management of data within MyGeotab. This article provides an introduction to the MyGeotab SDK, ...