List your OAuth apps
Your own OAuth apps on social platforms. A connect runs on one when it passes its id as oauthAppId: the consent screen then shows your app's name and logo, and the platform's rate limits and quotas are your app's. Add as many as you need, any number per platform. Also lists, in platforms, which platforms accept your own app and what to set up on each. Pages are ordered by id: pass pagination.nextCursor back as cursor until it is null. Like every OAuth-app call, it needs the account owner or a full-access team member, on a session or a full-scope API key.
Authorization
bearerAuth API key authentication: send your Zernio API key in the Authorization header, prefixed with Bearer.
In: header
Query Parameters
1 <= value <= 10050pagination.nextCursor from the previous page.
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.connect.listOAuthApps();console.log(data);{ "apps": [ { "id": "string", "platform": "string", "label": "string", "clientId": "string", "scopeAreas": [ "posting" ], "status": "ok", "lastCheckedAt": "2019-08-24T14:15:22Z", "lastError": "string", "accountCount": 0, "redirectUri": "http://example.com", "webhook": { "callbackUrl": "http://example.com", "verifyToken": "string", "object": "page", "fields": [ "string" ] }, "createdAt": "2019-08-24T14:15:22Z" } ], "pagination": { "nextCursor": "string" }, "platforms": [ { "platform": "string", "redirectUri": "http://example.com", "coreScopes": [ "string" ], "scopeAreas": [ { "area": "posting", "scopes": [ "string" ] } ] } ]}List Google Analytics properties for a pending connect
For headless flows. When the connect started with `redirect_url=...?headless=true` and the Google account can read several GA4 properties, Zernio redirects to your `redirect_url` with `step=select_property`, `profileId`, `platform=googleanalytics` and a `pendingDataToken`. Call this to list the properties and show your own picker, then call `POST /v1/connect/googleanalytics/select-property`. Listing does not consume the token. A headless token passes through your own URLs, so it is honored only together with your API key (or connect token) for the same profile. It expires after one hour.
Connect the chosen Google Analytics property
For headless flows. Connects the property the user picked as a `googleanalytics` account and returns where to send the user next: your `redirect_url` with `connected=googleanalytics`, `profileId`, `accountId` and `username`, or an `error` when the connect was refused (for example a billing block). Consumes the `pendingDataToken`; a refused or failed attempt leaves it usable for a retry. Send your API key (or connect token) for the same profile with a headless token.