Get Autopays
Use the Get Autopays API endpoint to retrieve the autopays currently scheduled against a customer's line of credit account.
Early AccessCredit API endpoints are currently being finalised as part of ongoing product development. While we do not anticipate significant changes, some interfaces, behaviours, and documentation may be refined before general availability.
The Get Autopays endpoint enables you to retrieve the current autopays on a customer's line of credit account, whichever of the customer's bank accounts each one collects from. Use this endpoint to display a customer's scheduled payments, or to retrieve an autopayId before updating or cancelling an autopay with the Update Autopay endpoint.
By default, the endpoint returns every current autopay on the account. To retrieve a single autopay, include its ID in the autopay_id query parameter.
NoteCreating an autopay does not replace an existing one, so an account can have several current autopays and more than one payment may be scheduled. Completed, failed, cancelled and inactive autopays are not included in the response.
More InformationFor more information about the Accounts endpoints, see: Credit Accounts.
Prerequisites
To integrate calls to the Get Autopays endpoint, you need:
- The
account_idof the line of credit account. This is the Thredd Account ID, returned when a credit application is approved. - To retrieve a single autopay, the
autopayIdof the autopay. This is returned when you create the autopay with the Create Autopay endpoint, and in the response to this endpoint.
Example Request
Retrieve the autopays on an account by making a GET request to the Get Autopays endpoint.
GET {{baseUrl}}/api/v1/credit/accounts/{account_id}/payment/autopay
To retrieve a single autopay, add its ID as a query parameter:
GET {{baseUrl}}/api/v1/credit/accounts/{account_id}/payment/autopay?autopay_id={autopay_id}
Path Parameters
| Parameter | Description |
|---|---|
account_id | string. Required. The unique identifier of the line of credit account. |
Query Parameters
| Parameter | Description |
|---|---|
autopay_id | integer. Optional. The unique identifier of a single current autopay to return. Must be a positive whole number. Omit it to return every current autopay on the account. |
Example Response
A successful request returns a 200 HTTP status code.
All Autopays
If you do not include autopay_id, the response contains every current autopay on the account, most recently created first. If the account has no current autopays, autopays is an empty list.
{
"accountId": "acc_123456",
"autopays": [
{
"autopayId": "789012",
"status": "scheduled",
"autopayType": "recurring",
"recurringPeriods": 12,
"achType": "standard",
"paymentAmountOption": "statement_balance",
"amount": null,
"paymentDate": "2025-02-15",
"frequency": "monthly"
},
{
"autopayId": "654321",
"status": "scheduled",
"autopayType": "single",
"recurringPeriods": null,
"achType": "same_day",
"paymentAmountOption": "other_amount",
"amount": "100.00",
"paymentDate": "2025-02-01",
"frequency": "one_time"
}
]
}Single Autopay
If you include autopay_id, the response contains that autopay as a single Autopay Object, without the accountId and autopays wrapper.
{
"autopayId": "654321",
"status": "scheduled",
"autopayType": "single",
"recurringPeriods": null,
"achType": "same_day",
"paymentAmountOption": "other_amount",
"amount": "100.00",
"paymentDate": "2025-02-01",
"frequency": "one_time"
}{
"detail": "Account mapping not found."
}{
"detail": "Current autopay not found."
}Response Fields
Autopay Response Object
Returned when you do not include autopay_id.
| Attribute | Description |
|---|---|
accountId | string. The unique identifier of the line of credit account the autopays belong to. |
autopays | array. The current autopays on the account, most recently created first. See Autopay Object below. |
Autopay Object
| Attribute | Description |
|---|---|
autopayId | string. The unique identifier of the autopay. Pass this value to the Update Autopay endpoint to update or cancel it. |
status | string. The status of the autopay. See Autopay Status Values below. |
autopayType | string. Whether the autopay is a single payment (single) or a monthly recurring payment (recurring). |
recurringPeriods | integer or null. The number of monthly payments for a recurring autopay. |
achType | string. The ACH transfer speed: standard or same_day. |
paymentAmountOption | string. Which amount the autopay collects. See Payment Amount Option Values below. |
amount | string or null. The payment amount. Only set when paymentAmountOption is other_amount. For every other option, the loan management system calculates the amount when the payment runs. |
paymentDate | string. The date the payment applies on, in YYYY-MM-DD format. |
frequency | string. How often the autopay repeats. See Frequency Values below. |
Autopay Status Values
| Value | Description |
|---|---|
scheduled | The autopay is scheduled and has not yet run. |
completed | The autopay has run successfully. |
failed | The autopay attempt failed. |
cancelled | The autopay was cancelled before it ran. |
unknown | The status of the autopay could not be determined. |
Payment Amount Option Values
| Value | Description |
|---|---|
minimum_payment | Collects the account's current minimum payment. |
statement_balance | Collects the account's most recent statement balance. |
current_balance | Collects the account's current balance at the time the autopay runs. |
past_due | Collects the amount currently past due on the account. |
other_amount | Collects the specific amount on the autopay. |
Frequency Values
| Value | Description |
|---|---|
one_time | The autopay runs once and does not repeat. |
weekly | The autopay repeats every week. |
biweekly | The autopay repeats every two weeks. |
semi_monthly | The autopay repeats twice a month. |
semi_monthly_alt | An alternate twice-a-month schedule. |
monthly | The autopay repeats every month. |
quarterly | The autopay repeats every quarter. |
semi_annually | The autopay repeats every six months. |
annually | The autopay repeats every year. |
custom | A custom repeat schedule. |
Error Messages
If there is a problem with the request, the response returns one of the following errors:
404: Theaccount_iddoes not match an existing account, or theautopay_idis not a current autopay on the account.422: Theautopay_idis not valid, or Thredd could not retrieve the autopays from the loan management system. Try the request again.
{
"detail": "Unable to retrieve the autopay configuration, please try again."
}Updated 15 days ago
