Step-by-step guide to connect your own X (Twitter) API credentials with Ayrshare
On March 31, 2026, X changed how third-party platforms access its API. As a result, every Ayrshare account posting to X through Ayrshare must register its own X Developer App and use its API Key and API Secret on every request.This is a platform-wide change mandated by X that affects all third-party tools.
BYO keys are set once per platform (account-wide), not per customer or sub-profile. You create one X Developer App under your own X account, and the same API Key + API Secret apply account-wide for X — they are used for every sub-profile / end-user that links X under your Ayrshare account. If you have a Business or Enterprise plan with hundreds of sub-profiles, you do not need to repeat this setup for each one. You set it up once for the X platform, then pass the same two headers on every request.
We’ve streamlined the setup process to make this as simple as possible, and it should take less than 10 minutes to complete. Follow our step-by-step guide below, and if you need any help along the way, our team is here to assist.
You only create one X Developer App per Ayrshare account. The same app and its API Key + API Secret are reused for every sub-profile / end-user you later link under your Ayrshare account. You do not create a new app per customer.
1
Navigate to Apps
In the Developer Console, navigate to Apps.
2
Create the app
In the App dashboard, click Create App (see X’s App setup docs for details). Enter an app name (typically your brand name). This name will appear in the OAuth authorization screen when users connect their X account.
3
Select environment
Select the Production environment in the dropdown.
4
Close the initial credentials popup
X will generate several credentials. Ignore these credentials and close this window.
Under “Apps,” locate the new app (refresh the page if it doesn’t appear), then click it to view its details.Under User authentication settings, click Set up.
2
Set app permissions
Under App permissions, select Read and write and Direct message. This is required for full feature support, including posting and DMs.
3
Set app type
Under Type of App, select Web App, Automated App or Bot. This is the right choice for server-side integrations like Ayrshare.
4
Set callback and website URLs
Under App info:
Callback URL: Add both of the following callback URLs:
https://profile.ayrshare.com/social-accounts
https://app.ayrshare.com/social-accounts
Website URL:https://app.ayrshare.com
Do not skip this step. These callback URLs are required for the OAuth linking flow. When your end-users authorize the X connection, X redirects them back to one of these URLs to complete the linking process. If these are missing, the OAuth flow will fail with a 403 Callback URL not approved error.
5
Save your settings
Click Save. You can ignore the OAuth 2.0 popup, since you will only be using 2 of the OAuth 1.0 keys (API Key and API Secret).
Important: Set permissions before linking. The permissions you choose here determine what your app can do. If you change permissions after linking your X account via OAuth, you’ll need to re-link so the new Access Token inherits the updated permissions.
Please make sure you store these 2 keys:
API Key (aka Consumer Key, the X app identifier)
API Secret (aka Consumer Secret)
You do NOT need to manually generate Access Tokens. Ayrshare handles this automatically when you link your X account via OAuth.
X now uses credit-based API billing, purchased through the developer console.
1
Navigate to billing
In the Developer Console, click Billing → Credits in the left sidebar.
2
Purchase credits
Purchase credits (the minimum is $5, which is enough for hundreds of API calls). Each API call is a fraction of a penny, so the cost should be minimal for most users.
3
Enable auto-recharge
You can enable auto-recharge to avoid service interruptions, and manage your spend cap by setting a maximum amount you can spend in your billing cycle.
Your API calls will fail without credits. X’s API is pay-per-use. If your credit balance is zero, every API request will return a 402 CreditsDepleted error with the message “Your enrolled account does not have any credits to fulfill this request.” This includes posting, reading tweets, and user lookups. Load credits before testing your integration. See How X API Pricing Works for a full update on X’s pricing.
In Step 3, you saved these 2 items securely in your own env, config, or secrets manager:
API Key (aka Consumer Key, the X app identifier)
API Secret (aka Consumer Secret)
Now, add your X credentials to the headers of your Ayrshare API calls.
Your keys stay private. The API Key and API Secret you send in these headers are used for that request only and are not stored by Ayrshare. Creating a linking URL is the one exception, described in the Security section below.
If your app permissions are misconfigured, your API request may return a 403 Forbidden error with the message: “Your client app is not configured with the appropriate OAuth1 app permissions.”
If you see this error, update your app permissions to Read and write and Direct message in the X Developer Console, then re-link your X account via OAuth so the new Access Token inherits the updated permissions.
curl -X POST https://api.ayrshare.com/api/post \ -H "Authorization: Bearer YOUR_AYRSHARE_API_KEY" \ -H "X-Twitter-OAuth1-Api-Key: your_api_key" \ -H "X-Twitter-OAuth1-Api-Secret: your_api_secret" \ -H "Content-Type: application/json" \ -d '{"post": "Hello from my own X App!", "platforms": ["twitter"]}'
const response = await fetch("https://api.ayrshare.com/api/post", { method: "POST", headers: { "Authorization": "Bearer YOUR_AYRSHARE_API_KEY", "Content-Type": "application/json", "X-Twitter-OAuth1-Api-Key": process.env.X_API_KEY, "X-Twitter-OAuth1-Api-Secret": process.env.X_API_SECRET, }, body: JSON.stringify({ post: "Hello from my own X App!", platforms: ["twitter"], }),});
import osimport requestsheaders = { "Authorization": "Bearer YOUR_AYRSHARE_API_KEY", "Content-Type": "application/json", "X-Twitter-OAuth1-Api-Key": os.environ["X_API_KEY"], "X-Twitter-OAuth1-Api-Secret": os.environ["X_API_SECRET"],}response = requests.post( "https://api.ayrshare.com/api/post", headers=headers, json={"post": "Hello from my own X App!", "platforms": ["twitter"]},)
Your existing automations and workflows will continue working as long as you include your API Key and API Secret headers in every request that targets X.
If you have sub-profiles that are already linked to X through Ayrshare, those profiles need to re-link their X accounts after you switch to BYO keys. This is because the existing access tokens were issued under Ayrshare’s X app and cannot be used with your consumer keys (OAuth 1.0a signatures are bound to the app that issued the token).
1
Include your keys in generateJWT
Add twitterApiKey and twitterApiSecret to your generateJWT call body. These are encrypted and stored with the linking session, and are not exposed to your end users.
Creating a linking URL is the only place your consumer keys go in the body — this request, or POST /profiles/link-sessions. Every other X request uses the headers described above.
2
Have users re-link X
After generating the JWT with the keys included, your users need to reconnect their X account through the profile linking page. The OAuth consent screen will now show your app name instead of Ayrshare’s.To streamline this, you can:
Unlink accounts programmatically via the Unlink API, then have users re-authorize
Use allowedSocial to show only X on the linking page during the migration flow
3
Keep sending headers on all API calls
After re-linking, continue including X-Twitter-OAuth1-Api-Key and X-Twitter-OAuth1-Api-Secret headers on every API call (posting, analytics, comments, etc.).
Once a profile has re-linked under your X app, all subsequent posts for that profile will use your credentials. You can verify this by checking the Usage page in your X Developer Console.
Make a test call through the Ayrshare API with your new headers to confirm everything is working. The /analytics/social endpoint is a good lightweight test, since it won’t create any posts.
Previously, Ayrshare covered the cost of X’s API usage on your behalf. Under X’s current model, each Ayrshare customer maintains their own X Developer account and pays X directly for the API requests their application makes. (One X Developer account per Ayrshare account, not per end-user. All your sub-profiles share the same X Developer account and credit balance.)X’s pricing model is pay-per-use: you purchase credits in the X Developer Console, and they are deducted as API requests are made. No contracts or subscriptions are needed.Typical operations are inexpensive. For example:
Operation
Approximate cost
Creating a post (text only)
~$0.01 per post
Creating a post with media
~$0.02 per post (media upload and post creation are separate requests)
Reading a post
~$0.005 per read
User lookup
~$0.01 per lookup
Sending a DM
~$0.01 per message
Reading DM events
~$0.01 per event
User interactions (follow, like, etc.)
~$0.015 per request
For context, if you’re posting about 100 times per month, your direct X cost would likely be around $1, and posts with media would be roughly $2 per month.
X’s pay-per-use pricing is currently in a pilot phase. Rates are subject to change, and additional costs may be introduced. Always check the Developer Console for the most current pricing. See X’s pricing information breakdown.
We know this introduces a cost that didn’t exist before, and we want to be transparent about that. At the same time, this model also unlocks several benefits that weren’t possible under the previous shared-key setup.
Using your own X API credentials provides more control and reliability than the previous shared-key model. This includes:
Branded OAuth experience: Users see your app name and branding when authorizing X access.
Dedicated rate limits: Your API usage is governed by your own X Developer account limits, separate from other Ayrshare users. You can monitor your usage in the X Developer Console and review the X API rate limits documentation.
Credential control: Your API Key and Secret stay in your own X Developer account. Ayrshare does not store the keys you send in request headers. Creating a linking URL is the one exception, described in the Security section below.
Portability: Because users authenticate with your X App, your integration remains fully under your control.
Usage visibility: Your X Developer dashboard shows API requests, rate limits, and credit usage.
X is the first platform requiring this model, but more platforms are moving toward “bring your own API key.” We’re expanding this capability across Ayrshare, so developers have the same control and independence across all social platforms.
The API Key and API Secret you send in request headers are used for that request only and are not stored by Ayrshare.
Creating a linking URL is the exception. When you pass twitterApiKey and twitterApiSecret to POST /profiles/generateJWT or POST /profiles/link-sessions, the pair is encrypted and stored with that linking session, because the linking page needs it when your user authorizes X a moment later. It is removed when you revoke the link, or when an expired link is next opened or checked, and in any case it is deleted with the session record within 30 days.
Do I need to set this up for every customer / sub-profile?
No. You set up one X Developer App under your own X account, and the same API Key + API Secret are reused for every sub-profile / end-user you link under your Ayrshare account.
You create the X Developer App once.
You pass the same two headers (X-Twitter-OAuth1-Api-Key and X-Twitter-OAuth1-Api-Secret) on every Ayrshare API call, regardless of which sub-profile the call is for.
Your end-users still each go through the OAuth linking flow to authorize their own X account, but they do not need their own X Developer App or API keys. They connect through your app.
All sub-profiles share the same X Developer account, the same rate limits, and the same credit balance.
The only time you handle the keys per-profile is in the generateJWT body during migration, which is still your same two keys, just delivered to the linking page so end-users can re-authorize under your app.
Is the X API key requirement active now?
Yes. As of March 31, 2026, all X operations through Ayrshare require your own X API credentials. If you haven’t set up your X Developer account yet, follow the steps above.
What happens if I don't add my X API key to Ayrshare?
Posting to X through Ayrshare requires your own X API credentials. Requests without valid BYO credentials are rejected. Posting to other platforms (Instagram, LinkedIn, Facebook, TikTok, etc.) is unaffected.
How much does the X API cost?
X charges per API call. Creating a post costs about $0.01, and reading a post costs about $0.005. For example, publishing 100 posts per month would cost roughly $1. See X’s pricing page for the full details.
Does this change my Ayrshare subscription price?
No. Your Ayrshare subscription price stays the same. The only additional cost is the X API usage fee billed directly by X through your developer account.
Does Ayrshare store my X API credentials?
For ordinary API requests, no: the API Key and API Secret you send in the headers are used for that request only and are not stored. Creating a linking URL is the exception, because the linking page needs the pair when your user authorizes X. There it is encrypted and stored with the linking session, then removed when you revoke the link, when an expired link is next opened or checked, or with the session record within 30 days. See the Security section above, and X’s authentication security guide for general best practices.
I already have an X Developer account. Can I use my existing key?
Yes. You can use your existing X App as long as it has “Read and write” permissions enabled (and Direct Messages if you use DM features).You’ll need your API Key (Consumer Key) and API Secret (Consumer Secret) from the Keys and tokens section of the X Developer Console. Link your X account via OAuth, then include these 2 headers in your Ayrshare API requests.If you’ve changed your app permissions since the initial setup, re-link your X account so the Access Token inherits the updated permissions.
The X Developer Portal shows many credentials. Which ones do I actually need?
You need your API Key (Consumer Key) and API Secret (Consumer Secret). See the header reference table above for exactly which Ayrshare header each one maps to. You can ignore the Client ID, Client Secret, Bearer Token, Access Token, and Access Token Secret.
What's the difference between 'API Key' and 'Client ID'?
They’re completely different credentials for different authentication methods:
API Key (also called “Consumer Key”) is for OAuth 1.0a. API Key (Consumer Key) + API Secret is what Ayrshare uses. It works with all X features, tokens never expire, and no refresh logic is needed.
Client ID is for OAuth 2.0. You do NOT need this for Ayrshare. OAuth 2.0 tokens expire after a short period and require refresh token management.
For Ayrshare, you only need your API Key and API Secret. You can ignore the Client ID, Client Secret, and Bearer Token.
Why OAuth 1.0a and not OAuth 2.0?
OAuth 2.0 access tokens expire every 2 hours and X’s refresh tokens are single-use (each refresh invalidates the old token). This makes it impossible to support a stateless BYO model, especially for scheduled posts. OAuth 1.0a tokens never expire, work with all X features, and require zero token management.
Do my existing users need to re-link their X accounts?
Yes. If your users linked X through Ayrshare before you set up BYO keys, they will need to reconnect. The existing access tokens were issued under Ayrshare’s X app and won’t work with your consumer keys. See Migrating Existing Profiles above for the step-by-step process.
Does this change affect posting to Instagram, LinkedIn, or other platforms?
No. This change only affects posting to X. All other platform integrations in Ayrshare continue working as usual.
What about RSS/Feed auto-posting to X?
RSS auto-posting to X is no longer supported. RSS feeds run automatically on a schedule, but the bring-your-own API key model requires credentials to be provided with each API request. Because of this, RSS feeds cannot authenticate when the post is sent.If you previously used RSS to post to X, we recommend switching to scheduled posts or direct API calls that include your credentials. RSS auto-posting to all other platforms is unchanged.
Why am I getting a 402 "CreditsDepleted" error?
This means your X Developer account has no API credits available. Go to console.x.com → Billing → Credits and purchase credits. Even $5 is enough for hundreds of API calls. Once credits are loaded, retry your request.
Why am I getting a 403 "Forbidden: OAuth1 App Permissions" error?
Your Access Token doesn’t have the right permissions. This usually means one of two things:
Your app permissions are set to “Read” instead of “Read and write.” Go to your app’s Settings in the Developer Console and change it to Read and write and Direct message.
You changed permissions after linking your X account. Access Tokens keep the permissions they were created with. Re-link your X account via OAuth so the new token inherits the updated permissions.
What if I need help setting this up?
Our support team is happy to help. If you have any questions or run into issues during setup, please reach out via support@ayrshare.com, and we’ll walk you through the process.
If you see a pair-mismatch error (e.g., “You provided Api-Key but not Api-Secret”), it means one of the two is missing. Both are always required.The error message will tell you which specific header is missing.
I'm getting a 403 error: "Callback URL not approved"
If you see this error when trying to link your X account, make sure you’ve added the required callback URLs to your X Developer App settings (under Authentication settings > Callback URI / Redirect URL):
Your X Developer account has no API credits loaded. Go to console.x.com → Billing → Credits and purchase credits. Even $5 is enough for hundreds of API calls.
I'm getting a 403 error: "oauth1 app permissions"
Your Access Token doesn’t have the right permissions. This usually means:
Your app permissions are set to “Read” instead of “Read and write.” Go to your app’s Settings in the Developer Console and change it to Read and write and Direct message.
You changed permissions after linking your X account. Access Tokens keep the permissions they were created with. Re-link your X account via OAuth so the new token inherits the updated permissions.
If you have any questions or run into issues while setting up your X API key, our engineering team is happy to help. You can reach us anytime at support@ayrshare.com.
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"Ayrshare Docs","colors":{"primary":"#2266C2","light":"#4985D8","dark":"#1A4E9A"},"logo":{"light":"https://mintcdn.com/ayrshare-docs/7bWzjvNjeuvs-M3N/images/logos/ayrshare-docs-logo-light.svg?fit=max\u0026auto=format\u0026n=7bWzjvNjeuvs-M3N\u0026q=85\u0026s=8d23367f493d06599eecbbfa2b6325cf","dark":"https://mintcdn.com/ayrshare-docs/7bWzjvNjeuvs-M3N/images/logos/ayrshare-docs-logo-dark.svg?fit=max\u0026auto=format\u0026n=7bWzjvNjeuvs-M3N\u0026q=85\u0026s=77590acef2781d2fec9a1b14b6e09b73","href":"https://www.ayrshare.com/docs"},"favicon":"https://mintcdn.com/ayrshare-docs/dKBti0xVDJrOZ19f/images/logos/icon-docs.png?fit=max\u0026auto=format\u0026n=dKBti0xVDJrOZ19f\u0026q=85\u0026s=9704762afaad78a9cfdd90a20cb1d253","api":{"playground":{"display":"simple"},"examples":{"languages":["bash","javascript","python","php","go","java"]},"mdx":{"auth":{"method":"bearer"},"server":"https://api.ayrshare.com/api"}},"appearance":{"default":"dark"},"background":{"decoration":"gradient"},"navbar":{"links":[{"href":"https://www.ayrshare.com/blog","label":"Blog"}],"primary":{"type":"button","label":"Dashboard","href":"https://app.ayrshare.com"}},"footer":{"socials":{"github":"https://github.com/ayrshare","x":"https://x.com/ayrshare","bluesky":"https://bsky.app/profile/ayrshare.com","facebook":"https://www.facebook.com/Ayrshare","linkedin":"https://www.linkedin.com/company/ayrshare","youtube":"https://www.youtube.com/@ayrshare"}},"seo":{"indexing":"navigable"},"styling":{"codeblocks":"system","latex":true},"integrations":{"gtm":{"tagId":"GTM-P23WG8W"},"plausible":{"domain":"docs.ayrshare.com"}},"contextual":{"options":["copy","chatgpt","claude","perplexity","cursor","vscode"],"display":"header"},"navigation":{"languages":[{"language":"en","href":"introduction"},{"language":"es","href":"es/introduction"},{"language":"cn","hidden":true,"href":"cn/introduction"},{"language":"zh","hidden":true,"href":"zh/introduction"},{"language":"pt-BR","href":"pt-BR/introduction"},{"language":"fr","href":"fr/introduction"},{"language":"de","href":"de/introduction"},{"language":"vi","href":"vi/introduction"},{"language":"ja","href":"ja/introduction"},{"language":"uk","href":"uk/introduction"},{"language":"hi","href":"hi/introduction"},{"language":"ar","href":"ar/introduction"},{"language":"zh-Hans","href":"zh-Hans/introduction"},{"language":"zh-Hant","href":"zh-Hant/introduction"}]}},"deployment":{"deploymentMetadataValue":{"subdomain":"ayrshare-docs","hasAudioNarration":false,"actualSubdomain":"ayrshare-docs","customDomains":["www.ayrshare.com"],"gitSource":{"type":"github","owner":"ayrshare","repo":"ayrshare_3","deployBranch":"docs-prod","contentDirectory":"apps/mintlify","isPrivate":true,"mountPath":"","label":"","_id":"6aec8a4b6de9d64b11a45855"},"chroma":{"liveDeploymentHistoryId":"6aecb2c1d226238b4601f6f0","collectionId":"1a2b3170-ae91-4c16-a91b-497e2aacba5d","schemaVersion":"v3","latestBuiltDeploymentHistoryId":"6aecb2c1d226238b4601f6f0"},"entitlements":{"AI_CHAT":{"status":"ENABLED"},"WEB_MCP":{"status":"ENABLED"},"NARRATION":{"status":"ENABLED"}},"buildId":"6aecb2c1d226238b4601f6f0","clientVersion":"0.0.4076","searchFilterCounts":[{"language":"en","tag":"Documentation","count":248},{"language":"ar","tag":"Documentation","count":248},{"language":"de","tag":"Documentation","count":248},{"language":"es","tag":"Documentation","count":248},{"language":"fr","tag":"Documentation","count":248},{"language":"hi","tag":"Documentation","count":248},{"language":"ja","tag":"Documentation","count":248},{"language":"pt-BR","tag":"Documentation","count":248},{"language":"uk","tag":"Documentation","count":248},{"language":"vi","tag":"Documentation","count":248},{"language":"zh-Hans","tag":"Documentation","count":248},{"language":"zh-Hant","tag":"Documentation","count":248},{"language":"en","tag":"API Endpoints","count":170},{"language":"ar","tag":"API Endpoints","count":170},{"language":"de","tag":"API Endpoints","count":170},{"language":"es","tag":"API Endpoints","count":170},{"language":"fr","tag":"API Endpoints","count":170},{"language":"hi","tag":"API Endpoints","count":170},{"language":"ja","tag":"API Endpoints","count":170},{"language":"pt-BR","tag":"API Endpoints","count":170},{"language":"uk","tag":"API Endpoints","count":170},{"language":"vi","tag":"API Endpoints","count":170},{"language":"zh-Hans","tag":"API Endpoints","count":170},{"language":"zh-Hant","tag":"API Endpoints","count":170},{"language":"en","tag":"Help Center","count":126},{"language":"ar","tag":"Help Center","count":126},{"language":"de","tag":"Help Center","count":126},{"language":"es","tag":"Help Center","count":126},{"language":"fr","tag":"Help Center","count":126},{"language":"hi","tag":"Help Center","count":126},{"language":"ja","tag":"Help Center","count":126},{"language":"pt-BR","tag":"Help Center","count":126},{"language":"uk","tag":"Help Center","count":126},{"language":"vi","tag":"Help Center","count":126},{"language":"zh-Hans","tag":"Help Center","count":126},{"language":"zh-Hant","tag":"Help Center","count":126},{"language":"en","tag":"Additional","count":40},{"language":"en","tag":"Technical Support","count":40},{"language":"ar","tag":"Additional","count":40},{"language":"ar","tag":"Technical Support","count":40},{"language":"de","tag":"Additional","count":40},{"language":"de","tag":"Technical Support","count":40},{"language":"es","tag":"Additional","count":40},{"language":"es","tag":"Technical Support","count":40},{"language":"fr","tag":"Additional","count":40},{"language":"fr","tag":"Technical Support","count":40},{"language":"hi","tag":"Additional","count":40},{"language":"hi","tag":"Technical Support","count":40},{"language":"ja","tag":"Additional","count":40},{"language":"ja","tag":"Technical Support","count":40},{"language":"pt-BR","tag":"Additional","count":40},{"language":"pt-BR","tag":"Technical Support","count":40},{"language":"uk","tag":"Additional","count":40},{"language":"uk","tag":"Technical Support","count":40},{"language":"vi","tag":"Additional","count":40},{"language":"vi","tag":"Technical Support","count":40},{"language":"zh-Hans","tag":"Additional","count":40},{"language":"zh-Hans","tag":"Technical Support","count":40},{"language":"zh-Hant","tag":"Additional","count":40},{"language":"zh-Hant","tag":"Technical Support","count":40},{"language":"en","tag":"Ads","count":30},{"language":"ar","tag":"Ads","count":30},{"language":"de","tag":"Ads","count":30},{"language":"es","tag":"Ads","count":30},{"language":"fr","tag":"Ads","count":30},{"language":"hi","tag":"Ads","count":30},{"language":"ja","tag":"Ads","count":30},{"language":"pt-BR","tag":"Ads","count":30},{"language":"uk","tag":"Ads","count":30},{"language":"vi","tag":"Ads","count":30},{"language":"zh-Hans","tag":"Ads","count":30},{"language":"zh-Hant","tag":"Ads","count":30},{"language":"en","tag":"Post","count":22},{"language":"ar","tag":"Post","count":22},{"language":"de","tag":"Post","count":22},{"language":"es","tag":"Post","count":22},{"language":"fr","tag":"Post","count":22},{"language":"hi","tag":"Post","count":22},{"language":"ja","tag":"Post","count":22},{"language":"pt-BR","tag":"Post","count":22},{"language":"uk","tag":"Post","count":22},{"language":"vi","tag":"Post","count":22},{"language":"zh-Hans","tag":"Post","count":22},{"language":"zh-Hant","tag":"Post","count":22},{"language":"en","tag":"Dashboard","count":21},{"language":"ar","tag":"Dashboard","count":21},{"language":"de","tag":"Dashboard","count":21},{"language":"es","tag":"Dashboard","count":21},{"language":"fr","tag":"Dashboard","count":21},{"language":"hi","tag":"Dashboard","count":21},{"language":"ja","tag":"Dashboard","count":21},{"language":"pt-BR","tag":"Dashboard","count":21},{"language":"uk","tag":"Dashboard","count":21},{"language":"vi","tag":"Dashboard","count":21},{"language":"zh-Hans","tag":"Dashboard","count":21},{"language":"zh-Hant","tag":"Dashboard","count":21},{"language":"en","tag":"Product","count":16},{"language":"ar","tag":"Product","count":16},{"language":"de","tag":"Product","count":16},{"language":"es","tag":"Product","count":16},{"language":"fr","tag":"Product","count":16},{"language":"hi","tag":"Product","count":16},{"language":"ja","tag":"Product","count":16},{"language":"pt-BR","tag":"Product","count":16},{"language":"uk","tag":"Product","count":16},{"language":"vi","tag":"Product","count":16},{"language":"zh-Hans","tag":"Product","count":16},{"language":"zh-Hant","tag":"Product","count":16},{"language":"en","tag":"Connect Social Accounts","count":15},{"language":"ar","tag":"Connect Social Accounts","count":15},{"language":"de","tag":"Connect Social Accounts","count":15},{"language":"es","tag":"Connect Social Accounts","count":15},{"language":"fr","tag":"Connect Social Accounts","count":15},{"language":"hi","tag":"Connect Social Accounts","count":15},{"language":"ja","tag":"Connect Social Accounts","count":15},{"language":"pt-BR","tag":"Connect Social Accounts","count":15},{"language":"uk","tag":"Connect Social Accounts","count":15},{"language":"vi","tag":"Connect Social Accounts","count":15},{"language":"zh-Hans","tag":"Connect Social Accounts","count":15},{"language":"zh-Hant","tag":"Connect Social Accounts","count":15}]},"assistantConfig":{},"basePath":"/docs","hasChatPermissions":true,"hasWebMcpPermissions":true,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"rbac-expansion","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-onboarding","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"full-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"assistant-v5","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-sso-scim","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-signup","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-dual-write","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-enabled","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"approve-review-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"sso-setup-deadline-banner","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-serve","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"live-agents","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"comment-mode","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"googleFontsInlined":false},"customCss":[{"filePath":"style.css","content":".center{display:block;margin-left:auto;margin-right:auto;max-width:100%;height:auto}.welcome-banner{margin-left:auto;margin-right:auto;max-width:100%;height:auto;border-radius:12px}.custom-bullets{padding-left:0}.custom-bullets li{position:relative;padding-left:1.5em;margin-bottom:0.75em;list-style-type:none;line-height:1.4}.custom-bullets li::before{content:\"\\2022\";color:#2266c2;position:absolute;left:0.5em;top:0}.custom-bullets li:last-child{margin-bottom:0}.custom-bullets li>*{margin-top:0;margin-bottom:0}ul ul{margin-left:20px}.custom-bullets li::after,.custom-bullets li::before{border:none!important;background:none!important}.button{background-color:#2266c2;color:#fff;padding:16px 24px;border-radius:8px;border:none;transition-duration:0.2s;margin-top:100px}.button:hover{background-color:#133e76;color:white}.button2{background-color:#fff;color:#2266c2;padding:16px 24px;border-radius:8px;border:1px solid #2266c2;transition-duration:0.2s}.button2:hover{background-color:#133e76;color:white}.video-container{width:100%;max-width:560px;margin:0 auto}.video-container iframe{width:100%;height:auto;aspect-ratio:16 / 9}.plan-tag-light{font-family:\"JetBrains Mono\", monospace;display:inline-block;padding:2px 6px;border-radius:4px;font-size:12px;color:#ffffff;background-color:#16171b;margin-right:10px}.plan-tag-dark{font-family:\"JetBrains Mono\", monospace;display:inline-block;padding:2px 6px;border-radius:4px;font-size:12px;color:#3f4144;background-color:#b7b9bb;margin-right:10px}@media (min-width: 768px){.video-container{display:flex;justify-content:center;align-items:center}}code{font-size:0.96em;line-height:1.7em}"}],"page":{"pagePath":"dashboard/connect-social-accounts/x-twitter-byo-keys","slug":"/dashboard/connect-social-accounts/x-twitter-byo-keys","pageMetadata":{"title":"Set Up Your Own X API Key","description":"Step-by-step guide to connect your own X (Twitter) API credentials with Ayrshare","icon":"x-twitter","href":"/dashboard/connect-social-accounts/x-twitter-byo-keys"},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsx(_components.p, {\n children: \"Step-by-step guide to connect your own X (Twitter) API credentials with Ayrshare\"\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={a:`a`,code:`code`,li:`li`,ol:`ol`,p:`p`,pre:`pre`,span:`span`,strong:`strong`,tbody:`tbody`,td:`td`,th:`th`,thead:`thead`,tr:`tr`,ul:`ul`,..._provideComponents(),...props.components},{Accordion,AccordionGroup,CodeBlock,CodeGroup,Heading,Info,Note,OptimizedImage,Step,Steps,Table,Warning}=_components;if(!Accordion)_missingMdxReference(`Accordion`,true);if(!AccordionGroup)_missingMdxReference(`AccordionGroup`,true);if(!CodeBlock)_missingMdxReference(`CodeBlock`,true);if(!CodeGroup)_missingMdxReference(`CodeGroup`,true);if(!Heading)_missingMdxReference(`Heading`,true);if(!Info)_missingMdxReference(`Info`,true);if(!Note)_missingMdxReference(`Note`,true);if(!OptimizedImage)_missingMdxReference(`OptimizedImage`,true);if(!Step)_missingMdxReference(`Step`,true);if(!Steps)_missingMdxReference(`Steps`,true);if(!Table)_missingMdxReference(`Table`,true);if(!Warning)_missingMdxReference(`Warning`,true);return _jsxs(_Fragment,{children:[_jsx(_components.p,{children:`On March 31, 2026, X changed how third-party platforms access its API. As a result, every Ayrshare account posting to X through Ayrshare must register its own X Developer App and use its API Key and API Secret on every request.`}),`\n`,_jsx(_components.p,{children:`This is a platform-wide change mandated by X that affects all third-party tools.`}),`\n`,_jsx(Info,{children:_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`BYO keys are set once per platform (account-wide), not per customer or sub-profile.`}),` You create `,_jsx(_components.strong,{children:`one X Developer App`}),` under your own X account, and the same `,_jsx(_components.strong,{children:`API Key + API Secret`}),` apply account-wide for X — they are used for `,_jsx(_components.strong,{children:`every`}),` sub-profile / end-user that links X under your Ayrshare account. If you have a Business or Enterprise plan with hundreds of sub-profiles, you do `,_jsx(_components.strong,{children:`not`}),` need to repeat this setup for each one. You set it up once for the X platform, then pass the same two headers on every request.`]})}),`\n`,_jsx(_components.p,{children:`We’ve streamlined the setup process to make this as simple as possible, and it should take less than 10 minutes to complete. Follow our step-by-step guide below, and if you need any help along the way, our team is here to assist.`}),`\n`,_jsx(Heading,{level:`2`,id:`step-1-create-your-x-developer-account`,children:`Step 1: Create Your X Developer Account`}),`\n`,_jsxs(Steps,{children:[_jsxs(Step,{title:`Sign in to the Developer Console`,children:[_jsxs(_components.p,{children:[`Go to `,_jsx(_components.a,{href:`https://console.x.com`,children:`console.x.com`}),` and sign in with your X account. See `,_jsx(_components.a,{href:`https://docs.x.com/x-api/getting-started/getting-access`,children:`X’s getting started guide`}),` if you need help.`]}),_jsx(OptimizedImage,{class:`center`,width:`700`,src:`https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step1-developer-console.webp?fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=58a00543db365d4d889722070643a070`,alt:`X Developer Console sign-in page`,\"data-og-width\":`1234`,\"data-og-height\":`803`,\"data-path\":`images/dashboard/x-byo-setup/step1-developer-console.webp`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step1-developer-console.webp?w=280\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=938879f1e567194f28309da83fc13ee7 280w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step1-developer-console.webp?w=560\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=8d06c7a4806c5fdc0ff5a000ce89b591 560w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step1-developer-console.webp?w=840\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=8167e68f57c9d3d30eedd20482bac0d8 840w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step1-developer-console.webp?w=1100\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=411376aafc312705b23976ea6b32e283 1100w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step1-developer-console.webp?w=1650\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=f20d8d63f8a31cdf0bd90aa256e47b65 1650w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step1-developer-console.webp?w=2500\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=2f6031fe4744e4e7e4fb8943553eb191 2500w`})]}),_jsx(Step,{title:`Complete onboarding`,children:_jsx(_components.p,{children:`Complete the developer onboarding and accept the Developer Agreement and policies.`})}),_jsx(Step,{title:`Access the console`,children:_jsx(_components.p,{children:`You’re now in the X Developer Console.`})})]}),`\n`,_jsx(Heading,{level:`2`,id:`step-2-create-an-app`,children:`Step 2: Create an App`}),`\n`,_jsx(Info,{children:_jsxs(_components.p,{children:[`You only create `,_jsx(_components.strong,{children:`one X Developer App per Ayrshare account`}),`. The same app and its API Key + API Secret are reused for every sub-profile / end-user you later link under your Ayrshare account. You do not create a new app per customer.`]})}),`\n`,_jsxs(Steps,{children:[_jsxs(Step,{title:`Navigate to Apps`,children:[_jsxs(_components.p,{children:[`In the Developer Console, navigate to `,_jsx(_components.strong,{children:`Apps`}),`.`]}),_jsx(OptimizedImage,{class:`center`,width:`700`,src:`https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step2-apps-page.webp?fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=36076b8577cb46f4713cad41933bae2f`,alt:`Apps page in X Developer Console`,\"data-og-width\":`2048`,\"data-og-height\":`875`,\"data-path\":`images/dashboard/x-byo-setup/step2-apps-page.webp`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step2-apps-page.webp?w=280\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=618a5b0a5c192d759d946bb84d30d97e 280w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step2-apps-page.webp?w=560\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=01a42a42982733035e31ddc1cc03908f 560w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step2-apps-page.webp?w=840\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=3ba5041fe7c38b74ee59e7225c7b2f4d 840w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step2-apps-page.webp?w=1100\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=d3346daba4eac0bc05707d8d3b26174b 1100w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step2-apps-page.webp?w=1650\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=8b8daa6f8dd11209fd40f89872b6303a 1650w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step2-apps-page.webp?w=2500\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=e5a80b04de69e89259566f8e6f6f1db8 2500w`})]}),_jsxs(Step,{title:`Create the app`,children:[_jsxs(_components.p,{children:[`In the App dashboard, click `,_jsx(_components.strong,{children:`Create App`}),` (see `,_jsx(_components.a,{href:`https://docs.x.com/fundamentals/developer-apps`,children:`X’s App setup docs`}),` for details). Enter an app name (typically your brand name). This name will appear in the OAuth authorization screen when users connect their X account.`]}),_jsx(OptimizedImage,{class:`center`,width:`700`,src:`https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step2-create-app.webp?fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=dd9627eeb7e58c80f6249dd5cbfb0d4e`,alt:`Create App button in the X Developer Console`,\"data-og-width\":`2048`,\"data-og-height\":`947`,\"data-path\":`images/dashboard/x-byo-setup/step2-create-app.webp`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step2-create-app.webp?w=280\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=abb52ed3abce2fb2f6e127c7ce69a1cc 280w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step2-create-app.webp?w=560\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=10d71bd1e512483a35bcb3b3832b9558 560w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step2-create-app.webp?w=840\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=5e7df1f1f964f08cc14fd8456e0adb5a 840w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step2-create-app.webp?w=1100\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=61cfb7400f71483333293f5503280210 1100w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step2-create-app.webp?w=1650\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=96e9795208e053de665d526b7abd7f8b 1650w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step2-create-app.webp?w=2500\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=bd4cdf9107efb7cc20741f2126d81e54 2500w`})]}),_jsxs(Step,{title:`Select environment`,children:[_jsxs(_components.p,{children:[`Select the `,_jsx(_components.strong,{children:`Production`}),` environment in the dropdown.`]}),_jsx(OptimizedImage,{class:`center`,width:`700`,src:`https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step2-credentials-popup.webp?fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=2b111d840665b0b7eb96fc0d9df99f0e`,alt:`Production environment selection and credentials popup`,\"data-og-width\":`1109`,\"data-og-height\":`900`,\"data-path\":`images/dashboard/x-byo-setup/step2-credentials-popup.webp`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step2-credentials-popup.webp?w=280\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=c8e37ddac31a20a0798ff7735cd59e9c 280w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step2-credentials-popup.webp?w=560\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=be02b3bc6d0d662ce9eb21f946dd870c 560w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step2-credentials-popup.webp?w=840\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=c71bebd542e27bceb80bd3adc0294f62 840w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step2-credentials-popup.webp?w=1100\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=88fccea45ab7202760a09211941733dc 1100w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step2-credentials-popup.webp?w=1650\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=a2ea9f4c1955fbddb31dce812cd7f779 1650w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step2-credentials-popup.webp?w=2500\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=537f94cee58e60756d29a5aead2dce57 2500w`})]}),_jsx(Step,{title:`Close the initial credentials popup`,children:_jsxs(_components.p,{children:[`X will generate several credentials. `,_jsx(_components.strong,{children:`Ignore these credentials and close this window.`})]})})]}),`\n`,_jsx(Heading,{level:`2`,id:`step-3-configure-app-permissions`,children:`Step 3: Configure App Permissions`}),`\n`,_jsxs(Steps,{children:[_jsxs(Step,{title:`Open your app settings`,children:[_jsx(_components.p,{children:`Under “Apps,” locate the new app (refresh the page if it doesn’t appear), then click it to view its details.`}),_jsx(OptimizedImage,{class:`center`,width:`700`,src:`https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step3-app-details.webp?fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=41f185aa2ffb4d90f0f9f174597cc4f1`,alt:`App details page in the X Developer Console`,\"data-og-width\":`2048`,\"data-og-height\":`937`,\"data-path\":`images/dashboard/x-byo-setup/step3-app-details.webp`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step3-app-details.webp?w=280\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=033178616425374ab2f1a47518398b3a 280w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step3-app-details.webp?w=560\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=8c75387800df2a54b4c1e1a9c2d63235 560w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step3-app-details.webp?w=840\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=e52c65c0824faf161c693c7674e6e8cb 840w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step3-app-details.webp?w=1100\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=8d6578e29681faab3b7a60806c2e3e43 1100w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step3-app-details.webp?w=1650\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=9672f489ac7e262f65e3d6ca4dbe3866 1650w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step3-app-details.webp?w=2500\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=90ab187dbc7b4dd68d3396d082cf170e 2500w`}),_jsxs(_components.p,{children:[`Under `,_jsx(_components.strong,{children:`User authentication settings`}),`, click `,_jsx(_components.strong,{children:`Set up`}),`.`]}),_jsx(OptimizedImage,{class:`center`,width:`700`,src:`https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step3-user-auth-settings.webp?fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=4faad9d5bc061f442ee0cc605e0aad6a`,alt:`User authentication settings, click Set up`,\"data-og-width\":`2048`,\"data-og-height\":`988`,\"data-path\":`images/dashboard/x-byo-setup/step3-user-auth-settings.webp`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step3-user-auth-settings.webp?w=280\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=114dcee67285e624649686f9af5b69da 280w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step3-user-auth-settings.webp?w=560\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=edfcf1b336fddcb4fe76f443aace668f 560w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step3-user-auth-settings.webp?w=840\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=88bfed4b63d47c3ee131faefd618bdaa 840w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step3-user-auth-settings.webp?w=1100\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=93fc2fc72f38d9722ac07314d934ff4b 1100w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step3-user-auth-settings.webp?w=1650\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=39f7365bae71f1ecf74f31c5155e16e9 1650w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step3-user-auth-settings.webp?w=2500\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=5050507e04eaf1f48b9165d48acae15a 2500w`})]}),_jsxs(Step,{title:`Set app permissions`,children:[_jsxs(_components.p,{children:[`Under `,_jsx(_components.strong,{children:`App permissions`}),`, select `,_jsx(_components.strong,{children:`Read and write and Direct message`}),`. This is required for full feature support, including posting and DMs.`]}),_jsx(OptimizedImage,{class:`center`,width:`700`,src:`https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step3-app-permissions.webp?fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=57549ea060507af5b99552b6952ef95a`,alt:`App permissions set to Read and write and Direct message`,\"data-og-width\":`2048`,\"data-og-height\":`916`,\"data-path\":`images/dashboard/x-byo-setup/step3-app-permissions.webp`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step3-app-permissions.webp?w=280\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=967663e9221988a42f5240ee3b04a7fa 280w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step3-app-permissions.webp?w=560\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=860fb7340e53f30de165d46cb504ae3a 560w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step3-app-permissions.webp?w=840\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=a45de33c96315163857be3df57ad9753 840w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step3-app-permissions.webp?w=1100\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=4ba2ac9b9a8cafb254225077d62d87c3 1100w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step3-app-permissions.webp?w=1650\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=a523bdc9a380a6cc6ce66effe823bd22 1650w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step3-app-permissions.webp?w=2500\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=2aa1bc4175dc3562e7651b4e16964fa9 2500w`})]}),_jsxs(Step,{title:`Set app type`,children:[_jsxs(_components.p,{children:[`Under `,_jsx(_components.strong,{children:`Type of App`}),`, select `,_jsx(_components.strong,{children:`Web App, Automated App or Bot`}),`. This is the right choice for server-side integrations like Ayrshare.`]}),_jsx(OptimizedImage,{class:`center`,width:`700`,src:`https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step3-app-type.webp?fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=8609d048548432862ad801113e7b7b8e`,alt:`Type of App set to Web App, Automated App or Bot`,\"data-og-width\":`2042`,\"data-og-height\":`658`,\"data-path\":`images/dashboard/x-byo-setup/step3-app-type.webp`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step3-app-type.webp?w=280\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=8cc5080d23a4f18a240245fba86ea825 280w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step3-app-type.webp?w=560\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=067ef3d8de679b214db46083f8ef902f 560w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step3-app-type.webp?w=840\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=2d6773c757e629dbd1baac07df398425 840w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step3-app-type.webp?w=1100\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=a0f6290ebdae9fe04416de5fb4ade368 1100w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step3-app-type.webp?w=1650\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=03eec010d9d59dc1be31028fb7b92669 1650w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step3-app-type.webp?w=2500\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=62a973daa73cd285b4d4889fae619140 2500w`})]}),_jsxs(Step,{title:`Set callback and website URLs`,children:[_jsxs(_components.p,{children:[`Under `,_jsx(_components.strong,{children:`App info`}),`:`]}),_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Callback URL:`}),` Add both of the following callback URLs:`,`\n`,_jsxs(_components.ul,{children:[`\n`,_jsx(_components.li,{children:_jsx(_components.code,{children:`https://profile.ayrshare.com/social-accounts`})}),`\n`,_jsx(_components.li,{children:_jsx(_components.code,{children:`https://app.ayrshare.com/social-accounts`})}),`\n`]}),`\n`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Website URL:`}),` `,_jsx(_components.code,{children:`https://app.ayrshare.com`})]}),`\n`]}),_jsx(Warning,{children:_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Do not skip this step.`}),` These callback URLs are required for the OAuth linking flow. When your end-users authorize the X connection, X redirects them back to one of these URLs to complete the linking process. If these are missing, the OAuth flow will fail with a `,_jsx(_components.code,{children:`403 Callback URL not approved`}),` error.`]})}),_jsx(OptimizedImage,{class:`center`,width:`700`,src:`https://mintcdn.com/ayrshare-docs/itktiDewCYTaymFN/images/dashboard/x-byo-setup/step3-app-info-urls.webp?fit=max\u0026auto=format\u0026n=itktiDewCYTaymFN\u0026q=85\u0026s=09d7254aa2d183e2899f95412e97316b`,alt:`App info form with callback URL and website URL filled in`,\"data-og-width\":`908`,\"data-og-height\":`664`,\"data-path\":`images/dashboard/x-byo-setup/step3-app-info-urls.webp`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/ayrshare-docs/itktiDewCYTaymFN/images/dashboard/x-byo-setup/step3-app-info-urls.webp?w=280\u0026fit=max\u0026auto=format\u0026n=itktiDewCYTaymFN\u0026q=85\u0026s=e4cd55b7c0e8e5b2e78f7f246486c6fe 280w, https://mintcdn.com/ayrshare-docs/itktiDewCYTaymFN/images/dashboard/x-byo-setup/step3-app-info-urls.webp?w=560\u0026fit=max\u0026auto=format\u0026n=itktiDewCYTaymFN\u0026q=85\u0026s=0daa1d7c0cfe379ab26d73fd3999914b 560w, https://mintcdn.com/ayrshare-docs/itktiDewCYTaymFN/images/dashboard/x-byo-setup/step3-app-info-urls.webp?w=840\u0026fit=max\u0026auto=format\u0026n=itktiDewCYTaymFN\u0026q=85\u0026s=57ed773de8d63058d7b63eedffcc9255 840w, https://mintcdn.com/ayrshare-docs/itktiDewCYTaymFN/images/dashboard/x-byo-setup/step3-app-info-urls.webp?w=1100\u0026fit=max\u0026auto=format\u0026n=itktiDewCYTaymFN\u0026q=85\u0026s=a641ad5ad76d12c1ec264a2c9def0a1a 1100w, https://mintcdn.com/ayrshare-docs/itktiDewCYTaymFN/images/dashboard/x-byo-setup/step3-app-info-urls.webp?w=1650\u0026fit=max\u0026auto=format\u0026n=itktiDewCYTaymFN\u0026q=85\u0026s=bdde71f24a7c1b009877ce3777b94486 1650w, https://mintcdn.com/ayrshare-docs/itktiDewCYTaymFN/images/dashboard/x-byo-setup/step3-app-info-urls.webp?w=2500\u0026fit=max\u0026auto=format\u0026n=itktiDewCYTaymFN\u0026q=85\u0026s=ac8ea4413fff8494654603ed248f0f04 2500w`})]}),_jsx(Step,{title:`Save your settings`,children:_jsxs(_components.p,{children:[`Click `,_jsx(_components.strong,{children:`Save`}),`. You can ignore the OAuth 2.0 popup, since you will only be using 2 of the OAuth 1.0 keys (API Key and API Secret).`]})})]}),`\n`,_jsxs(Warning,{children:[_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Important: Set permissions before linking.`}),` The permissions you choose here determine what your app can do. If you change permissions after linking your X account via OAuth, you’ll need to re-link so the new Access Token inherits the updated permissions.`]}),_jsx(OptimizedImage,{class:`center`,width:`700`,src:`https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step3-keys-and-tokens.webp?fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=761423c4c27f0c90b480d00f1ff253f7`,alt:`Keys and tokens page showing OAuth 1.0 keys with permission level`,\"data-og-width\":`926`,\"data-og-height\":`854`,\"data-path\":`images/dashboard/x-byo-setup/step3-keys-and-tokens.webp`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step3-keys-and-tokens.webp?w=280\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=96fb3e63f604deca1038c523a85e2a0f 280w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step3-keys-and-tokens.webp?w=560\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=ce1be3557c7c5d0ebd418647267dc08a 560w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step3-keys-and-tokens.webp?w=840\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=03bebbf43dfd5f1520ecf0211ad5d7f4 840w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step3-keys-and-tokens.webp?w=1100\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=03f9aeeec29de8366a5213a506ad45d3 1100w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step3-keys-and-tokens.webp?w=1650\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=8dbc09078b85136c43ab34a6ef44f5ad 1650w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step3-keys-and-tokens.webp?w=2500\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=0b16c0a19d011377c192ef190c3edafd 2500w`})]}),`\n`,_jsx(_components.p,{children:`Please make sure you store these 2 keys:`}),`\n`,_jsxs(_components.ol,{children:[`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`API Key`}),` (aka Consumer Key, the X app identifier)`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`API Secret`}),` (aka Consumer Secret)`]}),`\n`]}),`\n`,_jsx(Info,{children:_jsxs(_components.p,{children:[`You do `,_jsx(_components.strong,{children:`NOT`}),` need to manually generate Access Tokens. Ayrshare handles this automatically when you link your X account via OAuth.`]})}),`\n`,_jsx(Heading,{level:`2`,id:`step-4-purchase-x-api-credits`,children:`Step 4: Purchase X API Credits`}),`\n`,_jsx(_components.p,{children:`X now uses credit-based API billing, purchased through the developer console.`}),`\n`,_jsxs(Steps,{children:[_jsxs(Step,{title:`Navigate to billing`,children:[_jsxs(_components.p,{children:[`In the Developer Console, click `,_jsx(_components.strong,{children:`Billing → Credits`}),` in the left sidebar.`]}),_jsx(OptimizedImage,{class:`center`,width:`700`,src:`https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step4-billing-credits.webp?fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=b104e991f726ec2ecb8cc8274d1889d2`,alt:`Billing Credits page in X Developer Console`,\"data-og-width\":`2048`,\"data-og-height\":`885`,\"data-path\":`images/dashboard/x-byo-setup/step4-billing-credits.webp`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step4-billing-credits.webp?w=280\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=05857bceafa90c02bf795d8600c532d7 280w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step4-billing-credits.webp?w=560\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=b169db58214681f1f028250953a19210 560w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step4-billing-credits.webp?w=840\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=b041009571f7d6e3d6402ecab7ff0315 840w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step4-billing-credits.webp?w=1100\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=abb16fc8f0c380dbe8f7b1d606d65352 1100w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step4-billing-credits.webp?w=1650\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=f22c4726b85514ded6f879cc09d9ce63 1650w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step4-billing-credits.webp?w=2500\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=5172e62ed429e1aec41cb25dab287c1f 2500w`})]}),_jsxs(Step,{title:`Purchase credits`,children:[_jsx(_components.p,{children:`Purchase credits (the minimum is $5, which is enough for hundreds of API calls). Each API call is a fraction of a penny, so the cost should be minimal for most users.`}),_jsx(OptimizedImage,{class:`center`,width:`700`,src:`https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step4-purchase-credits.webp?fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=ae555dc44bcfdfb0d7e4f55237b248ef`,alt:`Credit purchase page in the X Developer Console`,\"data-og-width\":`2048`,\"data-og-height\":`1050`,\"data-path\":`images/dashboard/x-byo-setup/step4-purchase-credits.webp`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step4-purchase-credits.webp?w=280\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=880a3ca24b200671083b647a8e01c46f 280w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step4-purchase-credits.webp?w=560\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=1d4590391ebd4bb7fb25c3051c9c0915 560w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step4-purchase-credits.webp?w=840\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=7cf1371cc050e20e5dadf5bd0b48eb6d 840w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step4-purchase-credits.webp?w=1100\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=fa7c584c07a7c2ae9034ebbff4a66143 1100w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step4-purchase-credits.webp?w=1650\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=fd4012882939b5f4f2f35a97edd836a0 1650w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step4-purchase-credits.webp?w=2500\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=31445cf4987844d06fb7c8d989c51389 2500w`})]}),_jsxs(Step,{title:`Enable auto-recharge`,children:[_jsxs(_components.p,{children:[`You can enable `,_jsx(_components.strong,{children:`auto-recharge`}),` to avoid service interruptions, and manage your spend cap by setting a maximum amount you can spend in your billing cycle.`]}),_jsx(OptimizedImage,{class:`center`,width:`700`,src:`https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step4-auto-recharge.webp?fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=c9e0f36c379bbd5c47c8b242213eaa6a`,alt:`Auto-recharge and spend cap settings in X Developer Console`,\"data-og-width\":`1832`,\"data-og-height\":`593`,\"data-path\":`images/dashboard/x-byo-setup/step4-auto-recharge.webp`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step4-auto-recharge.webp?w=280\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=f7101537cfe4f11ad00731fb2a2aa367 280w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step4-auto-recharge.webp?w=560\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=3f3faaa4b77240d48d48c09acfd8799f 560w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step4-auto-recharge.webp?w=840\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=85708d9e27f8fd9b3f0d5dc290969eae 840w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step4-auto-recharge.webp?w=1100\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=3453c9a1780bc8d1a3374d421a673fcf 1100w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step4-auto-recharge.webp?w=1650\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=ab0b806605b208cb8e3b5a4cee307271 1650w, https://mintcdn.com/ayrshare-docs/qVYhhKC6hYCwYmRp/images/dashboard/x-byo-setup/step4-auto-recharge.webp?w=2500\u0026fit=max\u0026auto=format\u0026n=qVYhhKC6hYCwYmRp\u0026q=85\u0026s=ef3fcae5d4f8e3d14a68ed50faaf8d23 2500w`})]})]}),`\n`,_jsx(Warning,{children:_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Your API calls will fail without credits.`}),` X’s API is pay-per-use. If your credit balance is zero, every API request will return a `,_jsx(_components.code,{children:`402 CreditsDepleted`}),` error with the message “Your enrolled account does not have any credits to fulfill this request.” This includes posting, reading tweets, and user lookups. Load credits before testing your integration. See `,_jsx(_components.a,{href:`#how-x-api-pricing-works`,children:`How X API Pricing Works`}),` for a full update on X’s pricing.`]})}),`\n`,_jsx(Heading,{level:`2`,id:`step-5-update-your-ayrshare-api-calls`,children:`Step 5: Update Your Ayrshare API Calls`}),`\n`,_jsx(_components.p,{children:`In Step 3, you saved these 2 items securely in your own env, config, or secrets manager:`}),`\n`,_jsxs(_components.ol,{children:[`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`API Key`}),` (aka Consumer Key, the X app identifier)`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`API Secret`}),` (aka Consumer Secret)`]}),`\n`]}),`\n`,_jsx(_components.p,{children:`Now, add your X credentials to the headers of your Ayrshare API calls.`}),`\n`,_jsx(Info,{children:_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Your keys stay private.`}),` The API Key and API Secret you send in these headers are used for that request only and are not stored by Ayrshare. Creating a linking URL is the one exception, described in the Security section below.`]})}),`\n`,_jsx(Heading,{level:`3`,id:`header-reference`,children:`Header Reference`}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Header`}),_jsx(_components.th,{children:`Value`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`X-Twitter-OAuth1-Api-Key`})}),_jsx(_components.td,{children:`API Key (Consumer Key)`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`X-Twitter-OAuth1-Api-Secret`})}),_jsx(_components.td,{children:`API Key Secret (Consumer Secret)`})]})]})]}),`\n`,_jsxs(Warning,{children:[_jsx(_components.p,{children:_jsx(_components.strong,{children:`How to tell if your permissions are wrong:`})}),_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[`If your app permissions are misconfigured, your API request may return a `,_jsx(_components.code,{children:`403 Forbidden`}),` error with the message: “Your client app is not configured with the appropriate OAuth1 app permissions.”`]}),`\n`]}),_jsxs(_components.p,{children:[`If you see this error, update your app permissions to `,_jsx(_components.strong,{children:`Read and write and Direct message`}),` in the X Developer Console, then re-link your X account via OAuth so the new Access Token inherits the updated permissions.`]})]}),`\n`,_jsx(Heading,{level:`3`,id:`code-examples`,children:`Code Examples`}),`\n`,_jsxs(CodeGroup,{children:[_jsx(CodeBlock,{filename:`cURL`,numberOfLines:`6`,language:`shellscript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`6`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`curl`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` -X`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` POST`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` https://api.ayrshare.com/api/post`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D7BA7D`},children:` \\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` -H`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"Authorization: Bearer YOUR_AYRSHARE_API_KEY\"`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D7BA7D`},children:` \\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` -H`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"X-Twitter-OAuth1-Api-Key: your_api_key\"`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D7BA7D`},children:` \\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` -H`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"X-Twitter-OAuth1-Api-Secret: your_api_secret\"`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D7BA7D`},children:` \\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` -H`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"Content-Type: application/json\"`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D7BA7D`},children:` \\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` -d`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` '{\"post\": \"Hello from my own X App!\", \"platforms\": [\"twitter\"]}'`})]}),`\n`]})})}),_jsx(CodeBlock,{filename:`Node.js`,numberOfLines:`13`,language:`javascript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`javascript`,children:_jsxs(_components.code,{language:`javascript`,numberOfLines:`13`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`const`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` response`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` await`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:` fetch`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"https://api.ayrshare.com/api/post\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` method:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"POST\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` headers:`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"Authorization\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"Bearer YOUR_AYRSHARE_API_KEY\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"Content-Type\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"application/json\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"X-Twitter-OAuth1-Api-Key\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`:`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` process`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`env`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:`X_API_KEY`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"X-Twitter-OAuth1-Api-Secret\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`:`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` process`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`env`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:`X_API_SECRET`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` body:`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` JSON`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`stringify`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`({`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` post:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"Hello from my own X App!\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` platforms:`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` [`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"twitter\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`],`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }),`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`});`})}),`\n`]})})}),_jsx(CodeBlock,{filename:`Python`,numberOfLines:`15`,language:`python`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`python`,children:_jsxs(_components.code,{language:`python`,numberOfLines:`15`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`import`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` os`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`import`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` requests`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`headers `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"Authorization\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Bearer YOUR_AYRSHARE_API_KEY\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"Content-Type\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"application/json\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"X-Twitter-OAuth1-Api-Key\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: os.environ[`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"X_API_KEY\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`],`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"X-Twitter-OAuth1-Api-Secret\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: os.environ[`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"X_API_SECRET\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`],`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`response `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` requests.post(`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"https://api.ayrshare.com/api/post\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#9CDCFE`},children:` headers`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`headers,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#9CDCFE`},children:` json`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"post\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Hello from my own X App!\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"platforms\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: [`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"twitter\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`]},`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`)`})}),`\n`]})})})]}),`\n`,_jsx(_components.p,{children:`Your existing automations and workflows will continue working as long as you include your API Key and API Secret headers in every request that targets X.`}),`\n`,_jsx(`div`,{id:`migrating-existing-profiles-business-\u0026-enterprise`}),`\n`,_jsx(Heading,{level:`3`,id:`migrating-existing-profiles-business--enterprise`,children:`Migrating Existing Profiles (Business \u0026 Enterprise)`}),`\n`,_jsx(_components.p,{children:`If you have sub-profiles that are already linked to X through Ayrshare, those profiles need to re-link their X accounts after you switch to BYO keys. This is because the existing access tokens were issued under Ayrshare’s X app and cannot be used with your consumer keys (OAuth 1.0a signatures are bound to the app that issued the token).`}),`\n`,_jsxs(Steps,{children:[_jsxs(Step,{title:`Include your keys in generateJWT`,children:[_jsxs(_components.p,{children:[`Add `,_jsx(_components.code,{children:`twitterApiKey`}),` and `,_jsx(_components.code,{children:`twitterApiSecret`}),` to your `,_jsx(_components.a,{href:`/apis/profiles/generate-jwt#body-parameters`,children:`generateJWT`}),` call body. These are encrypted and stored with the linking session, and are not exposed to your end users.`]}),_jsx(CodeBlock,{filename:``,numberOfLines:`5`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`5`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"profileKey\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"...\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"twitterApiKey\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"YOUR_X_CONSUMER_KEY\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"twitterApiSecret\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"YOUR_X_CONSUMER_SECRET\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),_jsxs(_components.p,{children:[`Creating a linking URL is the only place your consumer keys go in the body — this request, or `,_jsx(_components.a,{href:`/apis/profiles/create-link-session`,children:_jsx(_components.code,{children:`POST /profiles/link-sessions`})}),`. Every other X request uses the headers described above.`]})]}),_jsxs(Step,{title:`Have users re-link X`,children:[_jsx(_components.p,{children:`After generating the JWT with the keys included, your users need to reconnect their X account through the profile linking page. The OAuth consent screen will now show your app name instead of Ayrshare’s.`}),_jsx(_components.p,{children:`To streamline this, you can:`}),_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[`Unlink accounts programmatically via the `,_jsx(_components.a,{href:`/apis/profiles/unlink-social-network`,children:`Unlink API`}),`, then have users re-authorize`]}),`\n`,_jsxs(_components.li,{children:[`Use the `,_jsxs(_components.a,{href:`/apis/profiles/generate-jwt#param-logout`,children:[_jsx(_components.code,{children:`logout`}),` parameter`]}),` in generateJWT to force a fresh login`]}),`\n`,_jsxs(_components.li,{children:[`Use `,_jsx(_components.a,{href:`/apis/profiles/generate-jwt#param-allowed-social`,children:_jsx(_components.code,{children:`allowedSocial`})}),` to show only X on the linking page during the migration flow`]}),`\n`]})]}),_jsx(Step,{title:`Keep sending headers on all API calls`,children:_jsxs(_components.p,{children:[`After re-linking, continue including `,_jsx(_components.code,{children:`X-Twitter-OAuth1-Api-Key`}),` and `,_jsx(_components.code,{children:`X-Twitter-OAuth1-Api-Secret`}),` headers on every API call (posting, analytics, comments, etc.).`]})})]}),`\n`,_jsx(Info,{children:_jsxs(_components.p,{children:[`Once a profile has re-linked under your X app, all subsequent posts for that profile will use your credentials. You can verify this by checking the Usage page in your `,_jsx(_components.a,{href:`https://console.x.com`,children:`X Developer Console`}),`.`]})}),`\n`,_jsx(Heading,{level:`3`,id:`verify-your-setup`,children:`Verify Your Setup`}),`\n`,_jsxs(_components.p,{children:[`Make a test call through the Ayrshare API with your new headers to confirm everything is working. The `,_jsx(_components.a,{href:`/apis/analytics/social`,children:`/analytics/social`}),` endpoint is a good lightweight test, since it won’t create any posts.`]}),`\n`,_jsx(Heading,{level:`2`,id:`how-x-api-pricing-works`,children:`How X API Pricing Works`}),`\n`,_jsx(_components.p,{children:`Previously, Ayrshare covered the cost of X’s API usage on your behalf. Under X’s current model, each Ayrshare customer maintains their own X Developer account and pays X directly for the API requests their application makes. (One X Developer account per Ayrshare account, not per end-user. All your sub-profiles share the same X Developer account and credit balance.)`}),`\n`,_jsx(_components.p,{children:`X’s pricing model is pay-per-use: you purchase credits in the X Developer Console, and they are deducted as API requests are made. No contracts or subscriptions are needed.`}),`\n`,_jsx(_components.p,{children:`Typical operations are inexpensive. For example:`}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Operation`}),_jsx(_components.th,{children:`Approximate cost`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`Creating a post (text only)`}),_jsx(_components.td,{children:`~$0.01 per post`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`Creating a post with media`}),_jsx(_components.td,{children:`~$0.02 per post (media upload and post creation are separate requests)`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`Reading a post`}),_jsx(_components.td,{children:`~$0.005 per read`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`User lookup`}),_jsx(_components.td,{children:`~$0.01 per lookup`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`Sending a DM`}),_jsx(_components.td,{children:`~$0.01 per message`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`Reading DM events`}),_jsx(_components.td,{children:`~$0.01 per event`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`User interactions (follow, like, etc.)`}),_jsx(_components.td,{children:`~$0.015 per request`})]})]})]}),`\n`,_jsx(_components.p,{children:`For context, if you’re posting about 100 times per month, your direct X cost would likely be around $1, and posts with media would be roughly $2 per month.`}),`\n`,_jsx(Note,{children:_jsxs(_components.p,{children:[`X’s pay-per-use pricing is currently in a pilot phase. Rates are subject to change, and additional costs may be introduced. Always check the Developer Console for the most current pricing. See `,_jsx(_components.a,{href:`https://docs.x.com/x-api/fundamentals/pricing`,children:`X’s pricing information breakdown`}),`.`]})}),`\n`,_jsx(_components.p,{children:`We know this introduces a cost that didn’t exist before, and we want to be transparent about that. At the same time, this model also unlocks several benefits that weren’t possible under the previous shared-key setup.`}),`\n`,_jsx(Heading,{level:`2`,id:`benefits-of-using-your-own-x-api-key`,children:`Benefits of Using Your Own X API Key`}),`\n`,_jsx(_components.p,{children:`Using your own X API credentials provides more control and reliability than the previous shared-key model. This includes:`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Branded OAuth experience:`}),` Users see your app name and branding when authorizing X access.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Dedicated rate limits:`}),` Your API usage is governed by your own X Developer account limits, separate from other Ayrshare users. You can monitor your usage in the `,_jsx(_components.a,{href:`https://console.x.com`,children:`X Developer Console`}),` and review the `,_jsx(_components.a,{href:`https://developer.x.com/en/docs/x-api/rate-limits`,children:`X API rate limits documentation`}),`.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Credential control:`}),` Your API Key and Secret stay in your own X Developer account. Ayrshare does not store the keys you send in request headers. Creating a linking URL is the one exception, described in the Security section below.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Portability:`}),` Because users authenticate with your X App, your integration remains fully under your control.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Usage visibility:`}),` Your X Developer dashboard shows API requests, rate limits, and credit usage.`]}),`\n`]}),`\n`,_jsx(_components.p,{children:`X is the first platform requiring this model, but more platforms are moving toward “bring your own API key.” We’re expanding this capability across Ayrshare, so developers have the same control and independence across all social platforms.`}),`\n`,_jsx(Heading,{level:`2`,id:`security`,children:`Security`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsx(_components.li,{children:`The API Key and API Secret you send in request headers are used for that request only and are not stored by Ayrshare.`}),`\n`,_jsxs(_components.li,{children:[`Creating a linking URL is the exception. When you pass `,_jsx(_components.code,{children:`twitterApiKey`}),` and `,_jsx(_components.code,{children:`twitterApiSecret`}),` to `,_jsx(_components.a,{href:`/apis/profiles/generate-jwt`,children:_jsx(_components.code,{children:`POST /profiles/generateJWT`})}),` or `,_jsx(_components.a,{href:`/apis/profiles/create-link-session`,children:_jsx(_components.code,{children:`POST /profiles/link-sessions`})}),`, the pair is encrypted and stored with that linking session, because the linking page needs it when your user authorizes X a moment later. It is removed when you `,_jsx(_components.a,{href:`/apis/profiles/revoke-link-session`,children:`revoke the link`}),`, or when an expired link is next opened or checked, and in any case it is deleted with the session record within 30 days.`]}),`\n`,_jsxs(_components.li,{children:[`For general security best practices, see `,_jsx(_components.a,{href:`https://docs.x.com/resources/fundamentals/authentication`,children:`X’s authentication security guide`}),`.`]}),`\n`]}),`\n`,_jsx(Heading,{level:`2`,id:`faq`,children:`FAQ`}),`\n`,_jsxs(AccordionGroup,{children:[_jsxs(Accordion,{title:`Do I need to set this up for every customer / sub-profile?`,id:`do-i-need-to-set-this-up-for-every-customer-sub-profile`,children:[_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`No.`}),` You set up `,_jsx(_components.strong,{children:`one`}),` X Developer App under your own X account, and the same `,_jsx(_components.strong,{children:`API Key + API Secret`}),` are reused for every sub-profile / end-user you link under your Ayrshare account.`]}),_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[`You create the X Developer App `,_jsx(_components.strong,{children:`once`}),`.`]}),`\n`,_jsxs(_components.li,{children:[`You pass the same two headers (`,_jsx(_components.code,{children:`X-Twitter-OAuth1-Api-Key`}),` and `,_jsx(_components.code,{children:`X-Twitter-OAuth1-Api-Secret`}),`) on every Ayrshare API call, regardless of which sub-profile the call is for.`]}),`\n`,_jsxs(_components.li,{children:[`Your end-users still each go through the OAuth linking flow to authorize their own X account, but they do `,_jsx(_components.strong,{children:`not`}),` need their own X Developer App or API keys. They connect through your app.`]}),`\n`,_jsx(_components.li,{children:`All sub-profiles share the same X Developer account, the same rate limits, and the same credit balance.`}),`\n`]}),_jsxs(_components.p,{children:[`The only time you handle the keys per-profile is in the `,_jsx(_components.a,{href:`/apis/profiles/generate-jwt`,children:`generateJWT`}),` body during migration, which is still your same two keys, just delivered to the linking page so end-users can re-authorize under your app.`]})]}),_jsx(Accordion,{title:`Is the X API key requirement active now?`,id:`is-the-x-api-key-requirement-active-now`,children:_jsx(_components.p,{children:`Yes. As of March 31, 2026, all X operations through Ayrshare require your own X API credentials. If you haven’t set up your X Developer account yet, follow the steps above.`})}),_jsx(Accordion,{title:`What happens if I don't add my X API key to Ayrshare?`,id:`what-happens-if-i-dont-add-my-x-api-key-to-ayrshare`,children:_jsx(_components.p,{children:`Posting to X through Ayrshare requires your own X API credentials. Requests without valid BYO credentials are rejected. Posting to other platforms (Instagram, LinkedIn, Facebook, TikTok, etc.) is unaffected.`})}),_jsx(Accordion,{title:`How much does the X API cost?`,id:`how-much-does-the-x-api-cost`,children:_jsxs(_components.p,{children:[`X charges per API call. Creating a post costs about $0.01, and reading a post costs about $0.005. For example, publishing 100 posts per month would cost roughly $1. See `,_jsx(_components.a,{href:`https://docs.x.com/x-api/fundamentals/pricing`,children:`X’s pricing page`}),` for the full details.`]})}),_jsx(Accordion,{title:`Does this change my Ayrshare subscription price?`,id:`does-this-change-my-ayrshare-subscription-price`,children:_jsx(_components.p,{children:`No. Your Ayrshare subscription price stays the same. The only additional cost is the X API usage fee billed directly by X through your developer account.`})}),_jsx(Accordion,{title:`Does Ayrshare store my X API credentials?`,id:`does-ayrshare-store-my-x-api-credentials`,children:_jsxs(_components.p,{children:[`For ordinary API requests, no: the API Key and API Secret you send in the headers are used for that request only and are not stored. Creating a linking URL is the exception, because the linking page needs the pair when your user authorizes X. There it is encrypted and stored with the linking session, then removed when you `,_jsx(_components.a,{href:`/apis/profiles/revoke-link-session`,children:`revoke the link`}),`, when an expired link is next opened or checked, or with the session record within 30 days. See the Security section above, and `,_jsx(_components.a,{href:`https://docs.x.com/resources/fundamentals/authentication`,children:`X’s authentication security guide`}),` for general best practices.`]})}),_jsxs(Accordion,{title:`I already have an X Developer account. Can I use my existing key?`,id:`i-already-have-an-x-developer-account-can-i-use-my-existing-key`,children:[_jsx(_components.p,{children:`Yes. You can use your existing X App as long as it has “Read and write” permissions enabled (and Direct Messages if you use DM features).`}),_jsx(_components.p,{children:`You’ll need your API Key (Consumer Key) and API Secret (Consumer Secret) from the Keys and tokens section of the X Developer Console. Link your X account via OAuth, then include these 2 headers in your Ayrshare API requests.`}),_jsx(_components.p,{children:`If you’ve changed your app permissions since the initial setup, re-link your X account so the Access Token inherits the updated permissions.`})]}),_jsx(Accordion,{title:`The X Developer Portal shows many credentials. Which ones do I actually need?`,id:`the-x-developer-portal-shows-many-credentials-which-ones-do-i-actually-need`,children:_jsxs(_components.p,{children:[`You need your API Key (Consumer Key) and API Secret (Consumer Secret). See the `,_jsx(_components.a,{href:`#header-reference`,children:`header reference table`}),` above for exactly which Ayrshare header each one maps to. You can ignore the Client ID, Client Secret, Bearer Token, Access Token, and Access Token Secret.`]})}),_jsxs(Accordion,{title:`What's the difference between 'API Key' and 'Client ID'?`,id:`whats-the-difference-between-api-key-and-client-id`,children:[_jsx(_components.p,{children:`They’re completely different credentials for different authentication methods:`}),_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`API Key`}),` (also called “Consumer Key”) is for OAuth 1.0a. API Key (Consumer Key) + API Secret is what Ayrshare uses. It works with all X features, tokens never expire, and no refresh logic is needed.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Client ID`}),` is for OAuth 2.0. You do NOT need this for Ayrshare. OAuth 2.0 tokens expire after a short period and require refresh token management.`]}),`\n`]}),_jsx(_components.p,{children:`For Ayrshare, you only need your API Key and API Secret. You can ignore the Client ID, Client Secret, and Bearer Token.`})]}),_jsx(Accordion,{title:`Why OAuth 1.0a and not OAuth 2.0?`,id:`why-oauth-1-0a-and-not-oauth-2-0`,children:_jsx(_components.p,{children:`OAuth 2.0 access tokens expire every 2 hours and X’s refresh tokens are single-use (each refresh invalidates the old token). This makes it impossible to support a stateless BYO model, especially for scheduled posts. OAuth 1.0a tokens never expire, work with all X features, and require zero token management.`})}),_jsx(Accordion,{title:`Do my existing users need to re-link their X accounts?`,id:`do-my-existing-users-need-to-re-link-their-x-accounts`,children:_jsxs(_components.p,{children:[`Yes. If your users linked X through Ayrshare before you set up BYO keys, they will need to reconnect. The existing access tokens were issued under Ayrshare’s X app and won’t work with your consumer keys. See `,_jsx(_components.a,{href:`#migrating-existing-profiles-business--enterprise`,children:`Migrating Existing Profiles`}),` above for the step-by-step process.`]})}),_jsx(Accordion,{title:`Does this change affect posting to Instagram, LinkedIn, or other platforms?`,id:`does-this-change-affect-posting-to-instagram-linkedin-or-other-platforms`,children:_jsx(_components.p,{children:`No. This change only affects posting to X. All other platform integrations in Ayrshare continue working as usual.`})}),_jsxs(Accordion,{title:`What about RSS/Feed auto-posting to X?`,id:`what-about-rss-feed-auto-posting-to-x`,children:[_jsx(_components.p,{children:`RSS auto-posting to X is no longer supported. RSS feeds run automatically on a schedule, but the bring-your-own API key model requires credentials to be provided with each API request. Because of this, RSS feeds cannot authenticate when the post is sent.`}),_jsxs(_components.p,{children:[`If you previously used RSS to post to X, we recommend switching to `,_jsx(_components.a,{href:`/apis/post/overview#schedule-posts`,children:`scheduled posts`}),` or direct API calls that include your credentials. RSS auto-posting to all other platforms is unchanged.`]})]}),_jsx(Accordion,{title:`Why am I getting a 402 \"CreditsDepleted\" error?`,id:`why-am-i-getting-a-402-creditsdepleted-error`,children:_jsxs(_components.p,{children:[`This means your X Developer account has no API credits available. Go to `,_jsx(_components.a,{href:`https://console.x.com`,children:`console.x.com`}),` → `,_jsx(_components.strong,{children:`Billing → Credits`}),` and purchase credits. Even $5 is enough for hundreds of API calls. Once credits are loaded, retry your request.`]})}),_jsxs(Accordion,{title:`Why am I getting a 403 \"Forbidden: OAuth1 App Permissions\" error?`,id:`why-am-i-getting-a-403-forbidden-oauth1-app-permissions-error`,children:[_jsx(_components.p,{children:`Your Access Token doesn’t have the right permissions. This usually means one of two things:`}),_jsxs(_components.ol,{children:[`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Your app permissions are set to “Read” instead of “Read and write.”`}),` Go to your app’s Settings in the Developer Console and change it to `,_jsx(_components.strong,{children:`Read and write and Direct message`}),`.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`You changed permissions after linking your X account.`}),` Access Tokens keep the permissions they were created with. Re-link your X account via OAuth so the new token inherits the updated permissions.`]}),`\n`]})]}),_jsx(Accordion,{title:`What if I need help setting this up?`,id:`what-if-i-need-help-setting-this-up`,children:_jsxs(_components.p,{children:[`Our support team is happy to help. If you have any questions or run into issues during setup, please reach out via `,_jsx(_components.a,{href:`mailto:support@ayrshare.com`,children:`support@ayrshare.com`}),`, and we’ll walk you through the process.`]})})]}),`\n`,_jsx(Heading,{level:`2`,id:`troubleshooting`,children:`Troubleshooting`}),`\n`,_jsxs(AccordionGroup,{children:[_jsxs(Accordion,{title:`I'm getting a 400 error about missing headers`,id:`i-m-getting-a-400-error-about-missing-headers`,children:[_jsx(_components.p,{children:`Make sure you’re sending both required headers:`}),_jsxs(_components.ul,{children:[`\n`,_jsx(_components.li,{children:_jsx(_components.code,{children:`X-Twitter-OAuth1-Api-Key`})}),`\n`,_jsx(_components.li,{children:_jsx(_components.code,{children:`X-Twitter-OAuth1-Api-Secret`})}),`\n`]}),_jsx(_components.p,{children:`If you see a pair-mismatch error (e.g., “You provided Api-Key but not Api-Secret”), it means one of the two is missing. Both are always required.`}),_jsx(_components.p,{children:`The error message will tell you which specific header is missing.`})]}),_jsxs(Accordion,{title:`I'm getting a 403 error: \"Callback URL not approved\"`,children:[_jsx(_components.p,{children:`If you see this error when trying to link your X account, make sure you’ve added the required callback URLs to your X Developer App settings (under Authentication settings > Callback URI / Redirect URL):`}),_jsxs(_components.ul,{children:[`\n`,_jsx(_components.li,{children:_jsx(_components.code,{children:`https://profile.ayrshare.com/social-accounts`})}),`\n`,_jsx(_components.li,{children:_jsx(_components.code,{children:`https://app.ayrshare.com/social-accounts`})}),`\n`]}),_jsxs(_components.p,{children:[`See the `,_jsx(_components.a,{href:`#step-3-configure-app-permissions`,children:`Callback URL setup step`}),` above.`]})]}),_jsx(Accordion,{title:`I'm getting a 402 error: \"CreditsDepleted\"`,children:_jsxs(_components.p,{children:[`Your X Developer account has no API credits loaded. Go to `,_jsx(_components.a,{href:`https://console.x.com`,children:`console.x.com`}),` → `,_jsx(_components.strong,{children:`Billing → Credits`}),` and purchase credits. Even $5 is enough for hundreds of API calls.`]})}),_jsxs(Accordion,{title:`I'm getting a 403 error: \"oauth1 app permissions\"`,children:[_jsx(_components.p,{children:`Your Access Token doesn’t have the right permissions. This usually means:`}),_jsxs(_components.ol,{children:[`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Your app permissions are set to “Read” instead of “Read and write.”`}),` Go to your app’s Settings in the Developer Console and change it to `,_jsx(_components.strong,{children:`Read and write and Direct message`}),`.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`You changed permissions after linking your X account.`}),` Access Tokens keep the permissions they were created with. Re-link your X account via OAuth so the new token inherits the updated permissions.`]}),`\n`]})]})]}),`\n`,_jsx(Heading,{level:`2`,id:`need-help`,children:`Need Help?`}),`\n`,_jsxs(_components.p,{children:[`If you have any questions or run into issues while setting up your X API key, our engineering team is happy to help. You can reach us anytime at `,_jsx(_components.a,{href:`mailto:support@ayrshare.com`,children:`support@ayrshare.com`}),`.`]})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"codeStyling":"system","config":{},"pageMetadata":{"title":"Set Up Your Own X API Key","description":"Step-by-step guide to connect your own X (Twitter) API credentials with Ayrshare","icon":"x-twitter","href":"/dashboard/connect-social-accounts/x-twitter-byo-keys"}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[{"title":"Step 1: Create Your X Developer Account","slug":"step-1-create-your-x-developer-account","depth":2,"children":[]},{"title":"Step 2: Create an App","slug":"step-2-create-an-app","depth":2,"children":[]},{"title":"Step 3: Configure App Permissions","slug":"step-3-configure-app-permissions","depth":2,"children":[]},{"title":"Step 4: Purchase X API Credits","slug":"step-4-purchase-x-api-credits","depth":2,"children":[]},{"title":"Step 5: Update Your Ayrshare API Calls","slug":"step-5-update-your-ayrshare-api-calls","depth":2,"children":[{"title":"Header Reference","slug":"header-reference","depth":3,"children":[]},{"title":"Code Examples","slug":"code-examples","depth":3,"children":[]},{"title":"Migrating Existing Profiles (Business \u0026 Enterprise)","slug":"migrating-existing-profiles-business--enterprise","depth":3,"children":[]},{"title":"Verify Your Setup","slug":"verify-your-setup","depth":3,"children":[]}]},{"title":"How X API Pricing Works","slug":"how-x-api-pricing-works","depth":2,"children":[]},{"title":"Benefits of Using Your Own X API Key","slug":"benefits-of-using-your-own-x-api-key","depth":2,"children":[]},{"title":"Security","slug":"security","depth":2,"children":[]},{"title":"FAQ","slug":"faq","depth":2,"children":[]},{"title":"Troubleshooting","slug":"troubleshooting","depth":2,"children":[]},{"title":"Need Help?","slug":"need-help","depth":2,"children":[]}],"codeExamples":{}},"jsLinks":["/docs/_mintlify/custom/ayrshare-docs/80ea29d8530ebaa2/script.js","/docs/_mintlify/custom/ayrshare-docs/3e93073b19ca64e9/tools/maintainScroll.js"],"subdomain":"ayrshare-docs","siteName":"Ayrshare Docs","title":"Set Up Your Own X API Key - Ayrshare Docs","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{"en":{"href":"/dashboard/connect-social-accounts/x-twitter-byo-keys","matchLevel":0},"es":{"href":"/es/dashboard/connect-social-accounts/x-twitter-byo-keys","matchLevel":1},"cn":{"href":"/cn/dashboard/connect-social-accounts/x-twitter-byo-keys","matchLevel":1,"hidden":true},"zh":{"href":"/zh/dashboard/connect-social-accounts/x-twitter-byo-keys","matchLevel":1,"hidden":true},"pt-BR":{"href":"/pt-BR/dashboard/connect-social-accounts/x-twitter-byo-keys","matchLevel":1},"fr":{"href":"/fr/dashboard/connect-social-accounts/x-twitter-byo-keys","matchLevel":1},"de":{"href":"/de/dashboard/connect-social-accounts/x-twitter-byo-keys","matchLevel":1},"vi":{"href":"/vi/dashboard/connect-social-accounts/x-twitter-byo-keys","matchLevel":1},"ja":{"href":"/ja/dashboard/connect-social-accounts/x-twitter-byo-keys","matchLevel":1},"uk":{"href":"/uk/dashboard/connect-social-accounts/x-twitter-byo-keys","matchLevel":1},"hi":{"href":"/hi/dashboard/connect-social-accounts/x-twitter-byo-keys","matchLevel":1},"ar":{"href":"/ar/dashboard/connect-social-accounts/x-twitter-byo-keys","matchLevel":1},"zh-Hans":{"href":"/zh-Hans/dashboard/connect-social-accounts/x-twitter-byo-keys","matchLevel":1},"zh-Hant":{"href":"/zh-Hant/dashboard/connect-social-accounts/x-twitter-byo-keys","matchLevel":1}}},"lastModified":"2026-09-25T00:45:10.422Z","originalFileLocation":"dashboard/connect-social-accounts/x-twitter-byo-keys.mdx","locale":"en"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"dark\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"Step-by-step guide to connect your own X (Twitter) API credentials with Ayrshare\">\u003cmeta data-mint-head name=\"application-name\" content=\"Ayrshare Docs\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/docs/mintlify-assets/_mintlify/favicons/ayrshare-docs/tc_XJFteIEk_1d3D/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/docs/mintlify-assets/_mintlify/favicons/ayrshare-docs/tc_XJFteIEk_1d3D/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/docs/mintlify-assets/_mintlify/favicons/ayrshare-docs/tc_XJFteIEk_1d3D/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/docs/mintlify-assets/_mintlify/favicons/ayrshare-docs/tc_XJFteIEk_1d3D/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/docs/mintlify-assets/_mintlify/favicons/ayrshare-docs/tc_XJFteIEk_1d3D/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/docs/mintlify-assets/_mintlify/favicons/ayrshare-docs/tc_XJFteIEk_1d3D/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/docs/mintlify-assets/_mintlify/favicons/ayrshare-docs/tc_XJFteIEk_1d3D/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/docs/mintlify-assets/_mintlify/favicons/ayrshare-docs/tc_XJFteIEk_1d3D/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/docs/mintlify-assets/_mintlify/favicons/ayrshare-docs/tc_XJFteIEk_1d3D/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Set Up Your Own X API Key - Ayrshare Docs\">\u003cmeta data-mint-head property=\"og:description\" content=\"Step-by-step guide to connect your own X (Twitter) API credentials with Ayrshare\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"Ayrshare Docs\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://www.ayrshare.com/docs/dashboard/connect-social-accounts/x-twitter-byo-keys\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://ayrshare-docs.mintlify.site/docs/_mintlify/api/og/v2?division=Connect+Social+Accounts\u0026amp;title=Set+Up+Your+Own+X+API+Key\u0026amp;description=Step-by-step+guide+to+connect+your+own+X+%28Twitter%29+API+credentials+with+Ayrshare\u0026amp;theme=9b71f2995bf23dbf0042e615\u0026amp;signature=fb7588508eb1d14f6fb26a5f65bbf06a3e2220f985c4eb8798f925698fcd903e\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"Set Up Your Own X API Key - Ayrshare Docs\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Step-by-step guide to connect your own X (Twitter) API credentials with Ayrshare\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://ayrshare-docs.mintlify.site/docs/_mintlify/api/og/v2?division=Connect+Social+Accounts\u0026amp;title=Set+Up+Your+Own+X+API+Key\u0026amp;description=Step-by-step+guide+to+connect+your+own+X+%28Twitter%29+API+credentials+with+Ayrshare\u0026amp;theme=9b71f2995bf23dbf0042e615\u0026amp;signature=fb7588508eb1d14f6fb26a5f65bbf06a3e2220f985c4eb8798f925698fcd903e\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/docs/mintlify-assets/_mintlify/favicons/ayrshare-docs/tc_XJFteIEk_1d3D/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"Ayrshare Docs\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#2266C2\">\u003clink data-mint-head rel=\"canonical\" href=\"https://www.ayrshare.com/docs/dashboard/connect-social-accounts/x-twitter-byo-keys\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/docs/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/docs/dashboard/connect-social-accounts/x-twitter-byo-keys.md\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"en\" href=\"https://www.ayrshare.com/docs/dashboard/connect-social-accounts/x-twitter-byo-keys\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"es\" href=\"https://www.ayrshare.com/docs/es/dashboard/connect-social-accounts/x-twitter-byo-keys\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"pt-BR\" href=\"https://www.ayrshare.com/docs/pt-BR/dashboard/connect-social-accounts/x-twitter-byo-keys\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"fr\" href=\"https://www.ayrshare.com/docs/fr/dashboard/connect-social-accounts/x-twitter-byo-keys\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"de\" href=\"https://www.ayrshare.com/docs/de/dashboard/connect-social-accounts/x-twitter-byo-keys\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"vi\" href=\"https://www.ayrshare.com/docs/vi/dashboard/connect-social-accounts/x-twitter-byo-keys\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"ja\" href=\"https://www.ayrshare.com/docs/ja/dashboard/connect-social-accounts/x-twitter-byo-keys\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"uk\" href=\"https://www.ayrshare.com/docs/uk/dashboard/connect-social-accounts/x-twitter-byo-keys\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"hi\" href=\"https://www.ayrshare.com/docs/hi/dashboard/connect-social-accounts/x-twitter-byo-keys\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"ar\" href=\"https://www.ayrshare.com/docs/ar/dashboard/connect-social-accounts/x-twitter-byo-keys\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"zh-Hans\" href=\"https://www.ayrshare.com/docs/zh-Hans/dashboard/connect-social-accounts/x-twitter-byo-keys\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"zh-Hant\" href=\"https://www.ayrshare.com/docs/zh-Hant/dashboard/connect-social-accounts/x-twitter-byo-keys\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"x-default\" href=\"https://www.ayrshare.com/docs/dashboard/connect-social-accounts/x-twitter-byo-keys\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://www.ayrshare.com/#organization\",\"name\":\"Ayrshare Docs\",\"url\":\"https://www.ayrshare.com\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/ayrshare-docs/7bWzjvNjeuvs-M3N/images/logos/ayrshare-docs-logo-light.svg?fit=max\u0026auto=format\u0026n=7bWzjvNjeuvs-M3N\u0026q=85\u0026s=8d23367f493d06599eecbbfa2b6325cf\"}},{\"@type\":\"WebSite\",\"@id\":\"https://www.ayrshare.com/docs#website\",\"name\":\"Ayrshare Docs\",\"url\":\"https://www.ayrshare.com/docs\",\"publisher\":{\"@id\":\"https://www.ayrshare.com/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://www.ayrshare.com/docs/dashboard/connect-social-accounts/x-twitter-byo-keys#webpage\",\"url\":\"https://www.ayrshare.com/docs/dashboard/connect-social-accounts/x-twitter-byo-keys\",\"name\":\"Set Up Your Own X API Key\",\"description\":\"Step-by-step guide to connect your own X (Twitter) API credentials with Ayrshare\",\"dateModified\":\"2026-09-25T00:45:10.422Z\",\"isPartOf\":{\"@id\":\"https://www.ayrshare.com/docs#website\"},\"breadcrumb\":{\"@id\":\"https://www.ayrshare.com/docs/dashboard/connect-social-accounts/x-twitter-byo-keys#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://www.ayrshare.com/docs/dashboard/connect-social-accounts/x-twitter-byo-keys#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Dashboard\",\"item\":\"https://www.ayrshare.com/docs/dashboard/overview\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Connect Social Accounts\",\"item\":\"https://www.ayrshare.com/docs/dashboard/connect-social-accounts/overview\"},{\"@type\":\"ListItem\",\"position\":3,\"name\":\"Set Up Your Own X API Key\",\"item\":\"https://www.ayrshare.com/docs/dashboard/connect-social-accounts/x-twitter-byo-keys\"}]},{\"@type\":[\"Article\",\"TechArticle\"],\"@id\":\"https://www.ayrshare.com/docs/dashboard/connect-social-accounts/x-twitter-byo-keys#article\",\"headline\":\"Set Up Your Own X API Key\",\"name\":\"Set Up Your Own X API Key\",\"description\":\"Step-by-step guide to connect your own X (Twitter) API credentials with Ayrshare\",\"url\":\"https://www.ayrshare.com/docs/dashboard/connect-social-accounts/x-twitter-byo-keys\",\"mainEntityOfPage\":{\"@id\":\"https://www.ayrshare.com/docs/dashboard/connect-social-accounts/x-twitter-byo-keys#webpage\"},\"dateModified\":\"2026-09-25T00:45:10.422Z\",\"publisher\":{\"@id\":\"https://www.ayrshare.com/#organization\"},\"isPartOf\":{\"@id\":\"https://www.ayrshare.com/docs#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"Ayrshare Docs\",\"creator\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","siteName":"Ayrshare Docs","nav":{"global":null,"languages":[{"language":"en","anchors":[{"anchor":"Documentation","icon":"code","groups":[{"group":"Get Started","pages":[{"title":"Ayrshare Social Media API","href":"/introduction"},{"title":"Quick Start Guide","href":"/quickstart"},{"group":"MCP Server","pages":[{"title":"Ayrshare MCP Server: Drive the API with AI Agents","sidebarTitle":"Overview","icon":"robot","href":"/additional/mcp-action-server"},{"title":"Connect to the MCP Server","sidebarTitle":"Connect \u0026 Setup","icon":"plug","href":"/additional/mcp-action-connect"},{"title":"MCP Tool Catalog","sidebarTitle":"Tool Catalog","icon":"list","href":"/additional/mcp-action-tools"},{"title":"Claude Code Plugin","icon":"terminal","href":"/additional/mcp-claude-code-plugin"},{"title":"n8n","icon":"diagram-project","href":"/additional/mcp-n8n"},{"title":"Onboard Client Social Accounts","sidebarTitle":"Client Onboarding","icon":"user-plus","href":"/additional/mcp-client-onboarding"},{"title":"Documentation MCP","sidebarTitle":"Documentation MCP","icon":"magnifying-glass","href":"/additional/mcp-server"}]}]},{"group":"API Endpoints","pages":[{"title":"Ayrshare API Overview","href":"/apis/overview"},{"group":"GraphQL","pages":[{"title":"GraphQL API Overview","href":"/apis/graphql/overview"},{"title":"Using the GraphQL API","href":"/apis/graphql/using-the-api"},{"title":"GraphQL Errors","href":"/apis/graphql/errors"},{"title":"GraphQL Limits and Billing","href":"/apis/graphql/limits"},{"title":"Ads","href":"/apis/graphql/ads"}]},{"group":"Ads","pages":[{"title":"Ads API: Boost Facebook and Instagram Posts and Manage Google Ads","sidebarTitle":"Ads API Overview","href":"/apis/ads/overview"},{"title":"Ad Campaigns","href":"/apis/ads/campaigns"},{"group":"Facebook Ads","pages":[{"title":"Accounts","api":"GET /ads/facebook/accounts","href":"/apis/ads/facebook/get-ad-accounts"},{"title":"Campaigns","api":"GET /ads/facebook/campaigns","href":"/apis/ads/facebook/get-ad-campaigns"},{"title":"Boost Post","api":"POST /ads/facebook/boost","href":"/apis/ads/facebook/boost-post"},{"title":"Boosted Ads","api":"GET /ads/facebook/ads","href":"/apis/ads/facebook/get-boosted-ads"},{"title":"History","api":"GET /ads/facebook/history","href":"/apis/ads/facebook/get-ad-history"},{"title":"Insights","api":"GET /ads/facebook/insights","href":"/apis/ads/facebook/get-ad-insights"},{"title":"Interests","api":"GET /ads/facebook/interests","href":"/apis/ads/facebook/get-ad-interests"},{"title":"Regions","api":"GET /ads/facebook/regions","href":"/apis/ads/facebook/get-ad-regions"},{"title":"Cities","api":"GET /ads/facebook/cities","href":"/apis/ads/facebook/get-ad-cities"},{"title":"DSA Recommendations","api":"GET /ads/facebook/dsaRecommendations","href":"/apis/ads/facebook/get-dsa-recommendations"},{"title":"Update Ad","api":"PUT /ads/facebook/ads","href":"/apis/ads/facebook/put-ad-update"}]},{"group":"Instagram Ads","pages":[{"title":"Accounts","api":"GET /ads/instagram/accounts","href":"/apis/ads/instagram/get-ad-accounts"},{"title":"Campaigns","api":"GET /ads/instagram/campaigns","href":"/apis/ads/instagram/get-ad-campaigns"},{"title":"Regions","api":"GET /ads/instagram/regions","href":"/apis/ads/instagram/get-ad-regions"},{"title":"Cities","api":"GET /ads/instagram/cities","href":"/apis/ads/instagram/get-ad-cities"},{"title":"DSA Recommendations","api":"GET /ads/instagram/dsaRecommendations","href":"/apis/ads/instagram/get-dsa-recommendations"},{"title":"Boost Post","api":"POST /ads/instagram/boost","href":"/apis/ads/instagram/boost-post"},{"title":"Boosted Ads","api":"GET /ads/instagram/ads","href":"/apis/ads/instagram/get-boosted-ads"},{"title":"History","api":"GET /ads/instagram/history","href":"/apis/ads/instagram/get-ad-history"},{"title":"Insights","api":"GET /ads/instagram/insights","href":"/apis/ads/instagram/get-ad-insights"},{"title":"Interests","api":"GET /ads/instagram/interests","href":"/apis/ads/instagram/get-ad-interests"},{"title":"Update Ad","api":"PUT /ads/instagram/ads","href":"/apis/ads/instagram/put-ad-update"}]},{"group":"Google Ads","pages":[{"title":"Accounts","api":"GET /ads/google/accounts","href":"/apis/ads/google/get-ad-accounts"},{"title":"Google Search Campaigns","sidebarTitle":"Search Campaigns","api":"POST /ads/google/campaigns","href":"/apis/ads/google/search-campaigns"},{"title":"Google Performance Max Campaigns","sidebarTitle":"Performance Max Campaigns","api":"POST /ads/google/campaigns","href":"/apis/ads/google/performance-max-campaigns"},{"title":"Get Campaign","api":"GET /ads/google/campaigns/{id}","href":"/apis/ads/google/get-campaign"},{"title":"Update Campaign","api":"PUT /ads/google/campaigns/{id}","href":"/apis/ads/google/update-campaign"},{"title":"Insights","api":"GET /ads/google/insights","href":"/apis/ads/google/get-ad-insights"}]}]},{"group":"Analytics","pages":[{"title":"Analytics API: Post, Social Account, and Link Metrics","sidebarTitle":"Analytics API Overview","href":"/apis/analytics/overview"},{"title":"Analytics on a Post","api":"POST /analytics/post","href":"/apis/analytics/post"},{"title":"Analytics on a Post by Social ID","api":"POST /analytics/post","href":"/apis/analytics/social-by-id"},{"title":"Analytics on a Social Network","api":"POST /analytics/social","href":"/apis/analytics/social"},{"title":"YouTube Playlists","api":"GET /analytics/youTubePlaylists","href":"/apis/analytics/youtube-playlists"},{"title":"Count of Instagram Followers Online","api":"GET /analytics/getInstagramOnlineFollowers","href":"/apis/analytics/instagram-follower-count"}]},{"group":"Auto Schedule","pages":[{"title":"Auto Schedule Overview","href":"/apis/auto-schedule/overview"},{"title":"Set Auto Schedule","api":"POST /auto-schedule/set","href":"/apis/auto-schedule/set-schedule"},{"title":"Delete Auto Schedule","api":"DELETE /auto-schedule/delete","href":"/apis/auto-schedule/delete-schedule"},{"title":"List Auto Schedule","api":"GET /auto-schedule/list","href":"/apis/auto-schedule/list-schedule"},{"title":"Get Pending Auto Schedule Posts","api":"GET /auto-schedule/pending","href":"/apis/auto-schedule/pending-auto-schedule"}]},{"group":"Automations","tag":"BETA","pages":[{"title":"Automations API Overview","href":"/apis/automations/overview"},{"title":"Create Automation","api":"POST /automations","href":"/apis/automations/create-automation"},{"title":"List Automations","api":"GET /automations","href":"/apis/automations/list-automations"},{"title":"Get Automation","api":"GET /automations/:id","href":"/apis/automations/get-automation"},{"title":"Update Automation","api":"PUT /automations/:id","href":"/apis/automations/update-automation"},{"title":"Delete Automation","api":"DELETE /automations/:id","href":"/apis/automations/delete-automation"},{"title":"Get Automation Activity","api":"GET /automations/:id/activity","href":"/apis/automations/get-activity"}]},{"group":"Brand","pages":[{"title":"Brand API: Public Account \u0026 Competitor Data","href":"/apis/brand/overview"}]},{"group":"Comments","pages":[{"title":"Comments API Overview","href":"/apis/comments/overview"},{"title":"Post a Comment","api":"POST /comments","href":"/apis/comments/post-comment"},{"title":"Get Comments","api":"GET /comments/:id","href":"/apis/comments/get-comments"},{"title":"Delete Comments","api":"DELETE /comments/:id","href":"/apis/comments/delete-comments"},{"title":"Reply to a Comment","api":"POST /comments/reply/:commentId","href":"/apis/comments/reply-to-comment"}]},{"group":"Feed","pages":[{"title":"RSS Feeds Overview","href":"/apis/feeds/overview"},{"title":"Add RSS Feed","api":"POST /feed","href":"/apis/feeds/add-feed"},{"title":"Delete RSS Feed","api":"DELETE /feed","href":"/apis/feeds/delete-feed"},{"title":"Get RSS Feeds","api":"GET /feed","href":"/apis/feeds/get-feeds"},{"title":"Update RSS Feed","api":"PUT /feed","href":"/apis/feeds/update-feed"}]},{"group":"Generate","pages":[{"title":"Generate API Overview","href":"/apis/generate/overview"},{"title":"Generate Post Text","api":"POST /generate/post","href":"/apis/generate/post-text"},{"title":"Rewrite Post","api":"POST /generate/rewrite","href":"/apis/generate/rewrite-post"},{"title":"Transcribe a Video","api":"POST /generate/transcription","href":"/apis/generate/transcribe-video"},{"title":"Translate Post","api":"POST /generate/translate","href":"/apis/generate/translate-post"},{"title":"Generate Alt Text","api":"POST /generate/altText","href":"/apis/generate/image-alt-text"},{"title":"Sentiment Analysis","api":"POST /generate/sentiment","href":"/apis/generate/sentiment"}]},{"group":"Hashtags","pages":[{"title":"Hashtags API Overview","href":"/apis/hashtags/overview"},{"title":"Auto Hashtags","api":"POST /hashtags/auto","href":"/apis/hashtags/auto-hashtags"},{"title":"Check Banned Hashtags","api":"GET /hashtags/banned","href":"/apis/hashtags/check-hashtags"},{"title":"Recommend Hashtags","api":"GET /hashtags/recommend","href":"/apis/hashtags/recommend-hashtags"},{"title":"Search Hashtags","api":"GET /hashtags/search","href":"/apis/hashtags/search-hashtags"}]},{"group":"History","pages":[{"title":"History API Overview","href":"/apis/history/overview"},{"title":"Posts History","api":"GET /history","href":"/apis/history/get-history"},{"title":"Post History by ID","api":"GET /history/:id","href":"/apis/history/get-history-id"},{"title":"Get post history for a social platform","api":"GET /history/:platform","href":"/apis/history/history-platform"},{"title":"Posts History by Social ID","api":"GET /history/:socialId","href":"/apis/history/history-social-id"}]},{"group":"Links","pages":[{"title":"Links API Overview","href":"/apis/links/overview"},{"title":"Create Short Link","api":"POST /links","href":"/apis/links/create-short-link"},{"title":"Update Short Link","api":"PUT /links/:id","href":"/apis/links/update-short-link"},{"title":"Link Analytics","api":"GET /links/:id","href":"/apis/links/link-analytics"}]},{"group":"Listening","pages":[{"title":"Listen API: Social Media Monitoring \u0026 Mentions","href":"/apis/listen/overview"},{"title":"Get Brand Data","api":"GET /brand/byUser","href":"/apis/listen/brand-user"},{"group":"Search","pages":[{"title":"Search Facebook Pages","api":"GET /brand/search/facebook","href":"/apis/listen/search/fb-page-search"},{"title":"Search LinkedIn","api":"GET /brand/search/linkedin","href":"/apis/listen/search/linkedin-search"}]},{"group":"Keyword","pages":[{"title":"Search Tweets by Keyword","api":"GET /listen/keyword","href":"/apis/listen/keyword/search-tweets"}]}]},{"group":"Media","pages":[{"title":"Media API Overview","href":"/apis/media/overview"},{"title":"Upload Image or Video","api":"POST /media/upload","href":"/apis/media/upload-media"},{"title":"Upload Large Media Files","api":"GET /media/uploadUrl","href":"/apis/media/upload-large-media"},{"title":"Verify Media URL Exists","api":"POST /media/urlExists","href":"/apis/media/verify-media-url"},{"title":"Get All Media in Gallery","api":"GET /media","href":"/apis/media/get-media-in-gallery"},{"title":"Resize an Image","api":"POST /media/resize","href":"/apis/media/resize"},{"title":"Metadata on a media file","api":"GET /media/meta","href":"/apis/media/get-media-metadata"},{"title":"Search Instagram audio","api":"GET /media/instagram/audio/search","href":"/apis/media/search-instagram-audio"},{"title":"Get Instagram audio metadata","api":"GET /media/instagram/audio/{audioId}","href":"/apis/media/get-instagram-audio"}]},{"group":"Messages","pages":[{"title":"Messages API Overview","href":"/apis/messages/overview"},{"title":"Send Message","api":"POST /messages/:platform","href":"/apis/messages/send-message"},{"title":"Get Messages","api":"GET /messages/:platform","href":"/apis/messages/get-messages"},{"title":"Update Messages","api":"PUT /messages/:platform/:conversationId","href":"/apis/messages/update-messages"},{"title":"Set Auto Response","api":"POST /messages/autoresponse","href":"/apis/messages/set-auto-response"},{"title":"Get Auto Response","api":"GET /messages/autoresponse","href":"/apis/messages/get-auto-response"}]},{"group":"Post","pages":[{"title":"Post API Overview","href":"/apis/post/overview"},{"title":"Publish a Post API: Post to Any Social Network","api":"POST /post","href":"/apis/post/post"},{"title":"Get a Post","api":"GET /post/:id","href":"/apis/post/get-post"},{"title":"Delete a Post","api":"DELETE /post","href":"/apis/post/delete-post"},{"title":"Update a Post","api":"PATCH /post","href":"/apis/post/update-post"},{"title":"Retry a Post","api":"PUT /post/retry","href":"/apis/post/retry-post"},{"title":"Copy a Post","api":"POST /post/copy","href":"/apis/post/copy-post"},{"title":"Bulk Post","api":"POST /post/bulk","href":"/apis/post/bulk-post"},{"group":"Social Networks","pages":[{"title":"Supported Social Networks","href":"/apis/post/social-networks/overview"},{"title":"Bluesky API","icon":"bluesky","href":"/apis/post/social-networks/bluesky"},{"title":"Facebook Page API","icon":"facebook","href":"/apis/post/social-networks/facebook"},{"title":"Google Business Profile API","icon":"google","href":"/apis/post/social-networks/google"},{"title":"Instagram API","icon":"instagram","href":"/apis/post/social-networks/instagram"},{"title":"LinkedIn API","icon":"linkedin","href":"/apis/post/social-networks/linkedin"},{"title":"Pinterest API","icon":"pinterest","href":"/apis/post/social-networks/pinterest"},{"title":"Reddit API","icon":"reddit","href":"/apis/post/social-networks/reddit"},{"title":"Snapchat API","icon":"snapchat","href":"/apis/post/social-networks/snapchat"},{"title":"Telegram API","icon":"telegram","href":"/apis/post/social-networks/telegram"},{"title":"Threads API","icon":"threads","href":"/apis/post/social-networks/threads"},{"title":"TikTok API","icon":"tiktok","href":"/apis/post/social-networks/tiktok"},{"title":"X API","icon":"x-twitter","href":"/apis/post/social-networks/x-twitter"},{"title":"YouTube API","icon":"youtube","href":"/apis/post/social-networks/youtube"}]}]},{"group":"Profiles","pages":[{"title":"Profiles API Overview","href":"/apis/profiles/overview"},{"title":"Create a User Profile","api":"POST /profiles","href":"/apis/profiles/create-profile"},{"title":"Delete a User Profile","api":"DELETE /profiles","href":"/apis/profiles/delete-profile"},{"title":"Update a User Profile","api":"PATCH /profiles","href":"/apis/profiles/update-profile"},{"title":"Get User Profiles","api":"GET /profiles","href":"/apis/profiles/get-profiles"},{"title":"Unlink a Social Network","api":"DELETE /profiles/social","href":"/apis/profiles/unlink-social-network"},{"title":"Social Linking Overview","href":"/apis/profiles/social-linking-overview"},{"title":"Create a Link Session","api":"POST /profiles/link-sessions","href":"/apis/profiles/create-link-session"},{"title":"Get a Link Session","api":"GET /profiles/link-sessions/{sessionId}","href":"/apis/profiles/get-link-session"},{"title":"Revoke a Link Session","api":"DELETE /profiles/link-sessions/{sessionId}","href":"/apis/profiles/revoke-link-session"},{"title":"Generate a Linking URL (generateJWT)","api":"POST /profiles/generateJWT","deprecated":true,"href":"/apis/profiles/generate-jwt"}]},{"group":"Reviews","pages":[{"title":"Reviews API Overview","href":"/apis/reviews/overview"},{"title":"Get All Reviews","api":"GET /reviews","href":"/apis/reviews/get-reviews"},{"title":"Get a Single Review","api":"GET /reviews/:id","href":"/apis/reviews/get-one-review"},{"title":"Reply to a Review","api":"POST /reviews","href":"/apis/reviews/reply-review"},{"title":"Delete a Review Reply","api":"DELETE /reviews","href":"/apis/reviews/delete-review-reply"}]},{"group":"User","pages":[{"title":"User Profile API Overview","href":"/apis/user/overview"},{"title":"User Profile Details","api":"GET /user","href":"/apis/user/profile-details"},{"title":"Pinterest Boards","api":"GET /user/details/pinterest","href":"/apis/user/pinterest-board"},{"title":"Update User","api":"PATCH /user/:platform","href":"/apis/user/update-user"},{"title":"WhatsApp Business Profile","api":"GET /user/details/whatsapp","href":"/apis/user/whatsapp-profile"},{"title":"Batch Get All","api":"GET /user/batch","href":"/apis/user/batch-all-users"}]},{"group":"Utils","pages":[{"title":"Collaborator Request Status","api":"GET /post/collaborators/:id","href":"/apis/utils/instagram-get-collaborator"},{"title":"Reddit Flair","api":"GET /post/redditFlair/:subreddit","href":"/apis/utils/reddit-get-flair"},{"title":"User Lookups","api":"GET /user/lookups","href":"/apis/utils/user-lookups"},{"group":"YouTube","pages":[{"title":"YouTube Categories","api":"GET /post/youtubeCategories/:region","href":"/apis/utils/youtube-categories"},{"title":"Set YouTube Watermark","api":"POST /post/youTubeWatermark","href":"/apis/utils/set-youtube-watermark"},{"title":"Remove YouTube Watermark","api":"DELETE /post/youTubeWatermark","href":"/apis/utils/remove-youtube-watermark"}]}]},{"group":"Validate","pages":[{"title":"Validate API Overview","href":"/apis/validate/overview"},{"title":"Validate Media","href":"/apis/validate/validate-media"},{"title":"Check Post Length","api":"POST /validate/postLength","href":"/apis/validate/check-post-length"},{"title":"Check Subreddit Exists","api":"GET /validate/redditExists/:subreddit","href":"/apis/validate/check-subreddit"},{"title":"Content Moderation","api":"POST /validate/moderation","href":"/apis/validate/moderation"},{"title":"Validate JSON","api":"POST /validate/json","href":"/apis/validate/validate-json"},{"title":"Validate a Post","api":"POST /validate/post","href":"/apis/validate/validate-post"}]},{"group":"Webhooks","pages":[{"title":"Webhooks Overview","href":"/apis/webhooks/overview"},{"title":"Webhook Actions","href":"/apis/webhooks/actions"},{"title":"Register Webhook","api":"POST /hook/webhook","href":"/apis/webhooks/register"},{"title":"Unregister Webhook","api":"DELETE /hook/webhook","href":"/apis/webhooks/unregister"},{"title":"Rotate Signing Secret","api":"POST /hook/webhook/secret","href":"/apis/webhooks/rotate-signing-secret"},{"title":"List Registered Webhooks","api":"GET /hook/webhook","href":"/apis/webhooks/list"},{"title":"Webhook History","api":"GET /hook/history","href":"/apis/webhooks/history"}]}]},{"group":"Multiple Users","pages":[{"title":"Launch Plan: entry-level multi-user Business plan","href":"/multiple-users/business-launch-overview"},{"title":"Business Plan Overview","href":"/multiple-users/business-plan-overview"},{"title":"User Integration","href":"/multiple-users/user-integration"},{"title":"API Integration for Business","href":"/multiple-users/api-integration-business"},{"title":"Ayrshare Connect Widget","href":"/multiple-users/connect-widget"},{"title":"Build Your Own Linking Popup","href":"/multiple-users/connect-direct-mode"},{"title":"Link Completion Events","href":"/multiple-users/link-completion-events"},{"title":"Manage Multiple User Profiles","href":"/multiple-users/manage-user-profiles"}]},{"group":"Dashboard","pages":[{"title":"Ayrshare Dashboard Overview: Manage Social Media Posting","href":"/dashboard/overview"},{"group":"Connect Social Accounts","pages":[{"title":"Connect Your Social Media Accounts","href":"/dashboard/connect-social-accounts/overview"},{"title":"Bluesky Linking","icon":"bluesky","href":"/dashboard/connect-social-accounts/bluesky"},{"title":"Facebook Linking","icon":"facebook","href":"/dashboard/connect-social-accounts/facebook"},{"title":"Google Business Profile Linking","icon":"google","href":"/dashboard/connect-social-accounts/google-business"},{"title":"Instagram Linking","icon":"instagram","href":"/dashboard/connect-social-accounts/instagram"},{"title":"LinkedIn Linking","icon":"linkedin","href":"/dashboard/connect-social-accounts/linkedin"},{"title":"Pinterest Linking","icon":"pinterest","href":"/dashboard/connect-social-accounts/pinterest"},{"title":"Reddit Linking","icon":"reddit","href":"/dashboard/connect-social-accounts/reddit"},{"title":"Snapchat Linking","icon":"snapchat","href":"/dashboard/connect-social-accounts/snapchat"},{"title":"Link a Telegram group or channel to Ayrshare","icon":"telegram","href":"/dashboard/connect-social-accounts/telegram"},{"title":"Threads Linking","icon":"threads","href":"/dashboard/connect-social-accounts/threads"},{"title":"TikTok Linking","description":"Link a TikTok personal or business account to Ayrshare by authorizing access on TikTok, with notes on the 365 day link expiration and troubleshooting.","icon":"tiktok","href":"/dashboard/connect-social-accounts/tiktok"},{"title":"Set Up Your Own X API Key","icon":"x-twitter","href":"/dashboard/connect-social-accounts/x-twitter-byo-keys"},{"title":"X Linking","description":"Link an X (Twitter) account to Ayrshare by entering your X Consumer Key and Consumer Secret, signing in through the pop-up, and authorizing the app.","icon":"x-twitter","href":"/dashboard/connect-social-accounts/x-twitter"},{"title":"YouTube Linking","icon":"youtube","href":"/dashboard/connect-social-accounts/youtube"}]},{"title":"How to Publish a Social Media Post","href":"/dashboard/publish-post"},{"title":"View JSON","href":"/dashboard/view-json"},{"title":"Revoke Access to Social Media","href":"/dashboard/revoke-access"},{"group":"RSS","pages":[{"title":"RSS, Substack, and YouTube Feeds","href":"/dashboard/automated-rss-feeds"},{"title":"Find an RSS Feed URL","href":"/dashboard/find-rss"}]}]},{"group":"Additional","pages":[{"group":"What's New At Ayrshare","pages":[{"title":"Latest Updates","href":"/whatsnew/latest"},{"title":"Update Archive","href":"/whatsnew/archive"},{"title":"Upcoming API Changes","mode":"wide","href":"/whatsnew/upcoming-api-changes"}]},{"group":"Errors","pages":[{"title":"Errors Overview","href":"/errors/overview"},{"title":"HTTP Status Codes","href":"/errors/errors-http"},{"title":"Ayrshare Error Codes","href":"/errors/errors-ayrshare"}]},{"title":"Max Pack","mode":"wide","href":"/additional/maxpack"},{"group":"Media Guidelines","pages":[{"title":"Social Media Image \u0026 Video Requirements","href":"/media-guidelines/overview"},{"title":"Bluesky","icon":"bluesky","href":"/media-guidelines/bluesky"},{"title":"Facebook Pages","icon":"facebook","href":"/media-guidelines/facebook-pages"},{"title":"Google Business Profile","icon":"google","href":"/media-guidelines/google-business-profile"},{"title":"Instagram","icon":"instagram","href":"/media-guidelines/instagram"},{"title":"LinkedIn","icon":"linkedin","href":"/media-guidelines/linkedin"},{"title":"Pinterest","icon":"pinterest","href":"/media-guidelines/pinterest"},{"title":"Reddit","icon":"reddit","href":"/media-guidelines/reddit"},{"title":"Snapchat","icon":"snapchat","href":"/media-guidelines/snapchat"},{"title":"Telegram","icon":"telegram","href":"/media-guidelines/telegram"},{"title":"Threads","icon":"threads","href":"/media-guidelines/threads"},{"title":"TikTok","icon":"tiktok","href":"/media-guidelines/tiktok"},{"title":"WhatsApp","icon":"whatsapp","href":"/media-guidelines/whatsapp"},{"title":"X","icon":"x-twitter","href":"/media-guidelines/x-twitter"},{"title":"YouTube","icon":"youtube","href":"/media-guidelines/youtube"}]},{"group":"Packages \u0026 Guides","pages":[{"title":"Ayrshare SDKs \u0026 Integration Guides Overview","mode":"wide","href":"/packages-guides/overview"},{"title":"Airtable","href":"/packages-guides/airtable"},{"title":"Bubble.io","href":"/packages-guides/bubble"},{"title":"Flutter","href":"/packages-guides/flutter"},{"title":"FlutterFlow","href":"/packages-guides/flutterflow"},{"title":"Make","href":"/packages-guides/make"},{"title":"n8n","href":"/packages-guides/n8n"},{"title":"Node.js NPM","href":"/packages-guides/nodejs"},{"title":"Notion","href":"/packages-guides/notion"},{"title":"Python PyPI","href":"/packages-guides/python"},{"title":"Retool","href":"/packages-guides/retool"}]},{"title":"System Status","href":"/additional/status"},{"group":"Testing \u0026 Verification","pages":[{"title":"Hurl","href":"/testing/hurl"},{"title":"Validation Endpoints","href":"/testing/validation-endpoints"},{"title":"Postman","href":"/testing/postman"},{"title":"Post Verification","href":"/testing/post-verification"}]},{"group":"ISO Codes","pages":[{"title":"Country Codes","href":"/iso-codes/country"},{"title":"Language Codes","href":"/iso-codes/language"}]}]}]},{"anchor":"Help Center","icon":"lightbulb","pages":[{"title":"Help Center","href":"/help-center/overview"}]}]},{"language":"es","pages":[{"title":"es","href":"/es/dashboard/connect-social-accounts/x-twitter-byo-keys"}]},{"language":"cn","hidden":true,"pages":[{"title":"cn","href":"/cn/dashboard/connect-social-accounts/x-twitter-byo-keys","hidden":true}]},{"language":"zh","hidden":true,"pages":[{"title":"zh","href":"/zh/dashboard/connect-social-accounts/x-twitter-byo-keys","hidden":true}]},{"language":"pt-BR","pages":[{"title":"pt-BR","href":"/pt-BR/dashboard/connect-social-accounts/x-twitter-byo-keys"}]},{"language":"fr","pages":[{"title":"fr","href":"/fr/dashboard/connect-social-accounts/x-twitter-byo-keys"}]},{"language":"de","pages":[{"title":"de","href":"/de/dashboard/connect-social-accounts/x-twitter-byo-keys"}]},{"language":"vi","pages":[{"title":"vi","href":"/vi/dashboard/connect-social-accounts/x-twitter-byo-keys"}]},{"language":"ja","pages":[{"title":"ja","href":"/ja/dashboard/connect-social-accounts/x-twitter-byo-keys"}]},{"language":"uk","pages":[{"title":"uk","href":"/uk/dashboard/connect-social-accounts/x-twitter-byo-keys"}]},{"language":"hi","pages":[{"title":"hi","href":"/hi/dashboard/connect-social-accounts/x-twitter-byo-keys"}]},{"language":"ar","pages":[{"title":"ar","href":"/ar/dashboard/connect-social-accounts/x-twitter-byo-keys"}]},{"language":"zh-Hans","pages":[{"title":"zh-Hans","href":"/zh-Hans/dashboard/connect-social-accounts/x-twitter-byo-keys"}]},{"language":"zh-Hant","pages":[{"title":"zh-Hant","href":"/zh-Hant/dashboard/connect-social-accounts/x-twitter-byo-keys"}]}]},"basePath":"","title":"Set Up Your Own X API Key - Ayrshare Docs","buildId":"dpl_ATnXPMW25DMPUr9VBw6kL6MfBt6T","deploymentId":"dpl_ATnXPMW25DMPUr9VBw6kL6MfBt6T","dynamics":["a74be98ba7"],"chunks":["zoom-image-lightbox-CypZe82l.js","lightbox-handle-r17bVUz3.js"]}