@amos.com/node 0.1.75 → 0.1.76
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/dist/index.d.mts +15 -3
- package/dist/index.d.ts +15 -3
- package/dist/index.js +3 -0
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +2 -0
- package/dist/index.mjs.map +1 -1
- package/openapi/schema.ts +14 -2
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -1471,8 +1471,6 @@ interface components {
|
|
|
1471
1471
|
last4?: string;
|
|
1472
1472
|
state?: string;
|
|
1473
1473
|
three_d_secure_supported?: boolean | null;
|
|
1474
|
-
/** @description Legacy card token. Prefer vault_token for new integrations. */
|
|
1475
|
-
token?: string;
|
|
1476
1474
|
/**
|
|
1477
1475
|
* Format: uuid
|
|
1478
1476
|
* @description Vault UUID for this card. Used for charges and Vault callbacks.
|
|
@@ -1516,6 +1514,7 @@ interface components {
|
|
|
1516
1514
|
/** Format: uuid */
|
|
1517
1515
|
customer_id?: string;
|
|
1518
1516
|
description?: string | null;
|
|
1517
|
+
failure?: components["schemas"]["PaymentFailure"] | null;
|
|
1519
1518
|
/** @enum {string|null} */
|
|
1520
1519
|
allowed_reverse_action?: "void" | "refund" | null;
|
|
1521
1520
|
metadata?: components["schemas"]["Metadata"];
|
|
@@ -1963,6 +1962,16 @@ interface components {
|
|
|
1963
1962
|
SubscriptionIntervalType: "day" | "week" | "month" | "year";
|
|
1964
1963
|
/** @enum {string} */
|
|
1965
1964
|
SubscriptionPlanType: "fixed" | "variable";
|
|
1965
|
+
/** @description Why a transaction failed, in terms that are the same for every processor. */
|
|
1966
|
+
PaymentFailure: {
|
|
1967
|
+
/** @description Stable failure code, for example insufficient_funds, issuer_declined or incorrect_cvc. New codes may be added over time, so treat unknown values as generic_decline. */
|
|
1968
|
+
code: string;
|
|
1969
|
+
type: components["schemas"]["PaymentFailureType"];
|
|
1970
|
+
/** @description Human readable explanation. Safe to show to the merchant. */
|
|
1971
|
+
message: string;
|
|
1972
|
+
};
|
|
1973
|
+
/** @enum {string} */
|
|
1974
|
+
PaymentFailureType: "payment_method_error" | "processing_error";
|
|
1966
1975
|
/** @enum {string} */
|
|
1967
1976
|
TransactionSourceType: "api" | "dashboard" | "iframe" | "system" | "subscription" | "admin";
|
|
1968
1977
|
/** @enum {string} */
|
|
@@ -2607,6 +2616,7 @@ interface components {
|
|
|
2607
2616
|
/** Format: uuid */
|
|
2608
2617
|
customer_id?: string;
|
|
2609
2618
|
description?: string | null;
|
|
2619
|
+
failure?: components["schemas"]["PaymentFailure"] | null;
|
|
2610
2620
|
metadata?: components["schemas"]["Metadata"];
|
|
2611
2621
|
/** Format: uuid */
|
|
2612
2622
|
original_transaction_id?: string;
|
|
@@ -2845,6 +2855,7 @@ interface components {
|
|
|
2845
2855
|
/** Format: uuid */
|
|
2846
2856
|
customer_id?: string;
|
|
2847
2857
|
description?: string | null;
|
|
2858
|
+
failure?: components["schemas"]["PaymentFailure"] | null;
|
|
2848
2859
|
metadata?: components["schemas"]["Metadata"];
|
|
2849
2860
|
/** Format: uuid */
|
|
2850
2861
|
original_transaction_id?: string;
|
|
@@ -6141,6 +6152,7 @@ declare const payoutStateTypeValues: ReadonlyArray<FlattenedDeepRequired<compone
|
|
|
6141
6152
|
declare const refundStateTypeValues: ReadonlyArray<FlattenedDeepRequired<components>["schemas"]["RefundStateType"]>;
|
|
6142
6153
|
declare const subscriptionIntervalTypeValues: ReadonlyArray<FlattenedDeepRequired<components>["schemas"]["SubscriptionIntervalType"]>;
|
|
6143
6154
|
declare const subscriptionPlanTypeValues: ReadonlyArray<FlattenedDeepRequired<components>["schemas"]["SubscriptionPlanType"]>;
|
|
6155
|
+
declare const paymentFailureTypeValues: ReadonlyArray<FlattenedDeepRequired<components>["schemas"]["PaymentFailureType"]>;
|
|
6144
6156
|
declare const transactionSourceTypeValues: ReadonlyArray<FlattenedDeepRequired<components>["schemas"]["TransactionSourceType"]>;
|
|
6145
6157
|
declare const walletProviderTypeValues: ReadonlyArray<FlattenedDeepRequired<components>["schemas"]["WalletProviderType"]>;
|
|
6146
6158
|
declare const webhookEventTypeValues: ReadonlyArray<FlattenedDeepRequired<components>["schemas"]["WebhookEventType"]>;
|
|
@@ -6192,4 +6204,4 @@ declare function createPayApiClient(options: ClientOptions): openapi_fetch.Clien
|
|
|
6192
6204
|
/** A configured Amos Pay API client returned by {@link createPayApiClient}. */
|
|
6193
6205
|
type PayApiClient = ReturnType<typeof createPayApiClient>;
|
|
6194
6206
|
|
|
6195
|
-
export { type $defs, AMOS_API_BASE_URL_PRODUCTION, AMOS_API_BASE_URL_SANDBOX, AMOS_API_VERSION, type PayApiClient, allowedApplePayPaymentMethodInputTypeValues, allowedApplePayPaymentMethodTypeValues, allowedBankAccountPaymentMethodInputTypeValues, allowedBankAccountPaymentMethodTypeValues, allowedCardPaymentMethodInputTypeValues, allowedCardPaymentMethodTypeValues, allowedGooglePayPaymentMethodInputTypeValues, allowedGooglePayPaymentMethodTypeValues, chargeAllowed_reverse_actionValues, chargeStateValues, type components, createPayApiClient, embedConfirmApplePayPaymentMethodInputTypeValues, embedConfirmBankAccountPaymentMethodInputTypeValues, embedConfirmCardPaymentMethodInputTypeValues, embedConfirmGooglePayPaymentMethodInputTypeValues, externalAccountTypeValues, internationalBillingAddressOptionsModeValues, legalEntityApplicationStateTypeValues, legalEntityDocumentTypeValues, legalEntityEntityTypeValues, legalEntityOwnershipTypeValues, merchantBusinessCategoryTypeValues, type operations, organizationKindValues, originApplepayRegistrationStateTypeValues, type paths, paymentIntentCaptureMethodTypeValues, paymentIntentStateValues, paymentLinkAmountTypeValues, paymentMethodTypeValues, payoutDirectionTypeValues, payoutStateTypeValues, processorTransactionPayment_transaction_typeValues, processorTransactionTransaction_typeValues, refundAllowed_reverse_actionValues, refundStateTypeValues, setupIntentStateValues, subscriptionIntervalTypeValues, subscriptionPlanTypeValues, subscriptionStateValues, transactionSourceTypeValues, usOnlyBillingAddressOptionsModeValues, usStateTypeValues, walletProviderTypeValues, webhookEventTypeValues, type webhooks };
|
|
6207
|
+
export { type $defs, AMOS_API_BASE_URL_PRODUCTION, AMOS_API_BASE_URL_SANDBOX, AMOS_API_VERSION, type PayApiClient, allowedApplePayPaymentMethodInputTypeValues, allowedApplePayPaymentMethodTypeValues, allowedBankAccountPaymentMethodInputTypeValues, allowedBankAccountPaymentMethodTypeValues, allowedCardPaymentMethodInputTypeValues, allowedCardPaymentMethodTypeValues, allowedGooglePayPaymentMethodInputTypeValues, allowedGooglePayPaymentMethodTypeValues, chargeAllowed_reverse_actionValues, chargeStateValues, type components, createPayApiClient, embedConfirmApplePayPaymentMethodInputTypeValues, embedConfirmBankAccountPaymentMethodInputTypeValues, embedConfirmCardPaymentMethodInputTypeValues, embedConfirmGooglePayPaymentMethodInputTypeValues, externalAccountTypeValues, internationalBillingAddressOptionsModeValues, legalEntityApplicationStateTypeValues, legalEntityDocumentTypeValues, legalEntityEntityTypeValues, legalEntityOwnershipTypeValues, merchantBusinessCategoryTypeValues, type operations, organizationKindValues, originApplepayRegistrationStateTypeValues, type paths, paymentFailureTypeValues, paymentIntentCaptureMethodTypeValues, paymentIntentStateValues, paymentLinkAmountTypeValues, paymentMethodTypeValues, payoutDirectionTypeValues, payoutStateTypeValues, processorTransactionPayment_transaction_typeValues, processorTransactionTransaction_typeValues, refundAllowed_reverse_actionValues, refundStateTypeValues, setupIntentStateValues, subscriptionIntervalTypeValues, subscriptionPlanTypeValues, subscriptionStateValues, transactionSourceTypeValues, usOnlyBillingAddressOptionsModeValues, usStateTypeValues, walletProviderTypeValues, webhookEventTypeValues, type webhooks };
|
package/dist/index.d.ts
CHANGED
|
@@ -1471,8 +1471,6 @@ interface components {
|
|
|
1471
1471
|
last4?: string;
|
|
1472
1472
|
state?: string;
|
|
1473
1473
|
three_d_secure_supported?: boolean | null;
|
|
1474
|
-
/** @description Legacy card token. Prefer vault_token for new integrations. */
|
|
1475
|
-
token?: string;
|
|
1476
1474
|
/**
|
|
1477
1475
|
* Format: uuid
|
|
1478
1476
|
* @description Vault UUID for this card. Used for charges and Vault callbacks.
|
|
@@ -1516,6 +1514,7 @@ interface components {
|
|
|
1516
1514
|
/** Format: uuid */
|
|
1517
1515
|
customer_id?: string;
|
|
1518
1516
|
description?: string | null;
|
|
1517
|
+
failure?: components["schemas"]["PaymentFailure"] | null;
|
|
1519
1518
|
/** @enum {string|null} */
|
|
1520
1519
|
allowed_reverse_action?: "void" | "refund" | null;
|
|
1521
1520
|
metadata?: components["schemas"]["Metadata"];
|
|
@@ -1963,6 +1962,16 @@ interface components {
|
|
|
1963
1962
|
SubscriptionIntervalType: "day" | "week" | "month" | "year";
|
|
1964
1963
|
/** @enum {string} */
|
|
1965
1964
|
SubscriptionPlanType: "fixed" | "variable";
|
|
1965
|
+
/** @description Why a transaction failed, in terms that are the same for every processor. */
|
|
1966
|
+
PaymentFailure: {
|
|
1967
|
+
/** @description Stable failure code, for example insufficient_funds, issuer_declined or incorrect_cvc. New codes may be added over time, so treat unknown values as generic_decline. */
|
|
1968
|
+
code: string;
|
|
1969
|
+
type: components["schemas"]["PaymentFailureType"];
|
|
1970
|
+
/** @description Human readable explanation. Safe to show to the merchant. */
|
|
1971
|
+
message: string;
|
|
1972
|
+
};
|
|
1973
|
+
/** @enum {string} */
|
|
1974
|
+
PaymentFailureType: "payment_method_error" | "processing_error";
|
|
1966
1975
|
/** @enum {string} */
|
|
1967
1976
|
TransactionSourceType: "api" | "dashboard" | "iframe" | "system" | "subscription" | "admin";
|
|
1968
1977
|
/** @enum {string} */
|
|
@@ -2607,6 +2616,7 @@ interface components {
|
|
|
2607
2616
|
/** Format: uuid */
|
|
2608
2617
|
customer_id?: string;
|
|
2609
2618
|
description?: string | null;
|
|
2619
|
+
failure?: components["schemas"]["PaymentFailure"] | null;
|
|
2610
2620
|
metadata?: components["schemas"]["Metadata"];
|
|
2611
2621
|
/** Format: uuid */
|
|
2612
2622
|
original_transaction_id?: string;
|
|
@@ -2845,6 +2855,7 @@ interface components {
|
|
|
2845
2855
|
/** Format: uuid */
|
|
2846
2856
|
customer_id?: string;
|
|
2847
2857
|
description?: string | null;
|
|
2858
|
+
failure?: components["schemas"]["PaymentFailure"] | null;
|
|
2848
2859
|
metadata?: components["schemas"]["Metadata"];
|
|
2849
2860
|
/** Format: uuid */
|
|
2850
2861
|
original_transaction_id?: string;
|
|
@@ -6141,6 +6152,7 @@ declare const payoutStateTypeValues: ReadonlyArray<FlattenedDeepRequired<compone
|
|
|
6141
6152
|
declare const refundStateTypeValues: ReadonlyArray<FlattenedDeepRequired<components>["schemas"]["RefundStateType"]>;
|
|
6142
6153
|
declare const subscriptionIntervalTypeValues: ReadonlyArray<FlattenedDeepRequired<components>["schemas"]["SubscriptionIntervalType"]>;
|
|
6143
6154
|
declare const subscriptionPlanTypeValues: ReadonlyArray<FlattenedDeepRequired<components>["schemas"]["SubscriptionPlanType"]>;
|
|
6155
|
+
declare const paymentFailureTypeValues: ReadonlyArray<FlattenedDeepRequired<components>["schemas"]["PaymentFailureType"]>;
|
|
6144
6156
|
declare const transactionSourceTypeValues: ReadonlyArray<FlattenedDeepRequired<components>["schemas"]["TransactionSourceType"]>;
|
|
6145
6157
|
declare const walletProviderTypeValues: ReadonlyArray<FlattenedDeepRequired<components>["schemas"]["WalletProviderType"]>;
|
|
6146
6158
|
declare const webhookEventTypeValues: ReadonlyArray<FlattenedDeepRequired<components>["schemas"]["WebhookEventType"]>;
|
|
@@ -6192,4 +6204,4 @@ declare function createPayApiClient(options: ClientOptions): openapi_fetch.Clien
|
|
|
6192
6204
|
/** A configured Amos Pay API client returned by {@link createPayApiClient}. */
|
|
6193
6205
|
type PayApiClient = ReturnType<typeof createPayApiClient>;
|
|
6194
6206
|
|
|
6195
|
-
export { type $defs, AMOS_API_BASE_URL_PRODUCTION, AMOS_API_BASE_URL_SANDBOX, AMOS_API_VERSION, type PayApiClient, allowedApplePayPaymentMethodInputTypeValues, allowedApplePayPaymentMethodTypeValues, allowedBankAccountPaymentMethodInputTypeValues, allowedBankAccountPaymentMethodTypeValues, allowedCardPaymentMethodInputTypeValues, allowedCardPaymentMethodTypeValues, allowedGooglePayPaymentMethodInputTypeValues, allowedGooglePayPaymentMethodTypeValues, chargeAllowed_reverse_actionValues, chargeStateValues, type components, createPayApiClient, embedConfirmApplePayPaymentMethodInputTypeValues, embedConfirmBankAccountPaymentMethodInputTypeValues, embedConfirmCardPaymentMethodInputTypeValues, embedConfirmGooglePayPaymentMethodInputTypeValues, externalAccountTypeValues, internationalBillingAddressOptionsModeValues, legalEntityApplicationStateTypeValues, legalEntityDocumentTypeValues, legalEntityEntityTypeValues, legalEntityOwnershipTypeValues, merchantBusinessCategoryTypeValues, type operations, organizationKindValues, originApplepayRegistrationStateTypeValues, type paths, paymentIntentCaptureMethodTypeValues, paymentIntentStateValues, paymentLinkAmountTypeValues, paymentMethodTypeValues, payoutDirectionTypeValues, payoutStateTypeValues, processorTransactionPayment_transaction_typeValues, processorTransactionTransaction_typeValues, refundAllowed_reverse_actionValues, refundStateTypeValues, setupIntentStateValues, subscriptionIntervalTypeValues, subscriptionPlanTypeValues, subscriptionStateValues, transactionSourceTypeValues, usOnlyBillingAddressOptionsModeValues, usStateTypeValues, walletProviderTypeValues, webhookEventTypeValues, type webhooks };
|
|
6207
|
+
export { type $defs, AMOS_API_BASE_URL_PRODUCTION, AMOS_API_BASE_URL_SANDBOX, AMOS_API_VERSION, type PayApiClient, allowedApplePayPaymentMethodInputTypeValues, allowedApplePayPaymentMethodTypeValues, allowedBankAccountPaymentMethodInputTypeValues, allowedBankAccountPaymentMethodTypeValues, allowedCardPaymentMethodInputTypeValues, allowedCardPaymentMethodTypeValues, allowedGooglePayPaymentMethodInputTypeValues, allowedGooglePayPaymentMethodTypeValues, chargeAllowed_reverse_actionValues, chargeStateValues, type components, createPayApiClient, embedConfirmApplePayPaymentMethodInputTypeValues, embedConfirmBankAccountPaymentMethodInputTypeValues, embedConfirmCardPaymentMethodInputTypeValues, embedConfirmGooglePayPaymentMethodInputTypeValues, externalAccountTypeValues, internationalBillingAddressOptionsModeValues, legalEntityApplicationStateTypeValues, legalEntityDocumentTypeValues, legalEntityEntityTypeValues, legalEntityOwnershipTypeValues, merchantBusinessCategoryTypeValues, type operations, organizationKindValues, originApplepayRegistrationStateTypeValues, type paths, paymentFailureTypeValues, paymentIntentCaptureMethodTypeValues, paymentIntentStateValues, paymentLinkAmountTypeValues, paymentMethodTypeValues, payoutDirectionTypeValues, payoutStateTypeValues, processorTransactionPayment_transaction_typeValues, processorTransactionTransaction_typeValues, refundAllowed_reverse_actionValues, refundStateTypeValues, setupIntentStateValues, subscriptionIntervalTypeValues, subscriptionPlanTypeValues, subscriptionStateValues, transactionSourceTypeValues, usOnlyBillingAddressOptionsModeValues, usStateTypeValues, walletProviderTypeValues, webhookEventTypeValues, type webhooks };
|
package/dist/index.js
CHANGED
|
@@ -57,6 +57,7 @@ __export(index_exports, {
|
|
|
57
57
|
merchantBusinessCategoryTypeValues: () => merchantBusinessCategoryTypeValues,
|
|
58
58
|
organizationKindValues: () => organizationKindValues,
|
|
59
59
|
originApplepayRegistrationStateTypeValues: () => originApplepayRegistrationStateTypeValues,
|
|
60
|
+
paymentFailureTypeValues: () => paymentFailureTypeValues,
|
|
60
61
|
paymentIntentCaptureMethodTypeValues: () => paymentIntentCaptureMethodTypeValues,
|
|
61
62
|
paymentIntentStateValues: () => paymentIntentStateValues,
|
|
62
63
|
paymentLinkAmountTypeValues: () => paymentLinkAmountTypeValues,
|
|
@@ -112,6 +113,7 @@ var payoutStateTypeValues = ["pending", "processing", "succeeded", "failed", "re
|
|
|
112
113
|
var refundStateTypeValues = ["pending", "processing", "requires_review", "succeeded", "cancelled", "failed"];
|
|
113
114
|
var subscriptionIntervalTypeValues = ["day", "week", "month", "year"];
|
|
114
115
|
var subscriptionPlanTypeValues = ["fixed", "variable"];
|
|
116
|
+
var paymentFailureTypeValues = ["payment_method_error", "processing_error"];
|
|
115
117
|
var transactionSourceTypeValues = ["api", "dashboard", "iframe", "system", "subscription", "admin"];
|
|
116
118
|
var walletProviderTypeValues = ["googlepay", "applepay"];
|
|
117
119
|
var webhookEventTypeValues = ["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.active", "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", "legal_entity_application.under_review", "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", "payment_method.updated", "payout.failed", "payout.notification_of_change", "payout.pending", "payout.processing", "payout.returned", "payout.same_day_missed", "payout.succeeded", "processor_transaction.completed", "reconciliation.created", "refund.cancelled", "refund.created", "refund.failed", "refund.pending", "refund.processing", "refund.requires_review", "refund.succeeded", "setup_intent.cancelled", "setup_intent.created", "setup_intent.errored", "setup_intent.failed", "setup_intent.requires_confirmation", "setup_intent.requires_payment_method", "setup_intent.requires_review", "setup_intent.succeeded", "setup_intent.verifying", "void.created", "void.failed", "void.pending", "void.processing", "void.requires_review", "void.succeeded"];
|
|
@@ -160,6 +162,7 @@ function createPayApiClient(options) {
|
|
|
160
162
|
merchantBusinessCategoryTypeValues,
|
|
161
163
|
organizationKindValues,
|
|
162
164
|
originApplepayRegistrationStateTypeValues,
|
|
165
|
+
paymentFailureTypeValues,
|
|
163
166
|
paymentIntentCaptureMethodTypeValues,
|
|
164
167
|
paymentIntentStateValues,
|
|
165
168
|
paymentLinkAmountTypeValues,
|