
Statements List
CertifiedList Mercury statements
Statements List
List Mercury statements
Retrieve statements for a specific Mercury depository bank account with automatic cursor-based pagination and filtering.
type: io.kestra.plugin.mercury.statements.ListExamples
List all statements for an account into memory
id: list_mercury_statements
namespace: company.team
tasks:
- id: list_statements
type: io.kestra.plugin.mercury.statements.List
apiToken: "{{ secret('MERCURY_API_TOKEN') }}"
accountId: "4b54e3d6-72aa-4c07-b3c6-9f4a56a64010"
fetchType: FETCH
List statements filtered by period start date range
id: list_statements_filtered
namespace: company.team
tasks:
- id: list_statements
type: io.kestra.plugin.mercury.statements.List
apiToken: "{{ secret('MERCURY_API_TOKEN') }}"
accountId: "4b54e3d6-72aa-4c07-b3c6-9f4a56a64010"
start: "2024-01-01"
end: "2024-03-31"
fetchType: FETCH
Stream all statements for an account to internal storage
id: store_mercury_statements
namespace: company.team
tasks:
- id: store_statements
type: io.kestra.plugin.mercury.statements.List
apiToken: "{{ secret('MERCURY_API_TOKEN') }}"
accountId: "4b54e3d6-72aa-4c07-b3c6-9f4a56a64010"
fetchType: STORE
Installation
Our standard Docker images already include this plugin. If you use a -slim image or another setup, install it with the following command:
kestractl plugins get io.kestra.plugin:plugin-mercury --compatible-for $KESTRA_VERSION For kestractl, use your Kestra version with --compatible-for, or specify an exact plugin version.
For Kestra CLI, replace LATEST with a specific version or version range to pin the plugin version.
Properties
accountId *string
Account ID
The unique identifier (UUID) of the Mercury bank account whose statements to list. Depository accounts only; credit and treasury accounts are not supported.
apiToken *string
Mercury API token
API token for authentication with the Mercury API.
assets
Assets this task consumes as inputs or produces as outputs, for lineage tracking and the asset graph (Enterprise Edition). A flow declaring this property on a task is rejected in the open-source edition.
io.kestra.core.models.assets.AssetsDeclaration
IGNOREFAILWARNAsset failure behavior
Behavior applied to the task state when a declared asset fails to render, emit, or be persisted (e.g. a lock conflict): FAIL escalates it to FAILED, WARN (default) warns it if it would otherwise succeed, IGNORE leaves the state untouched.
Whether to auto-register assets referenced dynamically at runtime that are not statically declared in inputs or outputs.
The assets consumed as inputs.
io.kestra.core.models.assets.AssetIdentifier
1The assets produced as outputs.
io.kestra.plugin.ee.assets.Dataset
1150{}1150io.kestra.plugin.ee.assets.File
1150{}1150io.kestra.plugin.ee.assets.Table
1150{}1150io.kestra.plugin.ee.assets.VM
1150{}1150io.kestra.core.models.assets.External
1150{}1150io.kestra.core.models.assets.Custom
11501Custom asset type
{}1150baseUrl string
https://api.mercury.com/api/v1Mercury API base URL
Base URL for the Mercury API. Override for the Mercury sandbox (https://api-sandbox.mercury.com/api/v1). Must use HTTPS, except for loopback hosts (localhost, 127.0.0.1, ::1) during local testing.
end string
End date filter
Latest date to filter statements by period start date. Format: YYYY-MM-DD. Mercury defaults to the current date if omitted or set to a future date. Mercury enforces a maximum range of 3 months between start and end.
fetchType string
FETCHSTOREFETCHFETCH_ONENONEFetch mode
Controls how results are returned: FETCH to return all rows in memory, FETCH_ONE for the first row, STORE to stream records as ION into internal storage, or NONE to skip collecting outputs.
limit integerstring
1000Results per page
Maximum number of statements to return per page. Minimum 1, maximum 1000. Default is 1000.
order string
ASCDESCSort order
Sort order of the returned records. Allowed values: ASC or DESC. Defaults to ASC for accounts, cards, and recipients; defaults to DESC for statements.
pageCap integerstring
100Maximum pages to retrieve
Safety cap on the number of pages fetched during pagination. Minimum 1. Default is 100.
start string
Start date filter
Earliest date to filter statements by period start date. Format: YYYY-MM-DD. Mercury enforces a maximum range of 3 months between start and end.
Outputs
row
The first statement fetched
The first statement retrieved. Only populated when fetchType is FETCH_ONE.
io.kestra.plugin.mercury.model.Statement
Account number
Bank account number for the depository account associated with this statement. Sensitive banking details; never log.
Company legal address
Registered legal address of the company associated with the account. Sensitive personal or business data; never log.
io.kestra.plugin.mercury.model.Recipient-Address
Address line 1
Primary street address line.
Address line 2
Secondary street address line (apartment, suite, unit, etc.).
City
City of the address.
Country code
Two-letter ISO 3166-1 alpha-2 country code.
Address name
Name associated with this address, if present.
Postal code
Postal or ZIP code.
Region
State, province, or region code.
Company legal name
Legal name of the entity that owns the depository account.
Download URL
Download URL for the statement document. May contain signed or credentialed parameters; never log.
Employer identification number
Federal Employer Identification Number (EIN) or tax identification number. Sensitive tax details; never log.
date-timeEnd date
End date and time of the statement period in UTC.
Ending balance
Ending ledger balance of the account for the statement period in USD.
Statement ID
Unique identifier (UUID) of the statement.
Routing number
American Bankers Association (ABA) routing transit number for the depository account. Sensitive banking details; never log.
date-timeStart date
Start date and time of the statement period in UTC.
Transactions
List of transaction summary records included in this statement period.
io.kestra.plugin.mercury.model.Statement-TransactionEntry
date-timeCreation timestamp
UTC timestamp when the transaction was initiated or created.
Transaction ID
Unique identifier (UUID) of the transaction.
date-timePosted timestamp
UTC timestamp when the transaction was posted to the ledger, or null if pending.
rows array
The statements fetched
List of retrieved statements. Only populated when fetchType is FETCH.
io.kestra.plugin.mercury.model.Statement
Account number
Bank account number for the depository account associated with this statement. Sensitive banking details; never log.
Company legal address
Registered legal address of the company associated with the account. Sensitive personal or business data; never log.
io.kestra.plugin.mercury.model.Recipient-Address
Address line 1
Primary street address line.
Address line 2
Secondary street address line (apartment, suite, unit, etc.).
City
City of the address.
Country code
Two-letter ISO 3166-1 alpha-2 country code.
Address name
Name associated with this address, if present.
Postal code
Postal or ZIP code.
Region
State, province, or region code.
Company legal name
Legal name of the entity that owns the depository account.
Download URL
Download URL for the statement document. May contain signed or credentialed parameters; never log.
Employer identification number
Federal Employer Identification Number (EIN) or tax identification number. Sensitive tax details; never log.
date-timeEnd date
End date and time of the statement period in UTC.
Ending balance
Ending ledger balance of the account for the statement period in USD.
Statement ID
Unique identifier (UUID) of the statement.
Routing number
American Bankers Association (ABA) routing transit number for the depository account. Sensitive banking details; never log.
date-timeStart date
Start date and time of the statement period in UTC.
Transactions
List of transaction summary records included in this statement period.
io.kestra.plugin.mercury.model.Statement-TransactionEntry
date-timeCreation timestamp
UTC timestamp when the transaction was initiated or created.
Transaction ID
Unique identifier (UUID) of the transaction.
date-timePosted timestamp
UTC timestamp when the transaction was posted to the ledger, or null if pending.
size integer
The total number of statements returned
For FETCH this matches the size of rows, for FETCH_ONE 0 or 1, for STORE the count of stored records, and 0 for NONE.
uri string
uriURI of stored results
The URI of the file containing ION-formatted records in internal storage. Only populated when fetchType is STORE.