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

# Whether the signed-in person may use the supplier plane, and why not

> Answers 200 for every signed-in person, with `allowed` and a `reasonCode`; it never answers 4xx for a person-level outcome. Call it on sign-in, and use the plane with the returned `supplierId` only when `allowed` is true; otherwise show `message`. `reasonCode` is one of: `SUPPLIER_ACTIVE` (allowed), `SUPPLIER_RECORD_INACTIVE`, `NO_ACCOUNT`, `NOT_A_MEMBER`, `MEMBERSHIP_INACTIVE`, `NO_SUPPLIER_ROLE` and `SUPPLIER_NOT_LINKED`. The other `/suppliers/me` routes refuse with the same codes and messages. It describes the person: `X-MB-Acting-Role` is ignored, and `roles` lists every role they hold here. Only the app’s credentials still fail: a missing or invalid user token (401), a key without standard access (403 `CAPABILITY_NOT_GRANTED`), or a project outside the key’s scope (403). Requires the API key and the person’s user token.



## OpenAPI

````yaml /api-reference/openapi.json get /v1/projects/{projectId}/suppliers/me/access
openapi: 3.0.0
info:
  title: MarketBox 2.0 Open API
  version: 1.0.0
  description: >-
    The MarketBox public API for building booking experiences. Core model:
    create an order, then draw its order items down into bookings. Single
    bookings reference an order item per service line; package bookings draw one
    PACKAGE item down across N sessions. To schedule a package, build a slate
    (POST /availability/package-slate) and book it by slateId (POST
    /orders/{orderId}/package-bookings). See the guides for end-to-end
    walkthroughs.
  contact:
    name: MarketBox support
servers:
  - url: https://apiv2.gomarketbox.com
    description: MarketBox Open API
security:
  - ApiKeyAuth: []
paths:
  /v1/projects/{projectId}/suppliers/me/access:
    get:
      tags:
        - Supplier plane
      summary: Whether the signed-in person may use the supplier plane, and why not
      description: >-
        Answers 200 for every signed-in person, with `allowed` and a
        `reasonCode`; it never answers 4xx for a person-level outcome. Call it
        on sign-in, and use the plane with the returned `supplierId` only when
        `allowed` is true; otherwise show `message`. `reasonCode` is one of:
        `SUPPLIER_ACTIVE` (allowed), `SUPPLIER_RECORD_INACTIVE`, `NO_ACCOUNT`,
        `NOT_A_MEMBER`, `MEMBERSHIP_INACTIVE`, `NO_SUPPLIER_ROLE` and
        `SUPPLIER_NOT_LINKED`. The other `/suppliers/me` routes refuse with the
        same codes and messages. It describes the person: `X-MB-Acting-Role` is
        ignored, and `roles` lists every role they hold here. Only the app’s
        credentials still fail: a missing or invalid user token (401), a key
        without standard access (403 `CAPABILITY_NOT_GRANTED`), or a project
        outside the key’s scope (403). Requires the API key and the person’s
        user token.
      parameters:
        - schema:
            type: string
            minLength: 1
            description: >-
              The project (tenant) that owns the resource. Every resource in
              this API is scoped to a project, and your API key is restricted to
              the projects it was issued for — a project outside that scope
              returns 403.
            example: prj_01kv60qgnef2kt3pvqgwmkbzfr
          required: true
          description: >-
            The project (tenant) that owns the resource. Every resource in this
            API is scoped to a project, and your API key is restricted to the
            projects it was issued for — a project outside that scope returns
            403.
          name: projectId
          in: path
      responses:
        '200':
          description: The person’s access
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    $ref: '#/components/schemas/SupplierPlaneAccess'
                required:
                  - data
        '401':
          description: Missing or invalid API key or user token
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorMessage'
        '403':
          description: >-
            The API key lacks standard access (CAPABILITY_NOT_GRANTED), or
            cannot access this project (FORBIDDEN)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorMessage'
        '404':
          description: Project not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorMessage'
      security:
        - ApiKeyAuth: []
          EndUserBearer: []
components:
  schemas:
    SupplierPlaneAccess:
      type: object
      properties:
        allowed:
          type: boolean
          description: >-
            True only for `SUPPLIER_ACTIVE`: use the supplier plane with
            `supplierId`. Otherwise show `message`.
          example: false
        reasonCode:
          type: string
          enum:
            - SUPPLIER_ACTIVE
            - SUPPLIER_RECORD_INACTIVE
            - NO_ACCOUNT
            - NOT_A_MEMBER
            - MEMBERSHIP_INACTIVE
            - NO_SUPPLIER_ROLE
            - SUPPLIER_NOT_LINKED
          description: >-
            Why. `SUPPLIER_ACTIVE`: an ACTIVE membership holding SUPPLIER and a
            linked, active supplier record. `SUPPLIER_RECORD_INACTIVE`: the
            same, but the record is `active: false`. `NO_ACCOUNT`: the token is
            valid but names no MarketBox account. `NOT_A_MEMBER`: no membership
            in this project. `MEMBERSHIP_INACTIVE`: the membership has ended
            (every role removed). `NO_SUPPLIER_ROLE`: an ACTIVE membership
            without SUPPLIER. `SUPPLIER_NOT_LINKED`: holds SUPPLIER, but no
            single supplier record is linked to the person.
          example: NO_SUPPLIER_ROLE
        message:
          type: string
          description: The reason, for a person. The data routes refuse with the same text.
          example: You don't have supplier access on this project.
        supplierId:
          type: string
          nullable: true
          description: >-
            The supplier record linked to the person here, for `SUPPLIER_ACTIVE`
            and `SUPPLIER_RECORD_INACTIVE`; otherwise null.
          example: null
        roles:
          type: array
          items:
            type: string
            enum:
              - CLIENT
              - ADMIN
              - MANAGER
              - DEVELOPER
              - SUPPLIER
          description: >-
            Every role the person holds on the project, in the order CLIENT,
            ADMIN, MANAGER, DEVELOPER, SUPPLIER. `[]` unless the membership is
            ACTIVE. `X-MB-Acting-Role` is ignored.
          example:
            - CLIENT
        membershipStatus:
          type: string
          nullable: true
          enum:
            - ACTIVE
            - INACTIVE
            - null
          description: >-
            The membership: `ACTIVE`, or `INACTIVE` for every other status. Null
            when the person has no account or no membership here.
          example: ACTIVE
      required:
        - allowed
        - reasonCode
        - message
        - supplierId
        - roles
        - membershipStatus
    ErrorMessage:
      type: object
      properties:
        code:
          type: string
          description: Stable machine-readable error code, e.g. NOT_FOUND.
        message:
          type: string
          description: Human-readable description of what went wrong.
        statusCode:
          type: integer
          description: The HTTP status code of this response.
        requestId:
          type: string
          description: >-
            The id of this request, also returned as the X-Request-Id header.
            Quote it in a support ticket.
      required:
        - code
        - message
        - statusCode
        - requestId
      example:
        code: NOT_FOUND
        message: Booking not found
        statusCode: 404
        requestId: a3f1c2de-9b64-4a2f-8f0e-5c9d1b7a2e10
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: x-api-key
      description: >-
        API key minted in the MarketBox dashboard. Scope is restricted to the
        projects you select at creation time. Every route needs the key's
        standard API access (`*`) except `POST /v1/projects/{projectId}/events`,
        which needs `events:write`; a key without `*` is refused with 403
        `CAPABILITY_NOT_GRANTED`.
    EndUserBearer:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: >-
        The signed-in person's Cognito access token, issued to this
        application's app client. Sent with the API key on the /clients/me and
        /suppliers/me routes.

````

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