This API allows the user to update the schema with custom attributes for REST API monitors from Applications Manager.
XML Input:
https://[HOST]:[PORT]/AppManager/xml/updateRestAPIMonitorSchema
JSON Input:
https://[HOST]:[PORT]/AppManager/json/updateRestAPIMonitorSchema
Supported HTTP methods: POST
Allowed roles: Administrator
Field | Description |
---|---|
apikey | The key generated using the Generate API Key option in the 'Admin' tab. |
resourceid | Resource IDs of the REST API monitor separated by commas. |
responseType | Indicates the response type - XML or JSON. |
schema | Schema to be updated for REST API monitor. It should be either in XLST or JSON type. |
Note: API should be used only through HTTP POST method.
XML Input:
https://apm-prod-server:8443/AppManager/xml/updateRestAPIMonitorSchema
Params in request body:
apikey=aaaaaabbbbbbccccccddddddeeeeee
resourceid=10000184,10000185
responseType=XML
schema=<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:output method="text"/>
<xsl:template match="/">
<xsl:for-each select="AppManager-response/result/response/Monitor">
<xsl:value-of select="@DISPLAYNAME"></xsl:value-of>:<xsl:value-of select="@AVAILABILITYATTRIBUTEID"></xsl:value-of>
<xsl:text>
</xsl:text>
</xsl:for-each>
</xsl:template>
</xsl:stylesheet>
JSON Input:
https://apm-prod-server:8443/AppManager/json/updateRestAPIMonitorSchema
Params in request body:
apikey=aaaaaabbbbbbccccccddddddeeeeee
resourceid=10000184,10000185
responseType=JSON
schema=Response Code::response-code
URI::response.response.uri
XML Output:
<?xml version="1.0" encoding="UTF-8"?>
<AppManager-response uri="/AppManager/xml/updateRestAPIMonitorSchema">
<result>
<response response-code="4000">
<Status Status="Schema updated for the resourceid(s): 10000185"/>
</response>
</result>
</AppManager-response>
JSON Output:
{"response-code":"4000","response":{"result":[{"Status":"Schema updated for the resourceid(s): 10000185"}],"uri":"/AppManager/json/updateRestAPIMonitorSchema"}}