Get operation analysis
curl --request GET \
--url https://sandbox.payfi.global/v1/operations/{operationId}/analysis \
--header 'X-PayFi-Api-Key: <api-key>' \
--header 'X-PayFi-Nonce: <api-key>' \
--header 'X-PayFi-Signature: <api-key>'{
"operation": {
"operationId": "op_example_ready",
"partnerOperationId": "acme-op-123",
"customerId": "cus_example",
"status": "READY_FOR_MANUAL_REVIEW",
"operationType": "IMPORT_GOODS",
"exchangeModality": "TERM",
"requirementsStatus": "APPROVED",
"requiredDocumentTypes": [
"invoice",
"bill_of_lading",
"packing_list"
],
"missingDocumentTypes": [],
"score0To100": 94,
"score1To10": 10,
"riskLevel": "low",
"createdAt": "2026-05-20T12:00:00.000Z",
"updatedAt": "2026-05-20T12:10:00.000Z"
},
"decisionPack": {
"decisionPackId": "dp_example",
"schemaVersion": 1,
"operationId": "op_example",
"analysisRunId": "job_example",
"status": "DECISION_PACK_READY",
"regulatoryCorpusVersion": "bc-cambio-2026-06-03",
"policyVersion": "braza-policy-2026-05",
"rulesVersion": "payfi-rules-0.3.1",
"modelProfile": "cheap-default-v1",
"operationFacts": {
"operationId": "op_example",
"operationType": "IMPORT_GOODS",
"exchangeModality": "TERM",
"declaredAmount": "80000",
"currency": "USD"
},
"documentCoverage": [
{
"documentType": "invoice",
"criticality": "critical",
"status": "present",
"documentIds": [
"doc_example"
],
"reasonCodes": [],
"citations": [
{
"citationId": "cit_requirement_invoice",
"sourceType": "REGULATION",
"sourceId": "documentos-por-modalidade.md",
"sourceTitle": "Documentos por modalidade",
"usedFor": "DOCUMENT_REQUIREMENT",
"sourceStatus": "FOUND"
}
]
}
],
"entityReconciliation": [],
"natureDecision": {
"declaredNatureCode": "12452",
"predictedNatureCode": "12452",
"resolvedNatureCode": "12452",
"status": "CONFIRMED",
"confidence": 0.93,
"alternatives": [],
"rationale": "Nature confirmed by operation facts and documentary evidence.",
"requiresHumanReview": true,
"reasonCodes": [
"NATURE_CONFIRMED"
],
"citations": [
{
"citationId": "cit_nature_example",
"sourceType": "SYSTEM_RULE",
"sourceId": "payfi-rules-0.3.1",
"usedFor": "NATURE_DECISION",
"sourceStatus": "FOUND"
}
]
},
"regulatoryChecks": [],
"policyChecks": [],
"fraudSignals": [],
"scoreBreakdown": [],
"overallScore": 8.2,
"score0To100": 82,
"riskLevel": "LOW",
"recommendedStatus": "READY_FOR_MANUAL_REVIEW",
"reviewPosture": "STANDARD_REVIEW",
"blockingReasons": [],
"warnings": [
"MANUAL_REVIEW_REQUIRED"
],
"actionItems": [],
"citations": [],
"rawResultRedacted": {
"workflow": "PayFi Operation Decision Engine",
"deterministic": true
},
"processingTraceEvents": [
{
"source": "workflow",
"stageKey": "decision_engine.output",
"status": "SUCCEEDED",
"sequence": 420
}
],
"createdAt": "2026-06-03T15:00:00.000Z"
},
"documentAnalyses": [
{
"documentId": "doc_invoice",
"documentType": "invoice",
"originalFileName": "invoice-2026-001.pdf",
"documentStatus": "PROCESSED",
"jobId": "job_invoice",
"jobStatus": "SUCCEEDED",
"jobAttempts": 1,
"jobError": null,
"score0To100": 94,
"riskLevel": "low",
"flags": {
"validated": [],
"rejected": [],
"additional": [],
"summary": {
"total": 0,
"critical": 0,
"warning": 0,
"info": 0
}
},
"extractedFields": {
"document_type_detected": "invoice",
"invoice_number": "INV-2026-001",
"value": 80000,
"currency": "USD",
"buyer_name": "Acme Ltda"
},
"rawResultRedacted": {
"operation_id": "op_example_ready",
"compliance_score": 94,
"risk_level": "low",
"flags": {
"validated": [],
"rejected": [],
"additional": [],
"summary": {
"total": 0,
"critical": 0,
"warning": 0,
"info": 0
}
},
"extracted_data": {
"document_type_detected": "invoice",
"invoice_number": "INV-2026-001",
"value": 80000,
"currency": "USD"
},
"completeness": {
"is_complete": true,
"missing_documents": [],
"missing_types": []
},
"pipeline_version": "P1",
"processed_at": "2026-05-20T12:05:00.000Z"
},
"createdAt": "2026-05-20T12:00:00.000Z",
"updatedAt": "2026-05-20T12:05:00.000Z",
"resultCreatedAt": "2026-05-20T12:05:00.000Z"
}
]
}Operations
Get operation analysis
Returns the operation status, latest operation-level Decision Pack when available, and per-document analysis projections.
GET
/
v1
/
operations
/
{operationId}
/
analysis
Get operation analysis
curl --request GET \
--url https://sandbox.payfi.global/v1/operations/{operationId}/analysis \
--header 'X-PayFi-Api-Key: <api-key>' \
--header 'X-PayFi-Nonce: <api-key>' \
--header 'X-PayFi-Signature: <api-key>'{
"operation": {
"operationId": "op_example_ready",
"partnerOperationId": "acme-op-123",
"customerId": "cus_example",
"status": "READY_FOR_MANUAL_REVIEW",
"operationType": "IMPORT_GOODS",
"exchangeModality": "TERM",
"requirementsStatus": "APPROVED",
"requiredDocumentTypes": [
"invoice",
"bill_of_lading",
"packing_list"
],
"missingDocumentTypes": [],
"score0To100": 94,
"score1To10": 10,
"riskLevel": "low",
"createdAt": "2026-05-20T12:00:00.000Z",
"updatedAt": "2026-05-20T12:10:00.000Z"
},
"decisionPack": {
"decisionPackId": "dp_example",
"schemaVersion": 1,
"operationId": "op_example",
"analysisRunId": "job_example",
"status": "DECISION_PACK_READY",
"regulatoryCorpusVersion": "bc-cambio-2026-06-03",
"policyVersion": "braza-policy-2026-05",
"rulesVersion": "payfi-rules-0.3.1",
"modelProfile": "cheap-default-v1",
"operationFacts": {
"operationId": "op_example",
"operationType": "IMPORT_GOODS",
"exchangeModality": "TERM",
"declaredAmount": "80000",
"currency": "USD"
},
"documentCoverage": [
{
"documentType": "invoice",
"criticality": "critical",
"status": "present",
"documentIds": [
"doc_example"
],
"reasonCodes": [],
"citations": [
{
"citationId": "cit_requirement_invoice",
"sourceType": "REGULATION",
"sourceId": "documentos-por-modalidade.md",
"sourceTitle": "Documentos por modalidade",
"usedFor": "DOCUMENT_REQUIREMENT",
"sourceStatus": "FOUND"
}
]
}
],
"entityReconciliation": [],
"natureDecision": {
"declaredNatureCode": "12452",
"predictedNatureCode": "12452",
"resolvedNatureCode": "12452",
"status": "CONFIRMED",
"confidence": 0.93,
"alternatives": [],
"rationale": "Nature confirmed by operation facts and documentary evidence.",
"requiresHumanReview": true,
"reasonCodes": [
"NATURE_CONFIRMED"
],
"citations": [
{
"citationId": "cit_nature_example",
"sourceType": "SYSTEM_RULE",
"sourceId": "payfi-rules-0.3.1",
"usedFor": "NATURE_DECISION",
"sourceStatus": "FOUND"
}
]
},
"regulatoryChecks": [],
"policyChecks": [],
"fraudSignals": [],
"scoreBreakdown": [],
"overallScore": 8.2,
"score0To100": 82,
"riskLevel": "LOW",
"recommendedStatus": "READY_FOR_MANUAL_REVIEW",
"reviewPosture": "STANDARD_REVIEW",
"blockingReasons": [],
"warnings": [
"MANUAL_REVIEW_REQUIRED"
],
"actionItems": [],
"citations": [],
"rawResultRedacted": {
"workflow": "PayFi Operation Decision Engine",
"deterministic": true
},
"processingTraceEvents": [
{
"source": "workflow",
"stageKey": "decision_engine.output",
"status": "SUCCEEDED",
"sequence": 420
}
],
"createdAt": "2026-06-03T15:00:00.000Z"
},
"documentAnalyses": [
{
"documentId": "doc_invoice",
"documentType": "invoice",
"originalFileName": "invoice-2026-001.pdf",
"documentStatus": "PROCESSED",
"jobId": "job_invoice",
"jobStatus": "SUCCEEDED",
"jobAttempts": 1,
"jobError": null,
"score0To100": 94,
"riskLevel": "low",
"flags": {
"validated": [],
"rejected": [],
"additional": [],
"summary": {
"total": 0,
"critical": 0,
"warning": 0,
"info": 0
}
},
"extractedFields": {
"document_type_detected": "invoice",
"invoice_number": "INV-2026-001",
"value": 80000,
"currency": "USD",
"buyer_name": "Acme Ltda"
},
"rawResultRedacted": {
"operation_id": "op_example_ready",
"compliance_score": 94,
"risk_level": "low",
"flags": {
"validated": [],
"rejected": [],
"additional": [],
"summary": {
"total": 0,
"critical": 0,
"warning": 0,
"info": 0
}
},
"extracted_data": {
"document_type_detected": "invoice",
"invoice_number": "INV-2026-001",
"value": 80000,
"currency": "USD"
},
"completeness": {
"is_complete": true,
"missing_documents": [],
"missing_types": []
},
"pipeline_version": "P1",
"processed_at": "2026-05-20T12:05:00.000Z"
},
"createdAt": "2026-05-20T12:00:00.000Z",
"updatedAt": "2026-05-20T12:05:00.000Z",
"resultCreatedAt": "2026-05-20T12:05:00.000Z"
}
]
}Authorizations
Path Parameters
Operation ID.
⌘I