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

# Update onboarding state

> **Auth:** signed-in organization admin only. Organization API keys are rejected with `403`.

Body: `{"onboarding_action": "start" | "skip"}`.



## OpenAPI

````yaml https://cp.xenovia.io/openapi.json patch /api/v1/orgs/{org_id}
openapi: 3.1.0
info:
  title: Xenovia Control Plane API
  version: 1.0.0
  description: >-
    Management API for proxies, providers, policies, telemetry, alerts and
    organization settings.
servers:
  - url: https://cp.xenovia.io
    description: Production
security:
  - BearerAuth: []
paths:
  /api/v1/orgs/{org_id}:
    patch:
      tags:
        - organizations
      summary: Update onboarding state
      description: >-
        **Auth:** signed-in organization admin only. Organization API keys are
        rejected with `403`.


        Body: `{"onboarding_action": "start" | "skip"}`.
      operationId: patch_org_api_v1_orgs__org_id__patch
      parameters:
        - name: org_id
          in: path
          required: true
          schema:
            type: string
            title: Org Id
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/OrganizationUpdate'
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/OrganizationRead'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
components:
  schemas:
    OrganizationUpdate:
      properties:
        onboarding_action:
          $ref: '#/components/schemas/OrganizationOnboardingAction'
      additionalProperties: false
      type: object
      required:
        - onboarding_action
      title: OrganizationUpdate
    OrganizationRead:
      properties:
        id:
          type: string
          format: uuid
          title: Id
        created_at:
          type: string
          format: date-time
          title: Created At
        updated_at:
          type: string
          format: date-time
          title: Updated At
        name:
          type: string
          title: Name
        slug:
          type: string
          title: Slug
        clerk_org_id:
          type: string
          title: Clerk Org Id
        plan:
          $ref: '#/components/schemas/OrgPlan'
        status:
          $ref: '#/components/schemas/OrgStatus'
        metronome_customer_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Metronome Customer Id
        entitlements:
          additionalProperties: true
          type: object
          title: Entitlements
        onboarding_state:
          $ref: '#/components/schemas/OrganizationOnboardingState'
        viewer_product_tour_eligible:
          type: boolean
          title: Viewer Product Tour Eligible
        viewer_product_tour_state:
          $ref: '#/components/schemas/UserProductTourState'
      type: object
      required:
        - id
        - created_at
        - updated_at
        - name
        - slug
        - clerk_org_id
        - plan
        - status
        - onboarding_state
        - viewer_product_tour_eligible
        - viewer_product_tour_state
      title: OrganizationRead
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    OrganizationOnboardingAction:
      type: string
      enum:
        - start
        - skip
      title: OrganizationOnboardingAction
    OrgPlan:
      type: string
      enum:
        - free
        - pro
        - enterprise
      title: OrgPlan
    OrgStatus:
      type: string
      enum:
        - pending
        - active
        - suspended
        - deleted
      title: OrgStatus
    OrganizationOnboardingState:
      properties:
        status:
          $ref: '#/components/schemas/OnboardingStatus'
          default: not_started
        completed_steps:
          items:
            $ref: '#/components/schemas/OnboardingStep'
          type: array
          title: Completed Steps
        proxy_id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
          title: Proxy Id
        started_at:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Started At
        started_by:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
          title: Started By
        skipped_at:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Skipped At
        skipped_by:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
          title: Skipped By
        completed_at:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Completed At
        completed_by:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
          title: Completed By
      type: object
      title: OrganizationOnboardingState
    UserProductTourState:
      properties:
        version:
          type: integer
          title: Version
          default: 1
        status:
          $ref: '#/components/schemas/ProductTourStatus'
          default: not_started
        current_step:
          $ref: '#/components/schemas/ProductTourStep'
          default: dashboard
        visited_steps:
          items:
            $ref: '#/components/schemas/ProductTourStep'
          type: array
          title: Visited Steps
        started_at:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Started At
        completed_at:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Completed At
        dismissed_at:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Dismissed At
      type: object
      title: UserProductTourState
    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
    OnboardingStatus:
      type: string
      enum:
        - not_started
        - existing
        - in_progress
        - skipped
        - completed
      title: OnboardingStatus
    OnboardingStep:
      type: string
      enum:
        - provider
        - proxy
        - policy
        - request
        - trace
      title: OnboardingStep
    ProductTourStatus:
      type: string
      enum:
        - not_started
        - in_progress
        - completed
        - dismissed
      title: ProductTourStatus
    ProductTourStep:
      type: string
      enum:
        - dashboard
        - proxies
        - policies
        - providers
        - traces
        - alerts
      title: ProductTourStep
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer
      description: >-
        Bearer token: an organization API key (`ak_…`) created under Settings →
        API Keys, or a dashboard user session token. Proxy keys (`xe_…`) are not
        accepted here. Endpoints marked as user-only in their description reject
        organization keys with `403`.

````