Skip to main content

Suggested Actions Coming Soon

A suggested action isn't carried out immediately — it's a suggestion your organization creates for a customer to review and explicitly approve before it takes effect. In the API, this object is called an intent — you'll see it as the /intents endpoints, and as a specific type value such as paymentIntent (just one example of a supported suggestion type) throughout this reference. Use it whenever your org wants to propose something for a customer — the customer stays in control: they can approve the suggestion as-is, edit some of the details before approving, or decline it outright. Your organization gets a clear view of each suggestion's status through a set of APIs and webhook events, so you can reflect that status in your product.

Overview page with suggested actions surfaced to the customer

How it works

  1. Your organization creates a suggested action, using your org API token. It sits in Created status, waiting on the customer to take action (approve/decline it).
  2. The customer reviews the suggestion, using their own session token, and either:
    • Approves — Approving is what triggers execution. Optionally, the customer edits some of the details needed to complete it (editable fields are action-dependent).
    • Declines — Rejecting a suggestion is final.
  3. Cancel — your organization can cancel the action at any point while it's still in Created status.
  4. Once approved, Unit moves the action through Processing to Completed automatically as it executes. If it fails, the action moves to Failed and can be approved again to retry.

Lifecycle

Created --(customer approves)--> Approved → Processing → Completed
Created --(customer declines)--> Declined (terminal)
Created --(org cancels)--------> Cancelled (terminal)
Created --(60 days pass)-------> Expired (terminal)

Processing, Completed, and Failed are reached automatically once the underlying action executes — there's no endpoint to set them directly; they're a side effect of the customer approving it.

Expiry

A suggestion that has not been acted on automatically moves to Expired after 60 days in Created status. Expiry is terminal — the customer can no longer approve or decline the suggestion, and your organization can no longer cancel it. Create a new suggestion if the action is still needed.

Decline vs. Cancel

Both end the flow from Created, but from different sides. Decline is triggered by the customer — they've reviewed the org's suggestion and rejected it. Cancel is triggered by your organization — you're withdrawing a suggestion, typically before the customer has acted on it.


Supported Suggestion Types

Every suggestion — regardless of type — is created and approved through the type-specific endpoints below, and fetched, listed, declined, or cancelled through the generic endpoints at the bottom of this page. What changes per type is the type value in the JSON:API body and the attributes it accepts and returns. Today, Managed Banking supports one suggestion type, with more on the way:

Suggested Account Creation Coming Soon

A suggestion for your organization to propose opening a new account on the customer's behalf, which the customer reviews and approves before it's created. Not yet available — endpoints and attributes will be documented here once it ships.

Suggested Split Income Rule Coming Soon

A suggestion for your organization to propose automatically splitting incoming funds, which the customer reviews and approves before it takes effect. Not yet available — endpoints and attributes will be documented here once it ships.

Suggested Payment

Suggested payment is not a payment, it is a suggested payment request. Customers must review and approve before submitting. When your organization wants to propose a payment (rent, a bill, a scheduled transfer, etc.) without directly moving the customer's money, the customer stays in control: they can approve the suggestion as-is, edit some of the payment details before approving, or decline it outright. The organization will have a clear view of the payment status through a set of APIs allowing you to update data displayed in your product.

A suggested payment (type: paymentIntent) is created with an amount, a counterparty, and either a customer or account. When the customer approves it, they can edit the payment type and the counterparty's routing/account numbers — but not the title, description, or amount, which are set by your organization at creation.

Suggested payment review screen, as customers see it in the Managed Solution component

Create Payment Suggestion

Called by your organization (org API token), as a suggestion the customer must approve. Create a new payment suggestion - a payment suggestion that must be explicitly approved by the customer before it is submitted to a payment rail. Exactly one of customer or account must be provided.

VerbPOST
URLhttps://api.s.unit.sh/intents
Required Scopeintents-write
Data TypepaymentIntent
Timeout (Seconds)5

Attributes

NameTypeDescription
title RequiredstringA short title for the suggestion (maximum of 20 characters).
description RequiredstringA description of the suggestion (maximum of 60 characters).
amount RequiredintegerThe amount (in cents). Must be a positive number.
counterparty.name RequiredstringThe name of the counterparty (maximum of 50 characters).
counterparty.routingNumber OptionalstringThe counterparty's routing number.
counterparty.accountNumber OptionalstringThe counterparty's account number.
paymentType OptionalstringThe type of payment. Currently only Ach is supported.
tags OptionalobjectSee Tags.
idempotencyKey OptionalstringSee Idempotency.

Relationships

NameTypeDescription
customerOptional, JSON:API RelationshipThe Customer the payment is being suggested to. Required if account is not provided.
accountOptional, JSON:API RelationshipThe Deposit Account the payment is being suggested for. Required if customer is not provided.
Note

Exactly one of customer or account must be provided — providing both or neither returns a 400 error.

Example Request:

curl -X POST 'https://api.s.unit.sh/intents' \
-H 'Content-Type: application/vnd.api+json' \
-H 'Authorization: Bearer ${TOKEN}' \
--data-raw '{
"data": {
"type": "paymentIntent",
"attributes": {
"title": "Monthly rent",
"description": "Rent for October",
"amount": 100000,
"counterparty": {
"name": "Landlord LLC",
"routingNumber": "021000021",
"accountNumber": "123456789"
},
"idempotencyKey": "unique-idempotency-key"
},
"relationships": {
"customer": {
"data": {
"type": "customer",
"id": "10014"
}
}
}
}
}'

Response

Returns the created payment suggestion, in Created status.

Response is a JSON:API document.

200 OK

NameTypeDescription
id RequiredstringIdentifier of the payment suggestion resource.
type RequiredstringType of the payment suggestion resource. The value is always paymentIntent.
attributes RequiredJSON ObjectJSON object representing the payment suggestion data.
relationships RequiredJSON:API RelationshipsDescribes relationships between the payment suggestion resource and other resources.

Attributes

NameTypeDescription
title RequiredstringThe title of the suggestion.
description RequiredstringThe description of the suggestion.
amount RequiredintegerThe amount (cents) of the suggestion.
counterparty RequiredobjectThe counterparty of the suggestion.
paymentType OptionalstringThe type of payment.
status RequiredstringThe status of the suggestion. One of Created, Approved, Declined, Cancelled, Processing, Completed, Failed, Expired.
approvedAt OptionalstringThe date the suggestion was approved. Present once status is Approved or later.
declinedAt OptionalstringThe date the suggestion was declined. Present only when status is Declined.
failureReason OptionalstringPresent only when status is Failed.
tags OptionalobjectSee Tags.
createdAt RequiredstringThe date the suggestion was created.
updatedAt RequiredstringThe date the suggestion was last updated.

Relationships

NameTypeDescription
customer RequiredOptional, JSON:API RelationshipThe Customer the suggestion belongs to.
account RequiredOptional, JSON:API RelationshipThe Deposit Account associated with the suggestion, once known.

Example Response:

{
"data": {
"type": "paymentIntent",
"id": "50001",
"attributes": {
"title": "Monthly rent",
"description": "Rent for October",
"amount": 100000,
"counterparty": {
"name": "Landlord LLC",
"routingNumber": "021000021",
"accountNumber": "123456789"
},
"status": "Created",
"tags": {},
"createdAt": "2023-10-20T10:15:22.123Z",
"updatedAt": "2023-10-20T10:15:22.123Z"
},
"relationships": {
"customer": {
"data": {
"type": "customer",
"id": "10014"
}
}
}
}
}

Approve Payment Suggestion

Called by the customer, using their own session token, to accept a suggested payment — the customer can edit the payment type and counterparty's bank details here, but not the title, description, or amount set by the org. Only allowed while the suggestion is in Created status.

VerbPOST
URLhttps://api.s.unit.sh/intents/:intentId/approve
Required Scopeintents-write
Data TypepaymentIntent
Timeout (Seconds)5

Attributes

NameTypeDescription
account Requiredstring The ID of the Deposit Account the customer wants to pay from.
paymentType OptionalstringOverrides the payment type set at creation. Currently only Ach is supported — approving with any other value returns a 400 error.
counterparty.routingNumber OptionalstringOverrides the counterparty's routing number set at creation.
counterparty.accountNumber OptionalstringOverrides the counterparty's account number set at creation.
idempotencyKey OptionalstringSee Idempotency.
Note

For Ach payment suggestions, counterparty.routingNumber and counterparty.accountNumber must be resolvable — either set by the org at creation or supplied by the customer here — otherwise the request fails with a 400 error.

Example Request:

curl -X POST 'https://api.s.unit.sh/intents/50001/approve' \
-H 'Content-Type: application/vnd.api+json' \
-H 'Authorization: Bearer ${TOKEN}' \
--data-raw '{
"data": {
"type": "paymentIntent",
"attributes": {
"account": "10004",
"paymentType": "Ach",
"counterparty": {
"routingNumber": "021000021",
"accountNumber": "123456789"
},
"idempotencyKey": "unique-idempotency-key"
}
}
}'

Response

Returns the payment suggestion with status Approved and approvedAt set.

Response is a JSON:API document.

200 OK

NameTypeDescription
id RequiredstringIdentifier of the payment suggestion resource.
type RequiredstringType of the payment suggestion resource. The value is always paymentIntent.
attributes RequiredJSON ObjectJSON object representing the payment suggestion data.
relationships RequiredJSON:API RelationshipsDescribes relationships between the payment suggestion resource and other resources.

Attributes

NameTypeDescription
title RequiredstringThe title of the suggestion.
description RequiredstringThe description of the suggestion.
amount RequiredintegerThe amount (cents) of the suggestion.
counterparty RequiredobjectThe counterparty of the suggestion.
paymentType RequiredstringThe type of payment.
status RequiredstringThe status of the suggestion. Always Approved in this response.
approvedAt RequiredstringThe date the customer approved the suggestion.
tags OptionalobjectSee Tags.
createdAt RequiredstringThe date the suggestion was created.
updatedAt RequiredstringThe date the suggestion was last updated.

Relationships

NameTypeDescription
customer RequiredOptional, JSON:API RelationshipThe Customer the suggestion belongs to.
account RequiredJSON:API RelationshipThe Deposit Account the payment will be made from.
payment RequiredOptional, JSON:API RelationshipThe Payment created as a result of approving this suggestion. Present once the underlying payment has been created.

Example Response:

{
"data": {
"type": "paymentIntent",
"id": "50001",
"attributes": {
"title": "Monthly rent",
"description": "Rent for October",
"amount": 100000,
"counterparty": {
"name": "Landlord LLC",
"routingNumber": "021000021",
"accountNumber": "123456789"
},
"paymentType": "Ach",
"status": "Approved",
"approvedAt": "2023-10-20T11:02:47.552Z",
"tags": {},
"createdAt": "2023-10-20T10:15:22.123Z",
"updatedAt": "2023-10-20T11:02:47.552Z"
},
"relationships": {
"customer": {
"data": {
"type": "customer",
"id": "10014"
}
},
"account": {
"data": {
"type": "account",
"id": "10004"
}
},
"payment": {
"data": {
"type": "payment",
"id": "20001"
}
}
}
}
}

Generic Suggested Actions

Unlike Create and Approve above, getting, listing, declining, and cancelling a suggestion don't depend on the suggestion's type — they work the same way, through the same four endpoints, no matter which suggestion type is involved.

Get Suggestion

Get a specific suggestion by its ID. Can be called with either your org API token or the customer's own session token.

VerbGET
URLhttps://api.s.unit.sh/intents/:intentId
Required Scopeintents
Timeout (Seconds)5

Example Request:

curl -X GET 'https://api.s.unit.sh/intents/50001' \
-H "Authorization: Bearer ${TOKEN}"

Response

Returns the suggestion details.

Response is a JSON:API document.

200 OK

NameTypeDescription
id RequiredstringIdentifier of the suggestion resource.
type RequiredstringType of the suggestion resource — one of the supported suggestion types, e.g. paymentIntent.
attributes RequiredJSON ObjectJSON object representing the suggestion's data. Which fields are present depends on type — see note below.
relationships RequiredJSON:API RelationshipsDescribes relationships between the suggestion resource and other resources.
Attributes depend on suggestion type

title, description, status, approvedAt, declinedAt, failureReason, tags, createdAt, and updatedAt are present on every suggestion type. The remaining attributes below (amount, counterparty, paymentType) reflect paymentIntent, the only type available today — see Supported Suggestion Types for other types' attributes once they're available.

Attributes

NameTypeDescription
title RequiredstringThe title of the suggestion.
description RequiredstringThe description of the suggestion.
amount RequiredintegerThe amount (cents) of the suggestion.
counterparty RequiredobjectThe counterparty of the suggestion.
paymentType OptionalstringThe type of payment.
status RequiredstringThe status of the suggestion. One of Created, Approved, Declined, Cancelled, Processing, Completed, Failed, Expired.
approvedAt OptionalstringThe date the suggestion was approved. Present once status is Approved or later.
declinedAt OptionalstringThe date the suggestion was declined. Present only when status is Declined.
failureReason OptionalstringPresent only when status is Failed.
tags OptionalobjectSee Tags.
createdAt RequiredstringThe date the suggestion was created.
updatedAt RequiredstringThe date the suggestion was last updated.

Relationships

NameTypeDescription
customer RequiredOptional, JSON:API RelationshipThe Customer the suggestion belongs to.
account RequiredOptional, JSON:API RelationshipThe Deposit Account associated with the suggestion, once known.
payment RequiredOptional, JSON:API RelationshipThe Payment created once the suggestion completes. Absent until then.

Example Response:

{
"data": {
"type": "paymentIntent",
"id": "50001",
"attributes": {
"title": "Monthly rent",
"description": "Rent for October",
"amount": 100000,
"counterparty": {
"name": "Landlord LLC"
},
"status": "Created",
"tags": {},
"createdAt": "2023-10-20T10:15:22.123Z",
"updatedAt": "2023-10-20T10:15:22.123Z"
},
"relationships": {
"customer": {
"data": {
"type": "customer",
"id": "10014"
}
}
}
}
}

List Suggestions

List suggestions, with optional filtering and pagination. Can be called with either your org API token or the customer's own session token.

VerbGET
URLhttps://api.s.unit.sh/intents
Required Scopeintents
Timeout (Seconds)5

Query Parameters

NameTypeDefaultDescription
filter[customerId]string(empty)Optional. Filter suggestions by customer ID.
filter[status][]string(empty)Optional. Filter by one or more statuses: Created, Approved, Declined, Cancelled, Processing, Completed, Failed, Expired. Usage example: filter[status][0]=Created&filter[status][1]=Approved.
sortstring-createdAtOptional. One of createdAt, updatedAt, approvedAt, declinedAt, status (ascending), or the same values prefixed with - for descending.
page[limit]integer100Optional. Maximum number of resources to return.
page[offset]integer0Optional. Number of resources to skip.

Example Request:

curl -X GET 'https://api.s.unit.sh/intents?filter[customerId]=10014&filter[status][]=Created' \
-H "Authorization: Bearer ${TOKEN}"

Response

Returns a paginated list of suggestions with their details.

Response is a JSON:API document.

200 OK

NameTypeDescription
data RequiredArray of suggestionsArray of suggestion resources. Each item's type and attributes follow the same per-type rules as Get Suggestion.

Example Response:

{
"data": [
{
"type": "paymentIntent",
"id": "50001",
"attributes": {
"title": "Monthly rent",
"description": "Rent for October",
"amount": 100000,
"counterparty": {
"name": "Landlord LLC"
},
"status": "Created",
"tags": {},
"createdAt": "2023-10-20T10:15:22.123Z",
"updatedAt": "2023-10-20T10:15:22.123Z"
},
"relationships": {
"customer": {
"data": {
"type": "customer",
"id": "10014"
}
}
}
}
],
"meta": {
"pagination": {
"total": 1,
"limit": 100,
"offset": 0
}
}
}

Decline Suggestion

Called by the customer, using their own session token, to reject a suggested action. Works the same way for every suggestion type. Only allowed while the suggestion is in Created status; declining is terminal. To have your organization withdraw a suggestion instead, use Cancel Suggestion.

VerbPOST
URLhttps://api.s.unit.sh/intents/:intentId/decline
Required Scopeintents-write
Timeout (Seconds)5

Attributes

NameTypeDescription
idempotencyKey OptionalstringSee Idempotency.

Example Request:

curl -X POST 'https://api.s.unit.sh/intents/50001/decline' \
-H 'Content-Type: application/vnd.api+json' \
-H 'Authorization: Bearer ${TOKEN}' \
--data-raw '{
"data": {
"type": "paymentIntent",
"attributes": {
"idempotencyKey": "unique-idempotency-key"
}
}
}'
Note

The request's data.type must match the actual type of the suggestion at :intentId (paymentIntent in this example) — see Supported Suggestion Types.

Response

Returns the declined suggestion, with status Declined and declinedAt set.

Response is a JSON:API document.

200 OK

NameTypeDescription
id RequiredstringIdentifier of the suggestion resource.
type RequiredstringType of the suggestion resource — one of the supported suggestion types, e.g. paymentIntent.
attributes RequiredJSON ObjectJSON object representing the suggestion's data. Which fields are present depends on type — see note below.
relationships RequiredJSON:API RelationshipsDescribes relationships between the suggestion resource and other resources.
Attributes depend on suggestion type

title, description, status, declinedAt, tags, createdAt, and updatedAt are present on every suggestion type. The remaining attributes below (amount, counterparty) reflect paymentIntent, the only type available today — see Supported Suggestion Types for other types' attributes once they're available.

Attributes

NameTypeDescription
title RequiredstringThe title of the suggestion.
description RequiredstringThe description of the suggestion.
amount RequiredintegerThe amount (cents) of the suggestion.
counterparty RequiredobjectThe counterparty of the suggestion.
status RequiredstringThe status of the suggestion. Always Declined in this response.
declinedAt RequiredstringThe date the customer declined the suggestion.
tags OptionalobjectSee Tags.
createdAt RequiredstringThe date the suggestion was created.
updatedAt RequiredstringThe date the suggestion was last updated.

Relationships

NameTypeDescription
customer RequiredOptional, JSON:API RelationshipThe Customer the suggestion belongs to.

Example Response:

{
"data": {
"type": "paymentIntent",
"id": "50001",
"attributes": {
"title": "Monthly rent",
"description": "Rent for October",
"amount": 100000,
"counterparty": {
"name": "Landlord LLC"
},
"status": "Declined",
"declinedAt": "2023-10-20T11:02:47.552Z",
"tags": {},
"createdAt": "2023-10-20T10:15:22.123Z",
"updatedAt": "2023-10-20T11:02:47.552Z"
},
"relationships": {
"customer": {
"data": {
"type": "customer",
"id": "10014"
}
}
}
}
}

Cancel Suggestion

Called by your organization, using your org API token, to withdraw a suggested action before the customer has acted on it. Works the same way for every suggestion type. Only allowed while the suggestion is in Created status; cancelling is terminal. To let the customer reject the suggestion themselves, see Decline Suggestion.

VerbPOST
URLhttps://api.s.unit.sh/intents/:intentId/cancel
Required Scopeintents-write
Timeout (Seconds)5

Attributes

NameTypeDescription
idempotencyKey OptionalstringSee Idempotency.

Example Request:

curl -X POST 'https://api.s.unit.sh/intents/50001/cancel' \
-H 'Content-Type: application/vnd.api+json' \
-H 'Authorization: Bearer ${TOKEN}' \
--data-raw '{
"data": {
"type": "paymentIntent",
"attributes": {
"idempotencyKey": "unique-idempotency-key"
}
}
}'
Note

The request's data.type must match the actual type of the suggestion at :intentId (paymentIntent in this example) — see Supported Suggestion Types.

Response

Returns the cancelled suggestion, with status Cancelled.

Response is a JSON:API document.

200 OK

NameTypeDescription
id RequiredstringIdentifier of the suggestion resource.
type RequiredstringType of the suggestion resource — one of the supported suggestion types, e.g. paymentIntent.
attributes RequiredJSON ObjectJSON object representing the suggestion's data. Which fields are present depends on type — see note below.
relationships RequiredJSON:API RelationshipsDescribes relationships between the suggestion resource and other resources.
Attributes depend on suggestion type

title, description, status, tags, createdAt, and updatedAt are present on every suggestion type. The remaining attributes below (amount, counterparty) reflect paymentIntent, the only type available today — see Supported Suggestion Types for other types' attributes once they're available.

Attributes

NameTypeDescription
title RequiredstringThe title of the suggestion.
description RequiredstringThe description of the suggestion.
amount RequiredintegerThe amount (cents) of the suggestion.
counterparty RequiredobjectThe counterparty of the suggestion.
status RequiredstringThe status of the suggestion. Always Cancelled in this response.
tags OptionalobjectSee Tags.
createdAt RequiredstringThe date the suggestion was created.
updatedAt RequiredstringThe date the suggestion was last updated.

Relationships

NameTypeDescription
customer RequiredOptional, JSON:API RelationshipThe Customer the suggestion belongs to.

Example Response:

{
"data": {
"type": "paymentIntent",
"id": "50001",
"attributes": {
"title": "Monthly rent",
"description": "Rent for October",
"amount": 100000,
"counterparty": {
"name": "Landlord LLC"
},
"status": "Cancelled",
"tags": {},
"createdAt": "2023-10-20T10:15:22.123Z",
"updatedAt": "2023-10-20T11:02:47.552Z"
},
"relationships": {
"customer": {
"data": {
"type": "customer",
"id": "10014"
}
}
}
}
}