@vendasta/billing 14.1.0 → 14.2.0
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/esm2022/lib/_internal/enums/index.mjs +3 -2
- package/esm2022/lib/_internal/enums/payment-method.enum.mjs +13 -0
- package/esm2022/lib/_internal/interfaces/index.mjs +1 -1
- package/esm2022/lib/_internal/interfaces/invoice.interface.mjs +1 -1
- package/esm2022/lib/_internal/interfaces/payment-method.interface.mjs +2 -0
- package/esm2022/lib/_internal/objects/index.mjs +3 -2
- package/esm2022/lib/_internal/objects/invoice.mjs +7 -1
- package/esm2022/lib/_internal/objects/payment-method.mjs +110 -0
- package/esm2022/lib/_internal/payment-method.api.service.mjs +7 -2
- package/fesm2022/vendasta-billing.mjs +487 -355
- package/fesm2022/vendasta-billing.mjs.map +1 -1
- package/lib/_internal/enums/index.d.ts +2 -1
- package/lib/_internal/enums/payment-method.enum.d.ts +5 -0
- package/lib/_internal/interfaces/index.d.ts +2 -1
- package/lib/_internal/interfaces/invoice.interface.d.ts +1 -0
- package/lib/_internal/interfaces/payment-method.interface.d.ts +17 -0
- package/lib/_internal/objects/index.d.ts +2 -1
- package/lib/_internal/objects/invoice.d.ts +1 -0
- package/lib/_internal/objects/payment-method.d.ts +31 -0
- package/lib/_internal/payment-method.api.service.d.ts +3 -2
- package/package.json +1 -1
|
@@ -8,6 +8,8 @@ export { ContractSubscriptionStatus, } from './contract.enum';
|
|
|
8
8
|
export { ProductSummaryBillingStrategy, ProductSummaryDiscountDiscountType, ProductSummaryProductType, PricingRuleType, } from './product-summary.enum';
|
|
9
9
|
export { SubscribeValidationStatus, } from './subscribe-validation.enum';
|
|
10
10
|
export { Consumer, RenewalState, } from './subscription.enum';
|
|
11
|
+
export { PaymentCardCARD_TYPE, PaymentCardFUNDING_TYPE, } from './payment-card.enum';
|
|
12
|
+
export { PaymentMethodType, } from './payment-method.enum';
|
|
11
13
|
export { ListInvoicesRequestFiltersDateFilterDateField, InvoiceStatus, } from './invoice.enum';
|
|
12
14
|
export { PayoutStatus, PayoutType, } from './payout.enum';
|
|
13
15
|
export { SortDirection, } from './sort-direction.enum';
|
|
@@ -16,7 +18,6 @@ export { Month, } from './month.enum';
|
|
|
16
18
|
export { MerchantReportStatus, } from './merchant-report.enum';
|
|
17
19
|
export { CardType, } from './card.enum';
|
|
18
20
|
export { DisputeStatus, PaymentAllocationType, PaymentSource, PaymentStatus, RetailPaymentReferenceType, RetailRefundFailureReason, RetailRefundReason, RetailRefundStatus, RetailTransactionType, } from './payment.enum';
|
|
19
|
-
export { PaymentCardCARD_TYPE, PaymentCardFUNDING_TYPE, } from './payment-card.enum';
|
|
20
21
|
export { ProductType, } from './product.enum';
|
|
21
22
|
export { CreditType, PurchaseStatus, ListPurchaseRequestState, } from './purchase.enum';
|
|
22
23
|
export { ReferenceType, RefundReason, RefundStatus, } from './refund.enum';
|
|
@@ -17,6 +17,8 @@ export { CreateDiscountRequestInterface, CreateDiscountResponseInterface, Discou
|
|
|
17
17
|
export { AppliedTaxRateInterface, } from './applied-tax-rate.interface';
|
|
18
18
|
export { ArchiveTaxRequestInterface, CalculateLineItemTaxesRequestInterface, CalculateLineItemTaxesResponseInterface, CalculateTaxRequestInterface, CalculateTaxResponseInterface, CreateTaxRequestInterface, ListTaxRequestFiltersInterface, GetMultiTaxRequestInterface, GetMultiTaxResponseInterface, CalculateLineItemTaxesRequestLineItemInterface, CalculateLineItemTaxesResponseLineItemTaxesInterface, ListTaxRequestInterface, ListTaxResponseInterface, TaxRateInterface, UpdateTaxRequestInterface, } from './tax-rate.interface';
|
|
19
19
|
export { AppliedBundleInterface, AppliedBundleItemInterface, } from './applied-bundle.interface';
|
|
20
|
+
export { CreatePaymentCardRequestInterface, DeletePaymentCardRequestInterface, ListPaymentCardsRequestInterface, ListPaymentCardsResponseInterface, PaymentCardInterface, SetDefaultPaymentMethodRequestInterface, UpdatePaymentCardRequestInterface, } from './payment-card.interface';
|
|
21
|
+
export { ListPaymentMethodsRequestInterface, ListPaymentMethodsResponseInterface, PaymentACHDebitInterface, PaymentMethodInterface, } from './payment-method.interface';
|
|
20
22
|
export { AddBundleRequestInterface, AddBundleResponseInterface, AddLineItemRequestInterface, AddLineItemResponseInterface, ChargeInvoiceRequestInterface, CreateInvoiceRequestInterface, CreateInvoiceResponseInterface, CreatePaymentLinkRequestInterface, CreatePaymentLinkResponseInterface, InvoiceCustomerAddressInterface, ListInvoicesRequestFiltersDateFilterInterface, DeleteInvoiceRequestInterface, DeleteLineItemRequestInterface, DeleteLineItemResponseInterface, DuplicateInvoiceRequestInterface, DuplicateInvoiceResponseInterface, ListInvoicesRequestFiltersInterface, GetInvoiceRequestInterface, GetInvoiceResponseInterface, GetUpcomingInvoicePreviewRequestInterface, GetUpcomingInvoicePreviewResponseInterface, InvoiceInterface, InvoiceItemInterface, ListInvoicesRequestInterface, ListInvoicesResponseInterface, NoteInterface, PayInvoiceRequestInterface, PaymentLinkItemInterface, RemoveBundleRequestInterface, RemoveBundleResponseInterface, SendInvoiceRequestInterface, UpdateBundleRequestInterface, UpdateBundleResponseInterface, UpdateDefaultTaxRatesRequestInterface, UpdateDefaultTaxRatesResponseInterface, UpdateInvoiceRequestInterface, UpdateInvoiceResponseInterface, UpdateLineItemRequestInterface, UpdateLineItemResponseInterface, VoidInvoiceRequestInterface, } from './invoice.interface';
|
|
21
23
|
export { AccountBalanceInterface, BalanceInterface, BalanceAmountInterface, } from './balance.interface';
|
|
22
24
|
export { DateRangeInterface, } from './date-range.interface';
|
|
@@ -25,7 +27,6 @@ export { CancelRetailBillingRequestInterface, ChargeSalesInvoiceRequestInterface
|
|
|
25
27
|
export { ListMerchantBillingReportsRequestInterface, ListMerchantBillingReportsResponseInterface, MerchantReportInterface, } from './merchant-report.interface';
|
|
26
28
|
export { CreateMeteredComponentRequestInterface, MeteredComponentInterface, TickComponentUsageRequestInterface, } from './metered-component.interface';
|
|
27
29
|
export { AdjustmentInterface, RetailPaymentCardDetailsInterface, CloseRetailDisputeRequestInterface, ConfigureRetailPaymentProviderRequestInterface, ConfigureRetailPaymentProviderResponseInterface, ConfirmRetailPaymentRequestInterface, DisputeInterface, DisputeEvidenceInterface, SubmitEvidenceRequestDisputeEvidenceInterface, DisputeEvidenceDetailsInterface, FileInterface, GetRetailDisputeRequestInterface, GetRetailDisputeResponseInterface, GetRetailPaymentProviderRequestInterface, GetRetailPaymentProviderResponseInterface, GetRetailPaymentRequestInterface, GetRetailPaymentResponseInterface, GetWholesaleProviderPublicKeyRequestInterface, GetWholesaleProviderPublicKeyResponseInterface, ListPaymentRequestListPaymentFiltersInterface, ListPaymentRequestInterface, ListPaymentResponseInterface, ListRetailDisputesRequestInterface, ListRetailDisputesResponseInterface, ListRetailPaymentsRequestListRetailPaymentsFiltersInterface, ListRetailPaymentsRequestInterface, ListRetailPaymentsResponseInterface, ListRetailTransactionsRequestListRetailTransactionsFiltersInterface, ListRetailTransactionsRequestInterface, ListRetailTransactionsResponseInterface, PrepareRetailPaymentRequestOrderInterface, PaymentInterface, PaymentPaymentAllocationInterface, PrepareRetailPaymentRequestInterface, PrepareRetailPaymentResponseInterface, RefundRetailPaymentRequestInterface, RefundRetailPaymentResponseInterface, RetailPaymentInterface, RetailPaymentsEnabledRequestInterface, RetailPaymentsEnabledResponseInterface, RetailRefundInterface, RetailStatusRequestInterface, RetailStatusResponseInterface, RetailTransactionInterface, SubmitEvidenceRequestInterface, UpdateRetailPaymentProviderRequestInterface, RetailStatusResponseVerificationErrorInterface, RetailStatusResponseVerificationRequirementsInterface, } from './payment.interface';
|
|
28
|
-
export { CreatePaymentCardRequestInterface, DeletePaymentCardRequestInterface, ListPaymentCardsRequestInterface, ListPaymentCardsResponseInterface, PaymentCardInterface, SetDefaultPaymentMethodRequestInterface, UpdatePaymentCardRequestInterface, } from './payment-card.interface';
|
|
29
30
|
export { CreatePricingPlanProductRequestInterface, CreatePricingPlanProductResponseInterface, DeletePricingPlanProductRequestInterface, GetMultiPricingPlanProductRequestInterface, GetMultiPricingPlanProductResponseInterface, GetPricingPlanProductRequestInterface, GetPricingPlanProductResponseInterface, ListPricingPlanProductsRequestListPricingPlanProductsFiltersInterface, ListPricingPlanProductsRequestInterface, ListPricingPlanProductsResponseInterface, PricingPlanProductPricingEntryInterface, CreatePricingPlanProductRequestPricingEntryInterface, UpdatePricingPlanProductRequestPricingEntryInterface, PricingPlanProductInterface, UpdatePricingPlanProductRequestInterface, UpdatePricingPlanProductResponseInterface, UpsertWholesalePricingRequestInterface, } from './pricing-plan-product.interface';
|
|
30
31
|
export { CreateProductRequestInterface, DeleteProductRequestInterface, GetMultiProductRequestInterface, GetMultiProductResponseInterface, ListProductsRequestListProductsFiltersInterface, ListProductsRequestInterface, ListProductsResponseInterface, ProductInterface, GetMultiProductResponseProductsEntryInterface, UpdateProductRequestInterface, } from './product.interface';
|
|
31
32
|
export { AppliedCreditInterface, ListPurchaseRequestListPurchaseBillingStrategyFilterInterface, ListPurchaseRequestListPurchaseFiltersInterface, ListPurchaseItemsRequestListPurchaseItemsFiltersInterface, ListPurchaseItemsRequestInterface, ListPurchaseItemsResponseInterface, ListPurchaseRequestInterface, ListPurchaseResponseInterface, PauseDunningRequestInterface, PurchaseInterface, PurchaseItemInterface, ResumeDunningRequestInterface, RetryPurchaseRequestInterface, StopDunningRequestInterface, VoidPurchaseRequestInterface, } from './purchase.interface';
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { PaymentCardInterface } from './payment-card.interface';
|
|
2
|
+
import * as e from '../enums';
|
|
3
|
+
export interface ListPaymentMethodsRequestInterface {
|
|
4
|
+
merchantId?: string;
|
|
5
|
+
customerId?: string;
|
|
6
|
+
}
|
|
7
|
+
export interface ListPaymentMethodsResponseInterface {
|
|
8
|
+
paymentMethods?: PaymentMethodInterface[];
|
|
9
|
+
}
|
|
10
|
+
export interface PaymentACHDebitInterface {
|
|
11
|
+
lastFourDigits?: string;
|
|
12
|
+
}
|
|
13
|
+
export interface PaymentMethodInterface {
|
|
14
|
+
type?: e.PaymentMethodType;
|
|
15
|
+
card?: PaymentCardInterface;
|
|
16
|
+
achDebit?: PaymentACHDebitInterface;
|
|
17
|
+
}
|
|
@@ -17,6 +17,8 @@ export { CreateDiscountRequest, CreateDiscountResponse, Discount, ExpireDiscount
|
|
|
17
17
|
export { AppliedTaxRate, } from './applied-tax-rate';
|
|
18
18
|
export { ArchiveTaxRequest, CalculateLineItemTaxesRequest, CalculateLineItemTaxesResponse, CalculateTaxRequest, CalculateTaxResponse, CreateTaxRequest, ListTaxRequestFilters, GetMultiTaxRequest, GetMultiTaxResponse, CalculateLineItemTaxesRequestLineItem, CalculateLineItemTaxesResponseLineItemTaxes, ListTaxRequest, ListTaxResponse, TaxRate, UpdateTaxRequest, } from './tax-rate';
|
|
19
19
|
export { AppliedBundle, AppliedBundleItem, } from './applied-bundle';
|
|
20
|
+
export { CreatePaymentCardRequest, DeletePaymentCardRequest, ListPaymentCardsRequest, ListPaymentCardsResponse, PaymentCard, SetDefaultPaymentMethodRequest, UpdatePaymentCardRequest, } from './payment-card';
|
|
21
|
+
export { ListPaymentMethodsRequest, ListPaymentMethodsResponse, PaymentACHDebit, PaymentMethod, } from './payment-method';
|
|
20
22
|
export { AddBundleRequest, AddBundleResponse, AddLineItemRequest, AddLineItemResponse, ChargeInvoiceRequest, CreateInvoiceRequest, CreateInvoiceResponse, CreatePaymentLinkRequest, CreatePaymentLinkResponse, InvoiceCustomerAddress, ListInvoicesRequestFiltersDateFilter, DeleteInvoiceRequest, DeleteLineItemRequest, DeleteLineItemResponse, DuplicateInvoiceRequest, DuplicateInvoiceResponse, ListInvoicesRequestFilters, GetInvoiceRequest, GetInvoiceResponse, GetUpcomingInvoicePreviewRequest, GetUpcomingInvoicePreviewResponse, Invoice, InvoiceItem, ListInvoicesRequest, ListInvoicesResponse, Note, PayInvoiceRequest, PaymentLinkItem, RemoveBundleRequest, RemoveBundleResponse, SendInvoiceRequest, UpdateBundleRequest, UpdateBundleResponse, UpdateDefaultTaxRatesRequest, UpdateDefaultTaxRatesResponse, UpdateInvoiceRequest, UpdateInvoiceResponse, UpdateLineItemRequest, UpdateLineItemResponse, VoidInvoiceRequest, } from './invoice';
|
|
21
23
|
export { AccountBalance, Balance, BalanceAmount, } from './balance';
|
|
22
24
|
export { DateRange, } from './date-range';
|
|
@@ -25,7 +27,6 @@ export { CancelRetailBillingRequest, ChargeSalesInvoiceRequest, ConnectStripeAcc
|
|
|
25
27
|
export { ListMerchantBillingReportsRequest, ListMerchantBillingReportsResponse, MerchantReport, } from './merchant-report';
|
|
26
28
|
export { CreateMeteredComponentRequest, MeteredComponent, TickComponentUsageRequest, } from './metered-component';
|
|
27
29
|
export { Adjustment, RetailPaymentCardDetails, CloseRetailDisputeRequest, ConfigureRetailPaymentProviderRequest, ConfigureRetailPaymentProviderResponse, ConfirmRetailPaymentRequest, Dispute, DisputeEvidence, SubmitEvidenceRequestDisputeEvidence, DisputeEvidenceDetails, File, GetRetailDisputeRequest, GetRetailDisputeResponse, GetRetailPaymentProviderRequest, GetRetailPaymentProviderResponse, GetRetailPaymentRequest, GetRetailPaymentResponse, GetWholesaleProviderPublicKeyRequest, GetWholesaleProviderPublicKeyResponse, ListPaymentRequestListPaymentFilters, ListPaymentRequest, ListPaymentResponse, ListRetailDisputesRequest, ListRetailDisputesResponse, ListRetailPaymentsRequestListRetailPaymentsFilters, ListRetailPaymentsRequest, ListRetailPaymentsResponse, ListRetailTransactionsRequestListRetailTransactionsFilters, ListRetailTransactionsRequest, ListRetailTransactionsResponse, PrepareRetailPaymentRequestOrder, Payment, PaymentPaymentAllocation, PrepareRetailPaymentRequest, PrepareRetailPaymentResponse, RefundRetailPaymentRequest, RefundRetailPaymentResponse, RetailPayment, RetailPaymentsEnabledRequest, RetailPaymentsEnabledResponse, RetailRefund, RetailStatusRequest, RetailStatusResponse, RetailTransaction, SubmitEvidenceRequest, UpdateRetailPaymentProviderRequest, RetailStatusResponseVerificationError, RetailStatusResponseVerificationRequirements, } from './payment';
|
|
28
|
-
export { CreatePaymentCardRequest, DeletePaymentCardRequest, ListPaymentCardsRequest, ListPaymentCardsResponse, PaymentCard, SetDefaultPaymentMethodRequest, UpdatePaymentCardRequest, } from './payment-card';
|
|
29
30
|
export { CreatePricingPlanProductRequest, CreatePricingPlanProductResponse, DeletePricingPlanProductRequest, GetMultiPricingPlanProductRequest, GetMultiPricingPlanProductResponse, GetPricingPlanProductRequest, GetPricingPlanProductResponse, ListPricingPlanProductsRequestListPricingPlanProductsFilters, ListPricingPlanProductsRequest, ListPricingPlanProductsResponse, PricingPlanProductPricingEntry, CreatePricingPlanProductRequestPricingEntry, UpdatePricingPlanProductRequestPricingEntry, PricingPlanProduct, UpdatePricingPlanProductRequest, UpdatePricingPlanProductResponse, UpsertWholesalePricingRequest, } from './pricing-plan-product';
|
|
30
31
|
export { CreateProductRequest, DeleteProductRequest, GetMultiProductRequest, GetMultiProductResponse, ListProductsRequestListProductsFilters, ListProductsRequest, ListProductsResponse, Product, GetMultiProductResponseProductsEntry, UpdateProductRequest, } from './product';
|
|
31
32
|
export { AppliedCredit, ListPurchaseRequestListPurchaseBillingStrategyFilter, ListPurchaseRequestListPurchaseFilters, ListPurchaseItemsRequestListPurchaseItemsFilters, ListPurchaseItemsRequest, ListPurchaseItemsResponse, ListPurchaseRequest, ListPurchaseResponse, PauseDunningRequest, Purchase, PurchaseItem, ResumeDunningRequest, RetryPurchaseRequest, StopDunningRequest, VoidPurchaseRequest, } from './purchase';
|
|
@@ -206,6 +206,7 @@ export declare class Invoice implements i.InvoiceInterface {
|
|
|
206
206
|
notes: Note[];
|
|
207
207
|
additionalContactIds: string[];
|
|
208
208
|
autoAdvance: Date;
|
|
209
|
+
paymentMethodTypes: e.PaymentMethodType[];
|
|
209
210
|
static fromProto(proto: any): Invoice;
|
|
210
211
|
constructor(kwargs?: i.InvoiceInterface);
|
|
211
212
|
toApiJson(): object;
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import * as i from '../interfaces';
|
|
2
|
+
import { PaymentCard } from './payment-card';
|
|
3
|
+
import * as e from '../enums';
|
|
4
|
+
export declare function enumStringToValue<E>(enumRef: any, value: string): E;
|
|
5
|
+
export declare class ListPaymentMethodsRequest implements i.ListPaymentMethodsRequestInterface {
|
|
6
|
+
merchantId: string;
|
|
7
|
+
customerId: string;
|
|
8
|
+
static fromProto(proto: any): ListPaymentMethodsRequest;
|
|
9
|
+
constructor(kwargs?: i.ListPaymentMethodsRequestInterface);
|
|
10
|
+
toApiJson(): object;
|
|
11
|
+
}
|
|
12
|
+
export declare class ListPaymentMethodsResponse implements i.ListPaymentMethodsResponseInterface {
|
|
13
|
+
paymentMethods: PaymentMethod[];
|
|
14
|
+
static fromProto(proto: any): ListPaymentMethodsResponse;
|
|
15
|
+
constructor(kwargs?: i.ListPaymentMethodsResponseInterface);
|
|
16
|
+
toApiJson(): object;
|
|
17
|
+
}
|
|
18
|
+
export declare class PaymentACHDebit implements i.PaymentACHDebitInterface {
|
|
19
|
+
lastFourDigits: string;
|
|
20
|
+
static fromProto(proto: any): PaymentACHDebit;
|
|
21
|
+
constructor(kwargs?: i.PaymentACHDebitInterface);
|
|
22
|
+
toApiJson(): object;
|
|
23
|
+
}
|
|
24
|
+
export declare class PaymentMethod implements i.PaymentMethodInterface {
|
|
25
|
+
type: e.PaymentMethodType;
|
|
26
|
+
card: PaymentCard;
|
|
27
|
+
achDebit: PaymentACHDebit;
|
|
28
|
+
static fromProto(proto: any): PaymentMethod;
|
|
29
|
+
constructor(kwargs?: i.PaymentMethodInterface);
|
|
30
|
+
toApiJson(): object;
|
|
31
|
+
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { DeletePaymentCardRequest, ListPaymentCardsRequest, ListPaymentCardsResponse, SetDefaultPaymentMethodRequest } from './objects/';
|
|
2
|
-
import { DeletePaymentCardRequestInterface, ListPaymentCardsRequestInterface, SetDefaultPaymentMethodRequestInterface } from './interfaces/';
|
|
1
|
+
import { DeletePaymentCardRequest, ListPaymentCardsRequest, ListPaymentCardsResponse, ListPaymentMethodsRequest, ListPaymentMethodsResponse, SetDefaultPaymentMethodRequest } from './objects/';
|
|
2
|
+
import { DeletePaymentCardRequestInterface, ListPaymentCardsRequestInterface, ListPaymentMethodsRequestInterface, SetDefaultPaymentMethodRequestInterface } from './interfaces/';
|
|
3
3
|
import { HttpClient, HttpResponse } from '@angular/common/http';
|
|
4
4
|
import { HostService } from '../_generated/host.service';
|
|
5
5
|
import { Observable } from 'rxjs';
|
|
@@ -13,6 +13,7 @@ export declare class PaymentMethodApiService {
|
|
|
13
13
|
listPaymentCards(r: ListPaymentCardsRequest | ListPaymentCardsRequestInterface): Observable<ListPaymentCardsResponse>;
|
|
14
14
|
deletePaymentCard(r: DeletePaymentCardRequest | DeletePaymentCardRequestInterface): Observable<HttpResponse<null>>;
|
|
15
15
|
setDefaultPaymentMethod(r: SetDefaultPaymentMethodRequest | SetDefaultPaymentMethodRequestInterface): Observable<HttpResponse<null>>;
|
|
16
|
+
list(r: ListPaymentMethodsRequest | ListPaymentMethodsRequestInterface): Observable<ListPaymentMethodsResponse>;
|
|
16
17
|
static ɵfac: i0.ɵɵFactoryDeclaration<PaymentMethodApiService, never>;
|
|
17
18
|
static ɵprov: i0.ɵɵInjectableDeclaration<PaymentMethodApiService>;
|
|
18
19
|
}
|