> ## Documentation Index
> Fetch the complete documentation index at: https://x-preview-mintlify-066e8699.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Ferramentas e Bibliotecas

> SDKs oficiais da X API em Python e TypeScript, ferramentas de CLI como xurl, servidor de playground, servidores MCP para IA e bibliotecas cliente da comunidade.

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>;
};

Acelere seu desenvolvimento com SDKs oficiais, ferramentas para desenvolvedores e bibliotecas da comunidade.

***

## SDKs oficiais

<CardGroup cols={2}>
  <Card title="Python SDK" icon="python" href="/xdks/python/overview">
    Suporte assíncrono, type hints e atualização automática de tokens. Perfeito para análise de dados e automação.
  </Card>

  <Card title="TypeScript SDK" icon="js" href="/xdks/typescript/overview">
    Segurança de tipos completa e suporte a ESM. Funciona em Node.js e bundlers modernos.
  </Card>
</CardGroup>

### Início rápido

<Tabs>
  <Tab title="Python">
    ```bash theme={null}
    pip install xdk
    ```

    ```python theme={null}
    from xdk import Client

    client = Client(bearer_token="YOUR_BEARER_TOKEN")

    for page in client.posts.search_recent(query="api", max_results=10):
        if page.data and len(page.data) > 0:
            print(page.data[0].text)
            break
    ```

    <Button href="/xdks/python/overview">Guia completo de Python</Button>
  </Tab>

  <Tab title="TypeScript">
    ```bash theme={null}
    npm install @xdevplatform/xdk
    ```

    ```typescript theme={null}
    import { Client } from '@xdevplatform/xdk';

    const client = new Client({ bearerToken: 'YOUR_BEARER_TOKEN' });
    const userResponse = await client.users.getByUsername('XDevelopers');
    console.log(userResponse.data?.username);
    ```

    <Button href="/xdks/typescript/overview">Guia completo de TypeScript</Button>
  </Tab>
</Tabs>

***

## Ferramentas para desenvolvedores

<CardGroup cols={2}>
  <Card title="Coleção do Postman" icon="server" href="https://www.postman.com/xapidevelopers/x-api-public-workspace/collection/34902927-2efc5689-99c6-4ab6-8091-996f35c2fd80">
    Teste interativo da API para todos os endpoints v2.
  </Card>

  <Card title="xurl" icon="terminal" href="/tools/xurl">
    CLI similar ao curl para a X API com autenticação OAuth integrada. Sem gerenciamento manual de tokens.
  </Card>

  <Card title="API Playground" icon="flask" href="https://github.com/xdevplatform/playground">
    Servidor mock local para testar endpoints da X API v2 sem usar créditos reais.
  </Card>

  <Card title="Recursos para Agentes" icon="robot" href="/tools/ai">
    XMCP, llms.txt, skill.md, servidor MCP de docs e recursos para desenvolvimento com IA.
  </Card>
</CardGroup>

### Outras ferramentas

| Ferramenta                                              | Descrição                                                   |
| :------------------------------------------------------ | :---------------------------------------------------------- |
| [OpenAPI Spec](https://api.x.com/2/openapi.json)        | Especificação da API legível por máquina                    |
| [twitter-text](https://github.com/twitter/twitter-text) | Analisa e valida o texto de posts, conta caracteres         |
| [Embed Generator](https://publish.x.com/#)              | Crie posts, timelines ou botões incorporáveis para seu site |

***

## Bibliotecas da comunidade

Bibliotecas mantidas pela comunidade com suporte à X API v2. Consulte a documentação de cada biblioteca para a cobertura atual.

<Tabs>
  <Tab title="Python">
    | Biblioteca                                                   | Descrição                                  |
    | :----------------------------------------------------------- | :----------------------------------------- |
    | [tweepy](https://github.com/tweepy/tweepy)                   | Biblioteca Python popular com suporte a v2 |
    | [twarc](https://twarc-project.readthedocs.io/)               | CLI e biblioteca para coleta de dados      |
    | [python-twitter](https://github.com/sns-sdks/python-twitter) | Wrapper Python simples                     |
    | [TwitterAPI](https://github.com/geduldig/TwitterAPI)         | Wrapper Python minimalista                 |
  </Tab>

  <Tab title="JavaScript/TypeScript">
    | Biblioteca                                                           | Descrição                                    |
    | :------------------------------------------------------------------- | :------------------------------------------- |
    | [node-twitter-api-v2](https://github.com/PLhery/node-twitter-api-v2) | Cliente Node.js fortemente tipado e completo |
    | [twitter.js](https://github.com/twitterjs/twitter.js)                | Biblioteca Node.js orientada a objetos       |
    | [twitter-v2](https://github.com/HunterLarco/twitter-v2)              | Biblioteca cliente assíncrona                |
  </Tab>

  <Tab title="Go">
    | Biblioteca                                                      | Descrição                   |
    | :-------------------------------------------------------------- | :-------------------------- |
    | [go-twitter](https://github.com/g8rswimmer/go-twitter)          | Biblioteca Go para a API v2 |
    | [gotwi](https://github.com/michimani/gotwi)                     | Wrapper Go para v2          |
    | [twitter-stream](https://github.com/Fallenstedt/twitter-stream) | Wrapper de filtered stream  |
  </Tab>

  <Tab title="Java/Kotlin">
    | Biblioteca                                            | Descrição                      |
    | :---------------------------------------------------- | :----------------------------- |
    | [twittered](https://github.com/redouane59/twittered)  | Cliente Java para v2           |
    | [twitter4j-v2](https://github.com/takke/twitter4j-v2) | Wrapper Twitter4J v2           |
    | [KTweet](https://github.com/ChromasIV/KTweet)         | Biblioteca Kotlin v2           |
    | [Tweedle](https://github.com/tyczj/Tweedle)           | Biblioteca Kotlin para Android |
  </Tab>

  <Tab title="PHP">
    | Biblioteca                                                        | Descrição                |
    | :---------------------------------------------------------------- | :----------------------- |
    | [twitter-api-v2-php](https://github.com/noweh/twitter-api-v2-php) | Cliente PHP v2           |
    | [bird-elephant](https://github.com/danieldevine/bird-elephant)    | Biblioteca PHP v2        |
    | [twitteroauth](https://github.com/abraham/twitteroauth)           | Biblioteca OAuth popular |
  </Tab>

  <Tab title="Ruby">
    | Biblioteca                                                        | Descrição            |
    | :---------------------------------------------------------------- | :------------------- |
    | [tweetkit](https://github.com/julianfssen/tweetkit)               | Cliente Ruby v2      |
    | [twitter\_oauth2](https://github.com/nov/twitter_oauth2)          | Biblioteca OAuth 2.0 |
    | [omniauth-twitter2](https://github.com/unasuke/omniauth-twitter2) | Estratégia OmniAuth  |
  </Tab>

  <Tab title="Outras">
    | Linguagem      | Biblioteca                                                                                                 |
    | :------------- | :--------------------------------------------------------------------------------------------------------- |
    | **C#/.NET**    | [Tweetinvi](https://github.com/linvi/tweetinvi), [LinqToTwitter](https://github.com/JoeMayo/LinqToTwitter) |
    | **Rust**       | [twitter-v2](https://github.com/jpopesculian/twitter-v2-rs)                                                |
    | **Swift**      | [Twift](https://github.com/daneden/Twift/), [TwitterAPIKit](https://github.com/mironal/TwitterAPIKit)      |
    | **R**          | [academictwitteR](https://github.com/cjbarrie/academictwitteR)                                             |
    | **PowerShell** | [BluebirdPS](https://github.com/thedavecarroll/BluebirdPS)                                                 |
  </Tab>
</Tabs>

<Note>
  As bibliotecas da comunidade não são mantidas pelo X. Consulte seus repositórios para suporte e status atual.
</Note>

***

## Exemplos de código

* [Código de exemplo da X API v2](https://github.com/xdevplatform/Twitter-API-v2-sample-code) — Exemplos em Python, JavaScript, Ruby e mais
* [Repositório de exemplos de código](https://github.com/xdevplatform/samples) — Exemplos usando os XDKs oficiais
* [GitHub de Desenvolvedores do X](https://github.com/xdevplatform) — Repositórios e ferramentas oficiais

***

## Bibliotecas da X Ads API

Para ferramentas e bibliotecas específicas da X Ads API, veja a página de [ferramentas e bibliotecas da Ads API](/x-ads-api/tools-and-libraries).
