Your organisation's sweeps, with how each last ran
const url = 'https://api.sotirea.com/v1/sweeps';const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url https://api.sotirea.com/v1/sweeps \ --header 'Authorization: Bearer <token>'Each sweep gathers what your customers’ deposit vaults hold free into one of your own vaults, every 15 minutes: every vault opened with a reference, or the vaults it names, never the vault it sweeps into. A vault is swept once it holds the minimum, unless one sweep would cost more than the fee ceiling or the gas pool cannot pay; then it waits. Lists active sweeps, proposals waiting for a second person, and recent decisions. A sweep is a payment with purpose sweep; its arrival is a deposit with sweep true, not a customer paying you.
Authorizations
Section titled “Authorizations”Responses
Section titled “Responses”Done.
object
object
Native, or a token’s contract.
The network’s coin, which pays the fees.
The asset’s decimals; absent for a token whose contract has not been read.
Whether it sweeps every vault opened with a reference: each customer’s deposit vault, including those opened later.
The most one sweep may cost in network fees, in the network coin’s smallest unit.
object
What happened, vault by vault, in words.
Swept; nothing (no vault held the minimum); skipped (every sweep worth making was held back: the fee above the ceiling, or the gas pool unable to pay); or failed.
When the current run of skips began. After a day, the people who manage sweeps are emailed once.
The least a vault must hold free before it is swept, in the asset’s smallest unit.
The person’s name, or the API key’s when a key proposed it.
Whether an API key proposed it. Nobody who has held that key’s secret may confirm it.
The rule a proposal changes or retires.
A proposal to stop the rule it replaces.
Confirmed by its proposer alone, because nobody else in your organisation manages sweeps.
The vaults it sweeps when it names them; empty when it sweeps every vault opened with a reference. Never the destination.
object
Active, proposed (waiting for a second person), declined or retired.
object
Quote it when asking about a request; it is in the X-Request-Id header too.
Example
{ "success": true}default
Section titled “default”Refused or failed, in words a person can act on.
object
object
object
object
Quote it when asking about a request.
Example
{ "success": false}