Anchor | ||||
---|---|---|---|---|
|
Applications can be accessed through this API using the GET service.
Info | ||
---|---|---|
| ||
http://host:port/flexdeploy/rest/application |
...
Each function returns JSON Application objects. The Application Object is an object that has these attributes,
Attributes | Type | Description |
---|---|---|
applicationName | String | This is the name of the Application. |
applicationId | String | This is the Id of the Application. |
parentapplicationId | Long | This is the Id of the parent Folder of this Application. |
applicationName | String | This is the Name used to identify this Application. |
description | String | This is a description of this Application. |
isActive | Boolean | This Boolean indicates whether or not this Application is marked as active. |
projectIds | List<Long> | This List contains the Id's of the active Projects in this Application. |
GET
There are two implementations of GET. One will find an Application with the given Id and return the JSON representation of the Application. The other will find a list of Applications matching the parameters supplied to it.
GET (Using Id)
This GET service will find an Application by Id and return a JSON representation of it.
Info | ||
---|---|---|
| ||
http://host:port/flexdeploy/rest/application/{id} |
Parameter | Required | Type | Description |
---|---|---|---|
id | Yes | URL | This is a URL path parameter for the id which is used to find an Application. |
HTTP Code | Description |
---|---|
200 | Application found and returned |
400 | Bad request |
401 | Unauthorized |
500 | Unexpected internal server error |
Example:
If we had a Application in our database with the following attributes:
Code Block | ||||
---|---|---|---|---|
| ||||
{ "applicationId": 10001, "parentFolderId": 99, "applicationName": "Application1", "isActive": true, "projectIds": [ 11202, 11204, 12701 ], "description": null } |
When we run a GET request at the following URL:
http://{host:port}/flexdeploy/rest/application/10001
The GET request would return the following JSON Application object
Code Block | ||||
---|---|---|---|---|
| ||||
{ "applicationId": 10001, "parentFolderId": 99, "applicationName": "ProjectApp1", "isActive": true, "projectIds": [ 11202, 11204, 12701 ], "description": null } |
Get(Using Query Parameters)
...
Info | ||
---|---|---|
| ||
http://host:port/flexdeploy/rest/application? Append the following character sequences to the above URL to specify Query parameters.Use '&' between successive query parameters:applicationName={name} Examples:To search by name only:http://host:port/flexdeploy/rest/application?applicationName={name} To search for all Applications:http://host:port/flexdeploy/rest/application |
Tip |
---|
The query parameters are not case sensitive. Searching by applicationName=NAME is the same as searching by applicationName=name. |
Parameters
Parameter | Required | Type | Description |
---|---|---|---|
applicationName | No | URL(query) | This is a URL query parameter for the name which is used to query Applications with. |
Response Codes
HTTP Code | Description |
---|---|
200 | Applications were found and returned |
400 | Bad request |
401 | Unauthorized |
500 | Unexpected internal server error |
Example
If we had Applications in our database with the names 'Application1' and 'Application2' and the following attributes:
...