> ## Documentation Index
> Fetch the complete documentation index at: https://docs.x.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Introduction

> X is committed to our community of developers who build with the X API. Reference for the X API v2 standard tier covering streams.

export const Button = ({href, children}) => {
  return <div className="not-prose group">
    <a href={href}>
      <button className="flex items-center space-x-2.5 py-1 px-4 bg-primary-dark dark:bg-white text-white dark:text-gray-950 rounded-full group-hover:opacity-[0.9] font-medium">
        <span>
          {children}
        </span>
        <svg width="3" height="24" viewBox="0 -9 3 24" class="h-6 rotate-0 overflow-visible"><path d="M0 0L3 3L0 6" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round"></path></svg>
      </button>
    </a>
  </div>;
};

X is committed to our community of developers who build with the X API. As part of this commitment, we aim to make our API open and fair to developers, safe for people on X and beneficial for the X platform as a whole. It is crucial that any developer who stores X content offline, ensures the data reflects user intent and the current state of content on X. For example, when someone on X deletes a Post or their account, protects their Posts, or edits a Post, it is critical for both X and our developers to honor that person's expectations and intent.

Near real-time streams of compliance events provide developers the tools to maintain X data in compliance with the [X Developer Agreement and Policy](https://developer.x.com/en/developer-terms/policy).

There are two compliance event streams, one for *Post compliance* events, and one for *User compliance* events. These streams are available with Enterprise access and are designed to help partners that ingest high volumes of data 'listen' for compliance events such as Post edit events.

These streams provide the following events:

**Post compliance stream:**

* **delete** - indicates that the Post was deleted.

* **tweet\_edit** - indicates a Post has been edited and provides the ID of the updated Post.

* **withheld** - indicates that the Post has been withheld from one or more countries.

* **drop** - indicates that the Post should be removed from public view.

* **undrop** - indicates that the Post may be displayed again and treated as public.

**User compliance stream:**

* **user\_delete** - indicates that the User account was deleted

* **user\_undelete** - indicates that the User account was undeleted

* **user\_protect** - indicates that the User account became private

* **user\_unprotect** - indicates that the User account became public

* **user\_withheld** - indicates that the User account has been withheld from one or more countries. 

* **user\_suspend** - indicates that the User account was suspended

* **user\_unsuspend** - indicates that the User account was unsuspended

* **user\_profile\_modification** - indicates that the User profile has been updated. This includes an updated description, name, location, and URL.

**Account setup**

To access these endpoints, you will need:

* An approved [developer account](https://developer.x.com/en/portal/petition/essential/basic-info).
* To authenticate using the keys and tokens from a [developer App](/resources/fundamentals/developer-apps) that is located within a [Project](/resources/fundamentals/developer-apps). 

Learn more about getting access to the X API v2 endpoints in our [getting started guide](/x-api/getting-started/getting-access).

<div className="flex space-x-2">
  <Button href="https://www.postman.com/xapidevelopers/x-api-public-workspace/collection/34902927-2efc5689-99c6-4ab6-8091-996f35c2fd80">
    Run in Postman
  </Button>

  <Button href="https://developer.x.com/apitools/api?endpoint=/2/compliance/jobs">
    Try with API Explorer
  </Button>
</div>

***

## Streaming fundamentals

<CardGroup cols={2}>
  <Card title="Consuming streaming data" icon="stream" href="/x-api/fundamentals/consuming-streaming-data">
    Best practices for streaming clients
  </Card>

  <Card title="Handling disconnections" icon="plug" href="/x-api/fundamentals/handling-disconnections">
    Reconnect gracefully
  </Card>

  <Card title="High volume capacity" icon="gauge-high" href="/x-api/fundamentals/high-volume-capacity">
    Handle high throughput
  </Card>

  <Card title="Recovery and redundancy" icon="shield" href="/x-api/fundamentals/recovery-and-redundancy">
    Build resilient applications
  </Card>
</CardGroup>
