FANVUE API · PYTHON

Use the Fanvue API from Python with plain requests

Fanvue publishes an official API, and CreatorAPI wraps it in one hosted REST layer for every connected platform. Any Python HTTP client can call it: one key, one header, stable JSON back.

Start free with 1,000 credits · no card · Fanvue included in every plan

Set up the client

All you need is the requests library and your CreatorAPI key in the X-API-Key header. Keep the key in an environment variable, never in code, and reuse one session so the header rides along on every call.

# pip install requests
import os, requests

BASE = "https://api.creator-api.com"
session = requests.Session()
session.headers["X-API-Key"] = os.environ["CREATOR_API_KEY"]

account = os.environ["CREATOR_ACCOUNT_ID"]  # the Fanvue creator id you get when you connect an account

Read subscribers

Subscribers come back as structured JSON from one GET request, pulled straight from Fanvue's official API. Every native route follows the same pattern: /v1/{account}/native/{path}, and each read costs 1 credit.

# list subscribers for a connected Fanvue creator
r = session.get(
    f"{BASE}/v1/{account}/native/creators/{{creator_uuid}}/subscribers",
)
r.raise_for_status()
print(r.json())

Read insights and everything else

Earnings, spending, top spenders, chats, posts and vault media are all reads on the same route pattern, so one helper covers the whole surface. The exact paths for all 147 official Fanvue routes are listed in the Fanvue API reference.

def native_get(path, **params):
    # works for any read path from the reference: earnings, insights, chats, posts
    r = session.get(f"{BASE}/v1/{account}/native/{path}", params=params)
    r.raise_for_status()
    return r.json()

Start a data export

A single POST starts a bulk export of subscribers, earnings, chats or posts to CSV or JSONL. One export job costs 10 credits, and you download the file when the job is done.

# export all earnings to CSV, 10 credits per job
job = session.post(
    f"{BASE}/v1/{account}/exports",
    json={"dataset": "earnings", "format": "csv"},
)
job.raise_for_status()
print(job.json())

Webhooks and errors

Fanvue's own native webhook subscriptions push events straight from Fanvue, and CreatorAPI's unified layer, signed with HMAC SHA256 and retried with backoff, normalises events across every platform you connect. The quickstart walks through signature verification. Errors are plain HTTP: 401 for a bad key, 402 when credits run out, 429 on rate limits, always with a JSON body of {"error": "..."}, so raise_for_status() plus one except block covers you.

Or let an AI write the Python for you

The whole API fits in one file made for language models. Paste it into Claude or Codex and describe what you want; the model writes the calls.

One file, full reference

Grab https://api.creator-api.com/llms-full.txt and paste it into your AI chat. Every route, parameter and error is in there.

Describe, then run

Ask for a script that pulls subscribers into a spreadsheet or flags top spenders. The model writes working requests code against real routes.

Grow it into a product

Once the reads work, the same key powers webhooks, tags and exports. See the Fanvue CRM API page for what to build on top.

Python questions

Is there an official Fanvue Python SDK?

Fanvue publishes an official public API, but no first party Python SDK. CreatorAPI is a hosted REST layer over that official API, and you reach it from Python with any HTTP client such as requests.

How do I authenticate from Python?

Send your CreatorAPI key in the X-API-Key header on every request. Store it in an environment variable and load it with os.environ, never hardcode it. The underlying Fanvue OAuth token is handled server side.

What data can I read from Python?

Chats, insights, earnings, subscribers, posts and vault media, all through one route pattern under /v1/{account}/native/. The official Fanvue API covers 147 paths and 187 operations.

How much does each call cost?

A native read costs 1 credit, a write 2 credits, and an export job 10 credits. The free trial includes 1,000 credits with no card required.

How do I verify webhooks in Python?

CreatorAPI's unified webhook deliveries are signed with HMAC SHA256 and retried with backoff. The quickstart shows how to verify the signature before you trust the payload.

Can an AI write the Python code for me?

Yes. CreatorAPI publishes its whole API reference in one text file made for language models. Paste it into Claude or Codex, describe what you want, and the model writes working calls.

Does the same code work for OnlyFans?

Yes. One key covers Fanvue, OnlyFans, Fansly and 4based, and the route pattern is identical, so the same Python client works across platforms.

Ship your first Fanvue integration today

Start free with 1,000 credits, no card required, and make your first call in minutes.

Start free with 1,000 credits · no card