Skip to content

Update a credit line

PATCH/api/v1/credit/lines/{credit_line_id}

Change the repayment account, AutoPay, the credit limit, or the status.

Supplying credit_limit_cents re-approves the line: it emits credit.line.limit_changed and pushes the new available credit to the issuer. This is the write behind Request More Funding.

Supplying status needs reason and emits credit.line.suspended, credit.line.reinstated or credit.line.closed. Activating a pending line whose disclosure awaits the merchant's acknowledgement needs acknowledgement_override from an operator.

Operation ID: update_credit_line·View as markdown·OpenAPI slice

Authentication

Bearer token authentication. Pass your DayZero API token in the Authorization header and the target business UUID in x-business-id.

Parameters

Path

credit_line_idstringrequired

Request body

linked_account_namestring

Display name of the merchant's repayment account.

linked_account_maskstring

Last digits of the repayment account.

plaid_account_idstring

The merchant's Plaid account the repayments leave from.

autopay_enabledboolean

Switch AutoPay due events on or off for the line.

merchant_emailstring

Where statements and borrower notices go.

merchant_business_idstring

The borrower's own DayZero business, when it keeps its books here. An underwriting assessment for the line measures this business. Must be a business the caller can access.

merchant_legal_namestring

The merchant's legal entity name, as printed on disclosures. Cannot be cleared while the program's compliance.enabled is true.

merchant_statestring

Two-letter US state, DC or territory code of the merchant. Selects the disclosure template. Cannot be cleared while the program's compliance.enabled is true.

merchant_addressMerchantAddress

The merchant's registered address. Cannot be cleared while the program's compliance.enabled is true.

statusCreditLineStatusEnum

Move the line between pending, active, suspended and closed. A change needs reason. Suspending, reinstating (suspended back to active) and closing emit credit.line.suspended, credit.line.reinstated and credit.line.closed. Closing is refused for an API token when the program's limit_change_policy is console_only. Sending the status the line already has changes nothing. Activating a pending line pushes its available credit to the issuer (or emits credit.line.limit_changed for partner-managed cards); while its disclosure awaits the merchant's acknowledgement it is refused (CREDIT_617) unless an operator sends acknowledgement_override.

reasonstring

Why the status changed. Required with a status change; carried on the event and returned as status_reason on the line.

acknowledgement_overrideAcknowledgementOverride

Activate a pending line whose disclosure awaits the merchant's acknowledgement without it. Operators in the console only: an API token sending it is 403 (CREDIT_618). The disclosure becomes overridden with who, when and reason, and credit.disclosure.overridden is emitted. Ignored on any other status change, or when nothing awaits acknowledgement.

reason_codestring

Optional category of a suspension or closure: credit_risk, delinquency, fraud, merchant_request or administrative. On a program with adverse-action notices on, the first three record an adverse action.

credit_limit_centsinteger

Re-approved limit, in cents. This is the write behind Request More Funding (§6.1) and behind a risk-led reduction. Changing it emits credit.line.limit_changed and pushes the new available credit to the issuer, so the card starts declining at the new limit. A reduction below the current balance is allowed — available credit floors at zero and existing loans keep their own terms. Follows the program's limit_change_policy: under approval_required every caller gets 409 (submit a limit-change request instead); under console_only an API token gets 403.

limit_change_reasonstring

Why the limit moved. Carried on the event and the ledger so an increase can be traced to the decision behind it.

Responses

200Successful Response

successboolean
messagestring
codestring
dataCreditLineResponse

400Bad Request - Invalid input

errorstringrequired

Error category: validation_error, unauthorized, forbidden, not_found, conflict, rate_limited, server_error, or service_unavailable.

messagestringrequired

Human-readable explanation, safe to show to end users.

codestringrequired

Stable machine-readable code in CATEGORY_NNN form (e.g. NOT_FOUND_006, AUTH_010, GEN_002).

request_idstring

Correlation id for support requests. Echoes the x-request-id request header when one was supplied.

errorsobject

Field-level validation messages keyed by field name. Present on 400/422 validation failures only.

401Unauthorized - Missing or expired token, an MCP OAuth token used against the REST API, or no access to this business

errorstringrequired

Error category: validation_error, unauthorized, forbidden, not_found, conflict, rate_limited, server_error, or service_unavailable.

messagestringrequired

Human-readable explanation, safe to show to end users.

codestringrequired

Stable machine-readable code in CATEGORY_NNN form (e.g. NOT_FOUND_006, AUTH_010, GEN_002).

request_idstring

Correlation id for support requests. Echoes the x-request-id request header when one was supplied.

errorsobject

Field-level validation messages keyed by field name. Present on 400/422 validation failures only.

403Forbidden - Insufficient permissions

errorstringrequired

Error category: validation_error, unauthorized, forbidden, not_found, conflict, rate_limited, server_error, or service_unavailable.

messagestringrequired

Human-readable explanation, safe to show to end users.

codestringrequired

Stable machine-readable code in CATEGORY_NNN form (e.g. NOT_FOUND_006, AUTH_010, GEN_002).

request_idstring

Correlation id for support requests. Echoes the x-request-id request header when one was supplied.

errorsobject

Field-level validation messages keyed by field name. Present on 400/422 validation failures only.

404Not Found - Resource does not exist

errorstringrequired

Error category: validation_error, unauthorized, forbidden, not_found, conflict, rate_limited, server_error, or service_unavailable.

messagestringrequired

Human-readable explanation, safe to show to end users.

codestringrequired

Stable machine-readable code in CATEGORY_NNN form (e.g. NOT_FOUND_006, AUTH_010, GEN_002).

request_idstring

Correlation id for support requests. Echoes the x-request-id request header when one was supplied.

errorsobject

Field-level validation messages keyed by field name. Present on 400/422 validation failures only.

422Validation Error

errorstringrequired

Error category: validation_error, unauthorized, forbidden, not_found, conflict, rate_limited, server_error, or service_unavailable.

messagestringrequired

Human-readable explanation, safe to show to end users.

codestringrequired

Stable machine-readable code in CATEGORY_NNN form (e.g. NOT_FOUND_006, AUTH_010, GEN_002).

request_idstring

Correlation id for support requests. Echoes the x-request-id request header when one was supplied.

errorsobject

Field-level validation messages keyed by field name. Present on 400/422 validation failures only.