Skip to main content
POST
Create a Twitter community with the X community API

How to create a community on Twitter with Xquik

Call POST /x/communities to create a community on Twitter from one connected account. This create Twitter community workflow submits a name and optional description. Xquik then tracks the write until X returns a final result. Use this route only when the account should own a new community. Use join or leave routes for an existing community. This route does not add rules, members, moderators, invitations, posts, analytics, or membership settings. Each community gives one topic a dedicated space on X. People can search for communities by name, description, or creator. They can join a community later. Each member of the community follows the chosen membership type and community rules. This X social media workflow creates the community container only.
10 credits per call · All plans from $0.00012/credit

Prepare a community creation request

Approve the community name, description, and rules before this call. Keep the connected owner in the approval record. Create one idempotency key for the intended community. Reuse it only when the same request needs network recovery. Use a new key after any approved input changes. Community creation workflows should include:
  • Checking the final name for spelling and scope.
  • Reviewing rules with the future moderation team.
  • Recording the owner account and approval reference.
  • Saving the returned community and action identifiers.
Do not submit parallel requests with different keys for one intended community. That can create multiple communities. Read the lifecycle state before exposing the new community to downstream workflows.

Build a reviewable community brief

Create a short brief before calling this endpoint. Record the proposed name, description, owner account, audience, and moderation purpose. Keep that brief beside the approval record. Reviewers can then compare the submitted fields against the approved community identity. Treat the name as a lasting public label. Check spelling, capitalization, and topic scope before approval. Use the description to explain who should join. Avoid campaign dates or temporary slogans in either field. Those details age quickly and make later community discovery confusing. Choose one connected account as the accountable owner. Record its username and stable account ID when available. Confirm that the account appears in your connected-account inventory. Keep the same owner during network recovery. A different owner means a different write request. Store these creation inputs together:
  • Connected owner username and account ID.
  • Final community name and description.
  • Approval reference and approving operator.
  • Idempotency key for this exact submission.
  • Returned action ID and lifecycle state.
This record separates approval from network recovery. Repeat the unchanged request only after a network timeout. Changed text needs a new approval and key.

Confirm the community admin account

Choose the connected account before review. X assigns admin ownership to the original creator. Community admins manage names, descriptions, rules, and moderators in X. Xquik only sends the creation request. X currently requires an eligible admin account. Its official moderator playbook lists these checks:
  • Use a public account.
  • Use an account that is at least 6 months old.
  • Verify an email address or phone number.
  • Keep the account compliant with the X Terms of Service.
X enforces these requirements and can change them. The request has no eligibility override. It also has no Premium field. Confirm current eligibility inside X before approval. Preserve any rejection reason for the operator. Review the X Communities moderator playbook before assigning the owner. It explains creator, admin, moderator, and member responsibilities. Store the chosen account with the approved community brief.

Plan community rules and membership

Define community rules before creating the container. Rules should describe the topic, allowed behavior, and moderation response. Do not place temporary campaign instructions in the public description. Keep the full rule set in the team’s approved moderation record. X offers open communities and restricted membership. Open communities show a Join button at the top of the community page. Restricted communities can let a person request to join. A moderator then accepts or denies that request. X may also allow member invitations. This endpoint does not choose a membership type. It does not add community members or moderators. Configure those settings after creation through the current X interface. Record the selected mode beside the returned community ID. Read the X Communities guide before opening membership. It covers visibility, roles, invitations, and moderation. Use the guide as the source for current X behavior. Use this page for Xquik’s API contract.

Prepare a brand or product community

Use a specific name that explains the shared topic. Write a description that identifies the intended community members. State who operates the community. Avoid names that imply an unsupported partnership or endorsement. Prepare the first discussion topics before launch. Assign community admins and moderators before invitations begin. Decide who reviews reports and removes disruptive members. Keep escalation rules outside the public description. This route cannot publish welcome posts or schedule discussions. It cannot promote or monetize the community. After launch, publish Community posts with Create Tweet. X may display Community posts inside a member’s Twitter feed.

Connect the community to a website or app

The request has no website, app, rules, or invitation field. Store those links in your application after X confirms creation. Associate them with the returned community ID, owner account, approval, and lifecycle record. After success, verify the name on the community page. Search for communities by name, description, or creator through X when available. X notes that not every community appears in search results. Do not treat search visibility as proof of creation. Use the community ID as the stable integration key. Do not key integrations by the editable display name. Store a verified community URL only after the read route confirms the new ID.

Answer common community creation questions

Do X communities still exist?

Yes. X still publishes current Communities and moderator guidance. This API creates an X Community through a connected account. X controls feature availability and account eligibility.

Do you need X Premium to create a community?

The Xquik request does not accept a Premium setting. X decides whether the connected account can create the community. Check current X eligibility before submitting a billable write.

Can the API add rules, members, or moderators?

No. The canonical request accepts account, name, and description. Set community rules, membership type, invitations, and moderator roles after creation. Never send undocumented fields.

Can the API schedule, grow, or monetize a community?

No. This route creates the community and tracks that write. It does not schedule posts, invite initial members, run promotions, provide analytics, or configure monetization.

How should software handle community creation?

Require an approved brief and one idempotency key. Store the action ID immediately. Poll the lifecycle, verify the new community ID, and then start separate membership or publishing workflows.

Validate the new community

Wait for the write lifecycle to finish before announcing the community. A 202 response means Xquik accepted the write for processing. It does not prove that X completed community creation. Follow the returned lifecycle state until the action reaches its final result. Capture the new community ID from the confirmed result. Then call Community Info. Compare its name and description with the approved brief. Save the returned community ID beside the owner account and action ID. Run these checks before inviting members:
  1. Confirm the community ID resolves.
  2. Compare the returned name with the approved name.
  3. Compare the returned description with the approved description.
  4. Confirm the intended owner account remains connected.
  5. Record the final write state and verification time.
Repeat the information request after a temporary read failure. Keep the same key only when every input remains unchanged.

Handle creation failures safely

Treat each response by its actual cause. Fix invalid names or missing accounts before sending another write. Restore credits before retrying a 402 response. Reconnect the owner after 403. A 409 means the key already identifies another request. Compare both request bodies. Reuse the key only when every creation input matches. Generate a new key after any approved field changes. For 422, preserve the rejected request and returned reason. Do not rewrite the community brief automatically. Return it to the operator for review. For 429, respect the retry guidance and keep the same approved intent. After 503, check the write lifecycle before retrying. A disconnected client does not prove failure. Duplicate creation costs more than delayed verification.

Headers

string
required
Your API key. OAuth bearer authentication is also supported. Generate a key from the dashboard.
string
required
Unique key for this intended write. Reuse it only for an exact network replay.
string
required
Must be application/json.

Body

string
required
The connected X account to create the community as. Must be a username you have connected to your Xquik account.
string
required
The name for the new community.
string
Optional description for the community explaining its purpose.

Response

Connect the requested account, then submit a newly approved write.

Durable write recovery

Send one unique Idempotency-Key per intended write. Reuse it only for the same account, target, payload, and media.
  1. Store id, the nested hash in request, billing, and statusUrl.
  2. Poll after Retry-After or pollAfterMs when terminal is false.
  3. Trust safeToRetry and nextAction before any new write.

200 Terminal or 202 active

Store terminal results. Poll active actions without creating another write.
  • After HTTP 200, store the result and settled billing.
  • After HTTP 202, poll the same action. Never submit another write.
  • After HTTP 400, fix the named field. Use a new idempotency key.
  • After HTTP 401, fix authentication. Do not retry unchanged.
  • After HTTP 402, fund the account before another write.
  • After HTTP 403, reconnect the account.
  • After HTTP 409, keep the original action. Use a new key for new input.
  • After HTTP 422, fix the rejected request before retrying.
  • After HTTP 429, wait for Retry-After. Preserve the same key.
  • After HTTP 500, retry only when safeToRetry is true.
  • After HTTP 503, poll while terminal is false.
See Get Write Action Status for every lifecycle field, terminal state, billing field, and retry rule.