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

# Get Integration Status

> Connection metadata + cached widget config + best-effort
analytics snapshot (last 7 days). Returns 200 with
`status="not_connected"` for un-connected merchants — never 404 —
so the dashboard doesn't have to special-case the empty state.



## OpenAPI

````yaml /api-reference/openapi.json get /api/dashboard/integrations/zunkiree
openapi: 3.1.0
info:
  title: Agentic Commerce API
  description: |2-

        Agentic Commerce API - E-commerce Backend

        ## APIs

        ### Dashboard API (`/api/dashboard`)
        Authenticated endpoints for merchant management:
        - Products, Variants, Options
        - Inventory management
        - Orders and fulfillment
        - Customers
        - Collections

        ### Storefront API (`/api/storefront`)
        Public endpoints for client websites:
        - Product catalog
        - Collections
        - Cart management
        - Checkout

        ### Sync API (`/api/sync`)
        Integration endpoints for zunkiree-search:
        - Product sync
        - Availability checks
        - Order creation from AI widget
        
  version: 1.0.0
servers: []
security: []
paths:
  /api/dashboard/integrations/zunkiree:
    get:
      tags:
        - Dashboard
        - Integrations
      summary: Get Integration Status
      description: |-
        Connection metadata + cached widget config + best-effort
        analytics snapshot (last 7 days). Returns 200 with
        `status="not_connected"` for un-connected merchants — never 404 —
        so the dashboard doesn't have to special-case the empty state.
      operationId: get_integration_status_api_dashboard_integrations_zunkiree_get
      parameters:
        - name: authorization
          in: header
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Authorization
        - name: X-API-Key
          in: header
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: X-Api-Key
        - name: X-Stella-Merchant-Id
          in: header
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: X-Stella-Merchant-Id
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/IntegrationStatusResponse'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
components:
  schemas:
    IntegrationStatusResponse:
      properties:
        status:
          type: string
          title: Status
          description: Either 'connected' or 'not_connected'.
        site_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Site Id
        customer_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Customer Id
          description: >-
            Locked null in v1 per §1.4 (internal Z-side ID; merchant doesn't
            need it). Reserved for future support_metadata exposure.
        widget_script:
          anyOf:
            - type: string
            - type: 'null'
          title: Widget Script
        widget_config:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Widget Config
        last_synced_widget_config_at:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Last Synced Widget Config At
        connected_at:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Connected At
        admin_token_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Admin Token Id
          description: Public token ID (zka_live_…). Log-safe.
        analytics:
          anyOf:
            - $ref: '#/components/schemas/AnalyticsBlock'
            - type: 'null'
          description: >-
            Best-effort. null if Zunkiree is down or the merchant is not
            connected. UI never breaks on this being null.
      type: object
      required:
        - status
      title: IntegrationStatusResponse
      description: |-
        Response from `GET /api/dashboard/integrations/zunkiree/`.

        On the not-connected branch every field except `status` is null; the
        UI uses that exact shape to decide between "show Connect button" and
        "show Connected panel". Always 200 — never 404 — so the dashboard
        doesn't have to special-case missing-row in the not-connected case.
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    AnalyticsBlock:
      properties:
        queries_total:
          type: integer
          title: Queries Total
          default: 0
        queries_with_answer:
          type: integer
          title: Queries With Answer
          default: 0
        leads_captured:
          type: integer
          title: Leads Captured
          default: 0
        orders_via_widget:
          type: integer
          title: Orders Via Widget
          default: 0
        top_questions:
          items:
            $ref: '#/components/schemas/TopQuestion'
          type: array
          title: Top Questions
        response_time_p95:
          anyOf:
            - type: number
            - type: 'null'
          title: Response Time P95
      additionalProperties: true
      type: object
      title: AnalyticsBlock
      description: |-
        The analytics payload returned by `GET /analytics` and embedded
        (best-effort) in `GET /`. Mirrors SHARED-CONTRACT §12.4.
    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
    TopQuestion:
      properties:
        text:
          type: string
          title: Text
        count:
          type: integer
          title: Count
      additionalProperties: true
      type: object
      required:
        - text
        - count
      title: TopQuestion
      description: |-
        One row of the top_questions list. Z6 may add fields over time;
        we accept whatever it returns and validate only the load-bearing
        ones, so a Z-side enhancement doesn't break the response model.

````