API reference › Finance › Invoices

Update invoice inline fields

PUT /v1/finance/invoices/{id}

Scope
finance:edit
Roles
admin, scheduler

Updates one or more fields from the list or detail screen without a full save: payment terms, financial status, due date, published flag, or a partial payment. Every field is optional; only the ones sent change.

Parameters

Path parameters

NameTypeDescription
id requiredstring

Invoice ID

Example INV-EWDM3W.

Headers

NameTypeDescription
Idempotency-Keystring

Retry key for a partial payment, max 255 characters. Wins over the body's idempotency_key. A partial payment needs this or transaction_id.

Example b2f6c1d4-8e0a-4b8b-9c1d-2a7e5f3c9d10.

Every call also sends Authorization and X-Tenant-ID; see Getting started.

Request body required

17 top-level fields; 3 hold nested fields, listed below.

FieldTypeDescription
override_locksboolean or null

Edit a paid document past its locks. Send on the retry after a save asks.

override_reasonobject (2 nested)
override_reason_textstring or null

max length 1000.

override_deliverystring or null

One of: internal_only, send_updated.

confirmationboolean or null

Confirms the resend prompt a save on a sent document raises.

resend_deliverystring or null

One of: send_updated, internal_only, send_now, save_only.

overpayment_confirmationboolean or null

Accept a payment that exceeds the balance due.

payment_termsobject or null (3 nested)
statusobject or null (3 nested)

Target financial status. A move that needs confirmation returns 422 with requires_confirmation=true.

due_datestring (date)

Example 2025-03-15.

reasonstring or null

Why the status changed, such as a rejection reason.

max length 500.

is_publishedboolean

Example false.

partial_payment_amountnumber or null

Records a partial payment. Requires the Idempotency-Key header, idempotency_key or transaction_id.

min 0. Example 50.

payment_amountnumber or null

min 0.

payment_methodstring or null

max length 50. Example check.

transaction_idstring or null

max length 255. Example CHK-10042.

idempotency_keystring or null

Body fallback for the Idempotency-Key header.

max length 255.

Nested fields

override_reason 2 fields
FieldTypeDescription
override_reason.idinteger or string

Example 1.

override_reason.labelstring or null

Example Example.

payment_terms 3 fields
FieldTypeDescription
payment_terms.idinteger

Example 1.

payment_terms.labelstring

Example Net 15.

payment_terms.isCustomboolean or null

Example false.

status 3 fields
FieldTypeDescription
status.idinteger

Example 4.

status.labelstring

Example Paid.

status.isCustomboolean or null

Example false.

Example

JSON
{
  "override_locks": true,
  "override_reason": {
    "id": 1,
    "label": "Example"
  },
  "override_reason_text": "string",
  "override_delivery": "internal_only",
  "confirmation": true,
  "resend_delivery": "send_updated",
  "overpayment_confirmation": true,
  "payment_terms": {
    "id": 1,
    "label": "Net 15",
    "isCustom": false
  },
  "status": {
    "id": 4,
    "label": "Paid",
    "isCustom": false
  },
  "due_date": "2025-03-15",
  "reason": "string",
  "is_published": false,
  "partial_payment_amount": 50,
  "payment_amount": 0,
  "payment_method": "check",
  "transaction_id": "CHK-10042",
  "idempotency_key": "string"
}

Example request

Shell
curl -X PUT "https://api.fetchfido.ai/v1/finance/invoices/{id}" \
  -H "Authorization: Bearer $FIDO_API_KEY" \
  -H "X-Tenant-ID: $FIDO_TENANT_ID" \
  -H "Idempotency-Key: b2f6c1d4-8e0a-4b8b-9c1d-2a7e5f3c9d10" \
  -H "Content-Type: application/json" \
  -d '{"override_locks":true,"override_reason":{"id":1,"label":"Example"},"override_reason_text":"string","override_delivery":"internal_only","confirmation":true,"resend_delivery":"send_updated","overpayment_confirmation":true,"payment_terms":{"id":1,"label":"Net 15","isCustom":false},"status":{"id":4,"label":"Paid","isCustom":false},"due_date":"2025-03-15","reason":"string","is_published":false,"partial_payment_amount":50,"payment_amount":0,"payment_method":"check","transaction_id":"CHK-10042","idempotency_key":"string"}'

Try it

Responses

200 Invoice updated successfully

Invoice updated successfully. Each field is present only when it applies.

JSON
{
  "success": true,
  "message": "Invoice updated successfully.",
  "data": {
    "id": "INV-EWDM3W",
    "payment_terms": {
      "id": 1,
      "label": "Net 15"
    },
    "status": {
      "id": 2,
      "name": "Sent"
    },
    "due_date": "2025-03-15",
    "is_published": false
  }
}
Response fields (12)
FieldTypeDescription
successboolean

Example true.

messagestring

Example Invoice updated successfully..

dataobject
data.idstring

Example INV-EWDM3W.

data.payment_termsobject

Echo of the payment_terms sent.

data.payment_terms.idinteger

Example 1.

data.payment_terms.labelstring

Example Net 15.

data.statusobject

The status after the change, when it changed.

data.status.idinteger

Example 2.

data.status.namestring

Example Sent.

data.due_datestring

Example 2025-03-15.

data.is_publishedboolean

Example false.

401 Not signed in

Missing, invalid or expired API key.

JSON
{
  "success": false,
  "message": "Invalid API key. Org and user tier keys must send an X-Tenant-ID header naming the organization the key was issued for.",
  "errors": null,
  "code": "API_KEY_MISSING"
}
Response fields (4)
FieldTypeDescription
successboolean

Example false.

messagestring

Example Invalid API key. Org and user tier keys must send an X-Tenant-ID header naming the organization the key was issued for..

errorsany or null

Null on this status.

codestring

Machine-readable reason, for branching on in client code.

One of: API_KEY_MISSING, API_KEY_INVALID, API_KEY_EXPIRED. Example API_KEY_MISSING.

403 Not allowed

Scope, tenant, IP allow-list or RBAC check failed.

JSON
{
  "success": false,
  "message": "You don't have permission to access this endpoint. This API key is missing the 'finance:edit' scope.",
  "errors": null,
  "code": ""
}
Response fields (4)
FieldTypeDescription
successboolean

Example false.

messagestring

Example You don't have permission to access this endpoint. This API key is missing the 'finance:edit' scope..

errorsany or null

Null on this status.

codestring

Always empty on this status.

Example .

404 Not found

Invoice not found

JSON
{
  "success": false,
  "message": "Invoice not found."
}
Response fields (2)
FieldTypeDescription
successboolean

Example false.

messagestring

Example Invoice not found..

422 Validation failed

Validation error

JSON
{
  "success": false,
  "message": "Validation failed",
  "errors": {
    "payment_terms": [
      "Payment terms are invalid."
    ]
  }
}
Response fields (3)
FieldTypeDescription
successboolean

Example false.

messagestring

Example Validation failed.

errorsobject
429 Too many requests

Rate limit exceeded. See Retry-After.

JSON
{
  "success": false,
  "message": "You've exceeded this API key's rate limit of 120 requests per minute. Try again in 37 seconds.",
  "errors": null,
  "code": "RATE_LIMITED"
}
Response fields (4)
FieldTypeDescription
successboolean

Example false.

messagestring

Example You've exceeded this API key's rate limit of 120 requests per minute. Try again in 37 seconds..

errorsany or null

Null on this status.

codestring

Machine-readable reason, for branching on in client code.

One of: RATE_LIMITED. Example RATE_LIMITED.

500 Server error

Unexpected error

JSON
{
  "success": false,
  "errors": "Invoice update failed",
  "message": "An unexpected error occurred ? please try again."
}
Response fields (3)
FieldTypeDescription
successboolean

Example false.

errorsstring or null

Null in production. The exception message only when the application runs with debug on.

Example Invoice update failed.

messagestring

Example An unexpected error occurred ? please try again..