Ninja Van Order API

Create and cancel delivery orders and generate waybills.

Operations 5

POST /4.2/orders Create delivery order (v4.2) #
POST /4.1/orders Create delivery order (v4.1) #
DELETE /2.2/orders/{trackingNo} Cancel order #
GET /2.0/reports/waybill Generate waybill #
GET /2.0/reports/international-waybills Generate international waybill #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/ninjavan-order-api-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

ninjavan-order-api-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Ninja Van API (ninjaAPI) Order API
  description: ninjaAPI is Ninja Van's REST API for integrating last-mile logistics across Southeast Asia (Singapore, Malaysia, Indonesia, Philippines, Vietnam, Thailand).
  version: 4.1.0
  contact:
    name: Ninja Van Developer Support
    url: https://api-docs.ninjavan.co/
servers:
- url: https://api.ninjavan.co/{countryCode}
  description: Production (countryCode is one of sg, my, id, ph, vn, th)
  variables:
    countryCode:
      default: sg
      enum:
      - sg
      - my
      - id
      - ph
      - vn
      - th
- url: https://api-sandbox.ninjavan.co/{countryCode}
  description: Sandbox (only the sg country code is supported)
  variables:
    countryCode:
      default: sg
      enum:
      - sg
security:
- bearerAuth: []
tags:
- name: Order API
  description: Create and cancel delivery orders and generate waybills.
paths:
  /4.2/orders:
    post:
      operationId: createOrderV42
      tags:
      - Order API
      summary: Create delivery order (v4.2)
      description: Creates a delivery order. Version 4.2 of the create-order endpoint. The request describes the service, the pickup (from) and delivery (to) parties, and the parcel job (dimensions, delivery instructions, cash on delivery, delivery timeframe).
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/OrderInput'
      responses:
        '200':
          description: The created order, including the assigned tracking number.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Order'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
  /4.1/orders:
    post:
      operationId: createOrderV41
      tags:
      - Order API
      summary: Create delivery order (v4.1)
      description: Creates a delivery order using version 4.1 of the create-order endpoint. Retained alongside 4.2 for existing integrations.
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/OrderInput'
      responses:
        '200':
          description: The created order, including the assigned tracking number.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Order'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
  /2.2/orders/{trackingNo}:
    delete:
      operationId: cancelOrder
      tags:
      - Order API
      summary: Cancel order
      description: Cancels an order that has not yet been picked up, by its tracking number.
      parameters:
      - name: trackingNo
        in: path
        required: true
        description: The tracking number of the order to cancel.
        schema:
          type: string
      responses:
        '200':
          description: Cancellation result.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CancelResponse'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '404':
          $ref: '#/components/responses/NotFound'
  /2.0/reports/waybill:
    get:
      operationId: generateWaybill
      tags:
      - Order API
      summary: Generate waybill
      description: Generates a waybill (air waybill / shipping label) PDF for one or more tracking numbers. Access to this endpoint must be granted by Ninja Van before use.
      parameters:
      - name: tid
        in: query
        required: true
        description: One or more tracking numbers to include on the waybill.
        schema:
          type: string
      - name: hide_shipper_details
        in: query
        required: false
        description: Whether to hide the shipper's details on the waybill.
        schema:
          type: boolean
      - name: orientation
        in: query
        required: false
        description: Waybill orientation.
        schema:
          type: string
          enum:
          - portrait
          - landscape
      responses:
        '200':
          description: A waybill document.
          content:
            application/pdf:
              schema:
                type: string
                format: binary
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
  /2.0/reports/international-waybills:
    get:
      operationId: generateInternationalWaybill
      tags:
      - Order API
      summary: Generate international waybill
      description: Generates an international waybill document for cross-border parcels.
      parameters:
      - name: tid
        in: query
        required: true
        description: One or more tracking numbers to include on the waybill.
        schema:
          type: string
      responses:
        '200':
          description: An international waybill document.
          content:
            application/pdf:
              schema:
                type: string
                format: binary
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
components:
  responses:
    Unauthorized:
      description: Missing or invalid access token.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    Forbidden:
      description: The caller lacks permission - wrong environment/country code, integration audit not passed, waybill access not granted, or a frozen account.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    NotFound:
      description: The requested resource was not found.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    BadRequest:
      description: The request was malformed or failed validation.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
  schemas:
    OrderInput:
      type: object
      required:
      - service_type
      - from
      - to
      - parcel_job
      properties:
        service_type:
          type: string
          description: For example Parcel.
        service_level:
          type: string
          description: For example Standard.
        requested_tracking_number:
          type: string
        reference:
          type: object
          properties:
            merchant_order_number:
              type: string
        from:
          $ref: '#/components/schemas/Contact'
        to:
          $ref: '#/components/schemas/Contact'
        parcel_job:
          $ref: '#/components/schemas/ParcelJob'
        marketplace:
          type: object
          additionalProperties: true
    Contact:
      type: object
      description: A pickup or delivery party.
      properties:
        name:
          type: string
        phone_number:
          type: string
        email:
          type: string
        address:
          type: object
          properties:
            address1:
              type: string
            address2:
              type: string
            area:
              type: string
            city:
              type: string
            state:
              type: string
            address_type:
              type: string
            country:
              type: string
            postcode:
              type: string
    CancelResponse:
      type: object
      properties:
        tracking_number:
          type: string
        status:
          type: string
    ParcelJob:
      type: object
      description: Details of the parcel and how it should be handled.
      properties:
        is_pickup_required:
          type: boolean
        pickup_service_type:
          type: string
        pickup_date:
          type: string
          format: date
        delivery_start_date:
          type: string
          format: date
        delivery_timeslot:
          type: object
          additionalProperties: true
        dimensions:
          type: object
          properties:
            weight:
              type: number
            length:
              type: number
            width:
              type: number
            height:
              type: number
        cash_on_delivery:
          type: number
        allow_weekend_delivery:
          type: boolean
    Error:
      type: object
      properties:
        error:
          type: object
          properties:
            title:
              type: string
            message:
              type: string
            details:
              type: object
              additionalProperties: true
    Order:
      allOf:
      - $ref: '#/components/schemas/OrderInput'
      - type: object
        properties:
          tracking_number:
            type: string
          status:
            type: string
          created_at:
            type: string
            format: date-time
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: 'OAuth2 client-credentials access token obtained from POST /{countryCode}/2.0/oauth/access_token, passed as `Authorization: Bearer ACCESS_TOKEN`.'