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

# Stream realtime events (SSE)

> Server-Sent Events stream of the account's realtime activity — new messages, subscriptions, tips, posts, streams, and more. Each SSE message carries the OnlyFans event name as the `event:` field and `{ data, meta, ts }` as `data:`. Send `Accept: text/event-stream`. Clients that send `Last-Event-ID` (or `?last_event_id=`) resume from the next event after that id; otherwise the stream delivers only events that arrive after connecting. The stream emits `ready` on connect and periodic `heartbeat` events. Requires `accounts:read`.



## OpenAPI

````yaml /api-reference/openapi.json get /v1/accounts/{id}/events
openapi: 3.1.0
info:
  title: onlyfanskit REST API
  description: >-
    Connect OnlyFans accounts and act on them over HTTP. Authenticate with a
    bearer API key, connect a creator account once, then call any method or
    stream realtime events. Not affiliated with OnlyFans or Fenix International
    Limited.
  version: 1.0.0
servers:
  - url: https://api.onlyfanskit.dev
    description: Production
security:
  - bearerAuth: []
tags:
  - name: Account
    description: Identity, keys, and usage for the calling org.
  - name: Connect
    description: Link OnlyFans accounts via cookie, cURL, email/password, or mobile.
  - name: Accounts
    description: Manage connected accounts.
  - name: SDK
    description: Call any SDK method against a connected account.
  - name: Realtime
    description: Server-Sent Events stream of account activity.
  - name: Webhooks
    description: HTTP callbacks for account events.
paths:
  /v1/accounts/{id}/events:
    get:
      tags:
        - Realtime
      summary: Stream realtime events (SSE)
      description: >-
        Server-Sent Events stream of the account's realtime activity — new
        messages, subscriptions, tips, posts, streams, and more. Each SSE
        message carries the OnlyFans event name as the `event:` field and `{
        data, meta, ts }` as `data:`. Send `Accept: text/event-stream`. Clients
        that send `Last-Event-ID` (or `?last_event_id=`) resume from the next
        event after that id; otherwise the stream delivers only events that
        arrive after connecting. The stream emits `ready` on connect and
        periodic `heartbeat` events. Requires `accounts:read`.
      operationId: streamEvents
      parameters:
        - $ref: '#/components/parameters/AccountId'
        - name: last_event_id
          in: query
          required: false
          schema:
            type: string
          description: Resume point. Equivalent to the `Last-Event-ID` header.
      responses:
        '200':
          description: An event stream
          content:
            text/event-stream:
              schema:
                type: string
components:
  parameters:
    AccountId:
      name: id
      in: path
      required: true
      schema:
        type: string
      description: Connected account id.
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: 'Your API key, sent as `Authorization: Bearer <key>`.'

````