Registers a webhook-like HTTP endpoint that Treasury Prime calls
synchronously, in real time, for every authorization on a
TreasuryPrime.CardProduct that references it (via the card product's
card_auth_loop_endpoint_id) — letting you accept or reject each card
transaction yourself (e.g. for velocity limits, custom fraud rules, or
balance checks beyond what card_controls supports).
Your endpoint receives an HTTP POST with a TreasuryPrime.CardEvent JSON
body and must respond with an empty JSON body and one of the documented
HTTP status codes within Treasury Prime's response time budget — any
other code, or a timeout, falls back to the default authorization
behavior. See the "Card Auth Loop Endpoint Protocol" guide for the exact
status codes and timing requirements.
Summary
Functions
Registers a new card auth loop endpoint. Required: url.
Deletes a card auth loop endpoint.
Fetches a single card auth loop endpoint by id.
Lists card auth loop endpoints.
Updates a card auth loop endpoint.
Types
Functions
@spec create(TreasuryPrime.Client.t(), map(), keyword()) :: {:ok, t()} | {:error, TreasuryPrime.Error.t()}
Registers a new card auth loop endpoint. Required: url.
@spec create!(TreasuryPrime.Client.t(), map(), keyword()) :: t()
@spec delete(TreasuryPrime.Client.t(), String.t()) :: {:ok, nil} | {:error, TreasuryPrime.Error.t()}
Deletes a card auth loop endpoint.
@spec delete!(TreasuryPrime.Client.t(), String.t()) :: nil
@spec get(TreasuryPrime.Client.t(), String.t()) :: {:ok, t()} | {:error, TreasuryPrime.Error.t()}
Fetches a single card auth loop endpoint by id.
@spec get!(TreasuryPrime.Client.t(), String.t()) :: t()
@spec list(TreasuryPrime.Client.t(), map()) :: {:ok, TreasuryPrime.Page.t()} | {:error, TreasuryPrime.Error.t()}
Lists card auth loop endpoints.
@spec list!(TreasuryPrime.Client.t(), map()) :: TreasuryPrime.Page.t()
@spec update(TreasuryPrime.Client.t(), String.t(), map()) :: {:ok, t()} | {:error, TreasuryPrime.Error.t()}
Updates a card auth loop endpoint.
@spec update!(TreasuryPrime.Client.t(), String.t(), map()) :: t()