REST API for Lookup Manager
- Cao Liang
Introduction
Now 3rd party apps can get and edit lookup tables with the newly added REST endpoints
Resources
Table
METHOD | URL | Data |
---|
METHOD | URL | Data |
---|---|---|
GET | /rest/lookuprestresource/1.0/lookup/table | Return an array of table information Example [
{
"columns":[
{
"id":4,
"name":"Application"
},
{
"id":5,
"name":"App Owner"
}
],
"name":"App Mapping",
"id":2
}
]
|
Sample code
//Get information for all the tables
def data = sendGetRequest("/rest/lookuprestresource/1.0/lookup/table/")
data.each{val ->
//TODO
}
METHOD | URL | Data |
---|
METHOD | URL | Data |
---|---|---|
POST | /rest/lookuprestresource/1.0/lookup/table | The data should be a valid JSON string containing the following information:
Example {
"name":"New_Table",
"columns": ["Column_1, Column_2"]
} |
Sample code
METHOD | URL | Data |
---|
METHOD | URL | Data |
---|---|---|
PUT | /rest/lookuprestresource/1.0/lookup/table/{TABLE_NAME} | The data should be a valid JSON string containing the following information:
Example |
Sample code
METHOD | URL | Data |
---|
METHOD | URL | Data |
---|---|---|
DELETE | /rest/lookuprestresource/1.0/lookup/table/{TABLE_ID} | - |
Sample code
Table row
METHOD | URL | Data |
---|
METHOD | URL | Data |
---|---|---|
GET | /rest/lookuprestresource/1.0/lookup/table/{TABLE_ID}/entries | Return the an array of rows information for a table Example
|
Sample code
Table Column
Useful Methods