Zernio
APIFor you
Zernio
APIFor you
API Reference

Audiences

List custom audiencesGETCreate custom audiencePOSTGet audience detailsGETUpdate an audiencePUTDelete custom audienceDELETEAdd users to audiencePOSTRemove users from audienceDELETEReplace audience companiesPOST
Dashboard
OverviewPlatformsAPI ReferenceResources
Audiences

Add users to audience

Uploads customer emails (and phone numbers on Meta) to a customer list audience, hashed before they are sent.

Data is SHA256-hashed server-side before sending to the platform. Email is used on every platform; phone is used on Meta only (other platforms ignore it). On TikTok and Pinterest, the first upload also provisions the audience (deferred create). LinkedIn uploads are full-replace. Max 10,000 users per request.

customer_list only. A LinkedIn company_list audience takes company rows, not people: send those to POST /v1/ads/audiences/{audienceId}/companies. This endpoint 422s for every other audience type.


PlatformsMetaGoogleTikTokLinkedInPinterestX
POST
/v1/ads/audiences/{audienceId}/users

Authorization

bearerAuth
AuthorizationBearer <token>

API key authentication: send your Zernio API key in the Authorization header, prefixed with Bearer.

In: header

Path Parameters

audienceId*string

The Zernio audience id (the id field of GET /v1/ads/audiences), not the platform segment id.

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

application/json

application/json

import Zernio from '@zernio/node';const zernio = new Zernio({ apiKey: process.env.ZERNIO_API_KEY });const { data } = await zernio.adaudiences.addUsersToAdAudience({  path: {    audienceId: 'audience_abc123',  },  body: {    users: [      {        email: 'user@example.com',        phone: 'string',      },    ],  },});console.log(data);
{  "message": "string",  "numReceived": 0,  "numInvalid": 0}
Was this page helpful?

Delete custom audience

Removes a custom audience from its ad platform (archiving it where the platform does not delete). Removes the audience on its ad platform, then deletes the Zernio record. Meta, Google, TikTok, LinkedIn list and engagement segments, and X are deleted; Pinterest audiences and LinkedIn `website_retargeting` segments are archived, which is how those platforms remove them. `saved_targeting` audiences exist only on Zernio, so only the local record is removed. If the platform refuses, the error is returned and the Zernio record is kept, so a retry is safe. An audience the platform no longer has counts as removed. Google Ads does not allow removing lookalike lists through its API, so those return 422 `FEATURE_NOT_AVAILABLE`.

Remove users from audience

Removes customer emails and phone numbers from a Meta customer list audience. Same body as `POST /v1/ads/audiences/{audienceId}/users`: send plaintext rows, they are normalized and SHA256-hashed server-side exactly like an upload, so a row removes the person it added. Meta only, customer_list only. Every other platform returns 422 with code `feature_not_available`, and every other audience type returns 422. Max 10,000 users per request. Meta applies the removal asynchronously, so the audience size does not drop immediately.

users*array<>
Itemsitems <= 10000