Skip to main content
Use your Invoca Tag’s built-in test mode to confirm it’s loading, swapping numbers, and capturing Marketing Data correctly before setting a revision live.
Your Invoca Tag includes a built-in testing feature you can use whether you’re troubleshooting an error or just confirming everything works. We recommend testing after every new revision, before setting it live. Before you begin: Make sure you’ve configured your Invoca Tag and deployed it on at least one landing page. This article can help answer:
  • Is my Invoca Tag loading on my landing page?
  • Is my Invoca Tag swapping phone numbers correctly?
  • Is my Invoca Tag collecting Marketing Data correctly?
  • Why isn’t my Invoca Tag loading correctly?

Accessing your Tag’s test function

The test feature lets you preview how a new revision will behave before setting it live.
  1. Deploy your Invoca Tag to the landing page you want to observe.
  2. Open a new tab in your browser and enter the URL of your landing page in the address bar — but don’t navigate to it yet. We recommend an Incognito or Private Browsing window.
  3. At the end of the URL, add ?invoca_rev=draft, then press Enter.
NoteIf you use the “Parameters Required to Run” advanced setting, make sure at least one required parameter is included in your URL’s query string alongside invoca_rev, separated by & — otherwise your Tag won’t load.
Your browser now loads the page with your most recent draft’s settings, rather than the live revision. If you maintain a staging environment, deploy the same Invoca Tag to both staging and production. You can also test other saved revisions:
  • ?invoca_rev=live: view the page with your currently live revision — useful for comparing against a draft.
  • ?invoca_rev=# (replace # with a revision number): view the page with any specific saved revision — useful when troubleshooting requires reverting to an older, working version.

Confirming your Tag is working correctly

  1. Load your landing page with the test function active, as described above.
  2. Open your browser’s Developer Console (right-click the page and select Inspect).
  3. Click the Console tab, type Invoca, and press Enter. If your Tag is loaded correctly, you’ll see the Invoca object returned.
  4. To confirm numbers are swapping correctly, type Invoca.PNAPI.display() and press Enter. This returns a log of which numbers were found and replaced, along with any errors or warnings. Review the results for:
    • Are the numbers you want tracked actually swapping for Invoca promo numbers?
    • Are numbers you want excluded staying the same, as expected?
    • Are numbers swapping for the correct type of promo number (toll-free vs. local, depending on availability)?
    • Are any expected numbers wrapped in an excluded HTML node? Invoca won’t swap numbers inside script, textarea, map, style, object, input, video, audio, img, canvas, br, hr, or noscript tags — this includes numbers intended for Destinations.
  5. To confirm Marketing Data capture, visit your landing page through a few different sources (organic search, paid search, social, direct), or simulate this by adding the relevant URL parameters, cookies, or JavaScript data to your session. After each test, return to the console and enter Invoca.PNAPI.debugAttribution(), then look under shared_attribution for the values Invoca captured. Confirm they match what you expected for that test.

Troubleshooting common errors

Invoca doesn’t seem to be loading at all. Load your page with the test function active, open the console, type Invoca, and press Enter.
  • If the console reports that Invoca is undefined, your Tag isn’t present on the page — check your source code for the Invoca Tag snippet. If it’s there and the Tag still isn’t loading, reach out to your account team or support@invoca.com.
  • If Invoca returns an object, your Tag loaded successfully — continue troubleshooting below for the specific issue you’re seeing.
Phone numbers aren’t swapping at all. With the test function active, type Invoca.PNAPI.display() in the console. If nothing swapped, try re-running the Tag manually with Invoca.PNAPI.run() — this rules out a page-load timing issue interfering with the Tag. If that doesn’t resolve it, reach out to your account team or support@invoca.com.

Where to go next

Last modified on September 21, 2026