How to Ping from TrackDrive to CallGrid (RTB)

Integrations

Overview

Note: the steps and reply fields described for CallGrid reflect CallGrid's Bid API as of October 2026 and may change as CallGrid updates its product.

A TrackDrive account can sell calls to a CallGrid buyer through CallGrid's Bid API. Before bridging a call, TrackDrive pings the bid URL CallGrid gave you. When the reply carries a SIP address, TrackDrive accepts the bid, takes the revenue and duration from the reply, and sends the call to that SIP address.

This guide builds the buyer by hand: no buyer template is provided for CallGrid.

What CallGrid Sends Back

CallGrid answers a bid with a JSON body:

  • Accepted bid: code is 1000, with dynamicBid (the payout), dynamicDuration (the seconds a call must last to convert), expirationSeconds, and dynamicSipAddress (where to send the call). When the bid URL carries pstn=true, the reply carries dynamicPhoneNumber instead of a SIP address.
  • Rejected bid: a code of 4000 or above and no address to send the call to.
  • Bid needing confirmation: some CallGrid buyers require a separate confirmation request before they return an address. TrackDrive does not send that request, so the setup below rejects such a bid.

Step 1 (In CallGrid): Get the Bid URL

CallGrid supplies a bid URL for your campaign, along the lines of:

https://bid.callgrid.com/api/bid/<your-id>?CallerId=...

The query string names the caller details CallGrid wants. CallerId is required; InboundStateCode, InboundZipCode, and any custom parameters the buyer asked for are optional.

Step 2: Replace CallGrid's Parameters With Tokens

Give each parameter a TrackDrive token as its value:

  • CallerId takes [caller_number].
  • InboundStateCode takes [caller_state].
  • InboundZipCode takes [caller_zip].

For example:

https://bid.callgrid.com/api/bid/<your-id>?CallerId=[caller_number]&InboundStateCode=[caller_state]&InboundZipCode=[caller_zip]

CallGrid rejects a caller ID without a country code, so use [caller_number], which includes the +1, rather than [caller_id_short]. TrackDrive URL-encodes token values in a ping URL, so the + arrives as %2B.

The URL CallGrid gives you may carry placeholders from another platform, such as CallGrid's own [[tag:CallerId]] or a Ringba tag like [tag:InboundNumber:Number]. TrackDrive does not fill those in: replace every one with a TrackDrive token. The "Ping and Postback Token Formats" article lists which token matches each tag.

Step 3: Create the Buyer

In the sidebar, open Campaigns and click Buyers, then click Add Buyer. Fill in the buyer's Name and Number. The Number must be a phone number or SIP address; on an accepted bid the SIP address in CallGrid's reply replaces it. Click Create Buyer.

Step 4: Add a Ping Conversion

On the buyer's edit page, find the Caps, Hours, & Conversions card and click Manage to open the buyer's Conversion Settings. On the buyer's conversion setting, click New Conversion Criteria (Add Conversion Criteria when the buyer has more than one conversion setting). If the buyer has no conversion setting, click New Conversion Setting and then Create first. In the form that opens, fill in:

  • Conversion Type: RTB Ping/Post Dynamic Buyer(s).
  • Bid Price (shown as Revenue on some accounts) and Duration: defaults used only when the reply leaves those values out.
  • What System Are You Interfacing With?: Custom RTB Ping/Post.
  • Method: GET.
  • Remote URL: the bid URL from Step 2.

Step 5: Accept Only a Reply With a SIP Address

Under Was The Response Acceptable? set:

  • Acceptable HTTP Status Codes: 200.
  • Extract Value From Response Body: dynamicSipAddress.
  • Operator: Equals.
  • Check If Response/Extracted Value: (any).

(any) accepts the reply only when the extracted value is present. A rejected bid, or one waiting on confirmation, has no SIP address, so TrackDrive treats the ping as failed instead of sending the call to the buyer's own Number.

Under Extract Buyer(s) From The Response set:

  • Telephone Number Path: dynamicSipAddress.
  • Revenue Path: dynamicBid.
  • Conversion Duration Path: dynamicDuration.

Click Create to save the conversion criteria.

Delivering by Phone Number Instead (PSTN)

SIP is CallGrid's default delivery and the one this guide recommends. To receive a phone number instead, add pstn=true to the bid URL and set both Extract Value From Response Body and Telephone Number Path to dynamicPhoneNumber. CallGrid rejects a PSTN call whose caller ID differs from the one in the bid, so the call must reach CallGrid showing the same caller ID that [caller_number] sent in the bid.

Checking the Reply

After a call pings the buyer, open the call and click the Webhook Logs tab. The ping's log shows the URL TrackDrive sent, the Response Code:, and the Response Body CallGrid returned. Compare the code and field names in the reply with the paths you set in Step 5. A code of 4000 or above means CallGrid did not accept the bid; the message CallGrid returns with it says why. Some codes are ordinary declines, such as a campaign at capacity or a caller already paid out. Others point at the request: 4003 means the caller ID is not in the format CallGrid requires, and 4001 means the campaign is disabled or the ID in the bid URL is not valid. Code 5001 means too many bids were sent too quickly.

Contact TrackDrive

Questions?

We're here to help. Reach out and a Voice Marketing Cloud Specialist will get back to you.

Email support@trackdrive.com
Request A Demo

Request A Demo.

See how you can improve your marketing and the customer experience with the Voice Marketing Cloud.

Request a demo