Skip to main content
Markifact supports two ways to connect X Ads: using the built-in Markifact app (Quick Connect) or connecting through your own X app (Custom App). With a custom app, every request Markifact makes to the X Ads API runs under your app, so your clients never see Markifact in their connected apps.
Custom app connections are available on the Team plan. See White-label Connections for the overview.

Quick Connect vs Custom App


What You Need

Four values, because the X Ads API uses OAuth 1.0a rather than OAuth 2.0. The API key pair identifies your app and the access token pair identifies the user, and every request is signed with a combination of the two.
All four values must come from the same app. An access token generated under a different API key cannot be signed with this one, and X rejects the request. There is nothing to refresh: OAuth 1.0a tokens stay valid until the user revokes the app.
Already have your own authorization flow? If your systems already hold an access token pair issued by your app, skip to Connect to Markifact.

Setting Up Your Custom X Ads App

1

Create the App

  1. Open the X developer portal and create a project and an app inside it
  2. Enter the app name. This is the branding users see when they authorize
  3. Under User authentication settings, turn on OAuth 1.0a, set App permissions to Read and write, and enter a callback URL you control (for example https://www.youragency.com/x-callback) and your website URL
2

Request Ads API Access

The Ads API is not available to every app. Apply for X Ads API access for your developer account and wait for approval. Agencies that already run their own integrations will have this in place; until it is granted, the accounts endpoint returns authorization errors.
3

Copy the API Key Pair

Open the app’s Keys and tokens tab and copy the API Key and API Key Secret (shown once when generated; regenerate if you lost them).
4

Generate the Access Token Pair

On the same tab, under Access Token and Secret, click Generate. The tokens are created for the X account you are signed in as, so sign in as the user who has access to the ad accounts you want to manage.Copy the Access Token and Access Token Secret. Make sure the permissions shown next to them say Read and Write; if they say Read only, fix the app permissions first and regenerate.
Important: Keep these values secure. Anyone holding all four can act on every ad account the user can reach.
5

Connect to Markifact

  1. In Markifact, go to the Connections page
  2. Click Connect on X Ads
  3. Select the Custom App (White-label) tab
  4. Enter a Connection Name (for example “Acme Agency X Ads”)
  5. Paste your API Key, API Key Secret, Access Token, and Access Token Secret
  6. Click Verify & Connect
Markifact makes one signed call that lists the ad accounts the tokens can reach. Nothing is saved unless it succeeds and returns at least one account.
Managing a client’s ad account rather than your own? Ask the client to add your X user to their ad account in X Ads Manager, then generate the access token pair as that user. The tokens carry whatever access that user has.

Selecting Your Connection

Custom app connections appear under the name you chose, with a Custom app badge on the Connections page. Select them in X Ads nodes, agents, and MCP exactly like any other X Ads connection.

Rotating or Replacing the Tokens

Add the connection again with the same connection name and the new values. Markifact replaces the stored credentials in place, so workflows and agents bound to the connection keep working.

Troubleshooting

The four values do not belong together, or one was mistyped. The access token must have been generated under the same API key you pasted. Regenerate the access token pair on the app’s Keys and tokens tab and paste all four again.
Either your developer account has no Ads API access yet, or the access token was generated while the app permissions were Read only. Fix the permissions under User authentication settings, regenerate the token pair (changing permissions does not update existing tokens), and try again.
The X user behind the access token has no access to any ad account. Add them in X Ads Manager under account access, then regenerate the tokens.
The accounts endpoint allows 5 requests per 15 minutes per token, which the connection check uses once. Wait a few minutes and try again.

Summary


White-label Connections

Overview of custom app connections across channels

Get Report

Pull X Ads performance data