Skip to main content
HydroGo
REST APIMember API

Member API

Sign-up, sign-in and profile endpoints for the visitors of your site, designed for mobile apps and token-based clients.

Members are visitor accounts, separate from admin users. The token API lives under /api/v1/mobile/member and never uses browser cookies (the client sends credentials: omit). It needs the members module.

Method and pathDescription
POST /api/v1/mobile/member/auth/registerCreate an account; returns a token pair.
POST /api/v1/mobile/member/auth/loginSign in; returns a token pair.
POST /api/v1/mobile/member/auth/refreshExchange a refresh token for a new pair.
POST /api/v1/mobile/member/auth/revokeSign out this device.
POST /api/v1/mobile/member/auth/revoke-allSign out every device.
GET /api/v1/mobile/member/auth/devicesList signed-in devices.
GET /api/v1/mobile/member/meThe member profile.
POST / DELETE /api/v1/mobile/member/push/subscriptionRegister or remove a push subscription.

Sign in

curl -X POST https://cms.example.com/api/v1/mobile/member/auth/login \
  -H 'Content-Type: application/json' \
  -d '{"email":"[email protected]","password":"…","device_id":"phone-1","device_name":"Pixel","platform":"android"}'
JSON
{
  "access_token": "…",
  "refresh_token": "…",
  "token_type": "Bearer",
  "expires_in": 900,
  "expires_at": "2026-04-01T12:15:00Z"
}
Unlike { data, metadata } content endpoints, member endpoints return top-level JSON fields (access_token, refresh_token, or the profile object directly). @hydrohq/client already handles each shape for you.

Authenticated calls

BASH
curl https://cms.example.com/api/v1/mobile/member/me -H 'Authorization: Bearer <access_token>'

Browser-based member sign-in (cookie sessions) and OAuth routes exist at /member/login, /member/register and /member/oauth/{provider}/start; they are meant for same-origin apps. The mobile OpenAPI contracts are stored in the repository under docs/api/.