> ## Documentation Index
> Fetch the complete documentation index at: https://developers.paperlink.online/llms.txt
> Use this file to discover all available pages before exploring further.

# Subscription screen state + localized plan comparison



## OpenAPI

````yaml https://app.paperlink.online/api/mobile/openapi.json get /api/mobile/billing/state
openapi: 3.1.0
info:
  title: PaperLink Mobile API
  version: 1.0.0
  description: >-
    Device-session API for the PaperLink mobile app. Tokens are per-user (no
    team baked in); the acting team is sent per request via X-Team-Id and the
    role is resolved live.
  contact:
    name: PaperLink Support
    url: https://paperlink.online
servers:
  - url: https://app.paperlink.online
    description: Production
security:
  - BearerAuth: []
tags:
  - name: Auth
    description: >-
      OAuth 2.1 + PKCE device-session flow: obtain, refresh, and revoke mobile
      tokens.
    x-group: Authentication
  - name: Data
    description: >-
      Team-scoped read endpoints (identity, files, folders, links, views). Send
      the active team via X-Team-Id.
    x-group: Data Access
  - name: Mobile Push
    description: >-
      Per-device Expo push token registration and revocation. Token-only auth
      (no team header).
    x-group: Push Notifications
  - name: Mobile Activity
    description: >-
      Team-scoped Activity read-state: mark alerts read and read the unread
      count. Shared with the web in-app bell.
    x-group: Push Notifications
  - name: Mobile Billing
    description: >-
      Apple In-App Purchase: read the Subscription screen state, verify a
      StoreKit transaction, and restore purchases. Team-scoped (X-Team-Id).
    x-group: Billing
paths:
  /api/mobile/billing/state:
    get:
      tags:
        - Mobile Billing
      summary: Subscription screen state + localized plan comparison
      operationId: mobileBillingState
      parameters:
        - $ref: '#/components/parameters/TeamHeader'
      responses:
        '200':
          description: Subscription state
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/MobileSubscriptionState'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          description: Not a member of this team
components:
  parameters:
    TeamHeader:
      name: X-Team-Id
      in: header
      required: true
      schema:
        type: string
        format: uuid
      description: Selected team; the role is resolved live for this team.
  schemas:
    MobileSubscriptionState:
      type: object
      required:
        - currentPlanSlug
        - hasActivePaidPlan
        - status
        - isOwner
        - purchasable
        - inGrace
        - planComparison
      properties:
        currentPlanSlug:
          type: string
        hasActivePaidPlan:
          type: boolean
        status:
          type: string
          enum:
            - active
            - cancelled
            - past_due
            - trialing
        provider:
          type: string
          enum:
            - apple
            - wayforpay
          nullable: true
        isOwner:
          type: boolean
        purchasable:
          type: boolean
        inGrace:
          type: boolean
        planComparison:
          type: array
          items:
            $ref: '#/components/schemas/PlanComparison'
    PlanComparison:
      type: object
      required:
        - planSlug
        - displayName
        - isPaid
        - features
      properties:
        planSlug:
          type: string
        displayName:
          type: string
        isPaid:
          type: boolean
        features:
          type: array
          items:
            type: object
            required:
              - label
              - included
            properties:
              label:
                type: string
              included:
                oneOf:
                  - type: boolean
                  - type: string
  responses:
    Unauthorized:
      description: Missing, expired, or revoked token
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.