Yroun Guide

Open API

The Yroun Open API gives hub owners full programmatic control over their hub: posts, pages, chat, schedules, series, widgets, webhooks. Everything in the UI is also a REST endpoint under https://oapi.yroun.com/hubs/{hubUid}/.

Admins of someone else's hub can use it too, for content work: pages, posts, series, schedules, media, place curations. Two things to know: the hub must be named explicitly in your key's hub list (an unrestricted key only ever reaches hubs you own), and snapshots, webhooks and chat stay owner-only.

Reading a PUBLIC hub is open to any key: posts, pages and schedules of a public hub can be read with your own key even if the hub is not yours. You receive exactly what a signed-out visitor sees on the web: its public pages. The owner and its admins see the full tree. Writing always needs ownership or admin access.

This page is the quickstart. The four sub-pages below are the deep references. Open whichever fits the work in front of you.

30-second auth

  • Open your hub → Settings → API Keys → Generate key.
  • Copy the key. You can re-view it any time in the same place.
  • Send it as the X-API-Key header on every request.
  • curl https://oapi.yroun.com/hubs/HUBUID \
      -H "X-API-Key: yroun_key_xxxxxxxxxxxx"

    A missing or invalid key returns 401. Sending a session token to /oapi/** returns 400. Don't mix the two.

    Credits at a glance

    API access is credit-based. A call costs by what it does: reading or changing one thing is 1 credit, and creating something new is 2. An upsert counts as a change, so it stays at 1. Credits are drawn from three pools in order:

  • Session credits: small pool, refills 5 hours after first use.
  • Weekly credits: larger pool, resets Monday 11:00 UTC.
  • Purchased balance: voucher-funded, never expires.
  • Every response carries the running totals as headers:

    X-Credits-Session-Remaining: 87
    X-Credits-Weekly-Remaining: 943
    X-Credits-Session-Resets-At: 2026-04-21T19:00:00Z
    X-Credits-Weekly-Resets-At: 2026-04-27T11:00:00Z

    Plan allocations: Pro = 500 session / 10,000 weekly. When all three pools are empty the response is 429 with the reset time.

    Where to next

  • REST Reference: every endpoint, with request and response shapes. Open this when you know which feature you want to call.
  • Content & Widgets: the Tiptap JSON shape that posts and pages carry, plus the apiTableBlock / chartBlock / apiRequestBlock node schemas you embed inside a page's content. Open this when you are building rich content programmatically.
  • Recipes: full copy-paste curl flows for common scenarios (auto-post a daily report, embed a live dashboard, sync external calendar, webhook your server into chat, bulk-import a series, multilingual pages, media upload). Open this when you want a working example to start from.
  • Errors, Limits & Conventions: HTTP codes, pagination envelope, idempotency, retry guidance. Open this when something is failing or you are hardening a client.
  • Top-3 starting points by scenario

  • Building a live dashboard in a hub page that reads from your own API → start at Content & Widgets, then Recipes → Embed a live dashboard.
  • Posting a daily auto-generated report into a hub → start at Recipes → Auto-post a daily report, then REST Reference → Posts.
  • Mirroring your server-side events to a hub chat room → start at Recipes → Webhook your server into chat, then REST Reference → Webhooks.
  • Stuck, or something here is wrong? Send us a message