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

# Submit a product review

> Leave a star rating and optional written review on a product. Reviews are final and cannot be edited.



## OpenAPI

````yaml post /v1/products/{product_id}/reviews
openapi: 3.1.0
info:
  title: Channel3 API
  version: 0.1.0
servers:
  - url: https://api.trychannel3.com
    description: Production
security: []
paths:
  /v1/products/{product_id}/reviews:
    post:
      tags:
        - product-reviews
      summary: Submit a product review
      description: >-
        Leave a star rating and optional written review on a product. Reviews
        are final and cannot be edited.
      operationId: submit_product_review_v1_products__product_id__reviews_post
      parameters:
        - name: product_id
          in: path
          required: true
          schema:
            type: string
            title: Product Id
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateProductReviewRequest'
      responses:
        '201':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ProductReviewResponse'
        '401':
          description: Unauthorized - Invalid or missing authentication
          content:
            application/json:
              examples:
                missing_key:
                  summary: Missing API Key
                  value:
                    detail: >-
                      Unauthorized. Missing authentication key. Make sure to
                      attach an x-api-key with your request. Need help? Reach
                      out to support@trychannel3.com.
                invalid_key:
                  summary: Invalid API Key
                  value:
                    detail: >-
                      API key was provided but is invalid. Need help? Reach out
                      to support@trychannel3.com.
              schema:
                $ref: '#/components/schemas/app__routers__utils__ErrorResponse'
        '402':
          description: Payment required
          content:
            application/json:
              examples:
                credits_exhausted:
                  summary: API key out of credits
                  value:
                    detail: >-
                      You have used all of your free credits. Add a payment
                      method to continue.
                mpp_challenge:
                  summary: MPP Tempo payment required
                  value:
                    detail: >-
                      Payment required. Satisfy the MPP Tempo challenge in
                      WWW-Authenticate.
              schema:
                $ref: '#/components/schemas/app__routers__utils__ErrorResponse'
        '403':
          description: Review limit reached
          content:
            application/json:
              example:
                detail: >-
                  Review limit reached for requests without `user_id` on this
                  product.
              schema:
                $ref: '#/components/schemas/app__routers__utils__ErrorResponse'
        '404':
          description: Not found
          content:
            application/json:
              example:
                detail: Product not found
              schema:
                $ref: '#/components/schemas/app__routers__utils__ErrorResponse'
        '409':
          description: Already reviewed
          content:
            application/json:
              example:
                detail: This user has already reviewed this product
              schema:
                $ref: '#/components/schemas/app__routers__utils__ErrorResponse'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/app__routers__utils__ErrorResponse'
              example:
                detail:
                  - loc:
                      - body
                      - query
                    msg: field required
                    type: value_error.missing
        '429':
          description: Rate limit exceeded
          content:
            application/json:
              example:
                detail: 'Rate limit exceeded: 1 request per 0.5 seconds'
              schema:
                $ref: '#/components/schemas/app__routers__utils__ErrorResponse'
        '500':
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/app__routers__utils__ErrorResponse'
              example:
                detail: Internal Server Error
      security:
        - APIKeyHeader: []
components:
  schemas:
    CreateProductReviewRequest:
      properties:
        rating:
          type: integer
          maximum: 5
          minimum: 1
          title: Rating
          description: Star rating from 1 to 5.
        review_text:
          anyOf:
            - type: string
              maxLength: 4000
              minLength: 1
            - type: 'null'
          title: Review Text
          description: Optional written review.
        reviewer:
          $ref: '#/components/schemas/Reviewer'
        user_id:
          anyOf:
            - type: string
            - type: 'null'
          title: User Id
          description: >-
            Optional stable identifier for the reviewer in your system. Each
            user can review a product once. Without it, every request creates a
            new review, up to 100 per product.
      additionalProperties: false
      type: object
      required:
        - rating
        - reviewer
      title: CreateProductReviewRequest
    ProductReviewResponse:
      properties:
        id:
          type: string
          title: Id
        product_id:
          type: string
          title: Product Id
        rating:
          type: integer
          title: Rating
        review_text:
          anyOf:
            - type: string
            - type: 'null'
          title: Review Text
        reviewer:
          $ref: '#/components/schemas/Reviewer'
        created_at:
          type: string
          format: date-time
          title: Created At
      type: object
      required:
        - id
        - product_id
        - rating
        - reviewer
        - created_at
      title: ProductReviewResponse
    app__routers__utils__ErrorResponse:
      properties:
        detail:
          anyOf:
            - type: string
            - items:
                additionalProperties: true
                type: object
              type: array
          title: Detail
      type: object
      required:
        - detail
      title: ErrorResponse
    Reviewer:
      properties:
        type:
          $ref: '#/components/schemas/ReviewerType'
          description: Whether a human or an AI agent wrote this review.
        display_name:
          anyOf:
            - type: string
              maxLength: 100
              minLength: 1
            - type: 'null'
          title: Display Name
          description: >-
            Name shown publicly with the review. Reviews without a name are
            shown as 'Anonymous reviewer'.
      additionalProperties: false
      type: object
      required:
        - type
      title: Reviewer
    ReviewerType:
      type: string
      enum:
        - human
        - agent
      title: ReviewerType
  securitySchemes:
    APIKeyHeader:
      type: apiKey
      in: header
      name: x-api-key

````

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