Page tree

The POST method of the applications API creates an application.

Before you begin

You must obtain an authToken by using the login API. The token authenticates the user performing the operation. For details, see  TSWS authentication Open link .

Synthetic configuration APIs

APIMethodDescription
Applications

GETRetrieve the details of one application or all applications
PUT

Update an existing application

POSTCreate a new application
DELETEDelete an application
Execution Plans

  
GETRetrieve the details of one or more Execution Plans
PUTCreate a new Execution Plan or
Update an existing Execution Plan
DELETEDelete an Execution Plan
ScriptsGETRetrieve the details of one script or all scripts
LocationsGETRetrieve the details of all locations
 

To create an application

The applications API uses the POST method to create an application.

Request syntax

https://<PresentationServerHostName>/tsws/10.0/api/appvis/synthetic/api/applications/create

In the above example, <PresentationServerHostName> indicates the host name of the TrueSight Presentation Server.

Request with REST client

After accessing the REST client, perform the following steps:

  1. Enter the URL for API.
    An example of a request to create an application is:
    https://localhost/tsws/10.0/api/appvis/synthetic/api/applications/create
  2. Add a new header row and select Authorization as the header type.

  3. Enter the text authToken followed by the authToken Open link  generated through the login API. 
  4. Enter the json code in the request body
  5. Click Send.

Request parameters

ElementDescription
authToken

Value of authToken Open link

Request body

The following code is an example of the JSON code to send with the request.

	{
		"name":"NewApp2",
		"importance":"MEDIUM",
		"description":"",
		"synthetic":"ON"
	}
 

Request body parameters

ParameterDescriptionValue
     name

Name of the application model

 

String

     importance
Importance level of the application
  • HIGH
  • MEDIUM
  • LOW
     description
(Optional) Description of the applicationString
     synthetic
Indicates if synthetic monitoring is enabled for the application

ON