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

# Submit review workspace

> Apply a workspace's staged changes to the project graph.

**Operation ID:** `http.graph.workspaces.submit`

```http theme={null}
POST /v1/orgs/{org}/projects/{project}/graph/workspaces/{ws}/submit
```


## OpenAPI

````yaml openapi.json POST /v1/orgs/{org}/projects/{project}/graph/workspaces/{ws}/submit
openapi: 3.1.0
info:
  title: Penumbra API
  version: v1
  description: >-
    HTTP reference for Files, search, extraction, reviews, Graph, Shapes and
    sharing.
servers:
  - url: https://api.pnbr.io
    description: Penumbra API
security: []
paths:
  /v1/orgs/{org}/projects/{project}/graph/workspaces/{ws}/submit:
    post:
      tags:
        - Review workspaces
      summary: Submit review workspace
      description: |-
        Apply a workspace's staged changes to the project graph.

        Product guidance: [Workspace](/concepts/workspace).
      operationId: http.graph.workspaces.submit
      parameters:
        - name: org
          in: path
          required: true
          schema:
            type: string
        - name: project
          in: path
          required: true
          schema:
            type: string
        - name: ws
          in: path
          required: true
          schema:
            type: string
        - name: Idempotency-Key
          in: header
          required: false
          description: >-
            1–200 printable ASCII characters, no surrounding spaces; '.' and
            '..' are reserved. Reuse this key with the same request when
            retrying an uncertain outcome. Required when an agent's request is
            held for approval.
          schema:
            type: string
            minLength: 1
            maxLength: 200
            pattern: ^(?!\.{1,2}$)[!-~](?:[ -~]*[!-~])?$
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/http_graph_workspaces_submit_request'
      responses:
        2XX:
          description: Success.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/http_graph_workspaces_submit_response'
      security:
        - bearerAuth: []
components:
  schemas:
    http_graph_workspaces_submit_request:
      type: object
      properties:
        expected_revision:
          description: >-
            The exact open revision reviewed for a new submission, or the
            retained source_revision when resuming. Omit only for legacy agent
            behavior.
          type: integer
          exclusiveMinimum: 0
          maximum: 9007199254740991
        submission_sequence:
          description: >-
            Retained sequence when resuming a reviewed submission. Requires
            expected_revision; omit for a new open-workspace submission.
          type: integer
          exclusiveMinimum: 0
          maximum: 9007199254740991
      additionalProperties: false
    http_graph_workspaces_submit_response:
      anyOf:
        - type: object
          properties:
            data:
              type: object
              properties:
                workspace:
                  type: object
                  properties:
                    id:
                      type: string
                    creation_origin:
                      type: string
                    name:
                      type: string
                    description:
                      anyOf:
                        - type: string
                        - type: 'null'
                    status:
                      type: string
                      enum:
                        - open
                        - submitted
                        - applied
                        - closed
                    revision:
                      type: integer
                      minimum: -9007199254740991
                      maximum: 9007199254740991
                    item_count:
                      type: integer
                      minimum: -9007199254740991
                      maximum: 9007199254740991
                    shape:
                      anyOf:
                        - type: object
                          properties:
                            shape_id:
                              type: string
                            artifact_digest:
                              type: string
                          required:
                            - shape_id
                            - artifact_digest
                          additionalProperties: {}
                        - type: 'null'
                    bindings:
                      type: array
                      items:
                        type: object
                        properties:
                          shape_id:
                            type: string
                          artifact_digest:
                            type: string
                        required:
                          - shape_id
                          - artifact_digest
                        additionalProperties: {}
                    bridge_set:
                      anyOf:
                        - type: object
                          properties:
                            digest:
                              type: string
                            declaration_count:
                              type: integer
                              minimum: -9007199254740991
                              maximum: 9007199254740991
                          required:
                            - digest
                            - declaration_count
                          additionalProperties: {}
                        - type: 'null'
                    created_at:
                      type: string
                    updated_at:
                      type: string
                    applied_at:
                      anyOf:
                        - type: string
                        - type: 'null'
                    replaced_by:
                      type: string
                  required:
                    - id
                    - creation_origin
                    - name
                    - description
                    - status
                    - revision
                    - item_count
                    - shape
                    - bindings
                    - bridge_set
                    - created_at
                    - updated_at
                    - applied_at
                  additionalProperties: {}
                outcome:
                  type: string
                  enum:
                    - applied
                    - partial
                    - rejected
                    - unknown
                diagnostics:
                  type: array
                  items:
                    type: object
                    properties:
                      severity:
                        type: string
                        enum:
                          - error
                          - warning
                      code:
                        type: string
                      message:
                        type: string
                      handle:
                        type: string
                      path:
                        type: string
                    required:
                      - severity
                      - code
                      - message
                    additionalProperties: {}
                handles:
                  type: array
                  items:
                    type: object
                    properties:
                      handle:
                        type: string
                      ref:
                        anyOf:
                          - type: string
                          - type: 'null'
                      resource_kind:
                        type: string
                        enum:
                          - node
                          - edge
                      id:
                        type: string
                      revision:
                        type: integer
                        minimum: -9007199254740991
                        maximum: 9007199254740991
                      operation:
                        type: string
                        enum:
                          - created
                          - updated
                          - deleted
                      type:
                        type: string
                      name:
                        anyOf:
                          - type: string
                          - type: 'null'
                    required:
                      - handle
                      - ref
                      - resource_kind
                      - id
                      - revision
                      - operation
                      - type
                      - name
                    additionalProperties: {}
                receipts:
                  type: object
                  properties:
                    lifecycle:
                      anyOf:
                        - type: object
                          properties:
                            kind:
                              type: string
                              enum:
                                - graph_create
                                - graph_lifecycle
                            mode:
                              type: string
                              const: managed_atomic
                            outcome:
                              type: string
                              const: applied
                            replayed:
                              type: boolean
                            request_id:
                              type: string
                            delta_id:
                              type: string
                            project_id:
                              type: string
                            surface_id:
                              type: string
                            native_scope_id:
                              type: string
                            plan_digest:
                              type: string
                            graph_receipt_id:
                              type: string
                            graph_commit_position:
                              type: string
                            mutations:
                              type: array
                              items:
                                type: object
                                properties:
                                  resource_kind:
                                    type: string
                                    enum:
                                      - node
                                      - edge
                                  id:
                                    type: string
                                  revision:
                                    type: integer
                                    minimum: -9007199254740991
                                    maximum: 9007199254740991
                                  operation_index:
                                    type: integer
                                    minimum: -9007199254740991
                                    maximum: 9007199254740991
                                  mutation_kind:
                                    type: string
                                  implicit:
                                    type: boolean
                                required:
                                  - resource_kind
                                  - id
                                  - revision
                                  - operation_index
                                  - mutation_kind
                                  - implicit
                                additionalProperties: {}
                            local_refs:
                              type: object
                              propertyNames:
                                type: string
                              additionalProperties:
                                type: object
                                properties:
                                  resource_kind:
                                    type: string
                                    enum:
                                      - node
                                      - edge
                                  id:
                                    type: string
                                  revision:
                                    type: integer
                                    minimum: -9007199254740991
                                    maximum: 9007199254740991
                                required:
                                  - resource_kind
                                  - id
                                  - revision
                                additionalProperties: {}
                            target_revision:
                              type: string
                            effect_receipt_ref:
                              type: string
                            timings_ms:
                              type: object
                              propertyNames:
                                type: string
                              additionalProperties:
                                type: number
                          required:
                            - kind
                            - mode
                            - outcome
                            - replayed
                            - request_id
                            - delta_id
                            - project_id
                            - surface_id
                            - native_scope_id
                            - plan_digest
                            - graph_receipt_id
                            - graph_commit_position
                            - local_refs
                            - target_revision
                            - effect_receipt_ref
                            - timings_ms
                          additionalProperties: {}
                        - type: 'null'
                    create:
                      anyOf:
                        - type: object
                          properties:
                            kind:
                              type: string
                              enum:
                                - graph_create
                                - graph_lifecycle
                            mode:
                              type: string
                              const: managed_atomic
                            outcome:
                              type: string
                              const: applied
                            replayed:
                              type: boolean
                            request_id:
                              type: string
                            delta_id:
                              type: string
                            project_id:
                              type: string
                            surface_id:
                              type: string
                            native_scope_id:
                              type: string
                            plan_digest:
                              type: string
                            graph_receipt_id:
                              type: string
                            graph_commit_position:
                              type: string
                            mutations:
                              type: array
                              items:
                                type: object
                                properties:
                                  resource_kind:
                                    type: string
                                    enum:
                                      - node
                                      - edge
                                  id:
                                    type: string
                                  revision:
                                    type: integer
                                    minimum: -9007199254740991
                                    maximum: 9007199254740991
                                  operation_index:
                                    type: integer
                                    minimum: -9007199254740991
                                    maximum: 9007199254740991
                                  mutation_kind:
                                    type: string
                                  implicit:
                                    type: boolean
                                required:
                                  - resource_kind
                                  - id
                                  - revision
                                  - operation_index
                                  - mutation_kind
                                  - implicit
                                additionalProperties: {}
                            local_refs:
                              type: object
                              propertyNames:
                                type: string
                              additionalProperties:
                                type: object
                                properties:
                                  resource_kind:
                                    type: string
                                    enum:
                                      - node
                                      - edge
                                  id:
                                    type: string
                                  revision:
                                    type: integer
                                    minimum: -9007199254740991
                                    maximum: 9007199254740991
                                required:
                                  - resource_kind
                                  - id
                                  - revision
                                additionalProperties: {}
                            target_revision:
                              type: string
                            effect_receipt_ref:
                              type: string
                            timings_ms:
                              type: object
                              propertyNames:
                                type: string
                              additionalProperties:
                                type: number
                          required:
                            - kind
                            - mode
                            - outcome
                            - replayed
                            - request_id
                            - delta_id
                            - project_id
                            - surface_id
                            - native_scope_id
                            - plan_digest
                            - graph_receipt_id
                            - graph_commit_position
                            - local_refs
                            - target_revision
                            - effect_receipt_ref
                            - timings_ms
                          additionalProperties: {}
                        - type: 'null'
                    link:
                      anyOf:
                        - type: object
                          properties:
                            kind:
                              type: string
                              enum:
                                - graph_create
                                - graph_lifecycle
                            mode:
                              type: string
                              const: managed_atomic
                            outcome:
                              type: string
                              const: applied
                            replayed:
                              type: boolean
                            request_id:
                              type: string
                            delta_id:
                              type: string
                            project_id:
                              type: string
                            surface_id:
                              type: string
                            native_scope_id:
                              type: string
                            plan_digest:
                              type: string
                            graph_receipt_id:
                              type: string
                            graph_commit_position:
                              type: string
                            mutations:
                              type: array
                              items:
                                type: object
                                properties:
                                  resource_kind:
                                    type: string
                                    enum:
                                      - node
                                      - edge
                                  id:
                                    type: string
                                  revision:
                                    type: integer
                                    minimum: -9007199254740991
                                    maximum: 9007199254740991
                                  operation_index:
                                    type: integer
                                    minimum: -9007199254740991
                                    maximum: 9007199254740991
                                  mutation_kind:
                                    type: string
                                  implicit:
                                    type: boolean
                                required:
                                  - resource_kind
                                  - id
                                  - revision
                                  - operation_index
                                  - mutation_kind
                                  - implicit
                                additionalProperties: {}
                            local_refs:
                              type: object
                              propertyNames:
                                type: string
                              additionalProperties:
                                type: object
                                properties:
                                  resource_kind:
                                    type: string
                                    enum:
                                      - node
                                      - edge
                                  id:
                                    type: string
                                  revision:
                                    type: integer
                                    minimum: -9007199254740991
                                    maximum: 9007199254740991
                                required:
                                  - resource_kind
                                  - id
                                  - revision
                                additionalProperties: {}
                            target_revision:
                              type: string
                            effect_receipt_ref:
                              type: string
                            timings_ms:
                              type: object
                              propertyNames:
                                type: string
                              additionalProperties:
                                type: number
                          required:
                            - kind
                            - mode
                            - outcome
                            - replayed
                            - request_id
                            - delta_id
                            - project_id
                            - surface_id
                            - native_scope_id
                            - plan_digest
                            - graph_receipt_id
                            - graph_commit_position
                            - local_refs
                            - target_revision
                            - effect_receipt_ref
                            - timings_ms
                          additionalProperties: {}
                        - type: 'null'
                  required:
                    - lifecycle
                    - create
                    - link
                  additionalProperties: {}
                error:
                  anyOf:
                    - type: string
                    - type: 'null'
                fence:
                  anyOf:
                    - type: object
                      properties:
                        schema:
                          type: string
                          const: penumbra.graph-fence
                        version:
                          type: number
                          const: 1
                        project_id:
                          type: string
                        scope_id:
                          type: string
                        position:
                          type: string
                      required:
                        - schema
                        - version
                        - project_id
                        - scope_id
                        - position
                      additionalProperties: {}
                    - type: 'null'
              required:
                - workspace
                - outcome
                - diagnostics
                - handles
                - receipts
                - error
                - fence
              additionalProperties: {}
          required:
            - data
          additionalProperties: false
        - type: object
          properties:
            request_id:
              type: string
            outcome:
              type: string
              const: pending
            reason:
              type: string
            operation:
              type: object
              properties:
                id:
                  type: string
                request_id:
                  type: string
                status_url:
                  type: string
              required:
                - id
                - request_id
                - status_url
              additionalProperties: false
            approval:
              type: object
              properties:
                url:
                  type: string
                status:
                  type: string
                expires_at:
                  type: string
                effects:
                  type: array
                  items:
                    type: string
                next:
                  type: string
              required:
                - url
                - status
                - expires_at
                - effects
                - next
              additionalProperties: false
          required:
            - request_id
            - outcome
            - reason
            - operation
            - approval
          additionalProperties: false
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer

````

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