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

# Create order report

> Create a PDF analysis report for an order. BIZ MORI picks the report type from the order type, so you don't send it:

- Watermark extract orders created with the v3 API → `watermarkDetection`
- AI Detection orders → `aiDetection`

Image watermark reports support `ko-KR`, `en-US`, and `ja-JP`. PDF watermark reports support `ko-KR` only. Requesting the same order and locale again returns the existing report.

**Responses**
- `202` with `queued` or `processing`: the report is being generated. Poll [`GET /api/v3/orders/{orderId}/reports/{locale}`](/api-reference/reports/get-report)
- `200` with `completed`: the report already exists and includes `download`
- `200` with `failed`: generation failed and cannot be retried (`failure.retryable` is `false`)

**Retries for watermark reports**
If a watermark report is `failed`, calling this endpoint again for the same order and locale starts a new attempt (`202`). Each attempt reserves 1 credit; failed attempts are refunded and only a successful attempt is charged. After 3 failed attempts the report is not regenerated.

Returns `400 ORDER_EXPIRED` after the order's retention period ends, even if a report exists.




## OpenAPI

````yaml api-reference/openapi.yaml POST /api/v3/orders/{orderId}/reports
openapi: 3.0.0
info:
  title: BIZ MORI API
  version: 2.0.0
  description: >
    BIZ MORI API provides four core services for digital content protection:

    - **Anti-AI**: Protect images from AI training

    - **Watermark Embed**: Embed invisible digital watermarks into images

    - **Watermark Extract**: Extract and verify watermarks from images

    - **AI Detection**: Detect whether an image is AI-generated

    - **Test API keys**: Keys with the `sk_test_` prefix use the same Bearer
    authentication and support order-lifecycle testing with mock responses
    without running processing services or consuming credits; test uploads
    discard file contents and do not create result files
  contact:
    name: BIZ MORI Support
    email: support@bizmori.com
  license:
    name: Proprietary
    url: https://docs.bizmori.com/legal/terms
servers:
  - url: https://api.bizmori.com
    description: Production
security: []
tags:
  - name: Anti-AI
    description: Anti-AI image protection orders
  - name: Watermark Embed
    description: Watermark embedding orders
  - name: Watermark Extract
    description: Watermark extraction orders
  - name: AI Detection
    description: AI-generated image detection orders
  - name: Orders
    description: Order query and management
  - name: Webhooks
    description: Webhook configuration and events
  - name: Reports
    description: PDF analysis reports for watermark extract and AI Detection orders
paths:
  /api/v3/orders/{orderId}/reports:
    post:
      tags:
        - Reports
      summary: Create an order report
      description: >
        Create a PDF analysis report for an order. BIZ MORI picks the report
        type from the order type, so you don't send it:


        - Watermark extract orders created with the v3 API →
        `watermarkDetection`

        - AI Detection orders → `aiDetection`


        Image watermark reports support `ko-KR`, `en-US`, and `ja-JP`. PDF
        watermark reports support `ko-KR` only. Requesting the same order and
        locale again returns the existing report.


        **Responses**

        - `202` with `queued` or `processing`: the report is being generated.
        Poll [`GET
        /api/v3/orders/{orderId}/reports/{locale}`](/api-reference/reports/get-report)

        - `200` with `completed`: the report already exists and includes
        `download`

        - `200` with `failed`: generation failed and cannot be retried
        (`failure.retryable` is `false`)


        **Retries for watermark reports**

        If a watermark report is `failed`, calling this endpoint again for the
        same order and locale starts a new attempt (`202`). Each attempt
        reserves 1 credit; failed attempts are refunded and only a successful
        attempt is charged. After 3 failed attempts the report is not
        regenerated.


        Returns `400 ORDER_EXPIRED` after the order's retention period ends,
        even if a report exists.
      operationId: createOrderReport
      parameters:
        - in: path
          name: orderId
          required: true
          schema:
            type: string
          description: Order ID
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                locale:
                  type: string
                  enum:
                    - ko-KR
                    - en-US
                    - ja-JP
                  default: ko-KR
                  description: Report language. Defaults to `ko-KR`.
            example:
              locale: en-US
      responses:
        '200':
          description: The report is already complete, or it failed and cannot be retried
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/OrderReportResponse'
        '202':
          description: The report request was accepted and is `queued` or `processing`
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/OrderReportResponse'
        '400':
          description: >-
            Invalid request, the order type does not support the locale, or the
            order's retention period has ended
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              examples:
                validation:
                  value:
                    code: VALIDATION_FAILED
                locale:
                  value:
                    code: REPORT_LOCALE_UNSUPPORTED
                expired:
                  value:
                    code: ORDER_EXPIRED
        '401':
          $ref: '#/components/responses/Unauthorized'
        '404':
          description: >-
            The order does not exist or belongs to another account, or the
            completed report file is missing
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              examples:
                order:
                  value:
                    code: ORDER_NOT_FOUND
                report:
                  value:
                    code: REPORT_NOT_FOUND
        '409':
          description: The order is not complete or cannot produce a report yet
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                code: REPORT_NOT_AVAILABLE
        '429':
          description: Too many requests
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                code: RATE_LIMIT_EXCEEDED
        '500':
          $ref: '#/components/responses/InternalError'
        '503':
          description: Report generation is temporarily unavailable
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                code: SERVICE_UNAVAILABLE
      security:
        - BearerAuth: []
      x-codeSamples:
        - lang: curl
          label: cURL
          source: >
            curl -X POST https://api.bizmori.com/api/v3/orders/ORDER_ID/reports
            \
              -H "Authorization: Bearer YOUR_API_KEY" \
              -H "Content-Type: application/json" \
              -d '{
              "locale": "en-US"
            }'
        - lang: javascript
          label: JavaScript
          source: >
            const orderId = 'ORDER_ID';

            const response = await
            fetch(`https://api.bizmori.com/api/v3/orders/${orderId}/reports`, {
              method: 'POST',
              headers: {
                'Authorization': 'Bearer YOUR_API_KEY',
                'Content-Type': 'application/json'
              },
              body: JSON.stringify({
                "locale": "en-US"
              })
            });

            const { data } = await response.json();
        - lang: python
          label: Python
          source: |
            import requests

            order_id = 'ORDER_ID'
            response = requests.post(
                f'https://api.bizmori.com/api/v3/orders/{order_id}/reports',
                headers={'Authorization': 'Bearer YOUR_API_KEY'},
                json={
                  "locale": "en-US"
                }
            )
            data = response.json()['data']
components:
  schemas:
    OrderReportResponse:
      type: object
      required:
        - data
      properties:
        data:
          $ref: '#/components/schemas/OrderReportResource'
    ErrorResponse:
      type: object
      properties:
        code:
          type: string
          description: Error code
    OrderReportResource:
      type: object
      required:
        - orderId
        - reportType
        - locale
        - status
        - download
      properties:
        orderId:
          type: string
          description: Order ID
        reportType:
          type: string
          enum:
            - watermarkDetection
            - aiDetection
          description: Set by BIZ MORI from the order type
        locale:
          type: string
          enum:
            - ko-KR
            - en-US
            - ja-JP
        status:
          type: string
          enum:
            - queued
            - processing
            - completed
            - failed
          description: Report generation status
        download:
          nullable: true
          description: Download information. Present only when `status` is `completed`
          allOf:
            - $ref: '#/components/schemas/OrderReportDownload'
        failure:
          nullable: true
          description: Failure information. Present only when `status` is `failed`
          allOf:
            - $ref: '#/components/schemas/OrderReportFailure'
    OrderReportDownload:
      type: object
      required:
        - url
        - expiresInSeconds
      properties:
        url:
          type: string
          format: uri
          description: >
            Presigned PDF URL, valid for 300 seconds. Watermark reports download
            as `<order name>-report-<locale>.pdf` (for example `Spring
            campaign-report-en-US.pdf`).

            Call the report endpoint again for a new URL instead of storing this
            one.
        expiresInSeconds:
          type: integer
          enum:
            - 300
    OrderReportFailure:
      type: object
      required:
        - code
        - retryable
      properties:
        code:
          type: string
          enum:
            - REPORT_GENERATION_FAILED
            - REPORT_NOT_AVAILABLE
        retryable:
          type: boolean
          description: >
            `true` if calling `POST /api/v3/orders/{orderId}/reports` again for
            the same order and locale starts a new attempt.

            Watermark reports become `false` after 3 failed attempts.
  responses:
    Unauthorized:
      description: Authentication failed
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          example:
            code: AUTH_NOT_AUTHENTICATED
    InternalError:
      description: Internal server error
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          example:
            code: SERVER_INTERNAL_ERROR
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer
      description: >-
        Bearer API key for external client access. Live keys use the `sk_`
        prefix; test keys use the `sk_test_` prefix and support order-lifecycle
        testing with mock responses without processing or credit usage.

````

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