@amos.com/node 0.1.31 → 0.1.33

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/openapi/schema.ts CHANGED
@@ -1216,7 +1216,7 @@ export interface components {
1216
1216
  account_type?: string;
1217
1217
  bank_name?: string;
1218
1218
  /** @enum {string|null} */
1219
- failure_reason?: "activation_failed" | "processing_error" | "vault_failed" | null;
1219
+ failure_reason?: "activation_failed" | "processing_error" | "vault_failed" | "insufficient_funds" | "verification_failed" | null;
1220
1220
  fingerprint?: string | null;
1221
1221
  last4?: string;
1222
1222
  routing_number?: string;
@@ -1261,10 +1261,20 @@ export interface components {
1261
1261
  exp_year?: number;
1262
1262
  moto?: boolean;
1263
1263
  };
1264
+ /** @description Apple Pay card profile for embed confirm. Clients must send the raw PKPaymentToken as wallet_payload; Vault decrypts it and returns the cryptogram. Encrypted PAN and client-supplied cryptogram are not supported. */
1265
+ ApplePayCardProfileInput: {
1266
+ wallet_brand?: string;
1267
+ /** @description Display last4 from the Apple Pay payment method. */
1268
+ wallet_last4?: string;
1269
+ /** @description The unmodified JSON-encoded PKPaymentToken. */
1270
+ wallet_payload: string;
1271
+ wallet_provider?: components["schemas"]["WalletProviderType"];
1272
+ };
1264
1273
  GooglePayCardProfileInput: {
1265
1274
  wallet_brand?: string;
1266
1275
  wallet_last4?: string;
1267
- wallet_payload?: string;
1276
+ /** @description The unmodified Google Pay payment token payload. */
1277
+ wallet_payload: string;
1268
1278
  wallet_provider?: components["schemas"]["WalletProviderType"];
1269
1279
  };
1270
1280
  CardProfile: {
@@ -1561,6 +1571,7 @@ export interface components {
1561
1571
  billing_address_attributes?: components["schemas"]["BillingAddressInput"];
1562
1572
  card_profile_attributes: components["schemas"]["CardProfileInput"];
1563
1573
  };
1574
+ /** @description Confirm an embedded intent with a bank account. When ACH verification is required for the intent amount, include plaid credentials; routing and account numbers are filled server-side from Plaid Auth. Otherwise provide encrypted_account_number and routing_number on bank_account_profile_attributes. */
1564
1575
  EmbedConfirmBankAccountPaymentMethodInput: {
1565
1576
  /**
1566
1577
  * @description discriminator enum property added by openapi-typescript
@@ -1568,6 +1579,7 @@ export interface components {
1568
1579
  */
1569
1580
  type: "bank_account";
1570
1581
  metadata?: components["schemas"]["Metadata"];
1582
+ plaid?: components["schemas"]["PlaidCredentialsInput"];
1571
1583
  bank_account_profile_attributes: components["schemas"]["BankAccountProfileInput"];
1572
1584
  billing_address_attributes?: components["schemas"]["BillingAddressInput"];
1573
1585
  };
@@ -1589,7 +1601,14 @@ export interface components {
1589
1601
  type: "applepay";
1590
1602
  metadata?: components["schemas"]["Metadata"];
1591
1603
  billing_address_attributes?: components["schemas"]["BillingAddressInput"];
1592
- card_profile_attributes: components["schemas"]["CardProfileInput"];
1604
+ card_profile_attributes: components["schemas"]["ApplePayCardProfileInput"];
1605
+ };
1606
+ /** @description One-time Plaid Link credentials used to source and verify a bank account when ACH verification is required. */
1607
+ PlaidCredentialsInput: {
1608
+ /** @description Temporary public_token returned by Plaid Link onSuccess. */
1609
+ public_token: string;
1610
+ /** @description Selected Plaid account_id from Link metadata. */
1611
+ account_id: string;
1593
1612
  };
1594
1613
  AllowedCardPaymentMethodOptions: {
1595
1614
  moto?: boolean;
@@ -1939,13 +1958,28 @@ export interface components {
1939
1958
  /** @enum {string} */
1940
1959
  state?: "requires_payment_method" | "requires_confirmation" | "requires_capture" | "processing_authorization" | "processing_capture" | "processing_sale" | "requires_review" | "succeeded" | "cancelled" | "errored_authorization" | "errored_capture" | "errored_sale";
1941
1960
  statement_descriptor?: string;
1961
+ /** @description True when the intent amount meets or exceeds the configured ACH verification threshold. */
1962
+ requires_ach_verification?: boolean;
1963
+ ach_verification?: components["schemas"]["AchVerification"];
1942
1964
  /** Format: date-time */
1943
1965
  created_at?: string;
1944
1966
  /** Format: date-time */
1945
1967
  updated_at?: string;
1946
1968
  };
1969
+ /** @description Instructions for the embed client to complete ACH verification via Plaid Link. */
1970
+ AchVerification: {
1971
+ /** @enum {string} */
1972
+ type: "plaid_auth";
1973
+ /** @description Short-lived Plaid Link token used to open Link in the embed client. */
1974
+ link_token: string;
1975
+ };
1976
+ /** @description How this payment intent relates to a recurring series. Use `initial` for the first charge that establishes the series. Use `network_transaction_id` and/or `transaction_link_id` for subsequent merchant-initiated charges. Do not combine `initial` with network identifiers on the same request. */
1947
1977
  RecurringPayment: {
1978
+ /** @description When true, marks the first payment in a recurring series so the processor can treat it as an initial recurring / credential-on-file setup transaction. */
1979
+ initial?: boolean;
1980
+ /** @description Network transaction id from the initial recurring charge, used for subsequent merchant-initiated payments. */
1948
1981
  network_transaction_id?: string;
1982
+ /** @description Processor transaction link id for subsequent recurring payments where supported. */
1949
1983
  transaction_link_id?: string;
1950
1984
  };
1951
1985
  CreatePaymentLinkInput: {
@@ -2450,13 +2484,32 @@ export interface components {
2450
2484
  /** Format: date-time */
2451
2485
  updated_at?: string;
2452
2486
  };
2487
+ /** @description Body POSTed to a webhook endpoint for an event delivery. */
2488
+ WebhookEventPayload: {
2489
+ /**
2490
+ * Format: uuid
2491
+ * @description Stable event id for this delivery. Identical across retries of the same event; use for idempotent handling.
2492
+ */
2493
+ id: string;
2494
+ /**
2495
+ * Format: uuid
2496
+ * @description Id of the webhook endpoint that received this delivery.
2497
+ */
2498
+ webhook_id: string;
2499
+ event: components["schemas"]["WebhookEventType"];
2500
+ /** @description Event-specific payload keyed by resource descriptor. */
2501
+ data: {
2502
+ [key: string]: unknown;
2503
+ };
2504
+ metadata?: components["schemas"]["Metadata"];
2505
+ };
2453
2506
  WebhookRequest: {
2454
2507
  id?: string;
2455
2508
  /** Format: uuid */
2456
2509
  webhook_endpoint_id?: string;
2457
2510
  /** Format: date-time */
2458
2511
  expires_at?: string;
2459
- request_body?: Record<string, never>;
2512
+ request_body?: components["schemas"]["WebhookEventPayload"];
2460
2513
  /** Format: date-time */
2461
2514
  created_at?: string;
2462
2515
  /** Format: date-time */
@@ -3466,7 +3519,10 @@ export interface operations {
3466
3519
  };
3467
3520
  GetEmbedPaymentIntent: {
3468
3521
  parameters: {
3469
- query?: never;
3522
+ query?: {
3523
+ /** @description When set to bank_account and ACH verification is required for the intent amount, the response includes ach_verification.link_token for Plaid Link. */
3524
+ payment_method_type?: "bank_account";
3525
+ };
3470
3526
  header?: never;
3471
3527
  path: {
3472
3528
  /** @description The ID of the payment intent to retrieve */
@@ -5123,7 +5179,8 @@ type ReadonlyArray<T> = [
5123
5179
  ] extends [
5124
5180
  unknown[]
5125
5181
  ] ? Readonly<Exclude<T, undefined>> : Readonly<Exclude<T, undefined>[]>;
5126
- export const bankAccountProfileFailure_reasonValues: ReadonlyArray<FlattenedDeepRequired<components>["schemas"]["BankAccountProfile"]["failure_reason"]> = ["activation_failed", "processing_error", "vault_failed"];
5182
+ export const pathsEmbedPayment_intentsIdGetParametersQueryPayment_method_typeValues: ReadonlyArray<FlattenedDeepRequired<paths>["/embed/payment_intents/{id}"]["get"]["parameters"]["query"]["payment_method_type"]> = ["bank_account"];
5183
+ export const bankAccountProfileFailure_reasonValues: ReadonlyArray<FlattenedDeepRequired<components>["schemas"]["BankAccountProfile"]["failure_reason"]> = ["activation_failed", "processing_error", "vault_failed", "insufficient_funds", "verification_failed"];
5127
5184
  export const cardProfileFailure_reasonValues: ReadonlyArray<FlattenedDeepRequired<components>["schemas"]["CardProfile"]["failure_reason"]> = ["authorization_failed", "avs_blocked", "brand_not_allowed", "brand_not_found", "cvc_blocked", "processing_error", "vault_failed"];
5128
5185
  export const chargeAllowed_reverse_actionValues: ReadonlyArray<FlattenedDeepRequired<components>["schemas"]["Charge"]["allowed_reverse_action"]> = ["void", "refund"];
5129
5186
  export const chargeStateValues: ReadonlyArray<FlattenedDeepRequired<components>["schemas"]["Charge"]["state"]> = ["cancelled", "errored", "failed", "processing", "requires_capture", "requires_confirmation", "requires_review", "settlement_failed", "succeeded"];
@@ -5155,6 +5212,7 @@ export const transactionSourceTypeValues: ReadonlyArray<FlattenedDeepRequired<co
5155
5212
  export const walletProviderTypeValues: ReadonlyArray<FlattenedDeepRequired<components>["schemas"]["WalletProviderType"]> = ["googlepay", "applepay"];
5156
5213
  export const webhookEventTypeValues: ReadonlyArray<FlattenedDeepRequired<components>["schemas"]["WebhookEventType"]> = ["charge.cancelled", "charge.created", "charge.errored", "charge.failed", "charge.processing", "charge.requires_capture", "charge.requires_confirmation", "charge.requires_review", "charge.settlement_failed", "charge.succeeded", "customer.created", "customer.updated", "legal_entity.created", "legal_entity.updated", "legal_entity_principal.created", "legal_entity_principal.updated", "legal_entity_application.approved", "legal_entity_application.denied", "legal_entity_application.needs_information", "legal_entity_application.pending", "legal_entity_application.submitted", "merchant.created", "merchant.updated", "payment_intent.cancelled", "payment_intent.created", "payment_intent.errored_authorization", "payment_intent.errored_capture", "payment_intent.errored_sale", "payment_intent.processing_authorization", "payment_intent.processing_capture", "payment_intent.processing_sale", "payment_intent.requires_capture", "payment_intent.requires_confirmation", "payment_intent.requires_payment_method", "payment_intent.requires_review", "payment_intent.succeeded", "processor_transaction.completed", "reconciliation.created", "refund.cancelled", "refund.created", "refund.failed", "refund.pending", "refund.processing", "refund.requires_review", "refund.succeeded", "void.created", "void.failed", "void.pending", "void.processing", "void.requires_review", "void.succeeded"];
5157
5214
  export const paymentIntentStateValues: ReadonlyArray<FlattenedDeepRequired<components>["schemas"]["PaymentIntent"]["state"]> = ["requires_payment_method", "requires_confirmation", "requires_capture", "processing_authorization", "processing_capture", "processing_sale", "requires_review", "succeeded", "cancelled", "errored_authorization", "errored_capture", "errored_sale"];
5215
+ export const achVerificationTypeValues: ReadonlyArray<FlattenedDeepRequired<components>["schemas"]["AchVerification"]["type"]> = ["plaid_auth"];
5158
5216
  export const processorTransactionPayment_transaction_typeValues: ReadonlyArray<FlattenedDeepRequired<components>["schemas"]["ProcessorTransaction"]["payment_transaction_type"]> = ["charge", "refund", "void"];
5159
5217
  export const processorTransactionTransaction_typeValues: ReadonlyArray<FlattenedDeepRequired<components>["schemas"]["ProcessorTransaction"]["transaction_type"]> = ["authorization", "authorization_reversal", "capture", "credit", "echeck_credit", "echeck_sale", "echeck_void", "sale", "void"];
5160
5218
  export const refundAllowed_reverse_actionValues: ReadonlyArray<FlattenedDeepRequired<components>["schemas"]["Refund"]["allowed_reverse_action"]> = ["void"];
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@amos.com/node",
3
- "version": "0.1.31",
3
+ "version": "0.1.33",
4
4
  "description": "Node.js client for the Amos Pay API.",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.mjs",