Skip to main content

Expense lifecycle

The path of an expense posted by the manager or consultant, from posting to payment, and the statuses and origin shown in the retrievals. The calls are on the next pages of this section.

Flow of an expense posted by the manager​

Steps of an expense posted by the manager through the API

Legend: blue boxes with a solid border are manager calls or steps where the expense waits for the manager; dashed grey boxes are QI Tech steps; the green box is the paid expense; the red one, the rejected expense.

  1. Vendor and contract, only for types that require a contract.
  2. Posting. The expense is posted in pending_submission, with the calculation statement and, if already available, the invoice. It can be canceled until it enters the portfolio: in pending_contract_analysis, pending_submission, pre_approved, in_manual_analysis or pending_manager_approval.
  3. Submission. Submit the expense for review, or use submit: true when posting. The expense follows one of two paths:
    • Without provision: it becomes pre_approved and waits for the invoice. If the contract is still under review, it first waits in pending_contract_analysis and becomes pre_approved when the contract takes effect.
    • With provision: it goes to QI Tech review (in_manual_analysis). Once approved, it enters the portfolio in in_provision and is provisioned daily. If the contract is still under review, it waits in pending_contract_analysis after approval and enters the portfolio when the contract takes effect.
  4. Invoice. With the expense in pre_approved or in_provision, submit the invoice. Until then, the payment date can be rescheduled.
  5. Consolidation and payment. QI Tech approves the invoice and the expense becomes consolidated. It is paid on the analysis date (paid) and ends in completed. A rejected invoice is replaced by a new analysis.

The flow changes in two cases:

  • Consultant expense. The expense and the invoice posted by the consultant go through the manager's decision after the QI Tech review.
  • Expense calculated by QI Tech (administration, management and performance fees, for example). It is created directly in the portfolio. When the invoice is issued by the manager, it is also submitted through the consolidation analysis.

Tracking. There is no expense webhook. Track expenses through the retrieval filtering by status. Actions taken through the API with an integration key appear in status_events with author_type: qitech.

Expense status​

Expenses posted by the manager or consultant first go through the submission and review stage. Then they enter the fund's portfolio, where they are provisioned, consolidated and paid. Expenses calculated by QI Tech are created directly in the portfolio.

Status lifecycle of an expense posted by the manager or consultant

Legend: blue with a solid border, the expense waits for the manager or consultant; dashed grey, with QI Tech; green, final; red, rejected. canceled is not in the diagram: through the API, the expense can be canceled until it enters the portfolio. Canceling the contract also cancels its expenses already in the portfolio and not yet paid; rejecting the contract rejects (contract_reproved) all of its expenses still outside the portfolio.

StatusStageDescription
pending_submissionSubmissionPosted, waiting to be submitted for review.
pending_contract_analysisSubmissionSubmitted, waiting for the linked contract to be approved.
pre_approvedSubmissionPre-approved: waiting for the invoice to be consolidated.
in_manual_analysisSubmissionUnder QI Tech review.
pending_manager_approvalSubmissionPosted by the consultant and approved by QI Tech, waiting for the manager's decision.
reprovedSubmissionRejected. reproval_reason gives the reason; post a new expense.
createdPortfolioRecorded, before entering the portfolio. For expenses posted by the manager or consultant, it only appears as the first event in status_events.
in_provisionPortfolioProvisioned daily between start_deferral_date and end_deferral_date.
on_demand_recognitionPortfolioRecognized on demand, without daily provisioning.
consolidatedPortfolioAmount consolidated and ready for payment.
paidPortfolioPaid; provisioning still runs until end_deferral_date.
completedPortfolioPaid and fully recognized.
canceledAnyCanceled.

Expense rejection reasons (reproval_reason): invalid_documents, missing_documents, incorrect_information, ineligible_contract, contract_reproved, manager_reproval. On rejection together with the invoice for incorrect_value, incorrect_payment_data or rebate_inconsistency, the expense's reproval_reason is null; the reason is in consolidation_analysis.reproval_reason.

Expense origin​

origin.origin_type tells how the expense was created:

origin_typeOrigin
expense_contractPosted by the manager or consultant under an expense contract. origin_key is the contract key.
expensePosted by the manager or consultant without a contract (notary, court fees, CVM and ANBIMA fees).
reimbursementReimbursement to the manager or consultant of an expense it has already paid.
rebate_feeManagement fee rebate, posted as a distribution fee.
quota_fee, performance_fee, payment_fee, recurring_expense, expense_control, manualCalculated or recorded by QI Tech.

Consolidation analysis​

Consolidating means closing the expense amount with the invoice. Until then, the amount is the one posted (and, with provision, the one provisioned day by day); the invoice confirms the final amount, which may differ, with a justification. Once consolidated (consolidated), the expense has final amount and payment data and moves on to payment.

Each expense posted by the manager or consultant has a consolidation analysis: the check of the invoice, the amount and the payment data before consolidating and paying. It appears in consolidation_analysis in the expense retrieval. The calls are in Consolidation analysis.

StatusDescription
createdInitial record of the review; it only appears as the first event in consolidation_status_events.
pending_submissionWaiting for the invoice to be submitted.
in_manual_analysisUnder QI Tech review.
pending_manager_approvalSubmitted by the consultant and approved by QI Tech, waiting for the manager's decision.
approvedApproved. The expense moves to consolidated.
reprovedRejected. Open a new analysis, which gets the next number (analysis_number).
consolidatedConsolidated automatically by QI Tech.
canceledClosed together with the expense.

Analysis rejection reasons (reproval_reason): invalid_documents, missing_documents, incorrect_value, incorrect_payment_data, incorrect_information, manager_reproval, rebate_inconsistency.

Errors​

Authentication, permission and host errors: see API Errors. Expense errors have the EXP prefix and are listed on each call's page.