Inttegro (inttegro v0.2.0)

Copy Markdown View Source

The official server-side Elixir SDK for the Inttegro commerce platform.

Inttegro provides APIs for orders and payments, customers, products and prices, purchase intents, payment methods, balances, payouts, refunds, messaging, files, and application administration. This package gives each domain a focused module and decodes responses into namespaced structs.

Architecture

The SDK has four layers:

HTTP envelopes and wire-codec helpers remain internal so callers work with domain values rather than transport details.

First request

client = Inttegro.Client.new!(System.fetch_env!("INTTEGRO_API_KEY"))
request = Inttegro.Orders.LookupRequest.new!(order_id: "or_...")

case Inttegro.Orders.lookup(client, request) do
  {:ok, order} ->
    IO.inspect(order.status, label: "order status")

  {:error, %Inttegro.Errors.APIError{} = error} ->
    IO.warn("Inttegro rejected the request: #{error.code}")

  {:error, %Inttegro.Errors.TransportError{} = error} ->
    IO.warn("Inttegro could not be reached: #{Exception.message(error)}")
end

Keep the secret key on the server. Every mutation should carry a stable idempotency key, and a browser redirect must not be treated as authoritative proof of payment. The Getting started and Orders and payments guides cover a complete integration.

Resource APIs