Authentication
How calls to the REM Vibe Coder API are authenticated - the REM Auth session, CSRF, stream tickets, signed artifact links - plus roles and error codes.
REM Vibe Coder has no passwords and no API keys of its own. A person signs in with REM Auth (OpenID Connect, authorization code with PKCE S256, scopes openid email profile groups offline_access), and Vibe Coder keeps a server-side session for them.
The session
After sign-in the browser holds two cookies for remvibecoder.com:
Cookie | Use |
|---|---|
| The session (HttpOnly, Secure) |
| The CSRF token; send its value in the |
A script running as you can use the same two values (copy them from your browser's developer tools; treat them like a password, they are valid until you sign out):
VC=https://remvibecoder.com/api/v1
curl -s "$VC/me" -H "Cookie: vcn_sessionid=$SID; vcn_csrftoken=$CSRF"{"id": 3, "username": "you@example.com", "email": "you@example.com", "display_name": "Your Name", "role": "member", "is_active": true}A write also needs the CSRF header and a same-site Referer:
curl -s -X POST "$VC/chats" \
-H "Cookie: vcn_sessionid=$SID; vcn_csrftoken=$CSRF" \
-H "X-CSRFToken: $CSRF" -H "Referer: https://remvibecoder.com/" \
-H "Content-Type: application/json" \
-d '{"prompt": "Build a habit tracker with streaks", "mode": "auto"}'The session is re-checked against REM Auth every five minutes. If your REM account is switched off, signed out or loses access, the next call answers 401 and the session ends.
Credentials that may go in a URL
Your session never goes in a URL. Two short-lived, signed credentials exist for the places where a header cannot be sent:
What | Get it with | Valid | Bound to |
|---|---|---|---|
Stream ticket for SSE |
| 60 s to open | that run and you |
Signed image link (test screenshots) |
| 300 s | that artifact and you |
Both are HMAC-signed and carry no secret of their own.
Roles
Role | From REM Auth | May |
|---|---|---|
| everyone allowed into Vibe Coder | own chats, projects, runs, memory, billing view |
| group | also |
| groups | also settings, AI providers, lessons |
An identity whose e-mail REM Auth has not verified is never more than a member.
Errors
Every error is JSON: {"code": "...", "detail": "..."}.
HTTP |
| When |
|---|---|---|
400 |
| Malformed request (for example |
401 | — | No or ended session |
402 |
| No Vibe Coder credits left |
403 |
| Your role may not; only organisation admins buy |
404 |
| Missing, or not yours |
409 |
| For example answering a question that is no longer open |
422 |
| A field fails validation ( |
429 |
| Slow down; too many live streams open |
502 |
| REM CloudHub did not answer |