Below are the instructions for how to send web reservations to CallPotential’s endpoint so they can be tracked appropriately and integrated into the marketing analytics suite.
Please note that the attached swagger document has additional instructions.
Endpoint
The web reservation endpoint is a POST call to the http://tracking-prod.callpotential.com/web-reservation/sitelink endpoint. For more information on the configuration of the endpoint call, see https://github.com/callpotential/CP-TransmissionService/blob/master/application/swagger.yaml or the swagger definition below.
Ad Session Info
The google analytics cookie is stored with the key “_ga” in the site cookies. See https://stackoverflow.com/questions/10730362/get-cookie-by-name for more information on how to do that in javascript. To get the gclid, you will need to parse the URL of the page that contains the gclid parameter. The full URL can be accessed via window.location.href
in javascript. Because the gclid is not persistent across pages, you will need to store it if the user submits a web reservation on another page.
You can optionally pass in the glsrc, the timestamp of when the conversion occurred, and any custom data to the endpoint.