Skip to main content
POST
/
api
/
receipts
/
commit
Commit receipt
curl --request POST \
  --url https://api.ai2fin.com/api/receipts/commit \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "assetUrl": "<string>",
  "mimeType": "<string>",
  "size": 123,
  "extracted": {
    "merchant": "<string>",
    "dateISO": "2023-12-25",
    "currency": "<string>",
    "total": 123,
    "tax": 123,
    "tip": 123,
    "lineItems": [
      {
        "description": "<string>",
        "quantity": 123,
        "unitPrice": 123,
        "amount": 123
      }
    ]
  },
  "action": {
    "type": "link",
    "transactionId": "<string>",
    "updateFields": {}
  }
}'
{
  "success": true,
  "data": {
    "entityType": "<string>",
    "entityId": "<string>"
  }
}

Authorizations

Authorization
string
header
required

JWT token obtained from /api/auth/login endpoint

Body

application/json
assetUrl
string
required
mimeType
string
required
size
integer
required
action
object
required
extracted
object

Response

200 - application/json

Receipt committed

success
boolean
data
object