X (Twitter)post/user/tweets

User's Tweets

User
Cost / request

$0.01

Response format

JSON

Protocol

REST

About this endpoint

Access X data through agntdata: User's Tweets. This endpoint return a list of user's tweets given a username. Responses are structured JSON for AI agents, analytics, and automation — one API key instead of juggling upstream accounts. Ideal when you need tweets, user profiles, followers, search, and hashtag streams programmatically.

Use cases

AI agents that need X data in structured form
Analytics and monitoring pipelines for X content
Research and GTM workflows that combine X signals with other data

Parameters

bodyRequest Body

Content type: application/json

{
  "type": "object",
  "properties": {
    "username": {
      "type": "string"
    },
    "user_id": {
      "type": "string"
    },
    "include_replies": {
      "type": "boolean"
    },
    "include_pinned": {
      "type": "boolean"
    }
  }
}

Responses

Response

{
  "type": "array",
  "items": {
    "type": "object"
  }
}

Agent / Developer Schema

Machine-readable formats for integrating this endpoint into AI agents and toolchains.

{
  "operationId": "User_s_Tweets_post__user_tweets",
  "method": "post",
  "path": "/user/tweets",
  "summary": "User's Tweets",
  "description": "This endpoint return a list of user's tweets given a username",
  "parameters": [],
  "requestBody": {
    "required": false,
    "content": {
      "application/json": {
        "schema": {
          "type": "object",
          "properties": {
            "username": {
              "type": "string"
            },
            "user_id": {
              "type": "string"
            },
            "include_replies": {
              "type": "boolean"
            },
            "include_pinned": {
              "type": "boolean"
            }
          }
        },
        "example": {
          "username": "elonmusk",
          "user_id": "44196397",
          "include_replies": false,
          "include_pinned": false
        }
      }
    }
  },
  "responses": [
    {
      "statusCode": "200",
      "description": "Response",
      "content": {
        "application/json": {
          "schema": {
            "type": "array",
            "items": {
              "type": "object"
            }
          },
          "example": {
            "detail": "The API is limited, please try again later"
          }
        }
      }
    },
    {
      "statusCode": "422",
      "description": "Validation Error",
      "content": {
        "application/json": {
          "schema": {
            "title": "HTTPValidationError",
            "type": "object",
            "properties": {
              "detail": {
                "title": "Detail",
                "type": "array",
                "items": {
                  "title": "ValidationError",
                  "required": [
                    "loc",
                    "msg",
                    "type"
                  ],
                  "type": "object",
                  "properties": {
                    "loc": {
                      "title": "Location",
                      "type": "array",
                      "items": {
                        "anyOf": [
                          {
                            "type": "string"
                          },
                          {
                            "type": "integer"
                          }
                        ]
                      }
                    },
                    "msg": {
                      "title": "Message",
                      "type": "string"
                    },
                    "type": {
                      "title": "Error Type",
                      "type": "string"
                    }
                  }
                }
              }
            }
          },
          "example": {
            "detail": [
              {
                "loc": [],
                "msg": "",
                "type": ""
              }
            ]
          }
        }
      }
    }
  ]
}

Pricing

$0.01per successful request

Credits are deducted from your agntdata balance on each successful API call. Failed requests (4xx/5xx) are not charged.

Related endpoints

Start using this endpoint

Generate your API key and make your first call in under a minute. Free tier available with transparent pricing.

X APIX data APIuser's tweets APIAI agents data APIX APIX data APIX for AI agents