|
JSON Object - Delete field |
Declaration
<AMJSON ACTIVITY="delete_field" JSONOBJECT="text" PATH="text" />
Description
Deletes a specified field and its value from an existing Automate JSON Object.
Practical Usage
JSON is primarily used to transmit data between a server and web application, as an alternative to XML. Use this activity to delete a field from an Automate JSON Object.
Parameters
General
Property | Type | Required | Default | Markup | Description |
---|---|---|---|---|---|
JSON Object name | Text | Yes | (Empty) | JSONOBJECT="donuts" | The name of the JSON Object to delete the field from. |
Field to delete | Text | Yes | (Empty) | PATH="chocolate" | Specifies the JSON field to delete. To select a field, click Select field, and then from the dialog that appears, choose the desired field by clicking its hyperlink. |
Example
NOTE:
- The sample AML code below can be copied and pasted directly into the Steps Panel of the Task Builder.
- Parameters containing user credentials, files, file paths, and/or other information specific to the task must be customized before the sample code can run successfully.
Description
This sample task deletes a field from an Automate JSON Object.
Copy
<AMJSON JSONOBJECT="donuts" JSONSTRING="{ 'chocolate': 10, 'glazed': 25 , 'jelly': 5 }" />
<AMJSON ACTIVITY="delete_field" JSONOBJECT="donuts" PATH="chocolate" />