Zinema Auth API

The Auth API from Zinema, for auth.

GitHub OpenAPI
Pull this API's OpenAPI, operations, scores and pricing into your own code or AI agent with a free APIs.io key — sign in with GitHub, Google or LinkedIn. No form to fill in; signing in shares your email address with us (Privacy).

Operations 15

POST /api/auth/complete Auth Complete #
POST /api/auth/google Auth Google #
POST /api/auth/google/device/start Auth Google Device Start #
POST /api/auth/google/device/poll Auth Google Device Poll #
POST /api/auth/apple Auth Apple #
POST /api/auth/plex/link Auth Plex Link #
POST /api/auth/plex/merge Auth Plex Merge #
POST /api/auth/email/request Auth Email Request #
GET /api/auth/email/verify Auth Email Verify #
POST /api/auth/email/device Auth Email Device #
GET /api/auth/email/poll Auth Email Poll #
GET /api/auth/me Auth Me #
HEAD /api/auth/me Auth Me #
POST /api/auth/logout Auth Logout #
POST /api/auth/delete Auth Delete #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • 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.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/zinema-tv:zinema-tv-auth-api"
All apis
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.

Get an API 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 Specification

zinema-tv-auth-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: zinema Auth API
  version: 0.1.0
tags:
- name: Auth
paths:
  /api/auth/complete:
    post:
      summary: Auth Complete
      operationId: auth_complete_api_auth_complete_post
      requestBody:
        content:
          application/json:
            schema:
              additionalProperties: true
              type: object
              title: Body
        required: true
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema: {}
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      tags:
      - Auth
  /api/auth/google:
    post:
      summary: Auth Google
      operationId: auth_google_api_auth_google_post
      requestBody:
        content:
          application/json:
            schema:
              additionalProperties: true
              type: object
              title: Body
        required: true
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema: {}
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      tags:
      - Auth
  /api/auth/google/device/start:
    post:
      summary: Auth Google Device Start
      operationId: auth_google_device_start_api_auth_google_device_start_post
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema: {}
      tags:
      - Auth
  /api/auth/google/device/poll:
    post:
      summary: Auth Google Device Poll
      description: 'Device-flow étape 2 : le device poste son device_code ; le serveur l''échange contre un token Google

        (client_id + SECRET, gardés serveur). `pending` tant que l''user n''a pas autorisé ; à l''autorisation →

        access_token → userinfo → compte Google → SESSION (même contrat que /api/auth/google).'
      operationId: auth_google_device_poll_api_auth_google_device_poll_post
      requestBody:
        content:
          application/json:
            schema:
              additionalProperties: true
              type: object
              title: Body
        required: true
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema: {}
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      tags:
      - Auth
  /api/auth/apple:
    post:
      summary: Auth Apple
      operationId: auth_apple_api_auth_apple_post
      requestBody:
        content:
          application/json:
            schema:
              additionalProperties: true
              type: object
              title: Body
        required: true
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema: {}
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      tags:
      - Auth
  /api/auth/plex/link:
    post:
      summary: Auth Plex Link
      operationId: auth_plex_link_api_auth_plex_link_post
      requestBody:
        content:
          application/json:
            schema:
              additionalProperties: true
              type: object
              title: Body
        required: true
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema: {}
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      tags:
      - Auth
  /api/auth/plex/merge:
    post:
      summary: Auth Plex Merge
      operationId: auth_plex_merge_api_auth_plex_merge_post
      requestBody:
        content:
          application/json:
            schema:
              additionalProperties: true
              type: object
              title: Body
        required: true
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema: {}
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      tags:
      - Auth
  /api/auth/email/request:
    post:
      summary: Auth Email Request
      description: 'Login email : envoie un magic-link (token Fernet TTL 15 min) à l''adresse, via Resend.

        Réponse volontairement neutre (on ne révèle pas si l''email existe déjà).'
      operationId: auth_email_request_api_auth_email_request_post
      requestBody:
        content:
          application/json:
            schema:
              additionalProperties: true
              type: object
              title: Body
        required: true
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema: {}
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      tags:
      - Auth
  /api/auth/email/verify:
    get:
      summary: Auth Email Verify
      description: 'Clic sur le magic-link : valide le token → find-or-create le compte (auth_identity email) →

        pose le cookie de session et redirige vers l''app. Lien expiré/altéré → retour landing.

        dev = nonce d''appairage tvOS (flux device) : le clic — fait sur le TÉLÉPHONE — valide aussi

        la TV qui poll ; le téléphone repart connecté lui aussi (deux sessions pour un clic).'
      operationId: auth_email_verify_api_auth_email_verify_get
      parameters:
      - name: token
        in: query
        required: false
        schema:
          type: string
          default: ''
          title: Token
      - name: dev
        in: query
        required: false
        schema:
          type: string
          default: ''
          title: Dev
      - name: wl
        in: query
        required: false
        schema:
          type: string
          default: ''
          title: Wl
      - name: retour
        in: query
        required: false
        schema:
          type: string
          default: ''
          title: Retour
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema: {}
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      tags:
      - Auth
  /api/auth/email/device:
    post:
      summary: Auth Email Device
      description: 'tvOS/iOS : envoie le magic-link PORTEUR d''un nonce d''appairage. Mêmes rate-limits que le

        web (le coût Resend et la réputation du domaine ne changent pas de plateforme).'
      operationId: auth_email_device_api_auth_email_device_post
      requestBody:
        content:
          application/json:
            schema:
              additionalProperties: true
              type: object
              title: Body
        required: true
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema: {}
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      tags:
      - Auth
  /api/auth/email/poll:
    get:
      summary: Auth Email Poll
      description: 'La TV poll : 202 tant que le lien n''est pas cliqué, 410 si nonce inconnu/expiré,

        200 {token} = session tvOS posée (nonce consommé, one-shot).'
      operationId: auth_email_poll_api_auth_email_poll_get
      parameters:
      - name: nonce
        in: query
        required: false
        schema:
          type: string
          default: ''
          title: Nonce
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema: {}
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      tags:
      - Auth
  /api/auth/me:
    get:
      summary: Auth Me
      operationId: auth_me_api_auth_me_get
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema: {}
      tags:
      - Auth
    head:
      summary: Auth Me
      operationId: headApiAuthMe
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema: {}
      tags:
      - Auth
      x-operation-id-source: normalized
      x-operation-id-original: auth_me_api_auth_me_get
  /api/auth/logout:
    post:
      summary: Auth Logout
      operationId: auth_logout_api_auth_logout_post
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema: {}
      tags:
      - Auth
  /api/auth/delete:
    post:
      summary: Auth Delete
      description: 'Suppression de compte — OBLIGATOIRE App Store (guideline 5.1.1(v)) + propre côté RGPD. IRRÉVERSIBLE :

        purge le user ET toutes ses données. Toutes les tables liées (auth_identities, connections, plex_resources,

        events, watchlist, sessions, reco_cache, account_provenance, match_*) sont en ON DELETE CASCADE depuis

        users → un seul DELETE suffit. On ne touche JAMAIS au compte Plex de l''utilisateur (séparé), ni aux items /

        BA globaux (partagés).

        (11/10, Apple TV 1.14, lot S, D8) D''abord, le jeton Sign in with Apple gardé est révoqué chez Apple

        (_siwa_revoque) : sans cela la suppression n''était pas conforme. Elle n''attend que cette révocation et ne

        dépend jamais de son issue.

        (22/10, profils, PROFILS_spec.md 4.6 et 8.3) Depuis le principal seulement : supprimer le compte efface tout le

        foyer, profils et listes compris (la cascade de users). 403 depuis tout profil ajouté, AVANT la révocation chez

        Apple ; jamais un 401, qui purgerait la session des applis.

        (17/11, go de Thierry : « go pour corriger les recherches YouTube avant la soumission ») yt_recherches n''avait pas

        de clé vers users et restait après la suppression : elle a la sienne, en ON DELETE CASCADE (ops/migrate_youtube.sql),

        et part dans le même DELETE ; yt_demandes l''avait déjà.'
      operationId: auth_delete_api_auth_delete_post
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema: {}
      tags:
      - Auth
components:
  schemas:
    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
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError