Skip to main content
Dynamic Callbacks/Postbacks

How to add dynamic callback URLs to tracking URLs and the supported parameters & macros.

Updated over 11 months ago

What is a Callback/Postback

A callback, alternatively referred to as a postback, involves an HTTP or HTTPS request exchanged between two servers. In the context of Swaarm, a callback is initiated promptly upon the tracking of a new activity within an ad engagement (through the tracking URL) or from the application itself (via the SDK). You have the option to configure real-time callbacks, enabling the direct transmission of advertising IDs, attribution details, and app data in raw form to your servers.

Dynamic Callback URLs

Swaarm enables adding dynamic callback URLs to tracking URLs, ensuring automatic callback transmission when a user interacts with the tracker. Your partners can add the callbacks directly inside click tracking links without the need to preconfigure postback links for your partners.

To do the same, your partners can add the following parameters to their click tracking links:

  • install_callback=INSERT_URL_ENCODED_POSTBACK_URL

  • event_callback_${EVENT_MAPPING_ID}=INSERT_URL_ENCODED_POSTBACK_URL

The ${EVENT_MAPPING_ID} for the event, can be taken from the App Edit page of the platforms as shown in the image below:

Tracking Links with Callback Parameters

The tracking links with the respective event callouts can also be directly copied from the platform from the offer details page as shown below and shared with your partners. The link will include the parameter for install along with the public events set for the offer.


Example Tracking Links with Sample Callbacks

Example with just the Install Callback:

https://yourdomain.trckswrm.com/click?offer_id=3&pub_id=3&install_callback=https%3A%2F%2Frequestlogger.internal.abc.com%2Finstall%3Fid%3D%23%7Bid%7D

Example with just the Event Callback:

Event mapping id: register

https://yourdomain.trckswrm.com/click?offer_id=3&pub_id=3&event_callback_register=https%3A%2F%2Frequestlogger.internal.abc.com%2Firegister%3Fid%3D%23%7Bid%7D

Example with Install and Multiple Event Callbacks

This can also be configured in the same URL as shown below in the example:

Event mapping id: register, purchase

https://yourdomain.trckswrm.com/click?offer_id=3&pub_id=3&install_callback=https%3A%2F%2Frequestlogger.internal.abc.com%2Finstall%3Fid%3D%23%7Bid%7D%26event_callback_register=https%3A%2F%2Frequestlogger.internal.abc.com%3Fid%3D%23%7Bid%7D%26event%3Dreg%26event_callback_purchase=https%3A%2F%2Frequestlogger.internal.abc.com%3Fid%3D%23%7Bid%7D%26event%3Dpurchase

โœ๏ธ Encode the Callback URL

Any of the online url encoder like the one here can be used to encode the callback URL.


Callback Macros

All macros listed here are supported can be used in the callback URLs by your partners.

Did this answer your question?