Yondry Auth API
The auth API from Yondry, for auth.
The auth API from Yondry, for auth.
Every API here is available over the APIs.io API and to AI agents over MCP.
One button, every client — Claude, Cursor, VS Code and the rest.
https://apis.io/mcp
find_apisBrowse and filter every API in the catalog.get_api_artifactsOne API's artifacts, grouped by type.get_openapiThe primary OpenAPI for this API.find_similar_apisAPIs that look like this one.apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.resolveTurn a domain, URL or GitHub org into the provider it belongs to.find_cohortsEvery scored population of providers in the catalog.curl "https://apis.io/api/v1/apis/yondry-app:yondry-app-auth-api"
curl "https://apis.io/api/v1/apis?limit=25"
Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.
Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. By signing up you are subscribing to the APIs.io and API Evangelist newsletters — you can unsubscribe from any issue. See our Privacy Policy and Terms.
A second provider on the same verified email joins the account you already have.
openapi: 3.2.0
info:
title: Yondry Auth API
version: 0.1.0
tags:
- name: Auth
paths:
/api/v1/auth/register:
post:
tags:
- Auth
summary: Register
operationId: register_api_v1_auth_register_post
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/RegisterRequest'
required: true
responses:
'201':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/TokenResponse'
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
/api/v1/auth/login:
post:
tags:
- Auth
summary: Login
operationId: login_api_v1_auth_login_post
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/LoginRequest'
required: true
responses:
'200':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/TokenResponse'
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
/api/v1/auth/refresh:
post:
tags:
- Auth
summary: Refresh
operationId: refresh_api_v1_auth_refresh_post
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/RefreshRequest'
required: true
responses:
'200':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/TokenResponse'
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
/api/v1/auth/social:
post:
tags:
- Auth
summary: Social Auth
description: 'Sign in with Apple or Google.
The mobile client obtains an id_token from the provider SDK and forwards
it here. The backend verifies the token, finds or creates the user, and
returns a token pair identical to the email/password login response plus
a ``user`` block and ``is_new_user`` flag so the client can route to
onboarding when appropriate.'
operationId: social_auth_api_v1_auth_social_post
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/SocialAuthRequest'
required: true
responses:
'200':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/SocialAuthResponse'
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
/api/v1/auth/upgrade:
post:
tags:
- Auth
summary: Upgrade Guest Account
description: 'Attach a verified Apple or Google identity to the caller''s guest account.
This exists because ``POST /auth/social`` cannot do it. That endpoint takes
no current user: it calls ``find_or_create_user()``, which matches on the
provider id, then on a verified email, and otherwise creates a **new row**.
A guest who signs in there keeps nothing — their saved places and plans stay
on the account they just walked away from, orphaned at the exact moment they
decided to commit.
Here the row is mutated in place, so the id never changes and every place,
plan, collection and visit stays attached. The caller''s existing tokens
remain valid for the same reason.
A provider identity already in use is **refused, never merged**. Merging two
populated accounts means choosing which home location, which collections and
which history survive, and getting that wrong destroys data silently. The
friction of "sign in instead" is recoverable; a bad merge is not.'
operationId: upgrade_guest_account_api_v1_auth_upgrade_post
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/SocialAuthRequest'
required: true
responses:
'200':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/GuestUpgradeResponse'
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
security:
- HTTPBearer: []
/api/v1/auth/guest:
post:
tags:
- Auth
summary: Guest Login
description: 'Create a fresh isolated guest account per call.
Each device session gets its own user row so places, plans, and home
location are never shared between guests.
The stored refresh token means a returning guest re-enters their own
account (not a new one) as long as their token is valid.'
operationId: guest_login_api_v1_auth_guest_post
responses:
'200':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/TokenResponse'
/api/v1/auth/logout:
post:
tags:
- Auth
summary: Logout
operationId: logout_api_v1_auth_logout_post
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/RefreshRequest'
required: true
responses:
'204':
description: Successful Response
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
components:
schemas:
RefreshRequest:
properties:
refresh_token:
type: string
title: Refresh Token
type: object
required:
- refresh_token
title: RefreshRequest
SocialAuthResponse:
properties:
access_token:
type: string
title: Access Token
refresh_token:
type: string
title: Refresh Token
token_type:
type: string
title: Token Type
default: bearer
user:
$ref: '#/components/schemas/UserAuthInfo'
is_new_user:
type: boolean
title: Is New User
type: object
required:
- access_token
- refresh_token
- user
- is_new_user
title: SocialAuthResponse
GuestUpgradeResponse:
properties:
user:
$ref: '#/components/schemas/UserAuthInfo'
type: object
required:
- user
title: GuestUpgradeResponse
description: 'Result of attaching a real identity to the caller''s guest account.
No token pair: the row keeps its id, so the caller''s existing tokens stay
valid and re-issuing would only invalidate a session that is still correct.'
LoginRequest:
properties:
email:
type: string
format: email
title: Email
password:
type: string
title: Password
type: object
required:
- email
- password
title: LoginRequest
ValidationError:
properties:
loc:
items:
anyOf:
- type: string
- type: integer
type: array
title: Location
msg:
type: string
title: Message
type:
type: string
title: Error Type
input:
title: Input
ctx:
type: object
title: Context
type: object
required:
- loc
- msg
- type
title: ValidationError
TokenResponse:
properties:
access_token:
type: string
title: Access Token
refresh_token:
type: string
title: Refresh Token
token_type:
type: string
title: Token Type
default: bearer
type: object
required:
- access_token
- refresh_token
title: TokenResponse
HTTPValidationError:
properties:
detail:
items:
$ref: '#/components/schemas/ValidationError'
type: array
title: Detail
type: object
title: HTTPValidationError
RegisterRequest:
properties:
email:
type: string
format: email
title: Email
password:
type: string
title: Password
type: object
required:
- email
- password
title: RegisterRequest
UserAuthInfo:
properties:
id:
type: string
format: uuid
title: Id
email:
type: string
title: Email
display_name:
anyOf:
- type: string
- type: 'null'
title: Display Name
avatar_url:
anyOf:
- type: string
- type: 'null'
title: Avatar Url
onboarding_completed:
type: boolean
title: Onboarding Completed
auth_provider:
type: string
title: Auth Provider
type: object
required:
- id
- email
- display_name
- avatar_url
- onboarding_completed
- auth_provider
title: UserAuthInfo
description: Minimal user representation returned inside SocialAuthResponse.
SocialAuthRequest:
properties:
provider:
type: string
enum:
- apple
- google
title: Provider
id_token:
type: string
title: Id Token
display_name:
anyOf:
- type: string
maxLength: 255
- type: 'null'
title: Display Name
type: object
required:
- provider
- id_token
title: SocialAuthRequest
securitySchemes:
APIKeyHeader:
type: apiKey
in: header
name: X-API-Key
HTTPBearer:
type: http
scheme: bearer