Weavr.Sends (Weavr v1.0.0)

Copy Markdown View Source

Send transactions — Outgoing Wire Transfers to different identities.

All paths confirmed from Weavr's published docs.

A Send (Outgoing Wire Transfer) moves funds from a managed account or managed card belonging to one identity to an instrument belonging to a different identity, or to an external bank account. For moving funds between instruments of the same identity, use Weavr.Transfers.

Confirmed endpoints

  • POST /sends — create an outgoing wire transfer
  • GET /sends/{id} — get send details
  • GET /sends — list sends

Source and destination

  • "source" — object with "type" ("managed_accounts" or "managed_cards") and "id"
  • "destination" — object with "type" and "id", where the destination can be a managed instrument of another identity, or an external bank account

Notes

  • Amounts in minor units (1000 = £10.00).
  • "profileId" is required.
  • Sends support idempotency-ref.
  • In UK programmes, sends may be subject to Linked Accounts rules — see Weavr.LinkedAccounts.

Summary

Functions

Creates an Outgoing Wire Transfer (Send).

Fetches a send (OWT) by id. GET /sends/{id}.

Lists sends (OWTs) for the authenticated identity.

Functions

create(config, attrs, opts \\ [])

@spec create(Weavr.Config.t(), map(), keyword()) ::
  {:ok, map()} | {:error, Weavr.Error.t()}

Creates an Outgoing Wire Transfer (Send).

POST /sends

Required fields in attrs:

  • "profileId" — from Multi Portal
  • "source" — instrument object: %{"type" => "managed_accounts", "id" => "..."}
  • "destination" — destination object (instrument or external account)
  • "destinationAmount"%{"currency" => "GBP", "amount" => 5000}

Optional: "description", "tag".

get(config, id, opts \\ [])

@spec get(Weavr.Config.t(), String.t(), keyword()) ::
  {:ok, map()} | {:error, Weavr.Error.t()}

Fetches a send (OWT) by id. GET /sends/{id}.

list(config, opts \\ [])

@spec list(
  Weavr.Config.t(),
  keyword()
) :: {:ok, map()} | {:error, Weavr.Error.t()}

Lists sends (OWTs) for the authenticated identity.

GET /sends — supports opts[:filters] for offset, limit, profileId, state, createdFrom, createdTo, tag.