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

# Start, edit, submit, approve, reject or discard a studio draft



## OpenAPI

````yaml /openapi/storefront.yaml post /api/v2/storefront/proposal-studio
openapi: 3.1.0
info:
  title: Semicola Exchange storefront API
  version: 2.0.0
  description: >-
    Seller (storefront) endpoints: storefront setup, inventory sources,
    products, AI Business Rules, playbook, demand inbox, proposals, approvals
    and seller reporting.
servers:
  - url: https://api.semicola.com
security:
  - bearerAuth: []
  - sessionCookie: []
tags:
  - name: Storefront
  - name: Inventory Sources
  - name: Products
  - name: Business Rules
  - name: Playbook
  - name: Library
  - name: Demand Inbox
  - name: Proposals
  - name: Approvals
  - name: Creative Reviews
  - name: Media Buys
  - name: Buyers
  - name: Reporting
  - name: Activity
  - name: Test Runs
paths:
  /api/v2/storefront/proposal-studio:
    post:
      tags:
        - Proposals
      summary: Start, edit, submit, approve, reject or discard a studio draft
      operationId: postStorefrontProposalStudio
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                action:
                  type: string
                  enum:
                    - start
                    - update
                    - submit
                    - approve
                    - reject
                    - discard
                rfpId:
                  type: string
                  minLength: 1
                turnId:
                  type: string
                  minLength: 1
                draftId:
                  type: string
                products:
                  maxItems: 20
                  type: array
                  items:
                    type: object
                    properties:
                      productId:
                        type: string
                        minLength: 1
                      price:
                        type: number
                        exclusiveMinimum: 0
                    required:
                      - productId
                      - price
                    additionalProperties: false
                allocations:
                  maxItems: 20
                  type: array
                  items:
                    type: object
                    properties:
                      productId:
                        type: string
                        minLength: 1
                      percentage:
                        type: integer
                        minimum: 0
                        maximum: 100
                      rationale:
                        type: string
                        maxLength: 2000
                    required:
                      - productId
                      - percentage
                    additionalProperties: false
                note:
                  type: string
                  maxLength: 4000
              required:
                - action
                - rfpId
                - turnId
              additionalProperties: false
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    anyOf:
                      - type: object
                        properties:
                          state:
                            type: string
                            enum:
                              - ok
                              - empty
                              - permission
                              - error
                              - loading
                          stateMessage:
                            type: string
                          storefrontId:
                            type: integer
                            exclusiveMinimum: 0
                            maximum: 9007199254740991
                          canEdit:
                            type: boolean
                          rfpId:
                            type: string
                          turnId:
                            type: string
                          source:
                            type: object
                            properties:
                              proposalName:
                                type: string
                              disposition:
                                type: string
                            required:
                              - proposalName
                              - disposition
                            additionalProperties: false
                          draft:
                            anyOf:
                              - type: object
                                properties:
                                  draftId:
                                    type: string
                                  status:
                                    type: string
                                    enum:
                                      - draft
                                      - submitted
                                      - approved
                                      - rejected
                                  composerName:
                                    type: string
                                  approverName:
                                    type:
                                      - string
                                      - 'null'
                                  submittedAt:
                                    anyOf:
                                      - type: string
                                        format: date-time
                                        pattern: >-
                                          ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d:[0-5]\d(?:\.\d+)?(?:Z|([+-](?:[01]\d|2[0-3]):[0-5]\d)))$
                                      - type: 'null'
                                  decidedAt:
                                    anyOf:
                                      - type: string
                                        format: date-time
                                        pattern: >-
                                          ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d:[0-5]\d(?:\.\d+)?(?:Z|([+-](?:[01]\d|2[0-3]):[0-5]\d)))$
                                      - type: 'null'
                                  note:
                                    type:
                                      - string
                                      - 'null'
                                  currency:
                                    type: string
                                  totalBudget:
                                    type:
                                      - number
                                      - 'null'
                                  products:
                                    type: array
                                    items:
                                      type: object
                                      properties:
                                        productId:
                                          type: string
                                        name:
                                          type: string
                                        pricingOptionId:
                                          type: string
                                        price:
                                          type: number
                                        floor:
                                          type: number
                                        currency:
                                          type: string
                                      required:
                                        - productId
                                        - name
                                        - pricingOptionId
                                        - price
                                        - floor
                                        - currency
                                      additionalProperties: false
                                  allocations:
                                    type: array
                                    items:
                                      type: object
                                      properties:
                                        productId:
                                          type: string
                                        percentage:
                                          type: integer
                                          minimum: 0
                                          maximum: 100
                                        role:
                                          type: string
                                        rationale:
                                          type: string
                                      required:
                                        - productId
                                        - percentage
                                        - role
                                        - rationale
                                      additionalProperties: false
                                  problems:
                                    type: array
                                    items:
                                      type: string
                                  resultTurnId:
                                    type:
                                      - string
                                      - 'null'
                                required:
                                  - draftId
                                  - status
                                  - composerName
                                  - approverName
                                  - submittedAt
                                  - decidedAt
                                  - note
                                  - currency
                                  - totalBudget
                                  - products
                                  - allocations
                                  - problems
                                  - resultTurnId
                                additionalProperties: false
                              - type: 'null'
                          canApprove:
                            type: boolean
                        required:
                          - state
                          - storefrontId
                          - canEdit
                          - rfpId
                          - turnId
                          - source
                          - draft
                          - canApprove
                        additionalProperties: false
                      - type: 'null'
                  error:
                    anyOf:
                      - type: object
                        properties:
                          code:
                            type: string
                          message:
                            type: string
                          field:
                            type: string
                          details: {}
                        required:
                          - code
                          - message
                        additionalProperties: false
                      - type: 'null'
                required:
                  - data
                  - error
                additionalProperties: false
        default:
          description: >-
            Error envelope `{data: null, error: {code, message, field?,
            details?}}`.
components:
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: API key or OAuth access token.
    sessionCookie:
      type: apiKey
      in: cookie
      name: sc_session

````