Chapter 18. Application Programing Interface (API)

Table of Contents
18.1. Acquiring Access Token
18.2. Access To PostgreSQL Tables
18.2.1. Create Dataset
18.2.2. Read Dataset
18.2.3. Update Dataset
18.2.4. Delete Dataset
18.2.5. Fine Grained Pre-check Function
18.3. Calling PostgreSQL Functions or Procedures

This chapter currently applies only to cloud version of PostERP.

Outside world can automatically exchange data set with PostERP by calling its representational state transfer RESTful API.

Calling RESTful API is in essence directly manipulating PostERP database similar to sending SQL commands for execution. All CRUD (Create, Read, Update, Delete) operations on database tables can be performed by API calls.


This section assumes that PostERP runs in your host

Every API call must consists of an HTTP request in JSON format and be posted to

Each response consists of HTTP response code. Response code 200 indicates successful API call. Other response codes with optional error messages indicate failed API calls.

When an API call requests for data set and succeeds, PostERP responds with a JSON array.

Privilege checks are performed on each API calls through this service.