Live Events
Event reference
Every live event a creator's OnlyFans account sends over the WebSocket, with its payload type: messages, typing, subscribers, online fans, tips, posts and streams.
These are the events a creator's connection can receive. Listen with .on(event, handler) (see live events for setup). Payload types are exported by the SDK, so your editor shows every field.
The event names come from OnlyFans itself, which is why their styles vary. An event only arrives when it applies to the creator you're connected to.
Chats and messages
| Event | When it fires | Payload |
|---|---|---|
api2_chat_message | A chat message arrives. A tip sent in chat arrives here too, with isTip and tipAmount. | WsChatMessage |
new_message | A new message notification. | WsNewMessage |
typing | Someone in a chat is typing. | { id: number } |
chat_message_delete | A message is deleted. | string |
chat_message_like | A message is liked. | string |
chat_message_unlike | A like is removed. | string |
chat_messages | The unread chat count changes. | number |
count_priority_chat | The unread priority chat count changes. | number |
messages | The unread message count changes. | number |
chat_queue_update | A mass message is still sending. | WsChatQueueUpdate |
chat_queue_finish | A mass message finished sending. | WsChatQueueFinish |
Fans
| Event | When it fires | Payload |
|---|---|---|
subscribed | Someone subscribes. | WsSubscribed (user, timestamp) |
online | Users come online. | WsOnline[] |
block_user | A user is blocked. | WsBlockUser |
unblock_user | A user is unblocked. | WsUnblockUser |
Money
| Event | When it fires | Payload |
|---|---|---|
unread_tips | The unread tips count changes. | number |
post_tips_updated | Tips on a post change. | WsPostTipsUpdated |
post_fundraising_updated | A post's fundraising total changes. | WsPostFundraisingUpdated |
price_changed | A price changes. | WsPriceChanged |
Posts and stories
| Event | When it fires | Payload |
|---|---|---|
post_published | A post goes live. | WsPostPublished |
post_updated | A post is edited. | string |
post_expire | A post expires. | string |
stories | Stories change. | WsStories[] |
Streams
| Event | When it fires | Payload |
|---|---|---|
stream_start | A live stream starts. | WsStreamStart |
stream_stop | A live stream stops. | WsStreamStop |
stream | Live stream details. | WsStream |
stream_update | A live stream changes. | WsStreamUpdate |
Account
| Event | When it fires | Payload |
|---|---|---|
connected | The connection is ready. | boolean |
toasts | OnlyFans shows the creator in-app notifications. | WsToasts[] |
faceId | OnlyFans asks for face verification. | WsFaceId |
logout | The creator's OnlyFans session logged out. | 1 |
Other events
OnlyFans also sends these for its own app. They're typed like the rest, but most integrations ignore them: hasSystemNotifications, has_new_alerts, has_new_hints, newTagsCount, need_a_tag_count, display_ticket, hasNewTicketReplies, ticketReply, faceIdRegular, sync_duplicated_release_forms, syncInProcess, account_switch, user_id, v and bc.
Log everything
To see exactly what arrives for a creator while you build:
ws.onAny((event, payload) => {
console.log(event, payload)
})