Open Tracked/Integrations/Brevo tag for server Google tag manager

Brevo tag for server Google tag manager

Brevo's contacts API lets a server container add or update subscribers without exposing your key. Consent decides what you may do.

4 min read · Updated October 26, 2026

SSign-up eventServer container tagBrevo contact
In this guide
Key takeaways
  • Call Brevo's contacts endpoint from a tag with an API key kept in a secure field.
  • Use updateEnabled so repeat sign-ups update instead of failing.
  • Respect consent: add to marketing lists only when the visitor agreed.

Brevo (formerly Sendinblue) is an e-mail and SMS platform with an API for contacts. If your sign-up form is custom, or you want a sign-up to feed Brevo and your ad platforms at once, a server container can do the Brevo part safely. This page shows the pattern. Check Brevo's API documentation for the current endpoints. It parallels Mailchimp from a server container.

What you need

  • A Brevo API key.
  • The ID of the list to add contacts to.
  • A sign-up event that carries the e-mail and a consent flag.
Try it

Works with your stack

Grab a logo and throw it. These are the tools Open Tracked already talks to.

Grab one. Throw it.

The request

const sendHttpRequest = require("sendHttpRequest");
const JSON = require("JSON");
const getEventData = require("getEventData");

sendHttpRequest("https://api.brevo.com/v3/contacts", (statusCode) => {
  (statusCode === 201 || statusCode === 204) ? data.gtmOnSuccess() : data.gtmOnFailure();
}, {
  method: "POST",
  headers: {
    "api-key": data.apiKey,
    "Content-Type": "application/json",
    "Accept": "application/json"
  },
  timeout: 4000
}, JSON.stringify({
  email: data.email,
  attributes: { FIRSTNAME: data.firstName, SOURCE: data.source },
  listIds: [data.listId],
  updateEnabled: true
}));

A new contact returns 201, and an update with updateEnabled returns 204. Allow https://api.brevo.com/* in the template permissions.

  • Trigger only when the visitor ticked a marketing consent box.
  • For double opt-in, use Brevo's double opt-in flow so the contact confirms by e-mail.
  • Store the consent source and date in an attribute.
  • Never re-subscribe someone who unsubscribed.
For online stores

Orders from your store, back to the ad that earned them

Your store sends the order once. Open Tracked passes it on to each ad platform, cleaned and deduplicated.

Errors

Symptom400
Likely causeAn invalid e-mail or attribute name.
FixValidate the e-mail; use the exact attribute names from your Brevo account.
Symptom401
Likely causeThe API key is wrong.
FixCheck it.
SymptomDuplicates
Likely causeNo updateEnabled.
FixSet it.
SymptomContacts without consent
Likely causeThe trigger does not check the flag.
FixAdd a condition.

Test

  1. Send a test sign-up in server Preview with a safe address.
  2. Check the tag status and response.
  3. Check the contact and its attributes in Brevo.
  4. Send the same address again: it should update, not fail.
0 of 5 done

A realistic example

A publisher has a newsletter sign-up form built into its theme, and wants sign-ups to reach Brevo, Meta and its own database without exposing a key in the page. It sends one sign_up event to its tagging server with the e-mail, the consent flag and a source. The container checks the flag, adds the contact to Brevo with the source as an attribute, and sends a hashed copy to Meta for audience building. A month later the team compares sign-ups by source in Brevo and finds that the in-article form brings three times as many as the footer form. One event now feeds three systems, and the Brevo key is stored where only the server can read it. That is the real benefit of doing it in the container.

Keep it healthy

Check the tag's responses in the logs after launch. A change in an attribute name in Brevo, or a revoked key, will show up as errors. Put a weekly reminder in the calendar to compare the number of sign-ups in your site's analytics with the number of new contacts in Brevo. A gap means something is failing quietly.

Check your setup

Check your tracking in one pass

This is an example. Run the check on your own site to see where yours stands.

Frequently asked questions

Can a server container add contacts to Brevo?

Yes, by calling Brevo's contacts API from a tag.

What does updateEnabled do?

It updates an existing contact instead of returning an error.

How do I use double opt-in?

Use Brevo's double opt-in flow so the contact confirms by e-mail.

Where should the API key live?

In a secure server-side field.

Do I need consent?

Yes, for marketing lists. Check it before sending.

Do I need spreadsheets to read my results?

No. Once tracking is live, the Open Tracked analytics shows spend, revenue, ROAS and profit, and you can ask Ari, the built-in AI assistant, questions about your own numbers in plain words. Ari's allowance depends on your analytics plan.

Is Open Tracked different from Open Track or Open Space Track?

No. Open Tracked is the official name of our server-side tracking platform, and the website is opentracked.io. Many people search for it as Open Track, OpenTrack or Open Space Track. All of them lead to the same product: server-side Google Tag Manager hosting, first-party analytics and a CRM pipeline.

Fix your tracking at the source

Open Tracked hosts your server-side Tag Manager, keeps first-party cookies alive and shows what each ad is really worth.

Open Tracked
Written by

The Open Tracked team

We build Open Tracked: server-side tracking hosting, analytics and the tools around them, for stores that spend on ads. Questions about this guide, or an idea for the next one?

Write to us Read the docs

Was this article helpful?

Comments

Loading comments...

Turn better tracking into better marketing performance

Start free