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

# Turn parts on an assembly quote

> The MCP's rotate_parts. Before an assembly quote is paid, when its board picture (JLCPCB's own view of each
part, pin 1 and polarity marks in magenta) shows a part facing the wrong way, or the customer asks: each part
turns by degrees counter-clockwise as seen from its own side, added to any turn it has. The price doesn't change.
The reply lists every turn and the board picture drawn with them; the order is placed with the turns.



## OpenAPI

````yaml /api-reference/openapi.json post /v1/quotes/{quote_id}/rotations
openapi: 3.1.0
info:
  title: ProvenMetal API
  version: 1.0.0
  description: >-
    Everything the ProvenMetal MCP does, over HTTP with an API key: upload a
    design, get a live JLCPCB quote and checkout link, follow it to delivery,
    pay with saved details, and check parts and designs. Formal quotes for any
    fab or assembler are under Orders.
servers:
  - url: https://api.provenmetal.com
security:
  - ApiKey: []
tags:
  - name: Uploads
  - name: Quotes
  - name: Saved details
  - name: Checks
  - name: Buy links
  - name: Orders
  - name: Account
paths:
  /v1/quotes/{quote_id}/rotations:
    post:
      tags:
        - Quotes
      summary: Turn parts on an assembly quote
      description: >-
        The MCP's rotate_parts. Before an assembly quote is paid, when its board
        picture (JLCPCB's own view of each

        part, pin 1 and polarity marks in magenta) shows a part facing the wrong
        way, or the customer asks: each part

        turns by degrees counter-clockwise as seen from its own side, added to
        any turn it has. The price doesn't change.

        The reply lists every turn and the board picture drawn with them; the
        order is placed with the turns.
      operationId: rotate_parts_v1_quotes__quote_id__rotations_post
      parameters:
        - name: quote_id
          in: path
          required: true
          schema:
            type: string
            maxLength: 80
            title: Quote Id
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/RotationsRequest'
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/RotationsReply'
        '422':
          description: >-
            A field was refused, or the design needs an answer first
            (needs_details...)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorReply'
        4XX:
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorReply'
          description: Client Error
        5XX:
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorReply'
          description: Server Error
components:
  schemas:
    RotationsRequest:
      properties:
        rotations:
          items:
            $ref: '#/components/schemas/PartTurn'
          type: array
          maxItems: 500
          title: Rotations
          description: The parts to turn, each added to any turn it already has.
        reset:
          type: boolean
          title: Reset
          description: >-
            Clear every turn first, so only these remain; with no rotations,
            clears them all.
          default: false
      additionalProperties: false
      type: object
      required:
        - rotations
      title: RotationsRequest
      description: >-
        Everything the MCP rotate_parts tool takes, for an assembly quote before
        it is paid.
    RotationsReply:
      properties:
        ok:
          type: boolean
          title: Ok
        rotations:
          items:
            additionalProperties: true
            type: object
          type: array
          title: Rotations
          description: Every part's turn on the quote, after this change.
        message:
          anyOf:
            - type: string
            - type: 'null'
          title: Message
        board_image_url:
          anyOf:
            - type: string
            - type: 'null'
          title: Board Image Url
          description: >-
            The board picture drawn with the turns: show it, and ask the
            customer to check those parts.
      additionalProperties: true
      type: object
      required:
        - ok
        - rotations
      title: RotationsReply
    ErrorReply:
      properties:
        ok:
          type: boolean
          const: false
          title: Ok
          default: false
        error:
          type: string
          title: Error
          description: >-
            The MCP's error code, for example needs_details, rate_limited or
            no_files.
        message:
          type: string
          title: Message
          description: What went wrong and what to do, in words to relay.
        questions:
          anyOf:
            - items:
                additionalProperties: true
                type: object
              type: array
            - type: 'null'
          title: Questions
          description: >-
            needs_details: each open question with its option, choices and usual
            answer. Answer them and send the same quote again with those fields.
        known:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Known
          description: 'needs_details: what the files already said.'
        parts:
          anyOf:
            - items:
                additionalProperties: true
                type: object
              type: array
            - type: 'null'
          title: Parts
          description: >-
            needs_part_numbers (and needs_details): the BOM lines to name
            exactly.
        off_board_parts:
          anyOf:
            - items:
                additionalProperties: true
                type: object
              type: array
            - type: 'null'
          title: Off Board Parts
          description: BOM lines with no pick-and-place position.
        retry_after_s:
          anyOf:
            - type: integer
            - type: 'null'
          title: Retry After S
          description: 'rate_limited: seconds to wait. Also in the Retry-After header.'
        checkout_url:
          anyOf:
            - type: string
            - type: 'null'
          title: Checkout Url
          description: >-
            card_declined / authentication_required: where the customer pays
            instead.
        fields:
          anyOf:
            - items:
                additionalProperties:
                  type: string
                type: object
              type: array
            - type: 'null'
          title: Fields
          description: 'invalid_request: each field that was refused and why.'
      additionalProperties: true
      type: object
      required:
        - error
        - message
      title: ErrorReply
    PartTurn:
      properties:
        reference:
          type: string
          maxLength: 40
          minLength: 1
          title: Reference
          description: The part's reference, as the BOM names it (D1).
        degrees:
          type: number
          maximum: 3600
          minimum: -3600
          title: Degrees
          description: >-
            Degrees counter-clockwise, as seen from the side the part sits on;
            negative turns it clockwise.
      additionalProperties: false
      type: object
      required:
        - reference
        - degrees
      title: PartTurn
      description: One part to turn.
  securitySchemes:
    ApiKey:
      type: apiKey
      in: header
      name: X-API-Key
      description: >-
        Your ProvenMetal API key (`pm_live_...`). `Authorization: Bearer <key>`
        also works.

````

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