Docs

SDK reference

Generated reference for @atmosphere-money/app-node exports, client methods, errors, and event helpers.

Closed beta@atmosphere-money/app-nodeSDK beta: 0.0.0-beta.0ATM API beta: 2026-0642 lexicons

Compatible with the closed-beta ATM app APIs and versioned ATM event headers. Check atm-api-version on every webhook or XRPC receiver event.

Generated source

This page is generated from packages/app-node/src/index.ts so app developers can trust that the docs match the package export surface. The App Node SDK is server-side, dependency-free at runtime, and MIT licensed as a package.

Package
@atmosphere-money/app-node
Runtime
Node 22+, ESM, TypeScript declarations from dist/index.d.ts.
License
MIT for the package only. The ATM monorepo and hosted platform remain private.
Generated exports
101
Generated client methods
17

Install shape

sh
npm install @atmosphere-money/app-node@beta

Client methods

Client methods are grouped by the app surface they help with. Payments methods are the smallest checkout path; Tickets methods are for scarce inventory and scanner flows.

GroupMethodPurpose
ticketsarchiveTicketTierArchive a ticket tier while preserving purchase history.
ticketscheckInTicketIdempotently check in a verified ticket token.
ticketsclaimFreeTicketIssue a limited free ticket with app auth plus buyer assertion.
ticketscreateCapacityGroupCreate a private event capacity group.
ticketscreateTicketHoldReserve scarce ticket capacity and return an ATM checkout token/url.
ticketscreateTicketTierCreate an app-scoped ticket tier for an event.
ticketsgetTicketAvailabilityRead private ATM ticket availability derived from holds and issued tickets.
ticketslistBuyerTicketsList app-scoped tickets for a buyer or payment.
ticketslistOrganizerTicketsList tickets for an organizer or event.
ticketsreleaseTicketHoldRelease an unused ticket hold.
ticketsupdateCapacityGroupUpdate capacity group metadata or capacity.
ticketsupdateTicketTierUpdate mutable ticket tier fields.
ticketsverifyTicketVerify an opaque QR/pass ticket token without checking in.
paymentsgetPaymentStatusPoll checkout/payment status for browser return UI.
paymentsgetPayoutStatusCheck if a recipient DID can currently receive payments before showing checkout.
profilesgetProfileRead an ATM profile through the AppView.
paymentsinitiatePaymentStart ATM-hosted checkout through strict network.attested.payment.initiate.

Exported helpers

The generated export list stays accurate to the package source, but the largest shared type section is collapsed by default so the practical helpers remain easy to scan.

core checkout10 exports
ExportKindDescription
AtmCheckoutEnvelopetypeServer-only checkout envelope input. May contain private session context.
AtmInitiatePaymentResulttypeExported TypeScript contract for ATM app integrations.
AtmPaymentStatustypeStatus response used for browser return polling and support tooling.
AtmPaymentSummarytypeApp-visible payment summary used in events and status responses.
AtmPaymentTypetypeATM payment classification used for dashboard, events, and app policy.
AtmPayoutStatustypePayability response used before showing checkout buttons.
AtmProfiletypeATM profile summary returned by the public AppView profile lookup.
createAtmAppClientfunctionCreate a server-side ATM client for app XRPC methods, checkout, status, profile, and Tickets calls.
createAtmCheckoutProductfunctionBuild the private atm.checkout.v1 envelope used by strict attested.network initiation.
createPaymentInitiateBodyfunctionBuild the strict { product } request body for network.attested.payment.initiate.
webhooks and events33 exports
ExportKindDescription
AtmCloudflareWorkerWebhookHandlertypeExported TypeScript contract for ATM app integrations.
AtmEventDataByTypetypeMap from known ATM event type to typed event data shape.
AtmEventDataFortypeConditional type that resolves event data for a known ATM event type.
AtmExpressWebhookHandlerOptionstypeOptions for creating Express-style webhook handlers.
AtmPaymentCompletedEventtypeExported TypeScript contract for ATM app integrations.
AtmPaymentEventDatatypeEvent data shape for payment events.
AtmProductEventDatatypeEvent data shape for product/catalog events.
AtmSubscriptionEventDatatypeEvent data shape for subscription events.
AtmTypedEventtypeTyped ATM event envelope for a known event type.
AtmTypedWebhookEnvelopetypeExported TypeScript contract for ATM app integrations.
AtmWebhookEnvelopetypeCanonical ATM event envelope used by HTTP webhooks and optional XRPC receivers.
AtmWebhookEventTypetypeKnown ATM event type union for typed webhook and XRPC receiver events.
AtmWebhookHandlerEventtypeEvent type passed into middleware-style webhook handlers.
AtmWebhookHandlerOptionstypeOptions for creating Request/Response webhook handlers.
AtmWebhookHandlerResulttypeReturn shape for middleware-style webhook handlers.
AtmWebhookHeaderstypeHeaders required to verify an ATM HTTP webhook.
AtmXrpcMethodtypeExported TypeScript contract for ATM app integrations.
AtmXrpcReceiverHeaderstypeHeaders used by optional ATM-to-app XRPC receiver delivery.
constructAtmWebhookEventfunctionVerify an HTTP webhook signature over the raw body and parse the ATM event envelope.
ConstructAtmWebhookOptionstypeOptions for verifying and parsing an ATM HTTP webhook event.
constructAtmXrpcReceiverEventfunctionVerify optional XRPC receiver service-auth and parse the ATM event envelope.
ConstructAtmXrpcReceiverOptionstypeOptions for verifying and parsing optional ATM XRPC receiver events.
constructTypedAtmWebhookEventfunctionVerify an HTTP webhook and narrow event.data for a known ATM event type.
constructTypedAtmXrpcReceiverEventfunctionVerify an XRPC receiver event and narrow event.data for a known ATM event type.
createAtmXrpcReceiverAudiencefunctionBuild the service-auth audience for an app-hosted ATM XRPC receiver service.
createCloudflareWorkerWebhookHandlerfunctionExported App Node SDK helper.
createExpressWebhookHandlerfunctionCreate an Express-style ATM webhook handler with raw-body verification.
createHonoWebhookHandlerfunctionExported App Node SDK helper.
createNextWebhookRouteconstAlias for Request/Response ATM webhook route handlers in Next route handlers.
createNodeWebhookHandlerfunctionCreate a Request/Response ATM webhook route handler for Node-compatible runtimes.
signAtmWebhookPayloadfunctionCreate a local ATM webhook signature for tests and fixture generation.
VerifyAtmWebhookOptionstypeOptions for raw ATM webhook HMAC verification.
verifyAtmWebhookSignaturefunctionCheck an ATM HTTP webhook HMAC signature with timestamp tolerance and secret rotation support.
tickets33 exports
ExportKindDescription
AtmArchiveTicketTierInputtypeInput for archiving a ticket tier.
AtmArchiveTicketTierResulttypeExported TypeScript contract for ATM app integrations.
AtmCapacityGroupResulttypeExported TypeScript contract for ATM app integrations.
AtmCapacityGroupSummarytypeExported TypeScript contract for ATM app integrations.
AtmCreateCapacityGroupInputtypeInput for creating a private capacity group.
AtmCreateTicketTierInputtypeInput for creating a ticket tier for an event.
AtmFreeTicketClaimInputtypeInput for claiming a limited free ticket without checkout.
AtmFreeTicketClaimResulttypeResult from claiming a limited free ticket without checkout.
AtmListBuyerTicketsParamstypeQuery parameters for app-scoped buyer ticket lists.
AtmListOrganizerTicketsParamstypeQuery parameters for organizer or event ticket lists.
AtmListTicketsResulttypeExported TypeScript contract for ATM app integrations.
AtmReleaseTicketHoldInputtypeInput for releasing an unused ticket hold.
AtmReleaseTicketHoldResulttypeExported TypeScript contract for ATM app integrations.
AtmTicketAvailabilitytypeAvailability response derived from private ATM holds and issued tickets.
AtmTicketAvailabilityParamstypeQuery parameters for reading app-scoped ticket availability.
AtmTicketCheckedInEventtypeExported TypeScript contract for ATM app integrations.
AtmTicketCheckInInputtypeInput for idempotent ticket check-in by opaque scan token.
AtmTicketCheckInResulttypeCheck-in result for scanner apps.
AtmTicketEventDatatypeEvent data shape for ticket hold, issuance, refund, void, and check-in events.
AtmTicketEventInputtypeEvent metadata supplied by a ticketing app when configuring tiers or capacity.
AtmTicketEventSummarytypeExported TypeScript contract for ATM app integrations.
AtmTicketHoldInputtypeInput for creating a paid ticket hold before checkout.
AtmTicketHoldResulttypeResult from creating a ticket hold, including hold id, token, url, and expiry.
AtmTicketsIssuedEventtypeExported TypeScript contract for ATM app integrations.
AtmTicketSummarytypeExported TypeScript contract for ATM app integrations.
AtmTicketTierResulttypeExported TypeScript contract for ATM app integrations.
AtmTicketTierSummarytypeExported TypeScript contract for ATM app integrations.
AtmUpdateCapacityGroupInputtypeInput for updating a private capacity group.
AtmUpdateTicketTierInputtypeInput for updating mutable ticket tier fields.
AtmVerifyTicketInputtypeInput for verifying an opaque ticket token without mutating check-in state.
AtmVerifyTicketResulttypeVerification result for QR/pass ticket presentation.
createFreeTicketClaimBodyfunctionExported App Node SDK helper.
createTicketHoldBodyfunctionExported App Node SDK helper.
errors3 exports
ExportKindDescription
AtmApiErrorclassStructured ATM request error with code, HTTP status, and parsed response body.
AtmWebhookSignatureErrorclassError thrown when HTTP webhook signature or event-header validation fails.
AtmXrpcReceiverAuthErrorclassError thrown when optional XRPC receiver auth or envelope validation fails.
constants9 exports
ExportKindDescription
ATM_BROKER_DIDconstATM broker DID used for broker service-auth and attested.network context.
ATM_BROKER_SERVICE_AUDIENCEconstDefault service-auth audience for ATM broker XRPC methods.
ATM_CHECKOUT_PRODUCT_PREFIXconstPrefix for ATM's launch checkout envelope token.
ATM_EVENT_RECEIVE_NSIDconstOptional app XRPC receiver method used for ATM event delivery.
ATM_XRPC_METHODSconstGrouped NSID constants for ATM app-facing XRPC methods.
DEFAULT_ATM_APPVIEW_URLconstDefault production AppView XRPC base URL.
DEFAULT_ATM_BROKER_URLconstDefault production broker and checkout XRPC base URL.
DEFAULT_ATM_WEBHOOK_TOLERANCE_SECONDSconstDefault timestamp tolerance for verifying ATM HTTP webhook signatures.
DEFAULT_ATM_XRPC_RECEIVER_SERVICEconstDefault DID service id for app-hosted ATM event receivers.
shared types13 exports
ExportKindDescription
AtmAppClientOptionstypeExported TypeScript contract for ATM app integrations.
AtmEnvironmenttypeATM app environment selector: test or live.
AtmExpressLikeRequesttypeMinimal Express-compatible request shape used by the SDK without depending on Express.
AtmExpressLikeResponsetypeMinimal Express-compatible response shape used by the SDK without depending on Express.
AtmHonoLikeContexttypeExported TypeScript contract for ATM app integrations.
AtmReceiverServiceAuthVerifiertypeCallback type for app code that verifies ATM service-auth JWT signatures.
AtmServiceAuthTokenProvidertypeExported TypeScript contract for ATM app integrations.
AtmStrongReftypeAT Protocol strongRef shape for public catalog and entitlement references.
AtmSubscriptionSummarytypeExported TypeScript contract for ATM app integrations.
AtmVerifiedServiceAuthClaimstypeMinimal verified service-auth claims ATM receiver helpers need after JWT verification.
verifyAtmReceiverServiceAuthClaimsfunctionValidate iss, aud, and lxm claims for an ATM-to-app XRPC receiver JWT after signature verification.
verifyServiceAuthRequestfunctionExported App Node SDK helper.
VerifyServiceAuthRequestOptionstypeExported TypeScript contract for ATM app integrations.

Errors

AtmApiErrorThrown when an ATM XRPC/API response is non-2xx. Carries code, status, and parsed body.
AtmWebhookSignatureErrorThrown when webhook signature, delivery id, event type, API version, or environment validation fails.
AtmXrpcReceiverAuthErrorThrown when optional XRPC receiver authorization or event envelope validation fails.
ts
import { AtmApiError } from "@atmosphere-money/app-node";

try {
  await atm.initiatePayment(input);
} catch (error) {
  if (error instanceof AtmApiError && error.code === "RecipientNotPayable") {
    return showSetupRequiredState();
  }
  throw error;
}

Release checks

  • Run npm run sdk:app-node:check from the repo root.
  • Run npm run publish:check from packages/app-node before public release.
  • Inspect npm pack --dry-run output and confirm README, CHANGELOG, LICENSE, dist/index.js, and dist/index.d.ts are included.
  • Update packages/app-node/CHANGELOG.md for every version.
  • Keep docs/developer/sdk/atm-app.ts aligned until the npm package is public.
  • Do not add browser checkout code or Supper widgets to this Node package.
SDK reference - Atmosphere Money Docs