How can we write custom debug information in Edge Trace tool?

Not applicable

How can we write debug information in Edge Trace tool?

I am using a JavaScript policy & want to write some custom debug messages to the APIGEE trace tool.

Please let me know how we can achieve this?

0 1 571
1 REPLY 1

Not applicable

you can use the print() function to output debug information to the trace tool.

For example

if(context.flow=="TARGET_REQ_FLOW")

{
print("In target request flow");
var username = context.getVariable("USER.name");
var url ="http://mocktarget.apigee.net/user?"

context.setVariable("target.url", url +"user="+ username);

print("callout to URL: ", context.getVariable("target.url"));

}