Help Docs

Custom Parameters Support via PHP Agent API

This PHP API is a key and a value pair that allows you to keep track of the parameters within a transaction. This gives deeper visibility into your own application methods.

To add a custom parameter, follow the syntax given below:



Parameter Name



The name  of the custom parameter you want to track for a particular transaction/request.


The value  of the custom parameter you want to track. It can be any of the below types,
int, float, long, double, bool, decimal or string.


The following method illustrates how the parameters are tracked via API,

function trigger_application_update(){
//Your application code...

$app_version = get_bloginfo( 'version' );
$user_name = wp_get_current_user();

zpa_custom_params("Action","Triggered update");

//Your application code...

The added parameter values will be displayed as follows under Traces > Summary > Custom Parameters:


Custom parameters can be found only if the transaction has an error or if the trace is populated for that transaction.

Was this document helpful?

Would you like to help us improve our documents? Tell us what you think we could do better.

We're sorry to hear that you're not satisfied with the document. We'd love to learn what we could do to improve the experience.

Thanks for taking the time to share your feedback. We'll use your feedback to improve our online help resources.

Shortlink has been copied!