2 RESTful Services
This chapter provides information about the RESTful Services used by DDS.
Discover
This end point returns a list of Dynamic Data Service end points.
HTTP Operation: GET
Path: /resources/discover
Get Data
This end point returns data from the provided schema and table(s). The query parameters "fromTables" allows single or multiple tables.
The query parameter "rowFilter" can be used to provide a join between tables.
Tables and columns need to be qualified if multiple tables are provided in "fromTables". The data is returned in JSON/XML format and one page of data is returned. The response contains a link to the next page if there are additional pages.
HTTP Operation: GET
Path: /resources/dds/{schemaName}/data?fromTables=<tables>
The following query parameters can be provided to filter the data.
-
columnFilter - Columns to be included in the response
-
rowFilter - Predicate can be provided in the rowFilter to filter the data
-
sortBy - Valid values are ascending(asc) or descending(desc)
-
Page - Page number
-
pageLimit - Number of records to be included in the page. The default page size is 25
-
format - Valid values are short or long. Short format provides data without column names. Long format provides data with column names.
Get Data from a Table
This end point returns data from a table using a primary key.
HTTP Operation: GET
Path: /resources/dds/{schemaName}/{table}?idFilter=<Primary Key>
Insert Data
This end point inserts data in a table. Input can be a single record or multiple records provided in JSON format. Users that belong to the admin or operator group can only perform this operation. Users also need to have DataCreatePermission to insert data.
HTTP Operation: PUT
Path: /resources/dds/{schemaName}/data/{table}
Sample input for inserting data in the BDI_RECEIVER_OPTIONS table
/dds/bdi_rms_schema/data/BDI_RECEIVER_OPTIONS
{ "items": [ { "ID":1, "BASE_FOLDER":"base", "FOLDER_TEMPLATE":"baseTemplate", "INTERFACE_MODULE":"interfaceModule", "INTERFACE_SHORT_NAME":"interfaceShortName", "MERGE_STRATEGY":"mergeStrategy" } ] }
Update Data
This end point updates data in a table using the rowFilter query parameter and input is provided in JSON format. Users that belong to the admin or operator group can only perform this operation. Users also need to have DataUpdatePermission to update data.
HTTP Operation: POST
Path: /resources/dds/{schemaName}/data/{table}?rowFilter=<predicate>
Sample input for updating data in the BDI_SYSTEM_OPTIONS table
/dds/bdi_rms_schema/data/BDI_SYSTEM_OPTIONS?rowFilter=VARIABLE_NAME='LOADJOBDEF'
{ "VARIABLE_VALUE":"TRUE" }
Delete Data
This end point deletes data from a table based on the rowFilter query parameter. Users that belong to the admin or operator group can only perform this operation. Users also need to have DataDeletePermission to delete data.
HTTP Operation: DELETE
Path: /resources/dds/{schemaName}/data/{table}?rowFilter=<predicate>
Sample End Point
/dds/bdi_rms_schema/data/BDI_SYSTEM_OPTIONS?rowFilter=VARIABLE_NAME='LOADJOBDEF'
Get Schemas
This end point returns all configured database schemas.
HTTP Operation: GET
Path: /resources/dds/schemas
Get Tables
This end point returns all tables from a database schema.
HTTP Operation: GET
Path: /resources/dds/{schemaName}/tables
Get Columns for a Table
This end point returns columns for a table.
HTTP Operation: GET
Path: /resources/dds/{schemaName}/{table}
Get System Options
This end point returns all system options from the DDS_SYSTEM_OPTIONS table.
HTTP Operation: GET
Path: /resources/system-setting/system-options
Create System Options
This end point creates a system option in the DDS_SYSTEM_OPTIONS table.
HTTP Operation: PUT
Path: /resources/system-setting/system-options
Sample Input
{ "key":"testKey", "value":"testValue" }
Update System Options
This end point updates a system option in the DDS_SYSTEM_OPTIONS table.
HTTP Operation: POST
Path: /resources/system-setting/system-options
Sample Input
{ "key":"testKey", "value":"testValue1" }