Skip to content

feat(payments): payment orders, checkout and order events - #57

Merged
Domantas merged 4 commits into
mainfrom
feat/payments-orders
Oct 19, 2026
Merged

Domantas merged 4 commits into
mainfrom
feat/payments-orders

Conversation

@Domantas

Copy link
Copy Markdown
Contributor

What

Payment orders and checkout (gateway campaign audit/payments-checkout, item sdk-all; same surface as @norbix.ai/ts v4.29.0).

  • api.payments (sync + async): create_payment_order, get_payment_order(id), get_payment_orders, start_payment_checkout(id).
  • Webhooks: the five payments.order.* events; payload is the order event; event.metadata.order (id, order_event_id — the de-duplication key — and status), payment ids lifted from data.payment.
  • Functions: FunctionEvent.as_payment_order() for data.order; PaymentFact.order_id; as_payment() unchanged.
  • Reference DTOs regenerated from a private stack of the gateway branch.

Only additions, no public method changed.

Checks

  • uv run pytest 1133 passed · ruff clean · mypy clean
  • Live smoke on a private stack: create → same id again → get (Created, 630 cents) → list contains it

🤖 Generated with Claude Code

Domantas and others added 4 commits October 19, 2026 14:35
…heckout a2d8be8d0

Refreshed in update mode (x <file>) against a private gateway stack on the
campaign head; BaseUrl put back to the usual localhost values. 42 Api and 51 Hub
types added, none removed: payment orders + checkout (CreatePaymentOrderRequest,
PaymentOrderDto, PaymentOrderEventDto, …), MontonioPaymentIntegrationRequest,
CodeFunctionDataDto.order, notification inbox, trigger definition, user import.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…der.* trigger

data.order is the order event (PaymentOrderEvent: order_event_id — the
de-duplication key —, event, from_/to, reason, order, payment). as_payment()
keeps returning the callback that changed the order; PaymentFact gains order_id.
A non-order event asked for as_payment_order() raises NorbixFunctionEventError.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… order + payment ids on event.metadata

payments.order.paid / partially_refunded / refunded / reversed / expired join
the catalog and NorbixWebhookEvents.Payments. The handler gets the
PaymentOrderEvent view; integration_id and the provider ids are lifted from
data.payment, and metadata.order = { id, order_event_id, status }
(WebhookOrderRef) — order_event_id is the de-duplication key.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… async)

create_payment_order, get_payment_order, get_payment_orders and
start_payment_checkout (gateway campaign audit/payments-checkout). Also on the
flat NorbixApi client. Tests: route, verb, path id, body and query per method,
and the four routes through httpx on the async client.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@Domantas
Domantas merged commit 2d9b664 into main Oct 19, 2026
9 checks passed
@Domantas
Domantas deleted the feat/payments-orders branch October 19, 2026 11:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant