search cancel

Xpath Configuration Example


Article ID: 197763


Updated On:


CA API Gateway API SECURITY CA API Gateway Precision API Monitoring Module for API Gateway (Layer 7) CA API Gateway Enterprise Service Manager (Layer 7) STARTER PACK-7 CA Microgateway


Xpath configuration Example, based on How to list Expiring Certificates tech doc policy example


Release :  10.x

Component : API GATEWAY


1. copy the Trusted certificate List (in XML format ) obtained when using the line #13 of your policy from the browser

use the URL from line 13 and paste it in your browser ,

Note: copy just the XML text, do not copy the first line "This XML file does.." or you will produce an error due the format does not accomplish XML document


2. From Evaluate Response XPath assertion , click on Add button to create a New Sample Message

3. Add a Name to the sample Message and Paste the copied XML text from Browser into the XML Document Section,  just over-writing the second line <empty/>

4. click OK

5. you will see now something like this.

6. To create the filter on the Xpath, select the attribute from the XML document Section,  as example : SubjectName

and the assertion will complete automatically the syntax needed under Xpath section , with this syntax :



7. this is the way to create  new sample message and create a new filter for xpath different/same as the example do you will use on the policy.

8. the next steps are test and see how it works and what do you need to add or modify to obtain the expected results .


Additional Information

1. Prerequisites , need to be Enabled the Restman Management Service on Gateway : 

Tasks-> Services and APIS -> Publish Internal Service -> Select Service to Publish

2. The Example shows on this KB is based on the Policy Sample used in "Monitor expiring trusted certificate with schedule task on API Gateway"