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

# Archive Custom Product

> Archive or unarchive a custom product. Archiving clears its default status.



## OpenAPI

````yaml POST /v1/custom-products/{productKey}/archive
openapi: 3.1.0
info:
  title: PriceOS Public API
  version: 1.0.0
servers: []
security: []
paths:
  /v1/custom-products/{productKey}/archive:
    post:
      summary: Archive Custom Product
      description: >-
        Archive or unarchive a custom product. Archiving clears its default
        status.
      parameters:
        - schema:
            type: string
            description: Product key.
          required: true
          description: Product key.
          name: productKey
          in: path
        - schema:
            type: string
            description: API key from your PriceOS dashboard.
          required: true
          description: API key from your PriceOS dashboard.
          name: x-api-key
          in: header
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                archived:
                  type: boolean
                  default: true
                  description: Whether the product should be archived.
              additionalProperties: false
      responses:
        '200':
          description: Custom product archived
          content:
            application/json:
              schema:
                type: object
                properties:
                  id:
                    type: string
                    description: Product ID.
                  key:
                    type: string
                    description: Product key.
                  name:
                    type: string
                    description: Product name.
                  type:
                    type: string
                    enum:
                      - stripe
                      - custom
                    description: Product type.
                  isDefault:
                    type: boolean
                    description: Whether this is the default custom product.
                  version:
                    type: number
                    description: Product version number.
                  stripeProductId:
                    type:
                      - string
                      - 'null'
                    description: Stripe product ID (Stripe products only).
                  metadata:
                    type: object
                    additionalProperties:
                      type: string
                    description: Custom product metadata (custom products only).
                  prices:
                    type: array
                    items:
                      type: object
                      properties:
                        id:
                          type: string
                          description: Price ID.
                        stripePriceId:
                          type: string
                          description: Stripe price ID.
                        currency:
                          type:
                            - string
                            - 'null'
                          description: ISO currency code.
                        unitAmount:
                          type:
                            - number
                            - 'null'
                          description: Unit amount in the smallest currency unit.
                        recurringInterval:
                          type:
                            - string
                            - 'null'
                          description: Recurring interval, if any.
                        recurringIntervalCount:
                          type:
                            - number
                            - 'null'
                          description: Recurring interval count, if any.
                        isActive:
                          type: boolean
                          description: Whether the price is active.
                        isDefault:
                          type: boolean
                          description: Whether this is the default price.
                      required:
                        - id
                        - stripePriceId
                        - currency
                        - unitAmount
                        - recurringInterval
                        - recurringIntervalCount
                        - isActive
                        - isDefault
                    description: Stripe prices linked to the product.
                  featureAccess:
                    type: array
                    items:
                      type: object
                      properties:
                        featureKey:
                          type: string
                          description: Feature key.
                        name:
                          type: string
                          description: Feature name.
                        type:
                          type: string
                          enum:
                            - boolean
                            - limit
                          description: Feature access type.
                        hasAccess:
                          type: boolean
                          description: Whether the product grants access to the feature.
                        limit:
                          type:
                            - number
                            - 'null'
                          description: Configured limit value for limit features.
                        isUnlimited:
                          type: boolean
                          description: Whether the limit feature is unlimited.
                      required:
                        - featureKey
                        - name
                        - type
                        - hasAccess
                    description: Feature access entries configured for this product.
                required:
                  - id
                  - key
                  - name
                  - type
                  - isDefault
                  - version
                  - stripeProductId
                  - metadata
                  - prices
                  - featureAccess
                description: Product.
        '400':
          description: Bad request
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    description: Error message.
                required:
                  - error
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    description: Error message.
                required:
                  - error
        '404':
          description: Not found
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    description: Error message.
                required:
                  - error
        '500':
          description: Server error
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    description: Error message.
                required:
                  - error

````