auth
billing

Auth Me

Return current authenticated user info, tier, and CSRF token.

Mirrors the existing _handle_auth_me logic exactly:

  • Checks trial status via billing module
  • Returns tier (free / plus_trial / plus / pro / etc.)
  • Extracts CSRF token from cookie for JS to use in X-CSRF-Token header

Also issues an anon CSRF token to unauthenticated callers — SSR pages (e.g. /learn/<course>/<module>/) need this so the quiz-submit flow can satisfy validate_csrf before sign-in. Symmetric to /api/auth/challenge.

get/api/auth/me

Request

  • Base URL: https://www.oxfordledge.com (the document declares no server; this is the origin it was published from)
  • URL: https://www.oxfordledge.com/api/auth/me
  • Auth: none declared

Response

Successful Response

authenticatedboolean required

True iff the request carried a valid session.

csrf_tokenstring required

CSRF token for the X-CSRF-Token header. Set on both anonymous and authenticated branches; anonymous callers also receive a fresh ol_csrf cookie scoped 1h.

tierstring nullable
effective_tierstring nullable
consumer_tierstring nullable
agent_planstring nullable
trial_activeboolean nullable
trial_days_remaininginteger nullable
terms_reacceptance_requiredboolean nullable
terms_version_userstring nullable
terms_version_currentstring nullable
consent_statusstring nullable

Parental consent for a 13-17 account: null when none is needed, else 'confirmed', 'pending' (a live approval link is with the parent) or 'needed' (no approval and no live link; the client offers to send the request again).

Changes

No recorded changes to this operation across all 1 revision of this API.