Print Route URL using Custom Message Completed
search cancel

Print Route URL using Custom Message Completed

book

Article ID: 264125

calendar_today

Updated On:

Products

CA API Gateway

Issue/Introduction

There's a requirement to print the route assertion URL in ssg logs using a Custom Message Completed Global policy. Using the ${httpRouting.url} context variable in the Global policy is not working.

Environment

API Gateway 10.1

Resolution

Try using the ${request.url} context variable.

In this example, there is a simple policy with a routing assertion. In the message-completed global policy, an audit message is used to print the name of the service and the routing URL. 

After hitting the service endpoint, check the audit details for the routing assertion's URL.