OnlyFans API
FanslyPosts

Send Post

Compose and publish a new post. Provide text, one or more media references in mediaFiles, or both. Each reference is either a fansly_media_ ID from the Upload Media endpoint, or a Fansly vault media ID — the mediaId of any media already in the account's vault, from the List Vault Media endpoint — so vault content can be posted without re-uploading it. Use wallIds (from the List Walls endpoint) to choose which walls the post is published to.

Attached media can be gated with any combination of the requirePurchase, requireSubscription, and requireFollow options (they stack — e.g. a media can require both a subscription and a purchase). The gating applies to all attached media: a single file, or the whole bundle when several are attached. When none of the gating options are sent, media is posted ungated (visible to anyone who can see the post).

Any attached media can be given a free preview — a separate media shown unlocked while the paid media is locked — via previews, a map of a mediaFiles reference to the preview media.

POST
/api/fansly/{fanslyAccount}/posts
AuthorizationBearer <token>

Get your API Key from OnlyFansAPI Console - https://app.onlyfansapi.com/api-keys

In: header

Path Parameters

fanslyAccount*string

The Fansly Account ID

Request Body

application/json

text?string

The post text content. Required unless mediaFiles is provided.

mediaFiles?array<string>

Media to attach, each either a fansly_media_ upload ID returned by the Upload Media endpoint or a Fansly vault media ID (a mediaId from the List Vault Media endpoint). A single item is attached on its own; multiple are grouped into a bundle, in the given order.

wallIds?array<string>

Wall IDs to publish the post to. Refer to the List Walls endpoint.

pinWallIds?array<string>

Wall IDs (from wallIds) the post should be pinned on.

expiresAt?integer

Unix timestamp in milliseconds when the post should expire. Keep empty for no expiration.

fypFlags?integer

For You Page behavior: 0 = post to the FYP if the post meets the requirements (default), 4 = do not post to the FYP.

Value in0 | 4
requirePurchase?boolean

Require the fan to purchase (unlock) the attached media. Requires price. Combinable with requireSubscription / requireFollow.

price?integer

Unlock price for requirePurchase, in Fansly's smallest unit — 1000 = $1.00 (e.g. 10000 = $10.00). Required when requirePurchase is true.

requireSubscription?boolean

Require the fan to be subscribed to view the attached media. Combinable with requirePurchase / requireFollow.

subscriptionTierId?string

Restrict requireSubscription to a single subscription tier. Tier IDs come from the List Subscription Tiers endpoint. Omit for any tier.

requireFollow?boolean

Require the fan to follow the account to view the attached media. Combinable with requirePurchase / requireSubscription.

previews?object

Free previews for attached media, as a map of a mediaFiles reference to the preview media. Both sides accept a fansly_media_ upload ID or a Fansly vault media ID. Each preview is shown unlocked while its (gated) media is locked. Only include media that should have a preview.

Response Body

application/json

curl -X POST "https://app.onlyfansapi.com/api/fansly/fansly_acct_XXXXXXXXXXXXXXX/posts" \  -H "Content-Type: application/json" \  -d '{}'
{
  "data": {
    "accountId": "800000000000000001",
    "content": "Hello everyone!",
    "fypFlags": 0,
    "inReplyTo": null,
    "quotedPostId": null,
    "replyPermissionFlags": 0,
    "postReplyPermissionFlags": [],
    "expiresAt": 1784301052641,
    "attachments": [
      {
        "contentType": 1,
        "contentId": "500000000000000001",
        "pos": 0,
        "postId": "400000000000000001"
      }
    ],
    "wallIds": [
      "200000000000000010"
    ],
    "pinWallIds": [],
    "pinned": 0,
    "id": "400000000000000001",
    "mediaLikeCount": 0,
    "totalTipAmount": 0,
    "attachmentTipAmount": 0,
    "accountMentions": []
  },
  "_meta": {
    "_credits": {
      "used": 1,
      "balance": 10055789,
      "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."
    }
  }
}