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

# Creates a new product

> Create a new product for one-time payments or subscriptions. Configure pricing, billing cycles, and features.



## OpenAPI

````yaml post /v1/products
openapi: 3.0.0
info:
  title: Creem API
  description: >-
    Creem is an all-in-one platform for managing subscriptions and recurring
    revenue, tailored specifically for today's SaaS companies. It enables you to
    boost revenue, enhance customer retention, and scale your operations
    seamlessly.
  version: v1
  contact:
    name: Creem Support
    url: https://creem.io
    email: support@creem.io
  license:
    name: Commercial
    url: https://creem.io/terms
  termsOfService: https://creem.io/terms
servers:
  - url: https://api.creem.io
  - url: https://test-api.creem.io
security: []
tags: []
externalDocs:
  description: Creem Documentation
  url: https://docs.creem.io
paths:
  /v1/products:
    post:
      tags:
        - Products
      summary: Creates a new product.
      description: >-
        Create a new product for one-time payments or subscriptions. Configure
        pricing, billing cycles, and features.
      operationId: createProduct
      parameters: []
      requestBody:
        required: true
        description: Product creation payload
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateProductRequestEntity'
      responses:
        '200':
          description: Successfully created a product
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ProductEntity'
        '400':
          description: Bad Request - Invalid input parameters
        '401':
          description: Unauthorized - Invalid or missing API key
        '404':
          description: Not Found - Resource does not exist
      security:
        - ApiKey: []
components:
  schemas:
    CreateProductRequestEntity:
      type: object
      properties:
        name:
          type: string
          description: Name of the product
        description:
          type: string
          description: Description of the product
        image_url:
          type: string
          description: URL of the product image
          example: https://picsum.photos/200/300
        price:
          type: integer
          description: >-
            The price of the product in cents. Must be 0 (free product) or at
            least 100 (one whole unit of the currency).
          example: 400
        currency:
          $ref: '#/components/schemas/ProductCurrency'
          example: USD
        billing_type:
          $ref: '#/components/schemas/ProductRequestBillingType'
          example: recurring
        billing_period:
          $ref: '#/components/schemas/ProductRequestBillingPeriod'
          example: every-month
        tax_mode:
          $ref: '#/components/schemas/TaxMode'
          example: inclusive
        tax_category:
          $ref: '#/components/schemas/TaxCategory'
          example: saas
        default_success_url:
          type: string
          description: >-
            The URL to which the user will be redirected after successfull
            payment.
          example: https://example.com/?status=successful
        custom_fields:
          description: >-
            Collect additional information from your customer using custom
            fields during checkout. Up to 3 fields are supported.
          type: array
          items:
            $ref: '#/components/schemas/CustomFieldRequestEntity'
        custom_field:
          description: >-
            DEPRECATED: Use `custom_fields` instead. Collect additional
            information from your customer using custom fields during checkout.
            Up to 3 fields are supported.
          deprecated: true
          type: array
          items:
            $ref: '#/components/schemas/CustomFieldRequestEntity'
        abandoned_cart_recovery_enabled:
          type: boolean
          description: Enable abandoned cart recovery for this product
          default: false
      required:
        - name
        - description
        - price
        - currency
        - billing_type
    ProductEntity:
      type: object
      properties:
        id:
          type: string
          description: Unique identifier for the object.
        mode:
          $ref: '#/components/schemas/EnvironmentMode'
        object:
          type: string
          description: >-
            String representing the object's type. Objects of the same type
            share the same value.
        name:
          type: string
          description: The name of the product
        description:
          type: string
          description: A brief description of the product
          example: This is a sample product description.
        image_url:
          type: string
          description: URL of the product image. Only png as jpg are supported
          example: https://example.com/image.jpg
        features:
          description: Features of the product.
          type: array
          items:
            $ref: '#/components/schemas/FeatureEntity'
        price:
          type: number
          description: The price of the product in cents. 1000 = $10.00
          example: 400
        currency:
          type: string
          description: >-
            Three-letter ISO currency code, in uppercase. Must be a supported
            currency.
          example: USD
        billing_type:
          $ref: '#/components/schemas/ProductBillingType'
          example: recurring
        billing_period:
          $ref: '#/components/schemas/ProductBillingPeriod'
          example: every-month
        status:
          $ref: '#/components/schemas/ProductStatus'
        tax_mode:
          $ref: '#/components/schemas/TaxMode'
          example: inclusive
        tax_category:
          $ref: '#/components/schemas/TaxCategory'
          example: saas
        product_url:
          type: string
          description: >-
            The product page you can redirect your customers to for express
            checkout.
          example: https://creem.io/product/prod_123123123123
        default_success_url:
          type: string
          description: >-
            The URL to which the user will be redirected after successfull
            payment.
          example: https://example.com/?status=successful
          nullable: true
        custom_fields:
          description: >-
            Custom fields configured for the product. Collect additional
            information from your customer during checkout.
          nullable: true
          type: array
          items:
            $ref: '#/components/schemas/CustomField'
        created_at:
          format: date-time
          type: string
          description: Creation date of the product
          example: '2023-01-01T00:00:00Z'
        updated_at:
          format: date-time
          type: string
          description: Last updated date of the product
          example: '2023-01-01T00:00:00Z'
      required:
        - id
        - mode
        - object
        - name
        - description
        - price
        - currency
        - billing_type
        - billing_period
        - status
        - tax_mode
        - tax_category
        - created_at
        - updated_at
    ProductCurrency:
      type: string
      description: >-
        Three-letter ISO currency code, in uppercase. Must be a supported
        currency.
      enum:
        - EUR
        - USD
    ProductRequestBillingType:
      type: string
      description: >-
        Indicates the billing method for the customer. It can either be a
        `recurring` billing cycle or a `onetime` payment.
      enum:
        - recurring
        - onetime
    ProductRequestBillingPeriod:
      type: string
      description: Billing period, required if billing_type is recurring
      enum:
        - once
        - every-month
        - every-three-months
        - every-six-months
        - every-year
    TaxMode:
      type: string
      description: >-
        Specifies the tax calculation mode for the transaction. If set to
        "inclusive," the tax is included in the price. If set to "exclusive,"
        the tax is added on top of the price.
      enum:
        - inclusive
        - exclusive
    TaxCategory:
      type: string
      description: >-
        Categorizes the type of product or service for tax purposes. This helps
        determine the applicable tax rules based on the nature of the item or
        service.
      enum:
        - saas
        - digital-goods-service
        - ebooks
    CustomFieldRequestEntity:
      type: object
      properties:
        type:
          $ref: '#/components/schemas/CustomFieldRequestType'
          example: text
        key:
          type: string
          description: >-
            Unique key for custom field. Must be unique to this field,
            alphanumeric, and up to 200 characters.
          example: companyName
          maxLength: 200
        label:
          type: string
          description: >-
            The label for the field, displayed to the customer, up to 50
            characters.
          example: Company Name
          maxLength: 50
        optional:
          type: boolean
          description: >-
            Whether the customer is required to complete the field. Defaults to
            `false`
        text:
          description: Configuration for text field type.
          allOf:
            - $ref: '#/components/schemas/TextFieldConfig'
        checkbox:
          description: Configuration for checkbox field type.
          allOf:
            - $ref: '#/components/schemas/CheckboxFieldConfig'
      required:
        - type
        - key
        - label
    EnvironmentMode:
      type: string
      description: String representing the environment.
      enum:
        - test
        - prod
        - sandbox
    FeatureEntity:
      type: object
      properties:
        id:
          type: string
          description: Unique identifier for the feature.
          example: feat_abc123
        type:
          $ref: '#/components/schemas/ProductFeatureType'
          example: licenseKey
        description:
          type: string
          description: A brief description of the feature.
          example: Access to premium course materials.
      required:
        - id
        - type
        - description
    ProductBillingType:
      type: string
      description: >-
        Indicates the billing method for the customer. It can either be a
        `recurring` billing cycle or a `onetime` payment.
      enum:
        - recurring
        - onetime
    ProductBillingPeriod:
      type: string
      description: Billing period
      enum:
        - every-month
        - every-three-months
        - every-six-months
        - every-year
        - once
    ProductStatus:
      type: string
      description: Status of the product
      enum:
        - active
        - archived
    CustomField:
      type: object
      properties:
        type:
          $ref: '#/components/schemas/CustomFieldType'
        key:
          type: string
          description: >-
            Unique key for custom field. Must be unique to this field,
            alphanumeric, and up to 200 characters.
          maxLength: 200
        label:
          type: string
          description: >-
            The label for the field, displayed to the customer, up to 50
            characters
          maxLength: 200
        optional:
          type: boolean
          description: >-
            Whether the customer is required to complete the field. Defaults to
            `false`.
          nullable: true
        text:
          description: Configuration for text field type.
          nullable: true
          allOf:
            - $ref: '#/components/schemas/Text'
        checkbox:
          description: Configuration for checkbox field type.
          nullable: true
          allOf:
            - $ref: '#/components/schemas/Checkbox'
      required:
        - type
        - key
        - label
    CustomFieldRequestType:
      type: string
      description: The type of the field.
      enum:
        - text
        - checkbox
    TextFieldConfig:
      type: object
      properties:
        max_length:
          type: number
          description: Maximum character length constraint for the input.
          example: 200
        min_length:
          type: number
          description: Minimum character length requirement for the input.
          example: 1
    CheckboxFieldConfig:
      type: object
      properties:
        label:
          type: string
          description: The markdown text to display for the checkbox.
          example: I agree to the [terms and conditions](https://example.com/terms)
    ProductFeatureType:
      type: string
      description: >-
        The type of the feature: privateNote (custom note), file (downloadable
        files), or licenseKey (license key).
      enum:
        - custom
        - file
        - licenseKey
        - customerCredits
    CustomFieldType:
      type: string
      description: The type of the field.
      enum:
        - text
        - checkbox
    Text:
      type: object
      properties:
        max_length:
          type: number
          description: Maximum character length constraint for the input.
          nullable: true
        minimum_length:
          type: number
          description: Minimum character length requirement for the input.
          nullable: true
        value:
          type: string
          description: The value of the input.
          nullable: true
    Checkbox:
      type: object
      properties:
        label:
          type: string
          description: The markdown text to display for the checkbox.
          nullable: true
        value:
          type: boolean
          description: The value of the checkbox (checked or not).
          nullable: true
  securitySchemes:
    ApiKey:
      type: apiKey
      in: header
      name: x-api-key
      description: >-
        API key for authentication. You can find your API key in the Creem
        dashboard under Settings > API Keys.

````