The PUT
method of the executionplans
API saves an Execution Plan.
You must obtain an authToken by using the login
API. The token authenticates the user performing the operation. For details, see
TSWS authentication
.
API | Method | Description |
---|---|---|
Applications | GET | Retrieve the details of one application or all applications |
PUT | Update an existing application | |
POST | Create a new application | |
DELETE | Delete an application | |
Execution Plans | GET | Retrieve the details of one or more Execution Plans |
PUT | Create a new Execution Plan or Update an existing Execution Plan | |
DELETE | Delete an Execution Plan | |
Scripts | GET | Retrieve the details of one script or all scripts |
Locations | GET | Retrieve the details of all locations |
The executionplan
API uses the PUT
method to save an Execution Plan.
https://<PresentationServerHostName>/tsws/10.0/api/appvis/synthetic/api/executionplans/save
In the above example,
<PresentationServerHostName>
indicates the host name of the TrueSight Presentation Server.
After accessing the REST client, perform the following steps:
https://localhost/tsws/10.0/api/appvis/synthetic/api/executionplans/save
Add a new header row and select Authorization as the header type.
login
API. application/json
.Element | Description |
---|---|
authToken | Value of authToken |
The following code is an example of the JSON code to send with the request.
Note
This functionality requires that you send the entire JSON for the Execution Plan you want to save. Sending only the fields you want to update is not sufficient.
Parameter | Description | Value |
---|---|---|
executionPlanId | ID of the Execution Plan
| String representing a numeric value |
blackOuts | Blackout periods defined for the Execution Plan (can be multiple) | |
startAtTimeOffset | Clock used for calculating the blackout period |
|
terminateAt | Date from when the blackout period is no longer used | One of the following:
|
daysOfRunTillHour | End time for the blackout period | Format: hh:mm Example: 21:00 |
daysOfRunFromHour | Start time for the blackout period | Format: hh:mm Example: 17:00 |
triggerType | Trigger for the blackout period | DAYS_OF_WEEK_BLACKOUT |
daysOfWeek | Days of the week when the blackout period is in effect | Comma-separated numeric values (0-6). Example: 0,2,5 indicates that the blackout is in effect on Sunday, Tuesday, and Friday. |
blackoutName | Name of the blackout period | String Name given to the blackout period |
startAt | Date from when the blackout period is in use | One of the following:
|
projectType | Type of Silk Performer project | String representing a numeric value |
scriptFileName | Name of the script run by the Execution Plan Content of this parameter is ignored. | String |
description | Description of the Execution Plan | String |
executionPlanName | Name of the Execution Plan | String |
version | Execution Plan version This number is updated every time the Execution Plan is updated. | Number |
scriptFileCRC | Cyclic Redundancy Check of the script file Content of this parameter is ignored. | String representing a numeric value |
scheduler | Schedule defined for the Execution Plan | |
startAtTimeOffset | Clock used for calculating the schedule |
|
terminateAt | Date from when the schedule is no longer used | One of the following:
|
transactionTimeout | Number of minutes a transaction is allowed to run before it is automatically timed out | String representing a numeric value |
startAtWithRandomDelay | Range, in minutes, within which the Execution Plan starts | String representing a numeric value |
startAt | Date from when the schedule is in use | One of the following:
|
intervalInMinutes | Number of minutes between runs of the Execution Plan | String representing a numeric value |
scriptId | ID of the script used by the Execution Plan
| String representing a numeric value |
agentGroups | Locations defined for the Execution Plan | |
name | Name of the Location | String |
id | ID of the Location | Number |
scriptFileSize | Size of the script file used by the Execution Plan in bytes Content of this parameter is ignored. | String representing a numeric value |
activeStatus | Indication if the Execution Plan is active or not | String representing a numeric value Valid values: 0—False 1—True |
attributeChangedEnvelopVersion | Version number that is incremented each time there is a change in blackouts, schedule, or Execution Plan name | String representing a numeric value |
activeBy | Array of two Boolean values indicating if the Execution Plan is active at the Execution Plan level, and at the Application level | Array |
executionPlanName | Name of the Execution Plan | String |
attributes | Attributes of the script run by the Execution Plan (can be multiple) You can obtain a list of attributes in a script from the Retrieving script details -- API. | |
encrypted | Indicates whether or not the attribute is encrypted | 0—False 1—True; used for a password attribute |
defaultValue | Default value of the attribute | Varies, depending on the attribute |
name | Name of the attribute | String |
encryptionType | Indicates whether the value parameter for the attribute is encoded | 0— 1— |
description | Description of the attribute | String |
type | Data type of the attribute |
|
value | Value of the attribute | Varies, depending on the attribute For a password enter the Base64 encoded value, and set |
order | Serial number of the appearance of the attribute in the user interface | Number |
applicationId | (Mandatory) ID of the application on the Presentation Server | String representing a numeric value |
syntheticApplicationId | Synthetic application ID This parameter is not updated by this API request. | String representing a numeric value |
syntheticApplicationName | Name of the application | String |
attributeChangedScriptVersion | Version number that is incremented each time there is a change in script attributes | String representing a numeric value |
11 Comments
Stephane Guedon
0 - No encryption
1,2 - Indicates encryption type
Great... what does 1 ou 2 mean ?any specific encryption algorythm ?
Sara Kamen
Hi Stephane,
I'll check with the developers and update and correct the content in the coming days.
In the mean time, the options are 0 and 1 (2 is not a valid value). You would use 1 if you are setting a password.
Regards,
Sara
Diane Porter
Sara Kamen
Harihara Subramanian
Stephane Guedon
Hi,
I've opened a case 3 days ago without any answer...
For password I guess encrypted should be set to 1 and encryptionType may depends on the encryption method
Regards
Harihara Subramanian
Sara Kamen
Hi Stephane,
I replied yesterday, but I'm sorry if you cannot see it. I'll add it here, below, and I should be able to update the documentation in the next day or two.
Regards,
Sara
============Reply from yesterday
Hi Stephane,
I'll check with the developers and update and correct the content in the coming days.
In the mean time, the options are 0 and 1 (2 is not a valid value). You would use 1 if you are setting a password.
Regards,
Sara
Stephane Guedon
Hi Sara
Are you sure ?
No mismatch between encrypted and encryptionType ?
What is encryption method used ?
Lots of doc improvment identified here
Sara Kamen
Hi Stephane,
I updated the documentation. While the content is now more precise—if you are setting a password, set
encrypted
andencryptionType
to 1—I will work to add a specific example for a password attribute with a fuller explanation.Thanks for taking the time to comment!
Regards,
Sara
Harihara Subramanian