WorkBook API

WORKBOOK API

Our API is a standard REST API.

It can send and receive requests in JSON or JSV

Verbs

GET – Get a single or set of items (Defined by the plural of the request and route)
PUT – Insert an item
POST – Update an item (Newer calls all use PATCH)
DELETE – Delete an item
PATCH – Update one or more fields on an item.

If a request or route has “Visualization”, the item is a mixture of fields and should not have an update,insert or delete function.

To see the avalible Endpoints, you can visit /api/metadata on your HTML version site.
Newer versions (9.3+) also has a /api/custommetadata file, with more information and search.
There is also a short example page on how to use it with AJAX on /test/apidoc.html

If the API is called from javascript, you must set the System Setting, 1061, CORSWebSites to the correct sender.
Otherwise the server will block the request.
See Cross Site Scripting

Authentication

Authentication can happen in a couple of ways all depending on the user setup.

Basic, Handshaking, LDAP, 2Factor.

If LDAP or 2Factor is use, the login procedure will return a header telling this.

With basic you can call every request if you include the correct Headers and we HIGHLY recommend that this is only used if running HTTPS.

Handshaking calls a hello request and creates a unique string using the returned request and the users password. This way the password is never sent directly to the server.

All of this can be seen in the apidoc.html

Some noteworthy example endpoints.

(TasksRequest) /api/tasks
(TaskRequest) /api/task/{Id}
(JobsRequest) /api/jobs
(JobRequest) /api/job/{Id}
(ResourceRequest) api/resource/{Id}
(ResourcesRequest) /api/resources

Code Examples

Javascript : https://github.com/dlj/UserTaskStatistics
C
# : https://github.com/dlj/CSharpApiTest

Was this article helpful? Useful Useless 1/11 found this article helpful.