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

# Set Task Artifact Status



## OpenAPI

````yaml https://app.usequanta.com/openapi/quanta-services-api/openapi.json put /admin_api/tasks/{occurrence_qid}/artifacts/{artifact_qid}
openapi: 3.1.0
info:
  title: FastAPI
  version: 0.1.0
servers:
  - url: https://app.usequanta.com
    description: Production
security:
  - HTTPBearer: []
paths:
  /admin_api/tasks/{occurrence_qid}/artifacts/{artifact_qid}:
    put:
      tags:
        - tasks
        - quanta-services-api
      summary: Set Task Artifact Status
      operationId: setTaskArtifactStatus
      parameters:
        - name: occurrence_qid
          in: path
          required: true
          schema:
            type: string
            title: Occurrence Qid
        - name: artifact_qid
          in: path
          required: true
          schema:
            type: string
            title: Artifact Qid
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/TaskArtifactStatusRequest'
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TaskArtifactResponse'
        '404':
          description: Not found
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
        - HTTPBearer: []
components:
  schemas:
    TaskArtifactStatusRequest:
      properties:
        client_request_id:
          type: string
          maxLength: 200
          minLength: 1
          title: Client Request Id
        status:
          $ref: '#/components/schemas/TaskArtifactStatus'
        reason_code:
          anyOf:
            - $ref: '#/components/schemas/CloseReviewResolutionReasonCode'
            - type: 'null'
        note:
          anyOf:
            - type: string
              maxLength: 5000
            - type: 'null'
          title: Note
        reason:
          anyOf:
            - type: string
              maxLength: 500
              minLength: 1
            - type: 'null'
          title: Reason
      additionalProperties: false
      type: object
      required:
        - client_request_id
        - status
      title: TaskArtifactStatusRequest
    TaskArtifactResponse:
      properties:
        qid:
          type: string
          title: Qid
        occurrence_qid:
          type: string
          title: Occurrence Qid
        artifact_key:
          type: string
          title: Artifact Key
        kind:
          $ref: '#/components/schemas/TaskArtifactKind'
        status:
          $ref: '#/components/schemas/TaskArtifactStatus'
        label:
          type: string
          title: Label
        summary:
          type: string
          title: Summary
        related_records:
          items:
            additionalProperties:
              type: string
            type: object
          type: array
          title: Related Records
        result_record:
          anyOf:
            - additionalProperties:
                type: string
              type: object
            - type: 'null'
          title: Result Record
        workpaper_path:
          anyOf:
            - type: string
            - type: 'null'
          title: Workpaper Path
        action_type:
          anyOf:
            - $ref: '#/components/schemas/ProposalActionType'
            - type: 'null'
        current_output:
          anyOf:
            - $ref: '#/components/schemas/Output'
            - type: 'null'
        latest_source_type:
          $ref: '#/components/schemas/TaskArtifactSourceType'
        latest_source_qid:
          type: string
          title: Latest Source Qid
        latest_source_decision_key:
          type: string
          title: Latest Source Decision Key
        resolved_by_user_qid:
          anyOf:
            - type: string
            - type: 'null'
          title: Resolved By User Qid
        resolved_by_name:
          anyOf:
            - type: string
            - type: 'null'
          title: Resolved By Name
        resolved_at:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Resolved At
        resolution_reason_code:
          anyOf:
            - type: string
            - type: 'null'
          title: Resolution Reason Code
        resolution_note:
          anyOf:
            - type: string
            - type: 'null'
          title: Resolution Note
        latest_event_type:
          anyOf:
            - $ref: '#/components/schemas/TaskArtifactEventType'
            - type: 'null'
        latest_event_source_qid:
          anyOf:
            - type: string
            - type: 'null'
          title: Latest Event Source Qid
        latest_event_at:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Latest Event At
        created_at:
          type: string
          format: date-time
          title: Created At
        updated_at:
          type: string
          format: date-time
          title: Updated At
      type: object
      required:
        - qid
        - occurrence_qid
        - artifact_key
        - kind
        - status
        - label
        - summary
        - related_records
        - result_record
        - workpaper_path
        - action_type
        - latest_source_type
        - latest_source_qid
        - latest_source_decision_key
        - resolved_by_user_qid
        - resolved_at
        - resolution_reason_code
        - resolution_note
        - latest_event_type
        - latest_event_source_qid
        - latest_event_at
        - created_at
        - updated_at
      title: TaskArtifactResponse
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    TaskArtifactStatus:
      type: string
      enum:
        - PASSED
        - READY
        - PROVISIONAL
        - NEEDS_INPUT
        - BLOCKED
        - REVIEW
        - RESOLVED
        - APPLIED
        - PARTIALLY_APPLIED
        - NOT_RIGHT
        - IRRELEVANT
        - SUPERSEDED
      title: TaskArtifactStatus
    CloseReviewResolutionReasonCode:
      type: string
      enum:
        - WRONG_FIX
        - NOT_AN_ISSUE
        - WRONG_PERIOD
        - NEEDS_CUSTOMER
        - OTHER
      title: CloseReviewResolutionReasonCode
    TaskArtifactKind:
      type: string
      enum:
        - CHECK
        - INPUT
        - PROPOSAL
        - RECORD
      title: TaskArtifactKind
    ProposalActionType:
      type: string
      enum:
        - create_manual_journal_entry
        - edit_journal_entry
        - open_record
        - request_input
        - update_booking
        - update_vendor_mapping
        - publish_leaf
        - remove_duplicate_payroll
        - remove_duplicate_invoice
      title: ProposalActionType
    Output:
      properties:
        id:
          type: string
          minLength: 1
          title: Id
        leaf_key:
          anyOf:
            - type: string
            - type: 'null'
          title: Leaf Key
        component_key:
          anyOf:
            - type: string
              minLength: 1
            - type: 'null'
          title: Component Key
        title:
          type: string
          maxLength: 60
          minLength: 1
          title: Title
        summary:
          type: string
          minLength: 1
          title: Summary
        evidence:
          items:
            $ref: '#/components/schemas/DecisionEvidence'
          type: array
          title: Evidence
        blocking:
          type: boolean
          title: Blocking
        workpaper_path:
          anyOf:
            - type: string
            - type: 'null'
          title: Workpaper Path
        result:
          anyOf:
            - $ref: '#/components/schemas/CheckPass'
            - $ref: '#/components/schemas/CheckNotChecked'
            - oneOf:
                - $ref: '#/components/schemas/CheckIssue'
                - $ref: '#/components/schemas/JournalEntryResult'
                - $ref: '#/components/schemas/BookingResult'
                - $ref: '#/components/schemas/ConfirmationResult'
                - $ref: '#/components/schemas/TextResult'
                - $ref: '#/components/schemas/QuestionResult'
              discriminator:
                propertyName: type
                mapping:
                  booking: '#/components/schemas/BookingResult'
                  check: '#/components/schemas/CheckIssue'
                  confirmation: '#/components/schemas/ConfirmationResult'
                  journal_entry: '#/components/schemas/JournalEntryResult'
                  question: '#/components/schemas/QuestionResult'
                  text: '#/components/schemas/TextResult'
          title: Result
        alternatives:
          anyOf:
            - items:
                $ref: '#/components/schemas/Alternative'
              type: array
            - type: 'null'
          title: Alternatives
      additionalProperties: false
      type: object
      required:
        - id
        - title
        - summary
        - evidence
        - blocking
        - result
      title: Output
    TaskArtifactSourceType:
      type: string
      enum:
        - CLOSE_REVIEW_RUN
        - WORK_TURN
        - OPERATOR
      title: TaskArtifactSourceType
    TaskArtifactEventType:
      type: string
      enum:
        - OBSERVED
        - STATUS_CHANGED
        - REOPENED
      title: TaskArtifactEventType
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
        input:
          title: Input
        ctx:
          type: object
          title: Context
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
    DecisionEvidence:
      properties:
        type:
          type: string
          title: Type
        description:
          type: string
          title: Description
        amounts:
          items:
            $ref: '#/components/schemas/LabeledAmount'
          type: array
          title: Amounts
          default: []
        ref_label:
          anyOf:
            - type: string
            - type: 'null'
          title: Ref Label
        dataset:
          anyOf:
            - type: string
            - type: 'null'
          title: Dataset
        sql:
          anyOf:
            - type: string
            - type: 'null'
          title: Sql
        value:
          anyOf:
            - type: string
            - type: number
            - type: 'null'
          title: Value
        as_of:
          anyOf:
            - type: string
            - type: 'null'
          title: As Of
        qid:
          anyOf:
            - type: string
            - type: 'null'
          title: Qid
        path:
          anyOf:
            - type: string
            - type: 'null'
          title: Path
      additionalProperties: true
      type: object
      required:
        - type
        - description
      title: DecisionEvidence
    CheckPass:
      properties:
        type:
          type: string
          const: check
          title: Type
        outcome:
          type: string
          const: pass
          title: Outcome
        records:
          items:
            $ref: '#/components/schemas/RecordRef'
          type: array
          title: Records
      additionalProperties: false
      type: object
      required:
        - type
        - outcome
        - records
      title: CheckPass
    CheckNotChecked:
      properties:
        type:
          type: string
          const: check
          title: Type
        outcome:
          type: string
          const: not_checked
          title: Outcome
        records:
          items:
            $ref: '#/components/schemas/RecordRef'
          type: array
          title: Records
      additionalProperties: false
      type: object
      required:
        - type
        - outcome
        - records
      title: CheckNotChecked
    CheckIssue:
      properties:
        type:
          type: string
          const: check
          title: Type
        outcome:
          type: string
          const: issue
          title: Outcome
        records:
          items:
            $ref: '#/components/schemas/RecordRef'
          type: array
          title: Records
        follow_up:
          oneOf:
            - $ref: '#/components/schemas/ManualFollowUp'
            - $ref: '#/components/schemas/LeaveUnchangedFollowUp'
          title: Follow Up
          discriminator:
            propertyName: kind
            mapping:
              leave_unchanged: '#/components/schemas/LeaveUnchangedFollowUp'
              manual: '#/components/schemas/ManualFollowUp'
        recommendation:
          type: string
          minLength: 1
          title: Recommendation
        expected_outcome:
          type: string
          minLength: 1
          title: Expected Outcome
      additionalProperties: false
      type: object
      required:
        - type
        - outcome
        - records
        - follow_up
        - recommendation
        - expected_outcome
      title: CheckIssue
    JournalEntryResult:
      properties:
        type:
          type: string
          const: journal_entry
          title: Type
        proposal:
          oneOf:
            - $ref: '#/components/schemas/CreateManualJournalEntryAction'
            - $ref: '#/components/schemas/EditJournalEntryAction'
          title: Proposal
          discriminator:
            propertyName: type
            mapping:
              create_manual_journal_entry: '#/components/schemas/CreateManualJournalEntryAction'
              edit_journal_entry: '#/components/schemas/EditJournalEntryAction'
        recommendation:
          type: string
          minLength: 1
          title: Recommendation
        expected_outcome:
          type: string
          minLength: 1
          title: Expected Outcome
      additionalProperties: false
      type: object
      required:
        - type
        - proposal
        - recommendation
        - expected_outcome
      title: JournalEntryResult
    BookingResult:
      properties:
        type:
          type: string
          const: booking
          title: Type
        transaction:
          $ref: '#/components/schemas/RecordRef'
        before:
          items:
            anyOf:
              - $ref: '#/components/schemas/BookingDraftSpend'
              - $ref: '#/components/schemas/BookingDraftCustomer'
          type: array
          minItems: 1
          title: Before
        after:
          items:
            anyOf:
              - $ref: '#/components/schemas/BookingDraftSpend'
              - $ref: '#/components/schemas/BookingDraftCustomer'
          type: array
          minItems: 1
          title: After
        recommendation:
          type: string
          minLength: 1
          title: Recommendation
        expected_outcome:
          type: string
          minLength: 1
          title: Expected Outcome
      additionalProperties: false
      type: object
      required:
        - type
        - transaction
        - before
        - after
        - recommendation
        - expected_outcome
      title: BookingResult
    ConfirmationResult:
      properties:
        type:
          type: string
          const: confirmation
          title: Type
        action:
          oneOf:
            - $ref: '#/components/schemas/VendorMappingAction'
            - $ref: '#/components/schemas/PayrollDuplicateCleanup'
            - $ref: '#/components/schemas/InvoiceDuplicateCleanup'
          title: Action
          discriminator:
            propertyName: type
            mapping:
              remove_duplicate_invoice: '#/components/schemas/InvoiceDuplicateCleanup'
              remove_duplicate_payroll: '#/components/schemas/PayrollDuplicateCleanup'
              update_vendor_mapping: '#/components/schemas/VendorMappingAction'
        recommendation:
          type: string
          minLength: 1
          title: Recommendation
        expected_outcome:
          type: string
          minLength: 1
          title: Expected Outcome
      additionalProperties: false
      type: object
      required:
        - type
        - action
        - recommendation
        - expected_outcome
      title: ConfirmationResult
    TextResult:
      properties:
        type:
          type: string
          const: text
          title: Type
        target:
          $ref: '#/components/schemas/TextTarget'
        base_version_qid:
          type: string
          minLength: 1
          title: Base Version Qid
        edits:
          items:
            $ref: '#/components/schemas/TextEdit'
          type: array
          minItems: 1
          title: Edits
        recommendation:
          type: string
          minLength: 1
          title: Recommendation
        expected_outcome:
          type: string
          minLength: 1
          title: Expected Outcome
      additionalProperties: false
      type: object
      required:
        - type
        - target
        - base_version_qid
        - edits
        - recommendation
        - expected_outcome
      title: TextResult
    QuestionResult:
      properties:
        type:
          type: string
          const: question
          title: Type
        records:
          items:
            $ref: '#/components/schemas/RecordRef'
          type: array
          title: Records
        request_kind:
          anyOf:
            - $ref: '#/components/schemas/SourceRequestKind'
            - type: 'null'
        subject_txn_qid:
          anyOf:
            - type: string
              minLength: 1
            - type: 'null'
          title: Subject Txn Qid
        existing_request:
          anyOf:
            - $ref: '#/components/schemas/ExistingRequest'
            - type: 'null'
        recommendation:
          type: string
          minLength: 1
          title: Recommendation
        expected_outcome:
          type: string
          minLength: 1
          title: Expected Outcome
      additionalProperties: false
      type: object
      required:
        - type
        - records
        - recommendation
        - expected_outcome
      title: QuestionResult
    Alternative:
      properties:
        id:
          type: string
          minLength: 1
          title: Id
        label:
          type: string
          minLength: 1
          title: Label
        result:
          oneOf:
            - $ref: '#/components/schemas/BookingResult'
            - $ref: '#/components/schemas/ConfirmationResult'
            - $ref: '#/components/schemas/TextResult'
            - $ref: '#/components/schemas/QuestionResult'
            - $ref: '#/components/schemas/CheckIssue'
            - $ref: '#/components/schemas/JournalEntryResult'
          title: Result
          discriminator:
            propertyName: type
            mapping:
              booking: '#/components/schemas/BookingResult'
              check: '#/components/schemas/CheckIssue'
              confirmation: '#/components/schemas/ConfirmationResult'
              journal_entry: '#/components/schemas/JournalEntryResult'
              question: '#/components/schemas/QuestionResult'
              text: '#/components/schemas/TextResult'
      additionalProperties: false
      type: object
      required:
        - id
        - label
        - result
      title: Alternative
    LabeledAmount:
      properties:
        label:
          type: string
          title: Label
        value:
          type: string
          title: Value
      additionalProperties: true
      type: object
      required:
        - label
        - value
      title: LabeledAmount
    RecordRef:
      properties:
        kind:
          type: string
          minLength: 1
          title: Kind
        qid:
          type: string
          minLength: 1
          title: Qid
        label:
          type: string
          minLength: 1
          title: Label
      additionalProperties: false
      type: object
      required:
        - kind
        - qid
        - label
      title: RecordRef
    ManualFollowUp:
      properties:
        kind:
          type: string
          const: manual
          title: Kind
        steps:
          items:
            $ref: '#/components/schemas/GuidedStep'
          type: array
          minItems: 1
          title: Steps
      additionalProperties: false
      type: object
      required:
        - kind
        - steps
      title: ManualFollowUp
    LeaveUnchangedFollowUp:
      properties:
        kind:
          type: string
          const: leave_unchanged
          title: Kind
      additionalProperties: false
      type: object
      required:
        - kind
      title: LeaveUnchangedFollowUp
    CreateManualJournalEntryAction:
      properties:
        type:
          type: string
          const: create_manual_journal_entry
          title: Type
        readiness:
          type: string
          enum:
            - complete
            - provisional
          title: Readiness
        journal_entry:
          $ref: '#/components/schemas/JournalEntryDraft'
      additionalProperties: false
      type: object
      required:
        - type
        - readiness
        - journal_entry
      title: CreateManualJournalEntryAction
    EditJournalEntryAction:
      properties:
        type:
          type: string
          const: edit_journal_entry
          title: Type
        readiness:
          type: string
          enum:
            - complete
            - provisional
          title: Readiness
        journal_entry_qid:
          type: string
          title: Journal Entry Qid
        before:
          $ref: '#/components/schemas/JournalEntryDraft'
        after:
          $ref: '#/components/schemas/JournalEntryDraft'
      additionalProperties: false
      type: object
      required:
        - type
        - readiness
        - journal_entry_qid
        - before
        - after
      title: EditJournalEntryAction
    BookingDraftSpend:
      properties:
        amount:
          $ref: '#/components/schemas/MonetaryAmount-Output'
        description:
          type: string
          title: Description
        gl_account_qid:
          type: string
          title: Gl Account Qid
        vendor_qid:
          anyOf:
            - type: string
            - type: 'null'
          title: Vendor Qid
        department_qid:
          anyOf:
            - type: string
            - type: 'null'
          title: Department Qid
        recognition:
          anyOf:
            - oneOf:
                - $ref: '#/components/schemas/PrepaidSpec'
                - $ref: '#/components/schemas/PrepaidData-Output'
                - $ref: '#/components/schemas/FixedAssetSpec'
                - $ref: '#/components/schemas/FixedAssetData-Output'
                - $ref: '#/components/schemas/LegacyAccrualSpec'
              discriminator:
                propertyName: vendor_recognition_type
                mapping:
                  ACCRUAL_SPEC: '#/components/schemas/LegacyAccrualSpec'
                  FIXED_ASSET_DATA: '#/components/schemas/FixedAssetData-Output'
                  FIXED_ASSET_SPEC: '#/components/schemas/FixedAssetSpec'
                  PREPAID_DATA: '#/components/schemas/PrepaidData-Output'
                  PREPAID_SPEC: '#/components/schemas/PrepaidSpec'
            - type: 'null'
          title: Recognition
        match:
          anyOf:
            - oneOf:
                - $ref: '#/components/schemas/SourceMatchInfo'
                - $ref: '#/components/schemas/BalanceTransactionMatchInfo-Output'
              discriminator:
                propertyName: type
                mapping:
                  balance_transaction: '#/components/schemas/BalanceTransactionMatchInfo-Output'
                  source_match: '#/components/schemas/SourceMatchInfo'
            - type: 'null'
          title: Match
        booking_item_qid:
          anyOf:
            - type: string
            - type: 'null'
          title: Booking Item Qid
      additionalProperties: false
      type: object
      required:
        - amount
        - description
        - gl_account_qid
      title: BookingDraftSpend
    BookingDraftCustomer:
      properties:
        amount:
          $ref: '#/components/schemas/MonetaryAmount-Output'
        description:
          type: string
          title: Description
        gl_account_qid:
          type: string
          title: Gl Account Qid
        customer_qid:
          type: string
          title: Customer Qid
        product_qid:
          anyOf:
            - type: string
            - type: 'null'
          title: Product Qid
        recognition:
          anyOf:
            - $ref: '#/components/schemas/RevenueScheduleSpec'
            - $ref: '#/components/schemas/RevenueScheduleData-Output'
            - type: 'null'
          title: Recognition
        match:
          anyOf:
            - oneOf:
                - $ref: '#/components/schemas/SourceMatchInfo'
                - $ref: '#/components/schemas/BalanceTransactionMatchInfo-Output'
              discriminator:
                propertyName: type
                mapping:
                  balance_transaction: '#/components/schemas/BalanceTransactionMatchInfo-Output'
                  source_match: '#/components/schemas/SourceMatchInfo'
            - type: 'null'
          title: Match
        paydown_data:
          anyOf:
            - $ref: '#/components/schemas/PaydownItemRequest-Output'
            - type: 'null'
        booking_item_qid:
          anyOf:
            - type: string
            - type: 'null'
          title: Booking Item Qid
      additionalProperties: false
      type: object
      required:
        - amount
        - description
        - gl_account_qid
        - customer_qid
      title: BookingDraftCustomer
    VendorMappingAction:
      properties:
        type:
          type: string
          const: update_vendor_mapping
          title: Type
        vendor:
          $ref: '#/components/schemas/RecordRef'
        before:
          $ref: '#/components/schemas/MappingValues'
        after:
          $ref: '#/components/schemas/MappingValues'
      additionalProperties: false
      type: object
      required:
        - type
        - vendor
        - before
        - after
      title: VendorMappingAction
    PayrollDuplicateCleanup:
      properties:
        type:
          type: string
          const: remove_duplicate_payroll
          title: Type
        retain_pay_statement_qid:
          type: string
          minLength: 1
          title: Retain Pay Statement Qid
        duplicate_pay_statement_qid:
          type: string
          minLength: 1
          title: Duplicate Pay Statement Qid
      additionalProperties: false
      type: object
      required:
        - type
        - retain_pay_statement_qid
        - duplicate_pay_statement_qid
      title: PayrollDuplicateCleanup
    InvoiceDuplicateCleanup:
      properties:
        type:
          type: string
          const: remove_duplicate_invoice
          title: Type
        retain_invoice_source_qid:
          type: string
          minLength: 1
          title: Retain Invoice Source Qid
        duplicate_invoice_source_qid:
          type: string
          minLength: 1
          title: Duplicate Invoice Source Qid
      additionalProperties: false
      type: object
      required:
        - type
        - retain_invoice_source_qid
        - duplicate_invoice_source_qid
      title: InvoiceDuplicateCleanup
    TextTarget:
      properties:
        kind:
          type: string
          const: leaf
          title: Kind
        slug:
          type: string
          minLength: 1
          title: Slug
        scope:
          type: string
          const: CURRENT_ORG
          title: Scope
      additionalProperties: false
      type: object
      required:
        - kind
        - slug
        - scope
      title: TextTarget
    TextEdit:
      properties:
        id:
          type: string
          minLength: 1
          title: Id
        before:
          type: string
          title: Before
        after:
          type: string
          title: After
        insert_after:
          anyOf:
            - type: string
            - type: 'null'
          title: Insert After
      additionalProperties: false
      type: object
      required:
        - id
        - before
        - after
      title: TextEdit
    SourceRequestKind:
      type: string
      enum:
        - transaction_document
        - external_document
        - data_confirmation
      title: SourceRequestKind
    ExistingRequest:
      properties:
        evidence:
          $ref: '#/components/schemas/DecisionEvidence'
        reentry_condition:
          type: string
          minLength: 1
          title: Reentry Condition
      additionalProperties: false
      type: object
      required:
        - evidence
        - reentry_condition
      title: ExistingRequest
    GuidedStep:
      properties:
        instruction:
          type: string
          minLength: 1
          title: Instruction
        target:
          oneOf:
            - $ref: '#/components/schemas/SourceTransactionTarget'
            - $ref: '#/components/schemas/ReconciliationTarget'
            - $ref: '#/components/schemas/RecordTarget'
          title: Target
          discriminator:
            propertyName: kind
            mapping:
              reconciliation: '#/components/schemas/ReconciliationTarget'
              record: '#/components/schemas/RecordTarget'
              source_transaction: '#/components/schemas/SourceTransactionTarget'
      additionalProperties: false
      type: object
      required:
        - instruction
        - target
      title: GuidedStep
    JournalEntryDraft:
      properties:
        effective_date:
          type: string
          format: date
          title: Effective Date
        memo:
          type: string
          title: Memo
        private_memo:
          anyOf:
            - type: string
            - type: 'null'
          title: Private Memo
        entity_qid:
          anyOf:
            - type: string
            - type: 'null'
          title: Entity Qid
        lines:
          items:
            $ref: '#/components/schemas/JournalEntryLineDraft'
          type: array
          minItems: 2
          title: Lines
      additionalProperties: false
      type: object
      required:
        - effective_date
        - memo
        - lines
      title: JournalEntryDraft
    MonetaryAmount-Output:
      properties:
        amount:
          type: string
          pattern: ^(?!^[-+.]*$)[+-]?0*\d*\.?\d*$
          title: Amount
        currency:
          $ref: '#/components/schemas/Currency'
      type: object
      required:
        - amount
        - currency
      title: MonetaryAmount
      description: Immutable monetary value with currency.
    PrepaidSpec:
      properties:
        vendor_recognition_type:
          type: string
          const: PREPAID_SPEC
          title: Vendor Recognition Type
          default: PREPAID_SPEC
        num_amortization_months:
          type: integer
          title: Num Amortization Months
        start_date:
          type: string
          format: date
          title: Start Date
        effective_day_of_the_month:
          $ref: '#/components/schemas/EffectiveDayOfTheMonth'
          default: last
      type: object
      required:
        - num_amortization_months
        - start_date
      title: PrepaidSpec
    PrepaidData-Output:
      properties:
        vendor_recognition_type:
          type: string
          const: PREPAID_DATA
          title: Vendor Recognition Type
          default: PREPAID_DATA
        items:
          items:
            $ref: '#/components/schemas/PrepaidItemData-Output'
          type: array
          minItems: 1
          title: Items
        service_start_date:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Service Start Date
      type: object
      required:
        - items
      title: PrepaidData
    FixedAssetSpec:
      properties:
        vendor_recognition_type:
          type: string
          const: FIXED_ASSET_SPEC
          title: Vendor Recognition Type
          default: FIXED_ASSET_SPEC
        asset_type:
          $ref: '#/components/schemas/FixedAssetType'
        lifetime_months:
          anyOf:
            - type: integer
            - type: 'null'
          title: Lifetime Months
        service_start_date:
          type: string
          format: date
          title: Service Start Date
      type: object
      required:
        - asset_type
        - service_start_date
      title: FixedAssetSpec
    FixedAssetData-Output:
      properties:
        vendor_recognition_type:
          type: string
          const: FIXED_ASSET_DATA
          title: Vendor Recognition Type
          default: FIXED_ASSET_DATA
        asset_type:
          $ref: '#/components/schemas/FixedAssetType'
        purchase_date:
          type: string
          format: date
          title: Purchase Date
        items:
          items:
            $ref: '#/components/schemas/FixedAssetItemData-Output'
          type: array
          minItems: 1
          title: Items
      type: object
      required:
        - asset_type
        - purchase_date
        - items
      title: FixedAssetData
    LegacyAccrualSpec:
      properties:
        vendor_recognition_type:
          type: string
          const: ACCRUAL_SPEC
          title: Vendor Recognition Type
          default: ACCRUAL_SPEC
        accrual_date:
          type: string
          format: date
          title: Accrual Date
      type: object
      required:
        - accrual_date
      title: LegacyAccrualSpec
    SourceMatchInfo:
      properties:
        type:
          type: string
          const: source_match
          title: Type
        targets:
          items:
            $ref: '#/components/schemas/SourceMatchTarget'
          type: array
          minItems: 1
          title: Targets
      type: object
      required:
        - type
        - targets
      title: SourceMatchInfo
    BalanceTransactionMatchInfo-Output:
      properties:
        type:
          type: string
          const: balance_transaction
          title: Type
        transaction_qids:
          items:
            $ref: '#/components/schemas/BalanceTransactionMatch-Output'
          type: array
          minItems: 1
          title: Transaction Qids
      type: object
      required:
        - type
        - transaction_qids
      title: BalanceTransactionMatchInfo
    RevenueScheduleSpec:
      properties:
        service_period:
          $ref: '#/components/schemas/ServicePeriodDates'
        amortization_granularity:
          anyOf:
            - $ref: '#/components/schemas/AmortizationGranularity'
            - type: 'null'
        apply_catch_up_revenue:
          type: boolean
          title: Apply Catch Up Revenue
          default: false
      type: object
      required:
        - service_period
      title: RevenueScheduleSpec
    RevenueScheduleData-Output:
      properties:
        service_period:
          $ref: '#/components/schemas/ServicePeriodDates'
        amortization_granularity:
          $ref: '#/components/schemas/AmortizationGranularity'
        items:
          items:
            $ref: '#/components/schemas/RevenueScheduleItemData-Output'
          type: array
          minItems: 1
          title: Items
        apply_catch_up_revenue:
          type: boolean
          title: Apply Catch Up Revenue
          default: false
      type: object
      required:
        - service_period
        - amortization_granularity
        - items
      title: RevenueScheduleData
    PaydownItemRequest-Output:
      properties:
        target_transaction_qid:
          type: string
          title: Target Transaction Qid
        amount:
          $ref: '#/components/schemas/MonetaryAmount-Output'
        credit_remaining:
          anyOf:
            - $ref: '#/components/schemas/AllocationCreditRemaining-Output'
            - type: 'null'
        expense_remaining:
          anyOf:
            - $ref: '#/components/schemas/AllocationExpenseRemaining-Output'
            - type: 'null'
      type: object
      required:
        - target_transaction_qid
        - amount
      title: PaydownItemRequest
    MappingValues:
      properties:
        gl_account_qid:
          anyOf:
            - type: string
            - type: 'null'
          title: Gl Account Qid
        department_qid:
          anyOf:
            - type: string
            - type: 'null'
          title: Department Qid
      additionalProperties: false
      type: object
      required:
        - gl_account_qid
        - department_qid
      title: MappingValues
    SourceTransactionTarget:
      properties:
        kind:
          type: string
          const: source_transaction
          title: Kind
        source_qid:
          type: string
          minLength: 1
          title: Source Qid
      additionalProperties: false
      type: object
      required:
        - kind
        - source_qid
      title: SourceTransactionTarget
    ReconciliationTarget:
      properties:
        kind:
          type: string
          const: reconciliation
          title: Kind
        name:
          type: string
          minLength: 1
          title: Name
        as_of:
          type: string
          format: date
          title: As Of
      additionalProperties: false
      type: object
      required:
        - kind
        - name
        - as_of
      title: ReconciliationTarget
    RecordTarget:
      properties:
        kind:
          type: string
          const: record
          title: Kind
        record:
          $ref: '#/components/schemas/RecordRef'
      additionalProperties: false
      type: object
      required:
        - kind
        - record
      title: RecordTarget
    JournalEntryLineDraft:
      properties:
        line_id:
          type: string
          title: Line Id
        account_qid:
          type: string
          title: Account Qid
        account_name:
          anyOf:
            - type: string
            - type: 'null'
          title: Account Name
        debit:
          anyOf:
            - type: string
              pattern: ^(?!^[-+.]*$)[+-]?0*\d*\.?\d*$
            - type: 'null'
          title: Debit
        credit:
          anyOf:
            - type: string
              pattern: ^(?!^[-+.]*$)[+-]?0*\d*\.?\d*$
            - type: 'null'
          title: Credit
        currency:
          type: string
        description:
          type: string
          title: Description
        department_qid:
          anyOf:
            - type: string
            - type: 'null'
          title: Department Qid
        vendor_qid:
          anyOf:
            - type: string
            - type: 'null'
          title: Vendor Qid
        customer_qid:
          anyOf:
            - type: string
            - type: 'null'
          title: Customer Qid
        product_qid:
          anyOf:
            - type: string
            - type: 'null'
          title: Product Qid
      additionalProperties: false
      type: object
      required:
        - line_id
        - account_qid
        - currency
        - description
      title: JournalEntryLineDraft
    Currency:
      type: string
      enum:
        - AED
        - AFN
        - ALL
        - AMD
        - ANG
        - AOA
        - ARS
        - AUD
        - AWG
        - AZN
        - BAM
        - BBD
        - BDT
        - BGN
        - BHD
        - BIF
        - BMD
        - BND
        - BOB
        - BOV
        - BRL
        - BSD
        - BTN
        - BWP
        - BYN
        - BZD
        - CAD
        - CDF
        - CHE
        - CHF
        - CHW
        - CLF
        - CLP
        - CNY
        - COP
        - COU
        - CRC
        - CUC
        - CUP
        - CVE
        - CZK
        - DJF
        - DKK
        - DOP
        - DZD
        - EGP
        - ERN
        - ETB
        - EUR
        - FJD
        - FKP
        - GBP
        - GEL
        - GHS
        - GIP
        - GMD
        - GNF
        - GTQ
        - GYD
        - HKD
        - HNL
        - HTG
        - HUF
        - IDR
        - ILS
        - INR
        - IQD
        - IRR
        - ISK
        - JMD
        - JOD
        - JPY
        - KES
        - KGS
        - KHR
        - KMF
        - KPW
        - KRW
        - KWD
        - KYD
        - KZT
        - LAK
        - LBP
        - LKR
        - LRD
        - LSL
        - LYD
        - MAD
        - MDL
        - MGA
        - MKD
        - MMK
        - MNT
        - MOP
        - MRU
        - MUR
        - MVR
        - MWK
        - MXN
        - MXV
        - MYR
        - MZN
        - NAD
        - NGN
        - NIO
        - NOK
        - NPR
        - NZD
        - OMR
        - PAB
        - PEN
        - PGK
        - PHP
        - PKR
        - PLN
        - PYG
        - QAR
        - RON
        - RSD
        - RUB
        - RWF
        - SAR
        - SBD
        - SCR
        - SDG
        - SEK
        - SGD
        - SHP
        - SLE
        - SLL
        - SOS
        - SRD
        - SSP
        - STN
        - SVC
        - SYP
        - SZL
        - THB
        - TJS
        - TMT
        - TND
        - TOP
        - TRY
        - TTD
        - TWD
        - TZS
        - UAH
        - UGX
        - USD
        - USN
        - UYI
        - UYU
        - UYW
        - UZS
        - VED
        - VES
        - VND
        - VUV
        - WST
        - XAF
        - XCD
        - XDR
        - XOF
        - XPF
        - XSU
        - XUA
        - YER
        - ZAR
        - ZMW
        - ZWL
      title: Currency
    EffectiveDayOfTheMonth:
      type: string
      enum:
        - first
        - last
      title: EffectiveDayOfTheMonth
    PrepaidItemData-Output:
      properties:
        amount:
          type: string
          pattern: ^(?!^[-+.]*$)[+-]?0*\d*\.?\d*$
          title: Amount
        effective_date:
          type: string
          format: date
          title: Effective Date
      type: object
      required:
        - amount
        - effective_date
      title: PrepaidItemData
    FixedAssetType:
      type: string
      enum:
        - Computer
        - Furniture
        - Leasehold Improvements
      title: FixedAssetType
    FixedAssetItemData-Output:
      properties:
        amount:
          type: string
          pattern: ^(?!^[-+.]*$)[+-]?0*\d*\.?\d*$
          title: Amount
        effective_date:
          type: string
          format: date
          title: Effective Date
      type: object
      required:
        - amount
        - effective_date
      title: FixedAssetItemData
    SourceMatchTarget:
      properties:
        qid:
          type: string
          title: Qid
        entity_type:
          type: string
          enum:
            - brex_reimbursement
            - ramp_reimbursement
            - reimbursement_bank_repayment
            - payroll
            - payroll_payment
            - payroll_liability_manual_adjustment
          title: Entity Type
      type: object
      required:
        - qid
        - entity_type
      title: SourceMatchTarget
    BalanceTransactionMatch-Output:
      properties:
        transaction_qid:
          type: string
          title: Transaction Qid
        source_qid:
          anyOf:
            - type: string
            - type: 'null'
          title: Source Qid
        amount:
          $ref: '#/components/schemas/MonetaryAmount-Output'
      type: object
      required:
        - transaction_qid
        - amount
      title: BalanceTransactionMatch
    ServicePeriodDates:
      properties:
        service_start_date:
          type: string
          format: date
          title: Service Start Date
        end_date_inclusive:
          type: string
          format: date
          title: End Date Inclusive
      type: object
      required:
        - service_start_date
        - end_date_inclusive
      title: ServicePeriodDates
    AmortizationGranularity:
      type: string
      enum:
        - monthly_evenly
        - monthly_ends_prorated
        - millisecond
        - manual
      title: AmortizationGranularity
    RevenueScheduleItemData-Output:
      properties:
        amount:
          type: string
          pattern: ^(?!^[-+.]*$)[+-]?0*\d*\.?\d*$
          title: Amount
        effective_date:
          type: string
          format: date
          title: Effective Date
      type: object
      required:
        - amount
        - effective_date
      title: RevenueScheduleItemData
    AllocationCreditRemaining-Output:
      properties:
        credit_remaining_amount:
          $ref: '#/components/schemas/MonetaryAmount-Output'
        user_qid:
          type: string
          title: User Qid
        admin_email:
          type: string
          title: Admin Email
      type: object
      required:
        - credit_remaining_amount
        - user_qid
        - admin_email
      title: AllocationCreditRemaining
    AllocationExpenseRemaining-Output:
      properties:
        expense_remaining_amount:
          $ref: '#/components/schemas/MonetaryAmount-Output'
        expense_remaining_gl_account_qid:
          type: string
          title: Expense Remaining Gl Account Qid
      type: object
      required:
        - expense_remaining_amount
        - expense_remaining_gl_account_qid
      title: AllocationExpenseRemaining
  securitySchemes:
    HTTPBearer:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: >-
        Quanta Services API scoped bearer token. Supported only on Services API
        routes.

````

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