# OpenProcessing Creative Coding API
> Live creator and sketch data from OpenProcessing, the community for Processing and p5.js creative-coding sketches, served from its public API. The user endpoint returns a creator's profile — username, name, bio, location, website, join date and total sketch count. The sketches endpoint lists a creator's published sketches with title, license, engine mode and dates. The sketch endpoint returns a single sketch's detail — title, description, tags, license, libraries used, the fork parent it was remixed from, and the author. The social endpoint returns a creator's followers or the accounts they follow. This is a creative-coding community stats API — creator profiles, sketch catalogues and the follow graph — distinct from the code-hosting, package-registry and other social-platform APIs in the catalogue. A user is a numeric OpenProcessing userID and a sketch is a numeric visualID, both visible in OpenProcessing URLs. Live, no key on the upstream, nothing stored.

## Authentication
All requests require your oanor API key in the `x-oanor-key` header. Get one at https://www.oanor.com/developer/keys.

```bash
curl -H "x-oanor-key: oanor_live_…" "https://api.oanor.com/openprocessing-api/..."
```

## Pricing
- **Free** (Free) — 26,000 calls/Mo, 4 req/s
- **Starter** ($4/Mo) — 310,000 calls/Mo, 12 req/s
- **Pro** ($14/Mo) — 1,340,000 calls/Mo, 30 req/s
- **Scale** ($33/Mo) — 4,750,000 calls/Mo, 80 req/s

## Endpoints

### Creators

#### `GET /v1/social` — A creator's followers or following

**Parameters:**
- `user` (query, required, string) — Numeric userID Example: `1`
- `type` (query, optional, string) — followers or following Example: `followers`
- `limit` (query, optional, string) — Max users (max 100) Example: `50`

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/openprocessing-api/v1/social?user=1&type=followers&limit=50"
```

**Response:**
```json
{
    "data": {
        "type": "followers",
        "count": 50,
        "limit": 50,
        "users": [
            {
                "since": "2020-04-19 11:54:26",
                "user_id": 134,
                "fullname": "ahmet kizilay",
                "username": "ahmetkizilay",
                "membership_type": 0
            },
            {
                "since": "2026-03-19 23:45:01",
                "user_id": 990,
                "fullname": "Owaun Scantlebury",
                "username": "owaun",
                "membership_type": 1
            },
            {
                "since": "2024-07-18 01:51:55",
                "user_id": 1273,
                "fullname": "Marius Watz",
                "username": "watz",
                "membership_type": 0
            },
            {
                "since": "2012-03-23 04:38:39",
                "user_id": 1277,
                "fullname": "R.A. Robertson",
                "username": "Phospheros",
                "membership_type": 0
            },
            {
                "since": "2013-02-21 07:08:34",
                "user_id": 1707,
                "fullname": "haoyun",
                "username": "misterioso",
                "membership_type": 0
            },
            {
                "since": "2012-04-24 19:02:52",
                "user_id": 1720,
                "fullname": "bitcraft",
                "username": "bitcraft_1720",
                "membership_type": 0
            },
       
…(truncated, see openapi.json for full schema)
```

#### `GET /v1/user` — Creator profile + total sketch count

**Parameters:**
- `user` (query, required, string) — Numeric OpenProcessing userID Example: `1`

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/openprocessing-api/v1/user?user=1"
```

**Response:**
```json
{
    "data": {
        "bio": "OpenProcessing master magician.Trying to stop obsessing with icon alignment.",
        "joined": "2008-02-06 22:58:37",
        "source": "OpenProcessing",
        "user_id": 1,
        "website": "https://wiredpieces.com",
        "fullname": "Sinan Ascioglu",
        "location": "Amsterdam",
        "username": "msawired",
        "total_sketches": 263,
        "membership_type": 2
    },
    "meta": {
        "timestamp": "2026-06-12T01:41:37.859Z",
        "request_id": "ac0423a1-e9e3-47e3-aba0-e03b8dbe070e"
    },
    "status": "ok",
    "message": "User retrieved successfully",
    "success": true
}
```

### Sketches

#### `GET /v1/sketch` — A single sketch's detail (incl. fork parent)

**Parameters:**
- `sketch` (query, required, string) — Numeric visualID Example: `13481`

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/openprocessing-api/v1/sketch?sketch=13481"
```

**Response:**
```json
{
    "data": {
        "mode": "pjs",
        "tags": [],
        "title": "Sugar buildings in HTML5",
        "source": "OpenProcessing",
        "created": "2012-03-03 23:35:46",
        "fork_of": 2921,
        "license": "by-nc-sa",
        "updated": "2025-12-30 08:03:21",
        "user_id": 1,
        "username": "msawired",
        "libraries": [],
        "visual_id": 13481,
        "mode_label": "Processing (Java)",
        "description": "To see if it is going to work in HTML5, I just copy pasted the code of Sugar Buildings by Jean-no:\nhttp://www.openprocessing.org/visuals/?visualID=2921\nPerformance is not too bad unless there are more than 100 blocks, but probably depends on the computer",
        "is_template": false,
        "instructions": null
    },
    "meta": {
        "timestamp": "2026-06-12T01:41:38.146Z",
        "request_id": "374657be-275a-4459-8415-02b86b3f8032"
    },
    "status": "ok",
    "message": "Sketch retrieved successfully",
    "success": true
}
```

#### `GET /v1/sketches` — A creator's published sketches

**Parameters:**
- `user` (query, required, string) — Numeric userID Example: `1`
- `limit` (query, optional, string) — Max sketches (max 100) Example: `25`
- `offset` (query, optional, string) — Pagination offset Example: `0`

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/openprocessing-api/v1/sketches?user=1&limit=25&offset=0"
```

**Response:**
```json
{
    "data": {
        "count": 25,
        "limit": 25,
        "offset": 0,
        "source": "OpenProcessing",
        "user_id": 1,
        "sketches": [
            {
                "mode": "pjs",
                "title": "Sugar buildings in HTML5",
                "created": "2012-03-03 23:35:46",
                "license": null,
                "updated": "2025-12-30 08:03:21",
                "is_draft": false,
                "visual_id": 13481,
                "mode_label": "Processing (Java)",
                "description": "To see if it is going to work in HTML5, I just copy pasted the code of Sugar Buildings by Jean-no:\nhttp://www.openprocessing.org/visuals/?visualID=2921\nPerformance is not too bad unless there are more than 100 blocks, but probably depends on the computer"
            },
            {
                "mode": "pjs",
                "title": "Swirlies in HTML5",
                "created": "2012-04-24 21:47:59",
                "license": null,
                "updated": "2025-12-30 08:03:21",
                "is_draft": true,
                "visual_id": 19142,
                "mode_label": "Processing (Java)",
                "description": "Html5 version of Swirlies by Tymm.\n\nPerformance drops a lot if you increase the SIZEW, SIZEH"
            },
            {
                "mode": "pjs",
                "title": "Leaf Experience",
                "created": "2011-01-31 00:06:19",
                "license": null,
                "update
…(truncated, see openapi.json for full schema)
```

### Meta

#### `GET /v1/meta` — Spec

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/openprocessing-api/v1/meta"
```

**Response:**
```json
{
    "data": {
        "note": "user is a numeric OpenProcessing userID; sketch is a numeric visualID (both visible in OpenProcessing URLs). Username lookup is not offered by the upstream, so ids are used. mode is the sketch engine (p5js, pjs, html).",
        "source": "OpenProcessing public API (openprocessing.org/api, live)",
        "service": "openprocessing-api",
        "endpoints": {
            "GET /v1/meta": "This document.",
            "GET /v1/user": "Creator profile + total sketch count (user=1).",
            "GET /v1/sketch": "A single sketch's detail incl. fork parent (sketch=13481).",
            "GET /v1/social": "A creator's followers or following (user=1, type=followers).",
            "GET /v1/sketches": "A creator's published sketches (user=1, limit=25, offset=0)."
        },
        "description": "Live creator and sketch data from OpenProcessing, the community for Processing / p5.js creative-coding sketches. user returns a creator's profile (username, name, bio, location, website, join date, total sketches); sketches lists a creator's published sketches; sketch returns a single sketch's detail (title, description, tags, license, libraries, fork parent, author); social returns a creator's followers or the accounts they follow. Live, no key, nothing stored. A creative-coding community stats API distinct from the code-hosting, package-registry and other social-platform APIs.",
        "upstream_status": "ok",
        "sample_user_total_sketches": 263
 
…(truncated, see openapi.json for full schema)
```


---
Marketplace page: https://www.oanor.com/api/openprocessing-api
OpenAPI spec: https://www.oanor.com/api/openprocessing-api/openapi.json
