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

# Top Message (/api-reference/engagement-messages/top-message)

Get the top performing message by purchases in the selected timeframe.

## OpenAPI

````yaml https://app.onlyfansapi.com/scribe-docs/openapi.yaml get /api/{account}/engagement/messages/top-message
openapi: 3.0.3
info:
  title: OnlyFans API
  description: ""
  version: 1.0.0
servers:
  - url: https://app.onlyfansapi.com
security:
  - default: []
tags:
  - name: API Keys
    description: ""
  - name: Account
    description: Endpoints for your linked accounts
  - name: Analytics - Financial
    description: APIs for retrieving financial analytics data
  - name: Analytics - Summary
    description: APIs for retrieving summary analytics data
  - name: Banking
    description: Operations related to user banking details, payout methods, legal
      and tax information, and account country settings.
  - name: Chargebacks
    description: ""
  - name: Chat Messages
    description: ""
  - name: Chats
    description: ""
  - name: Client Sessions
    description: ""
  - name: Connect OnlyFans Account
    description: ""
  - name: Data Exports
    description: APIs for managing data exports
  - name: Engagement / Messages
    description: ""
  - name: Fans
    description: APIs for managing OnlyFans fans (subscribers)
  - name: Fans - AI Summary
    description: APIs for generating and retrieving AI-powered fan profile summaries
  - name: Following
    description: APIs for managing OnlyFans followings (people you're subscribed to)
  - name: Free Trial Links
    description: APIs for managing Free Trial Links
  - name: Giphy
    description: ""
  - name: Link Tags
    description: APIs for managing tags on free trial links and tracking links
  - name: Mass Messaging
    description: ""
  - name: Media
    description: ""
  - name: Media Vault
    description: ""
  - name: Media Vault Lists
    description: ""
  - name: Notifications
    description: Endpoints for managingr account notifications
  - name: Payouts
    description: ""
  - name: Post Comments
    description: ""
  - name: Post Labels
    description: APIs for managing your post labels
  - name: Posts
    description: APIs for managing OnlyFans posts
  - name: Promotions
    description: ""
  - name: Public Profiles
    description: ""
  - name: Queue
    description: ""
  - name: Release Forms
    description: APIs for managing OnlyFans release forms
  - name: Saved For Later (Messages)
    description: ""
  - name: Saved For Later (Posts)
    description: ""
  - name: Settings
    description: ""
  - name: Shared Free Trial Links
    description: APIs for Free Trial Links that other OF creators have shared with
      this account. Revenue, cost, and spender data are not available for shared
      links.
  - name: Shared Tracking Links
    description: APIs for Tracking Links (campaigns) that other OF creators have
      shared with this account. Revenue, cost, and spender data are not
      available for shared campaigns.
  - name: Smart Link Postbacks
    description: APIs for managing Smart Link postback destinations
  - name: Smart Links
    description: APIs for managing Smart Links (Free Trial Links and Tracking Links
      with pooled inventory)
  - name: Statistics
    description: ""
  - name: Stored Free Trial Links
    description: Instant APIs for retrieving stored free trial links from the
      OnlyFansAPI Cache (free, no credits used)
  - name: Stored Shared Free Trial Links
    description: Instant APIs for retrieving stored shared Free Trial Links from the
      OnlyFansAPI Cache (free, no credits used)
  - name: Stored Shared Tracking Links
    description: Instant APIs for retrieving stored shared Tracking Links
      (campaigns) from the OnlyFansAPI Cache (free, no credits used)
  - name: Stored Tracking Links
    description: Instant APIs for retrieving stored tracking links from the
      OnlyFansAPI Cache (free, no credits used)
  - name: Stories
    description: APIs for managing OnlyFans stories
  - name: Story Highlights
    description: APIs for managing OnlyFans story highlights
  - name: Subscription Bundles
    description: ""
  - name: Tracking Links
    description: APIs for managing tracking links
  - name: Transactions
    description: APIs for managing OnlyFans transactions
  - name: User List Collections
    description: ""
  - name: Users
    description: APIs for fetching OnlyFans users
  - name: Webhooks
    description: ""
paths:
  /api/{account}/engagement/messages/top-message:
    parameters:
      - in: path
        name: account
        description: The Account ID
        example: acct_XXXXXXXXXXXXXXX
        required: true
        schema:
          type: string
    get:
      summary: Top Message
      operationId: topMessage
      description: Get the top performing message by purchases in the selected timeframe.
      parameters:
        - in: query
          name: startDate
          description: The start date for the period. Keep empty to retrieve from the
            model start date.
          example: 2026-01-07 00:00:00
          required: false
          schema:
            type: string
            description: The start date for the period. Keep empty to retrieve from the
              model start date.
            example: 2026-01-07 00:00:00
        - in: query
          name: endDate
          description: The end date for the period. Keep empty to retrieve until now. MUST
            BE DATE AFTER `startDate`.
          example: 2026-02-06 01:26:15
          required: false
          schema:
            type: string
            description: The end date for the period. Keep empty to retrieve until now. MUST
              BE DATE AFTER `startDate`.
            example: 2026-02-06 01:26:15
      responses:
        "200":
          description: ""
          content:
            application/json:
              schema:
                type: object
                example:
                  data:
                    purchases:
                      id: 6677889900
                      date: 2024-06-30T12:53:42+00:00
                      responseType: message
                      text: This is the hardest i've ever been fucked... would you make me cum more
                        than this?? 🥵💦
                      rawText: This is the hardest i've ever been fucked... would you make me cum more
                        than this?? 🥵💦
                      giphyId: null
                      isFree: false
                      isMediaReady: true
                      mediaCount: 1
                      media:
                        - id: 7788990011
                          type: video
                          convertedToVideo: false
                          canView: true
                          hasError: false
                          createdAt: 2023-01-31T13:14:15+00:00
                          isReady: true
                          files:
                            full:
                              url: https://cdn.example.com/files/placeholder/video_source.mp4
                              width: 1080
                              height: 1920
                              size: 0
                              sources: []
                            thumb:
                              url: https://cdn.example.com/files/placeholder/thumb.jpg
                              width: 300
                              height: 300
                              size: 0
                            preview:
                              url: https://cdn.example.com/files/placeholder/preview.jpg
                              width: 960
                              height: 1707
                              size: 0
                            squarePreview:
                              url: https://cdn.example.com/files/placeholder/square.jpg
                              width: 960
                              height: 960
                              size: 0
                          duration: 528
                          hasCustomPreview: false
                          videoSources:
                            "240": https://cdn.example.com/files/placeholder/video_240p.mp4
                            "720": https://cdn.example.com/files/placeholder/video_720p.mp4
                      previews: []
                      isTip: false
                      isReportedByMe: false
                      viewedCount: 9360
                      sentCount: 15802
                      isCanceled: true
                      template: group
                      canUnsend: false
                      unsendSeconds: 0
                      price: "98.00"
                      purchasedCount: 146
                      canSendMessageToBuyers: true
                      totalRevenueGenerated: "14308.00"
                      relationships:
                        buyers:
                          href: https://app.onlyfansapi.com/api/acct_XXXXXXXXXX/engagement/messages/6677889900/buyers?limit=10&offset=0&skip_users_dups=1&marker=0
                          method: GET
                  _meta:
                    _credits:
                      used: 1
                      balance: 11335469
                      note: Always
                    _cache:
                      is_cached: false
                      note: Cache disabled for this endpoint
                    _rate_limits:
                      limit_minute: 5000
                      limit_day: null
                      remaining_minute: 4999
                      remaining_day: null
                      notice: We have decided to remove our daily rate limits. Please remove any
                        references to these in your integrations.
                properties:
                  data:
                    type: object
                    properties:
                      purchases:
                        type: object
                        properties:
                          id:
                            type: integer
                            example: 6677889900
                          date:
                            type: string
                            example: 2024-06-30T12:53:42+00:00
                          responseType:
                            type: string
                            example: message
                          text:
                            type: string
                            example: This is the hardest i've ever been fucked... would you make me cum more
                              than this?? 🥵💦
                          rawText:
                            type: string
                            example: This is the hardest i've ever been fucked... would you make me cum more
                              than this?? 🥵💦
                          giphyId:
                            type: string
                            example: null
                            nullable: true
                          isFree:
                            type: boolean
                            example: false
                          isMediaReady:
                            type: boolean
                            example: true
                          mediaCount:
                            type: integer
                            example: 1
                          media:
                            type: array
                            example:
                              - id: 7788990011
                                type: video
                                convertedToVideo: false
                                canView: true
                                hasError: false
                                createdAt: 2023-01-31T13:14:15+00:00
                                isReady: true
                                files:
                                  full:
                                    url: https://cdn.example.com/files/placeholder/video_source.mp4
                                    width: 1080
                                    height: 1920
                                    size: 0
                                    sources: []
                                  thumb:
                                    url: https://cdn.example.com/files/placeholder/thumb.jpg
                                    width: 300
                                    height: 300
                                    size: 0
                                  preview:
                                    url: https://cdn.example.com/files/placeholder/preview.jpg
                                    width: 960
                                    height: 1707
                                    size: 0
                                  squarePreview:
                                    url: https://cdn.example.com/files/placeholder/square.jpg
                                    width: 960
                                    height: 960
                                    size: 0
                                duration: 528
                                hasCustomPreview: false
                                videoSources:
                                  "240": https://cdn.example.com/files/placeholder/video_240p.mp4
                                  "720": https://cdn.example.com/files/placeholder/video_720p.mp4
                            items:
                              type: object
                              properties:
                                id:
                                  type: integer
                                  example: 7788990011
                                type:
                                  type: string
                                  example: video
                                convertedToVideo:
                                  type: boolean
                                  example: false
                                canView:
                                  type: boolean
                                  example: true
                                hasError:
                                  type: boolean
                                  example: false
                                createdAt:
                                  type: string
                                  example: 2023-01-31T13:14:15+00:00
                                isReady:
                                  type: boolean
                                  example: true
                                files:
                                  type: object
                                  properties:
                                    full:
                                      type: object
                                      properties:
                                        url:
                                          type: string
                                          example: https://cdn.example.com/files/placeholder/video_source.mp4
                                        width:
                                          type: integer
                                          example: 1080
                                        height:
                                          type: integer
                                          example: 1920
                                        size:
                                          type: integer
                                          example: 0
                                        sources:
                                          type: array
                                          example: []
                                    thumb:
                                      type: object
                                      properties:
                                        url:
                                          type: string
                                          example: https://cdn.example.com/files/placeholder/thumb.jpg
                                        width:
                                          type: integer
                                          example: 300
                                        height:
                                          type: integer
                                          example: 300
                                        size:
                                          type: integer
                                          example: 0
                                    preview:
                                      type: object
                                      properties:
                                        url:
                                          type: string
                                          example: https://cdn.example.com/files/placeholder/preview.jpg
                                        width:
                                          type: integer
                                          example: 960
                                        height:
                                          type: integer
                                          example: 1707
                                        size:
                                          type: integer
                                          example: 0
                                    squarePreview:
                                      type: object
                                      properties:
                                        url:
                                          type: string
                                          example: https://cdn.example.com/files/placeholder/square.jpg
                                        width:
                                          type: integer
                                          example: 960
                                        height:
                                          type: integer
                                          example: 960
                                        size:
                                          type: integer
                                          example: 0
                                duration:
                                  type: integer
                                  example: 528
                                hasCustomPreview:
                                  type: boolean
                                  example: false
                                videoSources:
                                  type: object
                                  properties:
                                    "240":
                                      type: string
                                      example: https://cdn.example.com/files/placeholder/video_240p.mp4
                                    "720":
                                      type: string
                                      example: https://cdn.example.com/files/placeholder/video_720p.mp4
                          previews:
                            type: array
                            example: []
                          isTip:
                            type: boolean
                            example: false
                          isReportedByMe:
                            type: boolean
                            example: false
                          viewedCount:
                            type: integer
                            example: 9360
                          sentCount:
                            type: integer
                            example: 15802
                          isCanceled:
                            type: boolean
                            example: true
                          template:
                            type: string
                            example: group
                          canUnsend:
                            type: boolean
                            example: false
                          unsendSeconds:
                            type: integer
                            example: 0
                          price:
                            type: string
                            example: "98.00"
                          purchasedCount:
                            type: integer
                            example: 146
                          canSendMessageToBuyers:
                            type: boolean
                            example: true
                          totalRevenueGenerated:
                            type: string
                            example: "14308.00"
                          relationships:
                            type: object
                            properties:
                              buyers:
                                type: object
                                properties:
                                  href:
                                    type: string
                                    example: https://app.onlyfansapi.com/api/acct_XXXXXXXXXX/engagement/messages/6677889900/buyers?limit=10&offset=0&skip_users_dups=1&marker=0
                                  method:
                                    type: string
                                    example: GET
                  _meta:
                    type: object
                    properties:
                      _credits:
                        type: object
                        properties:
                          used:
                            type: integer
                            example: 1
                          balance:
                            type: integer
                            example: 11335469
                          note:
                            type: string
                            example: Always
                      _cache:
                        type: object
                        properties:
                          is_cached:
                            type: boolean
                            example: false
                          note:
                            type: string
                            example: Cache disabled for this endpoint
                      _rate_limits:
                        type: object
                        properties:
                          limit_minute:
                            type: integer
                            example: 5000
                          limit_day:
                            type: string
                            example: null
                            nullable: true
                          remaining_minute:
                            type: integer
                            example: 4999
                          remaining_day:
                            type: string
                            example: null
                            nullable: true
                          notice:
                            type: string
                            example: We have decided to remove our daily rate limits. Please remove any
                              references to these in your integrations.
      tags:
        - Engagement / Messages
components:
  securitySchemes:
    default:
      type: http
      scheme: bearer
      description: Get your API Key from OnlyFansAPI Console -
        https://app.onlyfansapi.com/api-keys
````