> ## Documentation Index
> Fetch the complete documentation index at: https://api-tools.memories.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Twitter Video Metadata

> Get Twitter video metadata.

<Info>
  **Product**: Visual Intelligence — Social Media Scraping
  **Use case**: Fetch video metadata, transcripts, captions, and comments from YouTube, Instagram, TikTok, and Twitter/X
  **Host**: `https://mavi-backend.memories.ai/serve/api/v2`
  **Auth**: `Authorization: sk-mavi-...` (no `Bearer` prefix)
</Info>

This endpoint allows you to retrieve metadata for a Twitter video.

<Note>
  Channel routing guide: see [Social Media Scraping Overview](/visual-intelligence/social-media-scraping-overview). Endpoints with a `channel` request field let you choose `apify`, `rapid`, or `memories.ai`; endpoints without this field use managed routing.
</Note>

<Note>
  **Pricing:**

  * **rapid** channel: \$0.01 per video
  * **memories.ai** channel: \$0.01 per video
  * **apify** channel: Charged at Apify's actual cost (higher and variable pricing)
</Note>

### Code Example

<CodeGroup>
  ```python Python theme={null}
  import requests

  BASE_URL = "https://mavi-backend.memories.ai/serve/api/v2"
  API_KEY = "sk-mavi-..."
  HEADERS = {
      "Authorization": f"{API_KEY}"
  }

  def twitter_video_metadata(video_url: str, channel: str):
      url = f"{BASE_URL}/twitter/video/metadata"
      data = {"video_url": video_url, "channel": channel}
      resp = requests.post(url, headers=HEADERS, json=data)
      return resp.json()

  # Usage example
  result = twitter_video_metadata("https://x.com/NBCOlympics/status/1989901761650323606", "apify")
  print(result)
  ```
</CodeGroup>

### Request Body

| Field      | Type   | Required | Description                                                         |
| ---------- | ------ | -------- | ------------------------------------------------------------------- |
| video\_url | string | Yes      | The Twitter video URL                                               |
| channel    | string | Yes      | The channel name. Supported values: `apify`, `rapid`, `memories.ai` |

### Response

<Warning>
  **Response shape depends on the `channel` parameter** — same channel-dependent split as the YouTube / TikTok / Instagram siblings. Verified live:

  * `channel: "apify"` — `data` is an **array**. On a tweet with no scrapable video it returns `[{ "noResults": ... }]`; on a tweet with video it returns the rich apify-shaped object below.
  * `channel: "memories.ai"` — `data` is an **object** wrapping Twitter's native shape: `{ result: { ... } }`.
  * `channel: "rapid"` — same alternative shape as `memories.ai`.

  Pick a channel per integration; the example below is the **apify** shape.
</Warning>

<ResponseExample>
  ```json theme={null}
  {
    "code": 200,
    "msg": "success",
    "data": [
      {
        "type": "tweet",
        "id": "1989901761650323606",
        "url": "https://x.com/NBCOlympics/status/1989901761650323606",
        "twitterUrl": "https://twitter.com/NBCOlympics/status/1989901761650323606",
        "text": "France's Kevin Aymoz couldn't believe his 159.97 free skate score that led to his first-ever ISU Grand Prix GOLD. 🤯 https://t.co/901FxyK1Jc",
        "fullText": "France's Kevin Aymoz couldn't believe his 159.97 free skate score that led to his first-ever ISU Grand Prix GOLD. 🤯 https://t.co/901FxyK1Jc",
        "source": "Wildmoka",
        "retweetCount": 257,
        "replyCount": 139,
        "likeCount": 5002,
        "quoteCount": 39,
        "viewCount": 43099524,
        "createdAt": "Sun Nov 16 03:42:05 +0000 2025",
        "lang": "en",
        "bookmarkCount": 607,
        "isReply": false,
        "conversationId": "1989901761650323606",
        "possiblySensitive": false,
        "isPinned": false,
        "author": {
          "type": "user",
          "userName": "NBCOlympics",
          "url": "https://x.com/NBCOlympics",
          "twitterUrl": "https://twitter.com/NBCOlympics",
          "id": "14955353",
          "name": "NBC Olympics & Paralympics",
          "isVerified": false,
          "verifiedType": "Business",
          "isBlueVerified": true,
          "profilePicture": "https://pbs.twimg.com/profile_images/1889684530245554177/hNcrFUJ0_normal.jpg",
          "coverPicture": "https://pbs.twimg.com/profile_banners/14955353/1762962343",
          "description": "The official home of NBC's coverage of the Olympics and Paralympics.",
          "followers": 1077295,
          "following": 2809,
          "createdAt": "Fri May 30 15:20:31 +0000 2008"
        },
        "extendedEntities": {
          "media": [
            {
              "display_url": "pic.x.com/901FxyK1Jc",
              "expanded_url": "https://x.com/NBCOlympics/status/1989901761650323606/video/1",
              "id_str": "1989901699746516992",
              "type": "video",
              "media_url_https": "https://pbs.twimg.com/media/G52NGsBXMAAniJV.jpg",
              "video_info": {
                "aspect_ratio": [16, 9],
                "duration_millis": 18261,
                "variants": [
                  {
                    "content_type": "application/x-mpegURL",
                    "url": "https://video.twimg.com/amplify_video/1989901699746516992/pl/Y7hhhkSJzh19OnTV.m3u8?tag=14&v=19e"
                  },
                  {
                    "bitrate": 2176000,
                    "content_type": "video/mp4",
                    "url": "https://video.twimg.com/amplify_video/1989901699746516992/vid/avc1/1280x720/OSp0AyG0fnyvfjZP.mp4?tag=14"
                  }
                ]
              }
            }
          ]
        },
        "isRetweet": false,
        "isQuote": false,
        "media": ["https://pbs.twimg.com/media/G52NGsBXMAAniJV.jpg"],
        "isConversationControlled": false
      }
    ],
    "failed": false,
    "success": true
  }
  ```
</ResponseExample>

### Response Parameters

| Parameter                                                      | Type           | Description                                       |
| -------------------------------------------------------------- | -------------- | ------------------------------------------------- |
| code                                                           | string         | Response code indicating the result status        |
| msg                                                            | string         | Response message describing the operation result  |
| data                                                           | array\[object] | Array containing Twitter/X tweet metadata objects |
| data\[].type                                                   | string         | Content type (e.g., "tweet")                      |
| data\[].id                                                     | string         | Tweet ID                                          |
| data\[].url                                                    | string         | X.com URL                                         |
| data\[].twitterUrl                                             | string         | Twitter.com URL                                   |
| data\[].text                                                   | string         | Tweet text                                        |
| data\[].fullText                                               | string         | Full tweet text                                   |
| data\[].source                                                 | string         | Source of the tweet                               |
| data\[].retweetCount                                           | number         | Number of retweets                                |
| data\[].replyCount                                             | number         | Number of replies                                 |
| data\[].likeCount                                              | number         | Number of likes                                   |
| data\[].quoteCount                                             | number         | Number of quotes                                  |
| data\[].viewCount                                              | number         | Number of views                                   |
| data\[].createdAt                                              | string         | Creation timestamp                                |
| data\[].lang                                                   | string         | Language code                                     |
| data\[].bookmarkCount                                          | number         | Number of bookmarks                               |
| data\[].author                                                 | object         | Author/user information                           |
| data\[].author.userName                                        | string         | Author username                                   |
| data\[].author.name                                            | string         | Author display name                               |
| data\[].author.isVerified                                      | boolean        | Whether the author is verified                    |
| data\[].author.isBlueVerified                                  | boolean        | Whether the author has blue verification          |
| data\[].author.followers                                       | number         | Number of followers                               |
| data\[].author.following                                       | number         | Number of users following                         |
| data\[].extendedEntities                                       | object         | Extended media entities                           |
| data\[].extendedEntities.media                                 | array\[object] | Array of media objects                            |
| data\[].extendedEntities.media\[].type                         | string         | Media type (e.g., "video")                        |
| data\[].extendedEntities.media\[].video\_info                  | object         | Video information                                 |
| data\[].extendedEntities.media\[].video\_info.duration\_millis | number         | Video duration in milliseconds                    |
| data\[].extendedEntities.media\[].video\_info.variants         | array\[object] | Array of video variants with different bitrates   |
| data\[].isRetweet                                              | boolean        | Whether the tweet is a retweet                    |
| data\[].isQuote                                                | boolean        | Whether the tweet is a quote                      |
| data\[].media                                                  | array\[string] | Array of media URLs                               |
| success                                                        | boolean        | Indicates whether the operation was successful    |
| failed                                                         | boolean        | Indicates whether the operation failed            |


## OpenAPI

````yaml POST /twitter/video/metadata
openapi: 3.1.0
info:
  title: Video Metadata & Transcript API Reference
  description: >-
    REST APIs for retrieving video metadata and transcripts from YouTube,
    Instagram, TikTok, and Twitter
  version: v1.0.1
servers:
  - url: https://mavi-backend.memories.ai/serve/api/v2
security:
  - ApiKeyAuth: []
paths:
  /twitter/video/metadata:
    post:
      summary: Twitter Video Metadata
      description: Get Twitter video metadata.
      operationId: twitter_video_metadata
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                video_url:
                  type: string
                  description: The Twitter video URL
                  example: https://x.com/NBCOlympics/status/1989901761650323606
                channel:
                  type: string
                  description: >-
                    The channel name. Supported values: apify, rapid,
                    memories.ai
                  enum:
                    - apify
                    - rapid
                    - memories.ai
                  example: apify
              required:
                - video_url
                - channel
      responses:
        '200':
          description: Video metadata information with detailed Twitter/X data
          content:
            application/json:
              schema:
                type: object
                properties:
                  code:
                    type: string
                    example: 200
                    description: Response code indicating the result status
                  msg:
                    type: string
                    example: success
                    description: Response message describing the operation result
                  data:
                    type: array
                    items:
                      type: object
                      properties:
                        type:
                          type: string
                          example: tweet
                          description: Content type
                        id:
                          type: string
                          example: '1989901761650323606'
                          description: Tweet ID
                        url:
                          type: string
                          example: https://x.com/NBCOlympics/status/1989901761650323606
                          description: X.com URL
                        twitterUrl:
                          type: string
                          example: >-
                            https://twitter.com/NBCOlympics/status/1989901761650323606
                          description: Twitter.com URL
                        text:
                          type: string
                          example: >-
                            France's Kevin Aymoz couldn't believe his 159.97
                            free skate score that led to his first-ever ISU
                            Grand Prix GOLD. 🤯 https://t.co/901FxyK1Jc
                          description: Tweet text
                        fullText:
                          type: string
                          example: >-
                            France's Kevin Aymoz couldn't believe his 159.97
                            free skate score that led to his first-ever ISU
                            Grand Prix GOLD. 🤯 https://t.co/901FxyK1Jc
                          description: Full tweet text
                        source:
                          type: string
                          example: Wildmoka
                          description: Source of the tweet
                        retweetCount:
                          type: number
                          example: 257
                          description: Number of retweets
                        replyCount:
                          type: number
                          example: 139
                          description: Number of replies
                        likeCount:
                          type: number
                          example: 5002
                          description: Number of likes
                        quoteCount:
                          type: number
                          example: 39
                          description: Number of quotes
                        viewCount:
                          type: number
                          example: 43099524
                          description: Number of views
                        createdAt:
                          type: string
                          example: Sun Nov 16 03:42:05 +0000 2025
                          description: Creation timestamp
                        lang:
                          type: string
                          example: en
                          description: Language code
                        bookmarkCount:
                          type: number
                          example: 607
                          description: Number of bookmarks
                        isReply:
                          type: boolean
                          example: false
                          description: Whether the tweet is a reply
                        conversationId:
                          type: string
                          example: '1989901761650323606'
                          description: Conversation ID
                        possiblySensitive:
                          type: boolean
                          example: false
                          description: Whether the content is possibly sensitive
                        isPinned:
                          type: boolean
                          example: false
                          description: Whether the tweet is pinned
                        author:
                          type: object
                          description: Author/user information
                          properties:
                            type:
                              type: string
                              example: user
                            userName:
                              type: string
                              example: NBCOlympics
                              description: Author username
                            url:
                              type: string
                              example: https://x.com/NBCOlympics
                            twitterUrl:
                              type: string
                              example: https://twitter.com/NBCOlympics
                            id:
                              type: string
                              example: '14955353'
                            name:
                              type: string
                              example: NBC Olympics & Paralympics
                              description: Author display name
                            isVerified:
                              type: boolean
                              example: false
                              description: Whether the author is verified
                            verifiedType:
                              type: string
                              example: Business
                              description: Verification type
                            isBlueVerified:
                              type: boolean
                              example: true
                              description: Whether the author has blue verification
                            profilePicture:
                              type: string
                              example: >-
                                https://pbs.twimg.com/profile_images/1889684530245554177/hNcrFUJ0_normal.jpg
                              description: Profile picture URL
                            coverPicture:
                              type: string
                              example: >-
                                https://pbs.twimg.com/profile_banners/14955353/1762962343
                              description: Cover picture URL
                            description:
                              type: string
                              example: >-
                                The official home of NBC's coverage of the
                                Olympics and Paralympics.
                              description: Author description
                            followers:
                              type: number
                              example: 1077295
                              description: Number of followers
                            following:
                              type: number
                              example: 2809
                              description: Number of users following
                            createdAt:
                              type: string
                              example: Fri May 30 15:20:31 +0000 2008
                              description: Account creation timestamp
                        extendedEntities:
                          type: object
                          description: Extended media entities
                          properties:
                            media:
                              type: array
                              items:
                                type: object
                                properties:
                                  display_url:
                                    type: string
                                    example: pic.x.com/901FxyK1Jc
                                  expanded_url:
                                    type: string
                                    example: >-
                                      https://x.com/NBCOlympics/status/1989901761650323606/video/1
                                  id_str:
                                    type: string
                                    example: '1989901699746516992'
                                  type:
                                    type: string
                                    example: video
                                    description: Media type
                                  media_url_https:
                                    type: string
                                    example: >-
                                      https://pbs.twimg.com/media/G52NGsBXMAAniJV.jpg
                                    description: Media URL
                                  video_info:
                                    type: object
                                    description: Video information
                                    properties:
                                      aspect_ratio:
                                        type: array
                                        items:
                                          type: number
                                        example:
                                          - 16
                                          - 9
                                        description: Video aspect ratio
                                      duration_millis:
                                        type: number
                                        example: 18261
                                        description: Video duration in milliseconds
                                      variants:
                                        type: array
                                        items:
                                          type: object
                                          properties:
                                            content_type:
                                              type: string
                                              example: video/mp4
                                            url:
                                              type: string
                                              example: >-
                                                https://video.twimg.com/amplify_video/1989901699746516992/vid/avc1/1280x720/OSp0AyG0fnyvfjZP.mp4?tag=14
                                            bitrate:
                                              type: number
                                              example: 2176000
                                              description: Video bitrate
                                        description: >-
                                          Array of video variants with different
                                          bitrates
                              description: Array of media objects
                        isRetweet:
                          type: boolean
                          example: false
                          description: Whether the tweet is a retweet
                        isQuote:
                          type: boolean
                          example: false
                          description: Whether the tweet is a quote
                        media:
                          type: array
                          items:
                            type: string
                          example:
                            - https://pbs.twimg.com/media/G52NGsBXMAAniJV.jpg
                          description: Array of media URLs
                        isConversationControlled:
                          type: boolean
                          example: false
                          description: Whether the conversation is controlled
                    description: Array containing Twitter/X tweet metadata objects
                  success:
                    type: boolean
                    example: true
                    description: Indicates whether the operation was successful
                  failed:
                    type: boolean
                    example: false
                    description: Indicates whether the operation failed
components:
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: Authorization

````