@smartbills/sdk 0.0.2-alpha.43 → 0.0.2-alpha.45
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/@types/client/SBClient.d.ts +78 -0
- package/dist/@types/client/SBClient.d.ts.map +1 -0
- package/dist/@types/client/SBClientOptions.d.ts +19 -0
- package/dist/@types/client/SBClientOptions.d.ts.map +1 -0
- package/dist/@types/client/SBCredentials.d.ts +29 -0
- package/dist/@types/client/SBCredentials.d.ts.map +1 -0
- package/dist/@types/client/SBEnvironment.d.ts +8 -0
- package/dist/@types/client/SBEnvironment.d.ts.map +1 -0
- package/dist/@types/client/SBError.d.ts +9 -0
- package/dist/@types/client/SBError.d.ts.map +1 -0
- package/dist/@types/client/SBErrorResponse.d.ts +11 -0
- package/dist/@types/client/SBErrorResponse.d.ts.map +1 -0
- package/dist/@types/client/SBException.d.ts +17 -0
- package/dist/@types/client/SBException.d.ts.map +1 -0
- package/dist/@types/client/SBInstance.d.ts +12 -0
- package/dist/@types/client/SBInstance.d.ts.map +1 -0
- package/dist/@types/client/SBLogger.d.ts +8 -0
- package/dist/@types/client/SBLogger.d.ts.map +1 -0
- package/dist/@types/client/SBPermission.d.ts +49 -0
- package/dist/@types/client/SBPermission.d.ts.map +1 -0
- package/dist/@types/client/SBRequestOption.d.ts +14 -0
- package/dist/@types/client/SBRequestOption.d.ts.map +1 -0
- package/dist/@types/client/SBServiceOptions.d.ts +11 -0
- package/dist/@types/client/SBServiceOptions.d.ts.map +1 -0
- package/dist/@types/constants/login/LoginError.d.ts +8 -0
- package/dist/@types/constants/login/LoginError.d.ts.map +1 -0
- package/dist/@types/entities/account/SBExternalProvider.d.ts +8 -0
- package/dist/@types/entities/account/SBExternalProvider.d.ts.map +1 -0
- package/dist/@types/entities/account/SBGenderEnum.d.ts +8 -0
- package/dist/@types/entities/account/SBGenderEnum.d.ts.map +1 -0
- package/dist/@types/entities/account/SBUserAccount.d.ts +24 -0
- package/dist/@types/entities/account/SBUserAccount.d.ts.map +1 -0
- package/dist/@types/entities/address/SBAddress.d.ts +18 -0
- package/dist/@types/entities/address/SBAddress.d.ts.map +1 -0
- package/dist/@types/entities/address/SBBillingAddress.d.ts +14 -0
- package/dist/@types/entities/address/SBBillingAddress.d.ts.map +1 -0
- package/dist/@types/entities/address/SBCoordinate.d.ts +9 -0
- package/dist/@types/entities/address/SBCoordinate.d.ts.map +1 -0
- package/dist/@types/entities/api-logs/SBLog.d.ts +19 -0
- package/dist/@types/entities/api-logs/SBLog.d.ts.map +1 -0
- package/dist/@types/entities/attachments/SBAttachment.d.ts +27 -0
- package/dist/@types/entities/attachments/SBAttachment.d.ts.map +1 -0
- package/dist/@types/entities/banks/SBBalanceHistory.d.ts +11 -0
- package/dist/@types/entities/banks/SBBalanceHistory.d.ts.map +1 -0
- package/dist/@types/entities/banks/SBBank.d.ts +18 -0
- package/dist/@types/entities/banks/SBBank.d.ts.map +1 -0
- package/dist/@types/entities/banks/SBBankAccount.d.ts +19 -0
- package/dist/@types/entities/banks/SBBankAccount.d.ts.map +1 -0
- package/dist/@types/entities/banks/SBBankBalance.d.ts +11 -0
- package/dist/@types/entities/banks/SBBankBalance.d.ts.map +1 -0
- package/dist/@types/entities/banks/SBBankInstitution.d.ts +12 -0
- package/dist/@types/entities/banks/SBBankInstitution.d.ts.map +1 -0
- package/dist/@types/entities/banks/SBBankState.d.ts +9 -0
- package/dist/@types/entities/banks/SBBankState.d.ts.map +1 -0
- package/dist/@types/entities/banks/SBBankTransaction.d.ts +36 -0
- package/dist/@types/entities/banks/SBBankTransaction.d.ts.map +1 -0
- package/dist/@types/entities/barcode/SBBarcode.d.ts +10 -0
- package/dist/@types/entities/barcode/SBBarcode.d.ts.map +1 -0
- package/dist/@types/entities/barcode/SBBarcodeType.d.ts +27 -0
- package/dist/@types/entities/barcode/SBBarcodeType.d.ts.map +1 -0
- package/dist/@types/entities/base.d.ts +58 -0
- package/dist/@types/entities/base.d.ts.map +1 -0
- package/dist/@types/entities/batches/SBBatch.d.ts +6 -0
- package/dist/@types/entities/batches/SBBatch.d.ts.map +1 -0
- package/dist/@types/entities/businesses/SBBusiness.d.ts +19 -0
- package/dist/@types/entities/businesses/SBBusiness.d.ts.map +1 -0
- package/dist/@types/entities/businesses/customers/SBCustomer.d.ts +35 -0
- package/dist/@types/entities/businesses/customers/SBCustomer.d.ts.map +1 -0
- package/dist/@types/entities/businesses/customers/balance-transactions/SBCustomerBalanceTransaction.d.ts +12 -0
- package/dist/@types/entities/businesses/customers/balance-transactions/SBCustomerBalanceTransaction.d.ts.map +1 -0
- package/dist/@types/entities/businesses/departments/SBDepartment.d.ts +35 -0
- package/dist/@types/entities/businesses/departments/SBDepartment.d.ts.map +1 -0
- package/dist/@types/entities/businesses/departments/SBDepartmentTeamMember.d.ts +22 -0
- package/dist/@types/entities/businesses/departments/SBDepartmentTeamMember.d.ts.map +1 -0
- package/dist/@types/entities/businesses/fees/SBFee.d.ts +12 -0
- package/dist/@types/entities/businesses/fees/SBFee.d.ts.map +1 -0
- package/dist/@types/entities/businesses/fees/SBFeeType.d.ts +7 -0
- package/dist/@types/entities/businesses/fees/SBFeeType.d.ts.map +1 -0
- package/dist/@types/entities/businesses/locations/SBLocation.d.ts +16 -0
- package/dist/@types/entities/businesses/locations/SBLocation.d.ts.map +1 -0
- package/dist/@types/entities/businesses/locations/SBLocationBatch.d.ts +9 -0
- package/dist/@types/entities/businesses/locations/SBLocationBatch.d.ts.map +1 -0
- package/dist/@types/entities/businesses/products/SBProduct.d.ts +21 -0
- package/dist/@types/entities/businesses/products/SBProduct.d.ts.map +1 -0
- package/dist/@types/entities/businesses/products/SBProductImage.d.ts +8 -0
- package/dist/@types/entities/businesses/products/SBProductImage.d.ts.map +1 -0
- package/dist/@types/entities/businesses/products/SBProductTranslation.d.ts +11 -0
- package/dist/@types/entities/businesses/products/SBProductTranslation.d.ts.map +1 -0
- package/dist/@types/entities/businesses/products/SBProductVariant.d.ts +18 -0
- package/dist/@types/entities/businesses/products/SBProductVariant.d.ts.map +1 -0
- package/dist/@types/entities/businesses/products/SBProductVariantOption.d.ts +7 -0
- package/dist/@types/entities/businesses/products/SBProductVariantOption.d.ts.map +1 -0
- package/dist/@types/entities/businesses/products/SBProductVendor.d.ts +7 -0
- package/dist/@types/entities/businesses/products/SBProductVendor.d.ts.map +1 -0
- package/dist/@types/entities/businesses/products/modifiers/SBProductModifier.d.ts +10 -0
- package/dist/@types/entities/businesses/products/modifiers/SBProductModifier.d.ts.map +1 -0
- package/dist/@types/entities/businesses/products/options/SBProductOption.d.ts +33 -0
- package/dist/@types/entities/businesses/products/options/SBProductOption.d.ts.map +1 -0
- package/dist/@types/entities/businesses/promo-codes/SBPromoCode.d.ts +13 -0
- package/dist/@types/entities/businesses/promo-codes/SBPromoCode.d.ts.map +1 -0
- package/dist/@types/entities/businesses/promo-codes/SBPromoCodeType.d.ts +4 -0
- package/dist/@types/entities/businesses/promo-codes/SBPromoCodeType.d.ts.map +1 -0
- package/dist/@types/entities/businesses/reviews/SBBusinessReview.d.ts +9 -0
- package/dist/@types/entities/businesses/reviews/SBBusinessReview.d.ts.map +1 -0
- package/dist/@types/entities/businesses/tables/SBTable.d.ts +15 -0
- package/dist/@types/entities/businesses/tables/SBTable.d.ts.map +1 -0
- package/dist/@types/entities/businesses/taxes/SBReceiptItemTax.d.ts +10 -0
- package/dist/@types/entities/businesses/taxes/SBReceiptItemTax.d.ts.map +1 -0
- package/dist/@types/entities/businesses/taxes/SBReceiptTax.d.ts +12 -0
- package/dist/@types/entities/businesses/taxes/SBReceiptTax.d.ts.map +1 -0
- package/dist/@types/entities/businesses/taxes/SBTax.d.ts +17 -0
- package/dist/@types/entities/businesses/taxes/SBTax.d.ts.map +1 -0
- package/dist/@types/entities/businesses/taxes/SBTaxType.d.ts +4 -0
- package/dist/@types/entities/businesses/taxes/SBTaxType.d.ts.map +1 -0
- package/dist/@types/entities/businesses/team/invitations/SBTeamMemberInvitation.d.ts +17 -0
- package/dist/@types/entities/businesses/team/invitations/SBTeamMemberInvitation.d.ts.map +1 -0
- package/dist/@types/entities/businesses/team/invitations/SBTeamMemberInvitationStatus.d.ts +9 -0
- package/dist/@types/entities/businesses/team/invitations/SBTeamMemberInvitationStatus.d.ts.map +1 -0
- package/dist/@types/entities/businesses/team/members/SBTeamMember.d.ts +22 -0
- package/dist/@types/entities/businesses/team/members/SBTeamMember.d.ts.map +1 -0
- package/dist/@types/entities/businesses/team/members/SBTeamMemberRole.d.ts +10 -0
- package/dist/@types/entities/businesses/team/members/SBTeamMemberRole.d.ts.map +1 -0
- package/dist/@types/entities/businesses/team/members/SBTeamMemberStatus.d.ts +10 -0
- package/dist/@types/entities/businesses/team/members/SBTeamMemberStatus.d.ts.map +1 -0
- package/dist/@types/entities/cards/SBCard.d.ts +20 -0
- package/dist/@types/entities/cards/SBCard.d.ts.map +1 -0
- package/dist/@types/entities/cards/SBCardSetupIntent.d.ts +7 -0
- package/dist/@types/entities/cards/SBCardSetupIntent.d.ts.map +1 -0
- package/dist/@types/entities/cards/SBCardType.d.ts +9 -0
- package/dist/@types/entities/cards/SBCardType.d.ts.map +1 -0
- package/dist/@types/entities/common/ImageUploadRequest.d.ts +8 -0
- package/dist/@types/entities/common/ImageUploadRequest.d.ts.map +1 -0
- package/dist/@types/entities/documents/SBDocument.d.ts +16 -0
- package/dist/@types/entities/documents/SBDocument.d.ts.map +1 -0
- package/dist/@types/entities/documents/SBDocumentUpload.d.ts +8 -0
- package/dist/@types/entities/documents/SBDocumentUpload.d.ts.map +1 -0
- package/dist/@types/entities/documents/ocr/SBBoundingBox.d.ts +10 -0
- package/dist/@types/entities/documents/ocr/SBBoundingBox.d.ts.map +1 -0
- package/dist/@types/entities/documents/ocr/SBDocumentOCR.d.ts +10 -0
- package/dist/@types/entities/documents/ocr/SBDocumentOCR.d.ts.map +1 -0
- package/dist/@types/entities/documents/ocr/SBExpenseDetection.d.ts +11 -0
- package/dist/@types/entities/documents/ocr/SBExpenseDetection.d.ts.map +1 -0
- package/dist/@types/entities/documents/ocr/SBExpenseField.d.ts +13 -0
- package/dist/@types/entities/documents/ocr/SBExpenseField.d.ts.map +1 -0
- package/dist/@types/entities/documents/ocr/SBExpenseType.d.ts +8 -0
- package/dist/@types/entities/documents/ocr/SBExpenseType.d.ts.map +1 -0
- package/dist/@types/entities/documents/ocr/SBGeometry.d.ts +11 -0
- package/dist/@types/entities/documents/ocr/SBGeometry.d.ts.map +1 -0
- package/dist/@types/entities/documents/ocr/SBLineItemFields.d.ts +9 -0
- package/dist/@types/entities/documents/ocr/SBLineItemFields.d.ts.map +1 -0
- package/dist/@types/entities/documents/ocr/SBLineItemGroup.d.ts +10 -0
- package/dist/@types/entities/documents/ocr/SBLineItemGroup.d.ts.map +1 -0
- package/dist/@types/entities/documents/ocr/SBOCRResult.d.ts +12 -0
- package/dist/@types/entities/documents/ocr/SBOCRResult.d.ts.map +1 -0
- package/dist/@types/entities/documents/ocr/SBPoint.d.ts +7 -0
- package/dist/@types/entities/documents/ocr/SBPoint.d.ts.map +1 -0
- package/dist/@types/entities/domains/SBDomain.d.ts +10 -0
- package/dist/@types/entities/domains/SBDomain.d.ts.map +1 -0
- package/dist/@types/entities/expense-groups/SBExpenseGroup.d.ts +15 -0
- package/dist/@types/entities/expense-groups/SBExpenseGroup.d.ts.map +1 -0
- package/dist/@types/entities/expense-groups/SBExpenseGroupAutomation.d.ts +5 -0
- package/dist/@types/entities/expense-groups/SBExpenseGroupAutomation.d.ts.map +1 -0
- package/dist/@types/entities/expense-groups/SBExpenseGroupBudget.d.ts +7 -0
- package/dist/@types/entities/expense-groups/SBExpenseGroupBudget.d.ts.map +1 -0
- package/dist/@types/entities/expense-groups/SBExpenseGroupForm.d.ts +12 -0
- package/dist/@types/entities/expense-groups/SBExpenseGroupForm.d.ts.map +1 -0
- package/dist/@types/entities/explore/SBExploreBusiness.d.ts +14 -0
- package/dist/@types/entities/explore/SBExploreBusiness.d.ts.map +1 -0
- package/dist/@types/entities/friends/SBFriend.d.ts +10 -0
- package/dist/@types/entities/friends/SBFriend.d.ts.map +1 -0
- package/dist/@types/entities/friends/SBFriendRequest.d.ts +10 -0
- package/dist/@types/entities/friends/SBFriendRequest.d.ts.map +1 -0
- package/dist/@types/entities/fulfillment/SBFulfillment.d.ts +24 -0
- package/dist/@types/entities/fulfillment/SBFulfillment.d.ts.map +1 -0
- package/dist/@types/entities/fulfillment/SBFulfillmentItem.d.ts +13 -0
- package/dist/@types/entities/fulfillment/SBFulfillmentItem.d.ts.map +1 -0
- package/dist/@types/entities/images/SBImage.d.ts +13 -0
- package/dist/@types/entities/images/SBImage.d.ts.map +1 -0
- package/dist/@types/entities/integrations/SBIntegration.d.ts +16 -0
- package/dist/@types/entities/integrations/SBIntegration.d.ts.map +1 -0
- package/dist/@types/entities/invoices/SBInvoice.d.ts +7 -0
- package/dist/@types/entities/invoices/SBInvoice.d.ts.map +1 -0
- package/dist/@types/entities/loyalty.d.ts +266 -0
- package/dist/@types/entities/loyalty.d.ts.map +1 -0
- package/dist/@types/entities/money/SBMoney.d.ts +7 -0
- package/dist/@types/entities/money/SBMoney.d.ts.map +1 -0
- package/dist/@types/entities/notifications/SBNotification.d.ts +29 -0
- package/dist/@types/entities/notifications/SBNotification.d.ts.map +1 -0
- package/dist/@types/entities/oauth/JwtToken.d.ts +10 -0
- package/dist/@types/entities/oauth/JwtToken.d.ts.map +1 -0
- package/dist/@types/entities/payment-methods/SBPaymentMethod.d.ts +25 -0
- package/dist/@types/entities/payment-methods/SBPaymentMethod.d.ts.map +1 -0
- package/dist/@types/entities/payment-methods/SBPaymentMethodBank.d.ts +10 -0
- package/dist/@types/entities/payment-methods/SBPaymentMethodBank.d.ts.map +1 -0
- package/dist/@types/entities/payment-methods/SBPaymentMethodCard.d.ts +19 -0
- package/dist/@types/entities/payment-methods/SBPaymentMethodCard.d.ts.map +1 -0
- package/dist/@types/entities/payment-methods/SBPaymentMethodFingerprint.d.ts +7 -0
- package/dist/@types/entities/payment-methods/SBPaymentMethodFingerprint.d.ts.map +1 -0
- package/dist/@types/entities/payment-methods/SBPaymentMethodFingerprintProvider.d.ts +7 -0
- package/dist/@types/entities/payment-methods/SBPaymentMethodFingerprintProvider.d.ts.map +1 -0
- package/dist/@types/entities/payment-methods/SBPaymentMethodSetup.d.ts +8 -0
- package/dist/@types/entities/payment-methods/SBPaymentMethodSetup.d.ts.map +1 -0
- package/dist/@types/entities/payments/SBPaymentStatus.d.ts +28 -0
- package/dist/@types/entities/payments/SBPaymentStatus.d.ts.map +1 -0
- package/dist/@types/entities/prices/SBPrice.d.ts +13 -0
- package/dist/@types/entities/prices/SBPrice.d.ts.map +1 -0
- package/dist/@types/entities/receipts/SBReceipt.d.ts +65 -0
- package/dist/@types/entities/receipts/SBReceipt.d.ts.map +1 -0
- package/dist/@types/entities/receipts/SBReceiptBatch.d.ts +8 -0
- package/dist/@types/entities/receipts/SBReceiptBatch.d.ts.map +1 -0
- package/dist/@types/entities/receipts/SBReceiptFee.d.ts +11 -0
- package/dist/@types/entities/receipts/SBReceiptFee.d.ts.map +1 -0
- package/dist/@types/entities/receipts/SBReceiptItem.d.ts +23 -0
- package/dist/@types/entities/receipts/SBReceiptItem.d.ts.map +1 -0
- package/dist/@types/entities/receipts/SBReceiptItemSplit.d.ts +14 -0
- package/dist/@types/entities/receipts/SBReceiptItemSplit.d.ts.map +1 -0
- package/dist/@types/entities/receipts/SBReceiptSource.d.ts +10 -0
- package/dist/@types/entities/receipts/SBReceiptSource.d.ts.map +1 -0
- package/dist/@types/entities/receipts/SBReceiptTransaction.d.ts +23 -0
- package/dist/@types/entities/receipts/SBReceiptTransaction.d.ts.map +1 -0
- package/dist/@types/entities/receipts/SBReceiptType.d.ts +9 -0
- package/dist/@types/entities/receipts/SBReceiptType.d.ts.map +1 -0
- package/dist/@types/entities/receipts/SBReceiptUser.d.ts +12 -0
- package/dist/@types/entities/receipts/SBReceiptUser.d.ts.map +1 -0
- package/dist/@types/entities/receipts/discounts/SBReceiptDiscount.d.ts +14 -0
- package/dist/@types/entities/receipts/discounts/SBReceiptDiscount.d.ts.map +1 -0
- package/dist/@types/entities/receipts/metadata/SBBrowserMetadata.d.ts +11 -0
- package/dist/@types/entities/receipts/metadata/SBBrowserMetadata.d.ts.map +1 -0
- package/dist/@types/entities/receipts/metadata/SBMetadata.d.ts +4 -0
- package/dist/@types/entities/receipts/metadata/SBMetadata.d.ts.map +1 -0
- package/dist/@types/entities/receipts/metadata/SBReceiptMetadata.d.ts +15 -0
- package/dist/@types/entities/receipts/metadata/SBReceiptMetadata.d.ts.map +1 -0
- package/dist/@types/entities/receipts/payments/SBReceiptPayment.d.ts +40 -0
- package/dist/@types/entities/receipts/payments/SBReceiptPayment.d.ts.map +1 -0
- package/dist/@types/entities/receipts/payments/SBReceiptPaymentBalance.d.ts +5 -0
- package/dist/@types/entities/receipts/payments/SBReceiptPaymentBalance.d.ts.map +1 -0
- package/dist/@types/entities/receipts/payments/SBReceiptPaymentBankAccount.d.ts +12 -0
- package/dist/@types/entities/receipts/payments/SBReceiptPaymentBankAccount.d.ts.map +1 -0
- package/dist/@types/entities/receipts/payments/SBReceiptPaymentCard.d.ts +23 -0
- package/dist/@types/entities/receipts/payments/SBReceiptPaymentCard.d.ts.map +1 -0
- package/dist/@types/entities/receipts/payments/SBReceiptPaymentCardAvsResult.d.ts +15 -0
- package/dist/@types/entities/receipts/payments/SBReceiptPaymentCardAvsResult.d.ts.map +1 -0
- package/dist/@types/entities/receipts/payments/SBReceiptPaymentCardCvvResult.d.ts +8 -0
- package/dist/@types/entities/receipts/payments/SBReceiptPaymentCardCvvResult.d.ts.map +1 -0
- package/dist/@types/entities/receipts/payments/SBReceiptPaymentCardEMV.d.ts +5 -0
- package/dist/@types/entities/receipts/payments/SBReceiptPaymentCardEMV.d.ts.map +1 -0
- package/dist/@types/entities/receipts/payments/SBReceiptPaymentCardEntryMethod.d.ts +10 -0
- package/dist/@types/entities/receipts/payments/SBReceiptPaymentCardEntryMethod.d.ts.map +1 -0
- package/dist/@types/entities/receipts/payments/SBReceiptPaymentCardError.d.ts +7 -0
- package/dist/@types/entities/receipts/payments/SBReceiptPaymentCardError.d.ts.map +1 -0
- package/dist/@types/entities/receipts/payments/SBReceiptPaymentCardTimeline.d.ts +8 -0
- package/dist/@types/entities/receipts/payments/SBReceiptPaymentCardTimeline.d.ts.map +1 -0
- package/dist/@types/entities/receipts/payments/SBReceiptPaymentCash.d.ts +9 -0
- package/dist/@types/entities/receipts/payments/SBReceiptPaymentCash.d.ts.map +1 -0
- package/dist/@types/entities/receipts/payments/SBReceiptPaymentExternal.d.ts +12 -0
- package/dist/@types/entities/receipts/payments/SBReceiptPaymentExternal.d.ts.map +1 -0
- package/dist/@types/entities/receipts/payments/SBReceiptPaymentExternalType.d.ts +17 -0
- package/dist/@types/entities/receipts/payments/SBReceiptPaymentExternalType.d.ts.map +1 -0
- package/dist/@types/entities/receipts/payments/SBReceiptPaymentMethodCard.d.ts +19 -0
- package/dist/@types/entities/receipts/payments/SBReceiptPaymentMethodCard.d.ts.map +1 -0
- package/dist/@types/entities/receipts/payments/SBReceiptPaymentRefund.d.ts +7 -0
- package/dist/@types/entities/receipts/payments/SBReceiptPaymentRefund.d.ts.map +1 -0
- package/dist/@types/entities/receipts/payments/SBReceiptPaymentRiskEvaluation.d.ts +9 -0
- package/dist/@types/entities/receipts/payments/SBReceiptPaymentRiskEvaluation.d.ts.map +1 -0
- package/dist/@types/entities/receipts/payments/SBReceiptPaymentRiskLevel.d.ts +8 -0
- package/dist/@types/entities/receipts/payments/SBReceiptPaymentRiskLevel.d.ts.map +1 -0
- package/dist/@types/entities/receipts/payments/SBReceiptPaymentStatus.d.ts +10 -0
- package/dist/@types/entities/receipts/payments/SBReceiptPaymentStatus.d.ts.map +1 -0
- package/dist/@types/entities/receipts/payments/SBReceiptPaymentType.d.ts +11 -0
- package/dist/@types/entities/receipts/payments/SBReceiptPaymentType.d.ts.map +1 -0
- package/dist/@types/entities/receipts/transactions/SBPaymentDetail.d.ts +11 -0
- package/dist/@types/entities/receipts/transactions/SBPaymentDetail.d.ts.map +1 -0
- package/dist/@types/entities/refund/SBReceiptItemRefund.d.ts +17 -0
- package/dist/@types/entities/refund/SBReceiptItemRefund.d.ts.map +1 -0
- package/dist/@types/entities/refund/SBRefund.d.ts +18 -0
- package/dist/@types/entities/refund/SBRefund.d.ts.map +1 -0
- package/dist/@types/entities/refund/SBRefundAjustment.d.ts +15 -0
- package/dist/@types/entities/refund/SBRefundAjustment.d.ts.map +1 -0
- package/dist/@types/entities/reports/SBDateRange.d.ts +7 -0
- package/dist/@types/entities/reports/SBDateRange.d.ts.map +1 -0
- package/dist/@types/entities/reports/SBPeriodReport.d.ts +9 -0
- package/dist/@types/entities/reports/SBPeriodReport.d.ts.map +1 -0
- package/dist/@types/entities/reports/SBPeriodReportData.d.ts +9 -0
- package/dist/@types/entities/reports/SBPeriodReportData.d.ts.map +1 -0
- package/dist/@types/entities/settlements/SBSettlement.d.ts +18 -0
- package/dist/@types/entities/settlements/SBSettlement.d.ts.map +1 -0
- package/dist/@types/entities/settlements/SBSettlementPayment.d.ts +15 -0
- package/dist/@types/entities/settlements/SBSettlementPayment.d.ts.map +1 -0
- package/dist/@types/entities/subscriptions/SBSubscription.d.ts +43 -0
- package/dist/@types/entities/subscriptions/SBSubscription.d.ts.map +1 -0
- package/dist/@types/entities/transactions/SBTransaction.d.ts +22 -0
- package/dist/@types/entities/transactions/SBTransaction.d.ts.map +1 -0
- package/dist/@types/entities/transactions/SBTransactionType.d.ts +9 -0
- package/dist/@types/entities/transactions/SBTransactionType.d.ts.map +1 -0
- package/dist/@types/entities/users/SBUser.d.ts +10 -0
- package/dist/@types/entities/users/SBUser.d.ts.map +1 -0
- package/dist/@types/entities/vendors/SBVendor.d.ts +15 -0
- package/dist/@types/entities/vendors/SBVendor.d.ts.map +1 -0
- package/dist/@types/entities/wallet/SBWallet.d.ts +27 -0
- package/dist/@types/entities/wallet/SBWallet.d.ts.map +1 -0
- package/dist/@types/index.d.ts +346 -0
- package/dist/@types/index.d.ts.map +1 -0
- package/dist/@types/interfaces/IBatchable.d.ts +40 -0
- package/dist/@types/interfaces/IBatchable.d.ts.map +1 -0
- package/dist/@types/interfaces/ICreatable.d.ts +37 -0
- package/dist/@types/interfaces/ICreatable.d.ts.map +1 -0
- package/dist/@types/interfaces/IDeletable.d.ts +35 -0
- package/dist/@types/interfaces/IDeletable.d.ts.map +1 -0
- package/dist/@types/interfaces/IListable.d.ts +38 -0
- package/dist/@types/interfaces/IListable.d.ts.map +1 -0
- package/dist/@types/interfaces/IRetrievable.d.ts +35 -0
- package/dist/@types/interfaces/IRetrievable.d.ts.map +1 -0
- package/dist/@types/interfaces/IRetrievableById.d.ts +50 -0
- package/dist/@types/interfaces/IRetrievableById.d.ts.map +1 -0
- package/dist/@types/interfaces/ITimestamp.d.ts +13 -0
- package/dist/@types/interfaces/ITimestamp.d.ts.map +1 -0
- package/dist/@types/interfaces/IUpdatable.d.ts +39 -0
- package/dist/@types/interfaces/IUpdatable.d.ts.map +1 -0
- package/dist/@types/services/BatchUpsertRequest.d.ts +17 -0
- package/dist/@types/services/BatchUpsertRequest.d.ts.map +1 -0
- package/dist/@types/services/ListRequest.d.ts +21 -0
- package/dist/@types/services/ListRequest.d.ts.map +1 -0
- package/dist/@types/services/SBService.d.ts +88 -0
- package/dist/@types/services/SBService.d.ts.map +1 -0
- package/dist/@types/services/UpsertRequest.d.ts +20 -0
- package/dist/@types/services/UpsertRequest.d.ts.map +1 -0
- package/dist/@types/services/addresses/AddressRequest.d.ts +13 -0
- package/dist/@types/services/addresses/AddressRequest.d.ts.map +1 -0
- package/dist/@types/services/addresses/BillingAddressRequest.d.ts +12 -0
- package/dist/@types/services/addresses/BillingAddressRequest.d.ts.map +1 -0
- package/dist/@types/services/api-logs/LogListRequest.d.ts +7 -0
- package/dist/@types/services/api-logs/LogListRequest.d.ts.map +1 -0
- package/dist/@types/services/api-logs/LogService.d.ts +18 -0
- package/dist/@types/services/api-logs/LogService.d.ts.map +1 -0
- package/dist/@types/services/attachments/AttachmentCreateRequest.d.ts +20 -0
- package/dist/@types/services/attachments/AttachmentCreateRequest.d.ts.map +1 -0
- package/dist/@types/services/attachments/AttachmentListRequest.d.ts +19 -0
- package/dist/@types/services/attachments/AttachmentListRequest.d.ts.map +1 -0
- package/dist/@types/services/attachments/AttachmentService.d.ts +85 -0
- package/dist/@types/services/attachments/AttachmentService.d.ts.map +1 -0
- package/dist/@types/services/attachments/AttachmentUpdateRequest.d.ts +23 -0
- package/dist/@types/services/attachments/AttachmentUpdateRequest.d.ts.map +1 -0
- package/dist/@types/services/attachments/AttachmentUpsertRequest.d.ts +23 -0
- package/dist/@types/services/attachments/AttachmentUpsertRequest.d.ts.map +1 -0
- package/dist/@types/services/banks/BankCreateRequest.d.ts +32 -0
- package/dist/@types/services/banks/BankCreateRequest.d.ts.map +1 -0
- package/dist/@types/services/banks/BankLinkResponse.d.ts +7 -0
- package/dist/@types/services/banks/BankLinkResponse.d.ts.map +1 -0
- package/dist/@types/services/banks/BankLinkTokenResponse.d.ts +7 -0
- package/dist/@types/services/banks/BankLinkTokenResponse.d.ts.map +1 -0
- package/dist/@types/services/banks/BankListRequest.d.ts +13 -0
- package/dist/@types/services/banks/BankListRequest.d.ts.map +1 -0
- package/dist/@types/services/banks/BankService.d.ts +169 -0
- package/dist/@types/services/banks/BankService.d.ts.map +1 -0
- package/dist/@types/services/banks/BankUpdateRequest.d.ts +9 -0
- package/dist/@types/services/banks/BankUpdateRequest.d.ts.map +1 -0
- package/dist/@types/services/banks/accounts/BankAccountCreateRequest.d.ts +11 -0
- package/dist/@types/services/banks/accounts/BankAccountCreateRequest.d.ts.map +1 -0
- package/dist/@types/services/banks/accounts/BankAccountListRequest.d.ts +5 -0
- package/dist/@types/services/banks/accounts/BankAccountListRequest.d.ts.map +1 -0
- package/dist/@types/services/banks/accounts/BankAccountService.d.ts +22 -0
- package/dist/@types/services/banks/accounts/BankAccountService.d.ts.map +1 -0
- package/dist/@types/services/banks/accounts/BankAccountUpdateRequest.d.ts +10 -0
- package/dist/@types/services/banks/accounts/BankAccountUpdateRequest.d.ts.map +1 -0
- package/dist/@types/services/banks/institutions/BankInstitutionListRequest.d.ts +7 -0
- package/dist/@types/services/banks/institutions/BankInstitutionListRequest.d.ts.map +1 -0
- package/dist/@types/services/banks/institutions/BankInstitutionService.d.ts +18 -0
- package/dist/@types/services/banks/institutions/BankInstitutionService.d.ts.map +1 -0
- package/dist/@types/services/banks/transactions/BankTransactionListRequest.d.ts +8 -0
- package/dist/@types/services/banks/transactions/BankTransactionListRequest.d.ts.map +1 -0
- package/dist/@types/services/banks/transactions/BankTransactionService.d.ts +24 -0
- package/dist/@types/services/banks/transactions/BankTransactionService.d.ts.map +1 -0
- package/dist/@types/services/billing/subscriptions/SubscriptionCreateRequest.d.ts +28 -0
- package/dist/@types/services/billing/subscriptions/SubscriptionCreateRequest.d.ts.map +1 -0
- package/dist/@types/services/billing/subscriptions/SubscriptionListRequest.d.ts +31 -0
- package/dist/@types/services/billing/subscriptions/SubscriptionListRequest.d.ts.map +1 -0
- package/dist/@types/services/billing/subscriptions/SubscriptionService.d.ts +120 -0
- package/dist/@types/services/billing/subscriptions/SubscriptionService.d.ts.map +1 -0
- package/dist/@types/services/billing/subscriptions/SubscriptionUpdateRequest.d.ts +29 -0
- package/dist/@types/services/billing/subscriptions/SubscriptionUpdateRequest.d.ts.map +1 -0
- package/dist/@types/services/billing/subscriptions/SubscriptionUpsertRequest.d.ts +33 -0
- package/dist/@types/services/billing/subscriptions/SubscriptionUpsertRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/BusinessCreateRequest.d.ts +37 -0
- package/dist/@types/services/businesses/BusinessCreateRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/BusinessInvitationRequest.d.ts +7 -0
- package/dist/@types/services/businesses/BusinessInvitationRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/BusinessListRequest.d.ts +7 -0
- package/dist/@types/services/businesses/BusinessListRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/BusinessService.d.ts +66 -0
- package/dist/@types/services/businesses/BusinessService.d.ts.map +1 -0
- package/dist/@types/services/businesses/BusinessUpdateRequest.d.ts +36 -0
- package/dist/@types/services/businesses/BusinessUpdateRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/customers/CustomerBatchUpsertRequest.d.ts +8 -0
- package/dist/@types/services/businesses/customers/CustomerBatchUpsertRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/customers/CustomerCreateRequest.d.ts +19 -0
- package/dist/@types/services/businesses/customers/CustomerCreateRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/customers/CustomerListRequest.d.ts +8 -0
- package/dist/@types/services/businesses/customers/CustomerListRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/customers/CustomerService.d.ts +94 -0
- package/dist/@types/services/businesses/customers/CustomerService.d.ts.map +1 -0
- package/dist/@types/services/businesses/customers/CustomerUpdateRequest.d.ts +5 -0
- package/dist/@types/services/businesses/customers/CustomerUpdateRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/customers/CustomerUpsertRequest.d.ts +8 -0
- package/dist/@types/services/businesses/customers/CustomerUpsertRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/customers/balance-transactions/CustomerBalanceTransactionCreateRequest.d.ts +10 -0
- package/dist/@types/services/businesses/customers/balance-transactions/CustomerBalanceTransactionCreateRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/customers/balance-transactions/CustomerBalanceTransactionListRequest.d.ts +7 -0
- package/dist/@types/services/businesses/customers/balance-transactions/CustomerBalanceTransactionListRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/customers/balance-transactions/CustomerBalanceTransactionService.d.ts +75 -0
- package/dist/@types/services/businesses/customers/balance-transactions/CustomerBalanceTransactionService.d.ts.map +1 -0
- package/dist/@types/services/businesses/customers/balance-transactions/CustomerBalanceTransactionUpdateRequest.d.ts +6 -0
- package/dist/@types/services/businesses/customers/balance-transactions/CustomerBalanceTransactionUpdateRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/customers/payment-methods/CustomerPaymentMethodCreateRequest.d.ts +5 -0
- package/dist/@types/services/businesses/customers/payment-methods/CustomerPaymentMethodCreateRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/customers/payment-methods/CustomerPaymentMethodListRequest.d.ts +7 -0
- package/dist/@types/services/businesses/customers/payment-methods/CustomerPaymentMethodListRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/customers/payment-methods/CustomerPaymentMethodService.d.ts +75 -0
- package/dist/@types/services/businesses/customers/payment-methods/CustomerPaymentMethodService.d.ts.map +1 -0
- package/dist/@types/services/businesses/customers/payment-methods/CustomerPaymentMethodUpdateRequest.d.ts +5 -0
- package/dist/@types/services/businesses/customers/payment-methods/CustomerPaymentMethodUpdateRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/departments/DepartmentBatchUpsertRequest.d.ts +11 -0
- package/dist/@types/services/businesses/departments/DepartmentBatchUpsertRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/departments/DepartmentCreateRequest.d.ts +36 -0
- package/dist/@types/services/businesses/departments/DepartmentCreateRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/departments/DepartmentService.d.ts +149 -0
- package/dist/@types/services/businesses/departments/DepartmentService.d.ts.map +1 -0
- package/dist/@types/services/businesses/departments/DepartmentUpdateRequest.d.ts +40 -0
- package/dist/@types/services/businesses/departments/DepartmentUpdateRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/departments/DepartmentUpsertRequest.d.ts +8 -0
- package/dist/@types/services/businesses/departments/DepartmentUpsertRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/departments/DepartmentsListRequest.d.ts +26 -0
- package/dist/@types/services/businesses/departments/DepartmentsListRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/departments/Employees/DepartmentEmployeeCreateRequest.d.ts +9 -0
- package/dist/@types/services/businesses/departments/Employees/DepartmentEmployeeCreateRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/departments/Employees/DepartmentEmployeeListRequest.d.ts +11 -0
- package/dist/@types/services/businesses/departments/Employees/DepartmentEmployeeListRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/departments/Employees/DepartmentEmployeeService.d.ts +75 -0
- package/dist/@types/services/businesses/departments/Employees/DepartmentEmployeeService.d.ts.map +1 -0
- package/dist/@types/services/businesses/departments/Employees/DepartmentEmployeeUpdateRequest.d.ts +10 -0
- package/dist/@types/services/businesses/departments/Employees/DepartmentEmployeeUpdateRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/domains/CreateDomainRequest.d.ts +6 -0
- package/dist/@types/services/businesses/domains/CreateDomainRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/domains/DomainService.d.ts +21 -0
- package/dist/@types/services/businesses/domains/DomainService.d.ts.map +1 -0
- package/dist/@types/services/businesses/domains/GetDomainsRequest.d.ts +7 -0
- package/dist/@types/services/businesses/domains/GetDomainsRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/fees/FeeCreateRequest.d.ts +12 -0
- package/dist/@types/services/businesses/fees/FeeCreateRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/fees/FeeListRequest.d.ts +7 -0
- package/dist/@types/services/businesses/fees/FeeListRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/fees/FeeService.d.ts +93 -0
- package/dist/@types/services/businesses/fees/FeeService.d.ts.map +1 -0
- package/dist/@types/services/businesses/fees/FeeUpdateRequest.d.ts +9 -0
- package/dist/@types/services/businesses/fees/FeeUpdateRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/fees/FeeUpsertRequest.d.ts +8 -0
- package/dist/@types/services/businesses/fees/FeeUpsertRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/locations/LocationBatchUpsertRequest.d.ts +8 -0
- package/dist/@types/services/businesses/locations/LocationBatchUpsertRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/locations/LocationCreateRequest.d.ts +13 -0
- package/dist/@types/services/businesses/locations/LocationCreateRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/locations/LocationService.d.ts +126 -0
- package/dist/@types/services/businesses/locations/LocationService.d.ts.map +1 -0
- package/dist/@types/services/businesses/locations/LocationUpdateRequest.d.ts +11 -0
- package/dist/@types/services/businesses/locations/LocationUpdateRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/locations/LocationUpsertRequest.d.ts +8 -0
- package/dist/@types/services/businesses/locations/LocationUpsertRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/locations/LocationsListRequest.d.ts +7 -0
- package/dist/@types/services/businesses/locations/LocationsListRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/prices/PriceCreateRequest.d.ts +5 -0
- package/dist/@types/services/businesses/prices/PriceCreateRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/prices/PriceService.d.ts +23 -0
- package/dist/@types/services/businesses/prices/PriceService.d.ts.map +1 -0
- package/dist/@types/services/businesses/prices/PriceUpdateRequest.d.ts +5 -0
- package/dist/@types/services/businesses/prices/PriceUpdateRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/prices/PricesListRequest.d.ts +7 -0
- package/dist/@types/services/businesses/prices/PricesListRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/products/ListImageRequest.d.ts +5 -0
- package/dist/@types/services/businesses/products/ListImageRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/products/ProductBatchUpsertRequest.d.ts +8 -0
- package/dist/@types/services/businesses/products/ProductBatchUpsertRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/products/ProductCreateRequest.d.ts +19 -0
- package/dist/@types/services/businesses/products/ProductCreateRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/products/ProductListRequest.d.ts +7 -0
- package/dist/@types/services/businesses/products/ProductListRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/products/ProductService.d.ts +118 -0
- package/dist/@types/services/businesses/products/ProductService.d.ts.map +1 -0
- package/dist/@types/services/businesses/products/ProductUpdateRequest.d.ts +17 -0
- package/dist/@types/services/businesses/products/ProductUpdateRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/products/ProductUpsertRequest.d.ts +8 -0
- package/dist/@types/services/businesses/products/ProductUpsertRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/products/images/ProductImageCreateRequest.d.ts +8 -0
- package/dist/@types/services/businesses/products/images/ProductImageCreateRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/products/images/ProductImageListRequest.d.ts +7 -0
- package/dist/@types/services/businesses/products/images/ProductImageListRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/products/images/ProductImageService.d.ts +75 -0
- package/dist/@types/services/businesses/products/images/ProductImageService.d.ts.map +1 -0
- package/dist/@types/services/businesses/products/images/ProductImageUpdateRequest.d.ts +5 -0
- package/dist/@types/services/businesses/products/images/ProductImageUpdateRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/products/modifiers/ProductModifierCreateRequest.d.ts +28 -0
- package/dist/@types/services/businesses/products/modifiers/ProductModifierCreateRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/products/modifiers/ProductModifierListRequest.d.ts +26 -0
- package/dist/@types/services/businesses/products/modifiers/ProductModifierListRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/products/modifiers/ProductModifierService.d.ts +88 -0
- package/dist/@types/services/businesses/products/modifiers/ProductModifierService.d.ts.map +1 -0
- package/dist/@types/services/businesses/products/modifiers/ProductModifierUpdateRequest.d.ts +28 -0
- package/dist/@types/services/businesses/products/modifiers/ProductModifierUpdateRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/products/modifiers/ProductModifierUpsertRequest.d.ts +30 -0
- package/dist/@types/services/businesses/products/modifiers/ProductModifierUpsertRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/products/options/ProductOptionCreateRequest.d.ts +28 -0
- package/dist/@types/services/businesses/products/options/ProductOptionCreateRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/products/options/ProductOptionListRequest.d.ts +26 -0
- package/dist/@types/services/businesses/products/options/ProductOptionListRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/products/options/ProductOptionService.d.ts +88 -0
- package/dist/@types/services/businesses/products/options/ProductOptionService.d.ts.map +1 -0
- package/dist/@types/services/businesses/products/options/ProductOptionUpdateRequest.d.ts +28 -0
- package/dist/@types/services/businesses/products/options/ProductOptionUpdateRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/products/options/ProductOptionUpsertRequest.d.ts +30 -0
- package/dist/@types/services/businesses/products/options/ProductOptionUpsertRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/products/variants/ProductVariantCreateRequest.d.ts +14 -0
- package/dist/@types/services/businesses/products/variants/ProductVariantCreateRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/products/variants/ProductVariantListRequest.d.ts +7 -0
- package/dist/@types/services/businesses/products/variants/ProductVariantListRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/products/variants/ProductVariantService.d.ts +75 -0
- package/dist/@types/services/businesses/products/variants/ProductVariantService.d.ts.map +1 -0
- package/dist/@types/services/businesses/products/variants/ProductVariantUpdateRequest.d.ts +5 -0
- package/dist/@types/services/businesses/products/variants/ProductVariantUpdateRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/promo-codes/PromoCodeBatchUpsertRequest.d.ts +8 -0
- package/dist/@types/services/businesses/promo-codes/PromoCodeBatchUpsertRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/promo-codes/PromoCodeCreateRequest.d.ts +11 -0
- package/dist/@types/services/businesses/promo-codes/PromoCodeCreateRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/promo-codes/PromoCodeListRequest.d.ts +7 -0
- package/dist/@types/services/businesses/promo-codes/PromoCodeListRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/promo-codes/PromoCodeService.d.ts +94 -0
- package/dist/@types/services/businesses/promo-codes/PromoCodeService.d.ts.map +1 -0
- package/dist/@types/services/businesses/promo-codes/PromoCodeUpdateRequest.d.ts +6 -0
- package/dist/@types/services/businesses/promo-codes/PromoCodeUpdateRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/promo-codes/PromoCodeUpsertRequest.d.ts +8 -0
- package/dist/@types/services/businesses/promo-codes/PromoCodeUpsertRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/reviews/BusinessReviewCreateRequest.d.ts +8 -0
- package/dist/@types/services/businesses/reviews/BusinessReviewCreateRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/reviews/BusinessReviewListRequest.d.ts +10 -0
- package/dist/@types/services/businesses/reviews/BusinessReviewListRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/reviews/BusinessReviewService.d.ts +30 -0
- package/dist/@types/services/businesses/reviews/BusinessReviewService.d.ts.map +1 -0
- package/dist/@types/services/businesses/reviews/BusinessReviewUpdateRequest.d.ts +7 -0
- package/dist/@types/services/businesses/reviews/BusinessReviewUpdateRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/tables/TableCreateRequest.d.ts +9 -0
- package/dist/@types/services/businesses/tables/TableCreateRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/tables/TableService.d.ts +23 -0
- package/dist/@types/services/businesses/tables/TableService.d.ts.map +1 -0
- package/dist/@types/services/businesses/tables/TableUpdateRequest.d.ts +14 -0
- package/dist/@types/services/businesses/tables/TableUpdateRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/taxes/TaxBatchUpsertRequest.d.ts +8 -0
- package/dist/@types/services/businesses/taxes/TaxBatchUpsertRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/taxes/TaxCreateRequest.d.ts +17 -0
- package/dist/@types/services/businesses/taxes/TaxCreateRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/taxes/TaxListRequest.d.ts +9 -0
- package/dist/@types/services/businesses/taxes/TaxListRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/taxes/TaxService.d.ts +89 -0
- package/dist/@types/services/businesses/taxes/TaxService.d.ts.map +1 -0
- package/dist/@types/services/businesses/taxes/TaxUpdateRequest.d.ts +12 -0
- package/dist/@types/services/businesses/taxes/TaxUpdateRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/taxes/TaxUpsertRequest.d.ts +8 -0
- package/dist/@types/services/businesses/taxes/TaxUpsertRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/team/invitations/TeamMemberInvitationCreateRequest.d.ts +13 -0
- package/dist/@types/services/businesses/team/invitations/TeamMemberInvitationCreateRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/team/invitations/TeamMemberInvitationListRequest.d.ts +7 -0
- package/dist/@types/services/businesses/team/invitations/TeamMemberInvitationListRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/team/invitations/TeamMemberInvitationRequest.d.ts +9 -0
- package/dist/@types/services/businesses/team/invitations/TeamMemberInvitationRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/team/invitations/TeamMemberInvitationResponseRequest.d.ts +8 -0
- package/dist/@types/services/businesses/team/invitations/TeamMemberInvitationResponseRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/team/invitations/TeamMemberInvitationService.d.ts +25 -0
- package/dist/@types/services/businesses/team/invitations/TeamMemberInvitationService.d.ts.map +1 -0
- package/dist/@types/services/businesses/team/members/TeamMemberListRequest.d.ts +10 -0
- package/dist/@types/services/businesses/team/members/TeamMemberListRequest.d.ts.map +1 -0
- package/dist/@types/services/businesses/team/members/TeamMemberService.d.ts +20 -0
- package/dist/@types/services/businesses/team/members/TeamMemberService.d.ts.map +1 -0
- package/dist/@types/services/businesses/vendors/VendorService.d.ts +85 -0
- package/dist/@types/services/businesses/vendors/VendorService.d.ts.map +1 -0
- package/dist/@types/services/cards/AttachCardRequest.d.ts +12 -0
- package/dist/@types/services/cards/AttachCardRequest.d.ts.map +1 -0
- package/dist/@types/services/cards/CardService.d.ts +28 -0
- package/dist/@types/services/cards/CardService.d.ts.map +1 -0
- package/dist/@types/services/cards/CreateCardRequest.d.ts +15 -0
- package/dist/@types/services/cards/CreateCardRequest.d.ts.map +1 -0
- package/dist/@types/services/cards/GetCardRequest.d.ts +5 -0
- package/dist/@types/services/cards/GetCardRequest.d.ts.map +1 -0
- package/dist/@types/services/cards/ListCardRequest.d.ts +5 -0
- package/dist/@types/services/cards/ListCardRequest.d.ts.map +1 -0
- package/dist/@types/services/documents/DocumentListRequest.d.ts +7 -0
- package/dist/@types/services/documents/DocumentListRequest.d.ts.map +1 -0
- package/dist/@types/services/documents/DocumentRenameRequest.d.ts +6 -0
- package/dist/@types/services/documents/DocumentRenameRequest.d.ts.map +1 -0
- package/dist/@types/services/documents/DocumentService.d.ts +24 -0
- package/dist/@types/services/documents/DocumentService.d.ts.map +1 -0
- package/dist/@types/services/documents/DocumentUploadRequest.d.ts +10 -0
- package/dist/@types/services/documents/DocumentUploadRequest.d.ts.map +1 -0
- package/dist/@types/services/expenses/ExpenseService.d.ts +20 -0
- package/dist/@types/services/expenses/ExpenseService.d.ts.map +1 -0
- package/dist/@types/services/expenses/ExpenseUploadRequest.d.ts +9 -0
- package/dist/@types/services/expenses/ExpenseUploadRequest.d.ts.map +1 -0
- package/dist/@types/services/explore/ExploreService.d.ts +13 -0
- package/dist/@types/services/explore/ExploreService.d.ts.map +1 -0
- package/dist/@types/services/friends/FriendListRequest.d.ts +7 -0
- package/dist/@types/services/friends/FriendListRequest.d.ts.map +1 -0
- package/dist/@types/services/friends/FriendRequestListRequest.d.ts +7 -0
- package/dist/@types/services/friends/FriendRequestListRequest.d.ts.map +1 -0
- package/dist/@types/services/friends/FriendService.d.ts +22 -0
- package/dist/@types/services/friends/FriendService.d.ts.map +1 -0
- package/dist/@types/services/images/ImageBase64CreateRequest.d.ts +8 -0
- package/dist/@types/services/images/ImageBase64CreateRequest.d.ts.map +1 -0
- package/dist/@types/services/images/ImageBaseCreateRequest.d.ts +6 -0
- package/dist/@types/services/images/ImageBaseCreateRequest.d.ts.map +1 -0
- package/dist/@types/services/images/ImageCreateRequest.d.ts +7 -0
- package/dist/@types/services/images/ImageCreateRequest.d.ts.map +1 -0
- package/dist/@types/services/images/ImageUrlCreateRequest.d.ts +8 -0
- package/dist/@types/services/images/ImageUrlCreateRequest.d.ts.map +1 -0
- package/dist/@types/services/integrations/IntegrationListRequest.d.ts +8 -0
- package/dist/@types/services/integrations/IntegrationListRequest.d.ts.map +1 -0
- package/dist/@types/services/integrations/IntegrationService.d.ts +20 -0
- package/dist/@types/services/integrations/IntegrationService.d.ts.map +1 -0
- package/dist/@types/services/invoices/InvoiceBatchUpsertRequest.d.ts +8 -0
- package/dist/@types/services/invoices/InvoiceBatchUpsertRequest.d.ts.map +1 -0
- package/dist/@types/services/invoices/InvoiceCreateRequest.d.ts +118 -0
- package/dist/@types/services/invoices/InvoiceCreateRequest.d.ts.map +1 -0
- package/dist/@types/services/invoices/InvoiceListRequest.d.ts +11 -0
- package/dist/@types/services/invoices/InvoiceListRequest.d.ts.map +1 -0
- package/dist/@types/services/invoices/InvoiceService.d.ts +216 -0
- package/dist/@types/services/invoices/InvoiceService.d.ts.map +1 -0
- package/dist/@types/services/invoices/InvoiceUpdateRequest.d.ts +73 -0
- package/dist/@types/services/invoices/InvoiceUpdateRequest.d.ts.map +1 -0
- package/dist/@types/services/invoices/InvoiceUpsertRequest.d.ts +5 -0
- package/dist/@types/services/invoices/InvoiceUpsertRequest.d.ts.map +1 -0
- package/dist/@types/services/loyalty/LoyaltyProgramService.d.ts +172 -0
- package/dist/@types/services/loyalty/LoyaltyProgramService.d.ts.map +1 -0
- package/dist/@types/services/notifications/NotificationCreateRequest.d.ts +20 -0
- package/dist/@types/services/notifications/NotificationCreateRequest.d.ts.map +1 -0
- package/dist/@types/services/notifications/NotificationService.d.ts +66 -0
- package/dist/@types/services/notifications/NotificationService.d.ts.map +1 -0
- package/dist/@types/services/oauth/AccessTokenResponse.d.ts +10 -0
- package/dist/@types/services/oauth/AccessTokenResponse.d.ts.map +1 -0
- package/dist/@types/services/oauth/AuthorizationCodeResponse.d.ts +11 -0
- package/dist/@types/services/oauth/AuthorizationCodeResponse.d.ts.map +1 -0
- package/dist/@types/services/oauth/AuthorizeRequest.d.ts +18 -0
- package/dist/@types/services/oauth/AuthorizeRequest.d.ts.map +1 -0
- package/dist/@types/services/oauth/OAuthService.d.ts +17 -0
- package/dist/@types/services/oauth/OAuthService.d.ts.map +1 -0
- package/dist/@types/services/oauth/RefreshTokenRequest.d.ts +9 -0
- package/dist/@types/services/oauth/RefreshTokenRequest.d.ts.map +1 -0
- package/dist/@types/services/oauth/TokenExchangeRequest.d.ts +15 -0
- package/dist/@types/services/oauth/TokenExchangeRequest.d.ts.map +1 -0
- package/dist/@types/services/payment-methods/PaymentMethodBankCreateRequest.d.ts +14 -0
- package/dist/@types/services/payment-methods/PaymentMethodBankCreateRequest.d.ts.map +1 -0
- package/dist/@types/services/payment-methods/PaymentMethodCardCreateRequest.d.ts +19 -0
- package/dist/@types/services/payment-methods/PaymentMethodCardCreateRequest.d.ts.map +1 -0
- package/dist/@types/services/payment-methods/PaymentMethodCreateRequest.d.ts +16 -0
- package/dist/@types/services/payment-methods/PaymentMethodCreateRequest.d.ts.map +1 -0
- package/dist/@types/services/payment-methods/PaymentMethodListRequest.d.ts +5 -0
- package/dist/@types/services/payment-methods/PaymentMethodListRequest.d.ts.map +1 -0
- package/dist/@types/services/payment-methods/PaymentMethodService.d.ts +29 -0
- package/dist/@types/services/payment-methods/PaymentMethodService.d.ts.map +1 -0
- package/dist/@types/services/payment-methods/PaymentMethodVerifyRequest.d.ts +6 -0
- package/dist/@types/services/payment-methods/PaymentMethodVerifyRequest.d.ts.map +1 -0
- package/dist/@types/services/receipts/BankTransactionAssociateRequest.d.ts +6 -0
- package/dist/@types/services/receipts/BankTransactionAssociateRequest.d.ts.map +1 -0
- package/dist/@types/services/receipts/ListReceiptRequest.d.ts +5 -0
- package/dist/@types/services/receipts/ListReceiptRequest.d.ts.map +1 -0
- package/dist/@types/services/receipts/ReceipTransactionPaymentDetailCreateRequest.d.ts +24 -0
- package/dist/@types/services/receipts/ReceipTransactionPaymentDetailCreateRequest.d.ts.map +1 -0
- package/dist/@types/services/receipts/ReceiptBatchUpsertRequest.d.ts +8 -0
- package/dist/@types/services/receipts/ReceiptBatchUpsertRequest.d.ts.map +1 -0
- package/dist/@types/services/receipts/ReceiptBulkJobCreateRequest.d.ts +6 -0
- package/dist/@types/services/receipts/ReceiptBulkJobCreateRequest.d.ts.map +1 -0
- package/dist/@types/services/receipts/ReceiptCreateRequest.d.ts +118 -0
- package/dist/@types/services/receipts/ReceiptCreateRequest.d.ts.map +1 -0
- package/dist/@types/services/receipts/ReceiptListRequest.d.ts +12 -0
- package/dist/@types/services/receipts/ReceiptListRequest.d.ts.map +1 -0
- package/dist/@types/services/receipts/ReceiptService.d.ts +250 -0
- package/dist/@types/services/receipts/ReceiptService.d.ts.map +1 -0
- package/dist/@types/services/receipts/ReceiptUpdateRequest.d.ts +73 -0
- package/dist/@types/services/receipts/ReceiptUpdateRequest.d.ts.map +1 -0
- package/dist/@types/services/receipts/ReceiptUpsertRequest.d.ts +8 -0
- package/dist/@types/services/receipts/ReceiptUpsertRequest.d.ts.map +1 -0
- package/dist/@types/services/receipts/discounts/ReceiptDiscountCreateRequest.d.ts +6 -0
- package/dist/@types/services/receipts/discounts/ReceiptDiscountCreateRequest.d.ts.map +1 -0
- package/dist/@types/services/receipts/discounts/ReceiptDiscountUpdateRequest.d.ts +6 -0
- package/dist/@types/services/receipts/discounts/ReceiptDiscountUpdateRequest.d.ts.map +1 -0
- package/dist/@types/services/receipts/fees/ReceiptFeeCreateRequest.d.ts +11 -0
- package/dist/@types/services/receipts/fees/ReceiptFeeCreateRequest.d.ts.map +1 -0
- package/dist/@types/services/receipts/fees/ReceiptFeeUpdateRequest.d.ts +5 -0
- package/dist/@types/services/receipts/fees/ReceiptFeeUpdateRequest.d.ts.map +1 -0
- package/dist/@types/services/receipts/line-items/ReceiptLineItemCreateRequest.d.ts +18 -0
- package/dist/@types/services/receipts/line-items/ReceiptLineItemCreateRequest.d.ts.map +1 -0
- package/dist/@types/services/receipts/line-items/ReceiptLineItemUpdateRequest.d.ts +13 -0
- package/dist/@types/services/receipts/line-items/ReceiptLineItemUpdateRequest.d.ts.map +1 -0
- package/dist/@types/services/receipts/metadata/BrowserMetadataCreateRequest.d.ts +29 -0
- package/dist/@types/services/receipts/metadata/BrowserMetadataCreateRequest.d.ts.map +1 -0
- package/dist/@types/services/receipts/metadata/ReceiptMetadataCreateRequest.d.ts +36 -0
- package/dist/@types/services/receipts/metadata/ReceiptMetadataCreateRequest.d.ts.map +1 -0
- package/dist/@types/services/receipts/payments/ReceiptPaymentUpdateRequest.d.ts +31 -0
- package/dist/@types/services/receipts/payments/ReceiptPaymentUpdateRequest.d.ts.map +1 -0
- package/dist/@types/services/receipts/payments/ReceiptTransactionCreateRequest.d.ts +48 -0
- package/dist/@types/services/receipts/payments/ReceiptTransactionCreateRequest.d.ts.map +1 -0
- package/dist/@types/services/receipts/payments/ReceiptTransactionUpdateRequest.d.ts +20 -0
- package/dist/@types/services/receipts/payments/ReceiptTransactionUpdateRequest.d.ts.map +1 -0
- package/dist/@types/services/receipts/reviews/ReceiptReviewCreateRequest.d.ts +8 -0
- package/dist/@types/services/receipts/reviews/ReceiptReviewCreateRequest.d.ts.map +1 -0
- package/dist/@types/services/receipts/reviews/ReceiptReviewUpdateRequest.d.ts +8 -0
- package/dist/@types/services/receipts/reviews/ReceiptReviewUpdateRequest.d.ts.map +1 -0
- package/dist/@types/services/receipts/taxes/ReceiptTaxCreateRequest.d.ts +7 -0
- package/dist/@types/services/receipts/taxes/ReceiptTaxCreateRequest.d.ts.map +1 -0
- package/dist/@types/services/receipts/taxes/ReceiptTaxUpdateRequest.d.ts +9 -0
- package/dist/@types/services/receipts/taxes/ReceiptTaxUpdateRequest.d.ts.map +1 -0
- package/dist/@types/services/settlements/SettlementListRequest.d.ts +9 -0
- package/dist/@types/services/settlements/SettlementListRequest.d.ts.map +1 -0
- package/dist/@types/services/settlements/SettlementPayRequest.d.ts +6 -0
- package/dist/@types/services/settlements/SettlementPayRequest.d.ts.map +1 -0
- package/dist/@types/services/settlements/SettlementService.d.ts +25 -0
- package/dist/@types/services/settlements/SettlementService.d.ts.map +1 -0
- package/dist/@types/services/transactions/ListTransactionRequest.d.ts +10 -0
- package/dist/@types/services/transactions/ListTransactionRequest.d.ts.map +1 -0
- package/dist/@types/services/transactions/TransactionService.d.ts +20 -0
- package/dist/@types/services/transactions/TransactionService.d.ts.map +1 -0
- package/dist/@types/services/user/UserService.d.ts +22 -0
- package/dist/@types/services/user/UserService.d.ts.map +1 -0
- package/dist/@types/services/user/UserUpdateRequest.d.ts +12 -0
- package/dist/@types/services/user/UserUpdateRequest.d.ts.map +1 -0
- package/dist/@types/services/users/SearchUsersRequest.d.ts +8 -0
- package/dist/@types/services/users/SearchUsersRequest.d.ts.map +1 -0
- package/dist/@types/services/users/UserService.d.ts +21 -0
- package/dist/@types/services/users/UserService.d.ts.map +1 -0
- package/dist/@types/services/users/UserUpdateRequest.d.ts +12 -0
- package/dist/@types/services/users/UserUpdateRequest.d.ts.map +1 -0
- package/dist/@types/services/vendors/VendorConnectRequest.d.ts +6 -0
- package/dist/@types/services/vendors/VendorConnectRequest.d.ts.map +1 -0
- package/dist/@types/services/vendors/VendorConnectResponse.d.ts +6 -0
- package/dist/@types/services/vendors/VendorConnectResponse.d.ts.map +1 -0
- package/dist/@types/services/vendors/VendorCreateRequest.d.ts +20 -0
- package/dist/@types/services/vendors/VendorCreateRequest.d.ts.map +1 -0
- package/dist/@types/services/vendors/VendorListRequest.d.ts +7 -0
- package/dist/@types/services/vendors/VendorListRequest.d.ts.map +1 -0
- package/dist/@types/services/vendors/VendorService.d.ts +32 -0
- package/dist/@types/services/vendors/VendorService.d.ts.map +1 -0
- package/dist/@types/services/vendors/VendorUpdateRequest.d.ts +20 -0
- package/dist/@types/services/vendors/VendorUpdateRequest.d.ts.map +1 -0
- package/dist/@types/utilities/FileFormData.d.ts +8 -0
- package/dist/@types/utilities/FileFormData.d.ts.map +1 -0
- package/dist/@types/utilities/SBAbortSignal.d.ts +6 -0
- package/dist/@types/utilities/SBAbortSignal.d.ts.map +1 -0
- package/dist/cjs/_virtual/__polyfill-node.util.cjs +11 -0
- package/dist/cjs/_virtual/__polyfill-node.util.cjs.map +1 -0
- package/dist/cjs/_virtual/_commonjsHelpers.cjs +37 -0
- package/dist/cjs/_virtual/_commonjsHelpers.cjs.map +1 -0
- package/dist/cjs/_virtual/_polyfill-node._inherits.cjs +28 -0
- package/dist/cjs/_virtual/_polyfill-node._inherits.cjs.map +1 -0
- package/dist/cjs/_virtual/_polyfill-node.buffer.cjs +1985 -0
- package/dist/cjs/_virtual/_polyfill-node.buffer.cjs.map +1 -0
- package/dist/cjs/_virtual/_polyfill-node.global.cjs +10 -0
- package/dist/cjs/_virtual/_polyfill-node.global.cjs.map +1 -0
- package/dist/cjs/_virtual/_polyfill-node.process.cjs +253 -0
- package/dist/cjs/_virtual/_polyfill-node.process.cjs.map +1 -0
- package/dist/cjs/_virtual/_polyfill-node.util.cjs +710 -0
- package/dist/cjs/_virtual/_polyfill-node.util.cjs.map +1 -0
- package/dist/cjs/_virtual/index.cjs +6 -0
- package/dist/cjs/_virtual/index.cjs.map +1 -0
- package/dist/cjs/client/SBClient.cjs +259 -0
- package/dist/cjs/client/SBClient.cjs.map +1 -0
- package/dist/cjs/client/SBCredentials.cjs +60 -0
- package/dist/cjs/client/SBCredentials.cjs.map +1 -0
- package/dist/cjs/client/SBEnvironment.cjs +15 -0
- package/dist/cjs/client/SBEnvironment.cjs.map +1 -0
- package/dist/cjs/client/SBException.cjs +38 -0
- package/dist/cjs/client/SBException.cjs.map +1 -0
- package/dist/cjs/client/SBInstance.cjs +59 -0
- package/dist/cjs/client/SBInstance.cjs.map +1 -0
- package/dist/cjs/client/SBLogger.cjs +16 -0
- package/dist/cjs/client/SBLogger.cjs.map +1 -0
- package/dist/cjs/client/SBPermission.cjs +50 -0
- package/dist/cjs/client/SBPermission.cjs.map +1 -0
- package/dist/cjs/client/SBServiceOptions.cjs +22 -0
- package/dist/cjs/client/SBServiceOptions.cjs.map +1 -0
- package/dist/cjs/client/constants.cjs +8 -0
- package/dist/cjs/client/constants.cjs.map +1 -0
- package/dist/cjs/constants/login/LoginError.cjs +9 -0
- package/dist/cjs/constants/login/LoginError.cjs.map +1 -0
- package/dist/cjs/entities/account/SBGenderEnum.cjs +9 -0
- package/dist/cjs/entities/account/SBGenderEnum.cjs.map +1 -0
- package/dist/cjs/entities/banks/SBBankState.cjs +10 -0
- package/dist/cjs/entities/banks/SBBankState.cjs.map +1 -0
- package/dist/cjs/entities/barcode/SBBarcodeType.cjs +28 -0
- package/dist/cjs/entities/barcode/SBBarcodeType.cjs.map +1 -0
- package/dist/cjs/entities/businesses/fees/SBFeeType.cjs +8 -0
- package/dist/cjs/entities/businesses/fees/SBFeeType.cjs.map +1 -0
- package/dist/cjs/entities/businesses/team/invitations/SBTeamMemberInvitationStatus.cjs +10 -0
- package/dist/cjs/entities/businesses/team/invitations/SBTeamMemberInvitationStatus.cjs.map +1 -0
- package/dist/cjs/entities/businesses/team/members/SBTeamMemberRole.cjs +11 -0
- package/dist/cjs/entities/businesses/team/members/SBTeamMemberRole.cjs.map +1 -0
- package/dist/cjs/entities/businesses/team/members/SBTeamMemberStatus.cjs +11 -0
- package/dist/cjs/entities/businesses/team/members/SBTeamMemberStatus.cjs.map +1 -0
- package/dist/cjs/entities/cards/SBCardType.cjs +10 -0
- package/dist/cjs/entities/cards/SBCardType.cjs.map +1 -0
- package/dist/cjs/entities/payment-methods/SBPaymentMethod.cjs +8 -0
- package/dist/cjs/entities/payment-methods/SBPaymentMethod.cjs.map +1 -0
- package/dist/cjs/entities/payment-methods/SBPaymentMethodFingerprintProvider.cjs +8 -0
- package/dist/cjs/entities/payment-methods/SBPaymentMethodFingerprintProvider.cjs.map +1 -0
- package/dist/cjs/entities/receipts/SBReceiptSource.cjs +11 -0
- package/dist/cjs/entities/receipts/SBReceiptSource.cjs.map +1 -0
- package/dist/cjs/entities/receipts/SBReceiptType.cjs +10 -0
- package/dist/cjs/entities/receipts/SBReceiptType.cjs.map +1 -0
- package/dist/cjs/entities/receipts/payments/SBReceiptPaymentCardAvsResult.cjs +16 -0
- package/dist/cjs/entities/receipts/payments/SBReceiptPaymentCardAvsResult.cjs.map +1 -0
- package/dist/cjs/entities/receipts/payments/SBReceiptPaymentCardCvvResult.cjs +9 -0
- package/dist/cjs/entities/receipts/payments/SBReceiptPaymentCardCvvResult.cjs.map +1 -0
- package/dist/cjs/entities/receipts/payments/SBReceiptPaymentCardEntryMethod.cjs +11 -0
- package/dist/cjs/entities/receipts/payments/SBReceiptPaymentCardEntryMethod.cjs.map +1 -0
- package/dist/cjs/entities/receipts/payments/SBReceiptPaymentExternalType.cjs +18 -0
- package/dist/cjs/entities/receipts/payments/SBReceiptPaymentExternalType.cjs.map +1 -0
- package/dist/cjs/entities/receipts/payments/SBReceiptPaymentRiskLevel.cjs +9 -0
- package/dist/cjs/entities/receipts/payments/SBReceiptPaymentRiskLevel.cjs.map +1 -0
- package/dist/cjs/entities/receipts/payments/SBReceiptPaymentStatus.cjs +11 -0
- package/dist/cjs/entities/receipts/payments/SBReceiptPaymentStatus.cjs.map +1 -0
- package/dist/cjs/entities/receipts/payments/SBReceiptPaymentType.cjs +12 -0
- package/dist/cjs/entities/receipts/payments/SBReceiptPaymentType.cjs.map +1 -0
- package/dist/cjs/entities/transactions/SBTransactionType.cjs +10 -0
- package/dist/cjs/entities/transactions/SBTransactionType.cjs.map +1 -0
- package/dist/cjs/index.cjs +222 -0
- package/dist/cjs/index.cjs.map +1 -0
- package/dist/cjs/node_modules/@babel/runtime/helpers/esm/defineProperty.cjs +17 -0
- package/dist/cjs/node_modules/@babel/runtime/helpers/esm/defineProperty.cjs.map +1 -0
- package/dist/cjs/node_modules/@babel/runtime/helpers/esm/toPrimitive.cjs +19 -0
- package/dist/cjs/node_modules/@babel/runtime/helpers/esm/toPrimitive.cjs.map +1 -0
- package/dist/cjs/node_modules/@babel/runtime/helpers/esm/toPropertyKey.cjs +14 -0
- package/dist/cjs/node_modules/@babel/runtime/helpers/esm/toPropertyKey.cjs.map +1 -0
- package/dist/cjs/node_modules/@babel/runtime/helpers/esm/typeof.cjs +16 -0
- package/dist/cjs/node_modules/@babel/runtime/helpers/esm/typeof.cjs.map +1 -0
- package/dist/cjs/node_modules/call-bind/index.cjs +31 -0
- package/dist/cjs/node_modules/call-bind/index.cjs.map +1 -0
- package/dist/cjs/node_modules/call-bind-apply-helpers/actualApply.cjs +17 -0
- package/dist/cjs/node_modules/call-bind-apply-helpers/actualApply.cjs.map +1 -0
- package/dist/cjs/node_modules/call-bind-apply-helpers/applyBind.cjs +17 -0
- package/dist/cjs/node_modules/call-bind-apply-helpers/applyBind.cjs.map +1 -0
- package/dist/cjs/node_modules/call-bind-apply-helpers/functionApply.cjs +15 -0
- package/dist/cjs/node_modules/call-bind-apply-helpers/functionApply.cjs.map +1 -0
- package/dist/cjs/node_modules/call-bind-apply-helpers/functionCall.cjs +15 -0
- package/dist/cjs/node_modules/call-bind-apply-helpers/functionCall.cjs.map +1 -0
- package/dist/cjs/node_modules/call-bind-apply-helpers/index.cjs +22 -0
- package/dist/cjs/node_modules/call-bind-apply-helpers/index.cjs.map +1 -0
- package/dist/cjs/node_modules/call-bind-apply-helpers/reflectApply.cjs +7 -0
- package/dist/cjs/node_modules/call-bind-apply-helpers/reflectApply.cjs.map +1 -0
- package/dist/cjs/node_modules/call-bound/index.cjs +23 -0
- package/dist/cjs/node_modules/call-bound/index.cjs.map +1 -0
- package/dist/cjs/node_modules/define-data-property/index.cjs +56 -0
- package/dist/cjs/node_modules/define-data-property/index.cjs.map +1 -0
- package/dist/cjs/node_modules/dunder-proto/get.cjs +31 -0
- package/dist/cjs/node_modules/dunder-proto/get.cjs.map +1 -0
- package/dist/cjs/node_modules/es-define-property/index.cjs +18 -0
- package/dist/cjs/node_modules/es-define-property/index.cjs.map +1 -0
- package/dist/cjs/node_modules/es-errors/eval.cjs +7 -0
- package/dist/cjs/node_modules/es-errors/eval.cjs.map +1 -0
- package/dist/cjs/node_modules/es-errors/index.cjs +7 -0
- package/dist/cjs/node_modules/es-errors/index.cjs.map +1 -0
- package/dist/cjs/node_modules/es-errors/range.cjs +7 -0
- package/dist/cjs/node_modules/es-errors/range.cjs.map +1 -0
- package/dist/cjs/node_modules/es-errors/ref.cjs +7 -0
- package/dist/cjs/node_modules/es-errors/ref.cjs.map +1 -0
- package/dist/cjs/node_modules/es-errors/syntax.cjs +7 -0
- package/dist/cjs/node_modules/es-errors/syntax.cjs.map +1 -0
- package/dist/cjs/node_modules/es-errors/type.cjs +7 -0
- package/dist/cjs/node_modules/es-errors/type.cjs.map +1 -0
- package/dist/cjs/node_modules/es-errors/uri.cjs +7 -0
- package/dist/cjs/node_modules/es-errors/uri.cjs.map +1 -0
- package/dist/cjs/node_modules/function-bind/implementation.cjs +77 -0
- package/dist/cjs/node_modules/function-bind/implementation.cjs.map +1 -0
- package/dist/cjs/node_modules/function-bind/index.cjs +16 -0
- package/dist/cjs/node_modules/function-bind/index.cjs.map +1 -0
- package/dist/cjs/node_modules/get-intrinsic/index.cjs +341 -0
- package/dist/cjs/node_modules/get-intrinsic/index.cjs.map +1 -0
- package/dist/cjs/node_modules/gopd/gOPD.cjs +7 -0
- package/dist/cjs/node_modules/gopd/gOPD.cjs.map +1 -0
- package/dist/cjs/node_modules/gopd/index.cjs +18 -0
- package/dist/cjs/node_modules/gopd/index.cjs.map +1 -0
- package/dist/cjs/node_modules/has-property-descriptors/index.cjs +26 -0
- package/dist/cjs/node_modules/has-property-descriptors/index.cjs.map +1 -0
- package/dist/cjs/node_modules/has-symbols/index.cjs +33 -0
- package/dist/cjs/node_modules/has-symbols/index.cjs.map +1 -0
- package/dist/cjs/node_modules/has-symbols/shams.cjs +72 -0
- package/dist/cjs/node_modules/has-symbols/shams.cjs.map +1 -0
- package/dist/cjs/node_modules/hasown/index.cjs +20 -0
- package/dist/cjs/node_modules/hasown/index.cjs.map +1 -0
- package/dist/cjs/node_modules/object-inspect/index.cjs +535 -0
- package/dist/cjs/node_modules/object-inspect/index.cjs.map +1 -0
- package/dist/cjs/node_modules/object-inspect/util.inspect.cjs +8 -0
- package/dist/cjs/node_modules/object-inspect/util.inspect.cjs.map +1 -0
- package/dist/cjs/node_modules/qs/lib/formats.cjs +24 -0
- package/dist/cjs/node_modules/qs/lib/formats.cjs.map +1 -0
- package/dist/cjs/node_modules/qs/lib/index.cjs +21 -0
- package/dist/cjs/node_modules/qs/lib/index.cjs.map +1 -0
- package/dist/cjs/node_modules/qs/lib/parse.cjs +265 -0
- package/dist/cjs/node_modules/qs/lib/parse.cjs.map +1 -0
- package/dist/cjs/node_modules/qs/lib/stringify.cjs +253 -0
- package/dist/cjs/node_modules/qs/lib/stringify.cjs.map +1 -0
- package/dist/cjs/node_modules/qs/lib/utils.cjs +231 -0
- package/dist/cjs/node_modules/qs/lib/utils.cjs.map +1 -0
- package/dist/cjs/node_modules/set-function-length/index.cjs +47 -0
- package/dist/cjs/node_modules/set-function-length/index.cjs.map +1 -0
- package/dist/cjs/node_modules/side-channel/index.cjs +50 -0
- package/dist/cjs/node_modules/side-channel/index.cjs.map +1 -0
- package/dist/cjs/node_modules/side-channel-list/index.cjs +119 -0
- package/dist/cjs/node_modules/side-channel-list/index.cjs.map +1 -0
- package/dist/cjs/node_modules/side-channel-map/index.cjs +76 -0
- package/dist/cjs/node_modules/side-channel-map/index.cjs.map +1 -0
- package/dist/cjs/node_modules/side-channel-weakmap/index.cjs +92 -0
- package/dist/cjs/node_modules/side-channel-weakmap/index.cjs.map +1 -0
- package/dist/cjs/packages/sdk/package.json.cjs +6 -0
- package/dist/cjs/packages/sdk/package.json.cjs.map +1 -0
- package/dist/cjs/services/SBService.cjs +161 -0
- package/dist/cjs/services/SBService.cjs.map +1 -0
- package/dist/cjs/services/api-logs/LogService.cjs +19 -0
- package/dist/cjs/services/api-logs/LogService.cjs.map +1 -0
- package/dist/cjs/services/attachments/AttachmentService.cjs +86 -0
- package/dist/cjs/services/attachments/AttachmentService.cjs.map +1 -0
- package/dist/cjs/services/banks/BankService.cjs +183 -0
- package/dist/cjs/services/banks/BankService.cjs.map +1 -0
- package/dist/cjs/services/banks/accounts/BankAccountService.cjs +25 -0
- package/dist/cjs/services/banks/accounts/BankAccountService.cjs.map +1 -0
- package/dist/cjs/services/banks/institutions/BankInstitutionService.cjs +19 -0
- package/dist/cjs/services/banks/institutions/BankInstitutionService.cjs.map +1 -0
- package/dist/cjs/services/banks/transactions/BankTransactionService.cjs +28 -0
- package/dist/cjs/services/banks/transactions/BankTransactionService.cjs.map +1 -0
- package/dist/cjs/services/billing/subscriptions/SubscriptionService.cjs +129 -0
- package/dist/cjs/services/billing/subscriptions/SubscriptionService.cjs.map +1 -0
- package/dist/cjs/services/businesses/BusinessService.cjs +98 -0
- package/dist/cjs/services/businesses/BusinessService.cjs.map +1 -0
- package/dist/cjs/services/businesses/customers/CustomerService.cjs +94 -0
- package/dist/cjs/services/businesses/customers/CustomerService.cjs.map +1 -0
- package/dist/cjs/services/businesses/customers/balance-transactions/CustomerBalanceTransactionService.cjs +82 -0
- package/dist/cjs/services/businesses/customers/balance-transactions/CustomerBalanceTransactionService.cjs.map +1 -0
- package/dist/cjs/services/businesses/customers/payment-methods/CustomerPaymentMethodService.cjs +82 -0
- package/dist/cjs/services/businesses/customers/payment-methods/CustomerPaymentMethodService.cjs.map +1 -0
- package/dist/cjs/services/businesses/departments/DepartmentService.cjs +159 -0
- package/dist/cjs/services/businesses/departments/DepartmentService.cjs.map +1 -0
- package/dist/cjs/services/businesses/departments/Employees/DepartmentEmployeeService.cjs +81 -0
- package/dist/cjs/services/businesses/departments/Employees/DepartmentEmployeeService.cjs.map +1 -0
- package/dist/cjs/services/businesses/domains/DomainService.cjs +21 -0
- package/dist/cjs/services/businesses/domains/DomainService.cjs.map +1 -0
- package/dist/cjs/services/businesses/fees/FeeService.cjs +93 -0
- package/dist/cjs/services/businesses/fees/FeeService.cjs.map +1 -0
- package/dist/cjs/services/businesses/locations/LocationService.cjs +139 -0
- package/dist/cjs/services/businesses/locations/LocationService.cjs.map +1 -0
- package/dist/cjs/services/businesses/prices/PriceService.cjs +24 -0
- package/dist/cjs/services/businesses/prices/PriceService.cjs.map +1 -0
- package/dist/cjs/services/businesses/products/ProductService.cjs +123 -0
- package/dist/cjs/services/businesses/products/ProductService.cjs.map +1 -0
- package/dist/cjs/services/businesses/products/images/ProductImageService.cjs +99 -0
- package/dist/cjs/services/businesses/products/images/ProductImageService.cjs.map +1 -0
- package/dist/cjs/services/businesses/products/modifiers/ProductModifierService.cjs +94 -0
- package/dist/cjs/services/businesses/products/modifiers/ProductModifierService.cjs.map +1 -0
- package/dist/cjs/services/businesses/products/options/ProductOptionService.cjs +94 -0
- package/dist/cjs/services/businesses/products/options/ProductOptionService.cjs.map +1 -0
- package/dist/cjs/services/businesses/products/variants/ProductVariantService.cjs +83 -0
- package/dist/cjs/services/businesses/products/variants/ProductVariantService.cjs.map +1 -0
- package/dist/cjs/services/businesses/promo-codes/PromoCodeService.cjs +94 -0
- package/dist/cjs/services/businesses/promo-codes/PromoCodeService.cjs.map +1 -0
- package/dist/cjs/services/businesses/reviews/BusinessReviewService.cjs +32 -0
- package/dist/cjs/services/businesses/reviews/BusinessReviewService.cjs.map +1 -0
- package/dist/cjs/services/businesses/tables/TableService.cjs +29 -0
- package/dist/cjs/services/businesses/tables/TableService.cjs.map +1 -0
- package/dist/cjs/services/businesses/taxes/TaxService.cjs +89 -0
- package/dist/cjs/services/businesses/taxes/TaxService.cjs.map +1 -0
- package/dist/cjs/services/businesses/team/invitations/TeamMemberInvitationService.cjs +34 -0
- package/dist/cjs/services/businesses/team/invitations/TeamMemberInvitationService.cjs.map +1 -0
- package/dist/cjs/services/businesses/team/members/TeamMemberService.cjs +26 -0
- package/dist/cjs/services/businesses/team/members/TeamMemberService.cjs.map +1 -0
- package/dist/cjs/services/businesses/vendors/VendorService.cjs +91 -0
- package/dist/cjs/services/businesses/vendors/VendorService.cjs.map +1 -0
- package/dist/cjs/services/cards/CardService.cjs +40 -0
- package/dist/cjs/services/cards/CardService.cjs.map +1 -0
- package/dist/cjs/services/documents/DocumentService.cjs +40 -0
- package/dist/cjs/services/documents/DocumentService.cjs.map +1 -0
- package/dist/cjs/services/expenses/ExpenseService.cjs +68 -0
- package/dist/cjs/services/expenses/ExpenseService.cjs.map +1 -0
- package/dist/cjs/services/explore/ExploreService.cjs +16 -0
- package/dist/cjs/services/explore/ExploreService.cjs.map +1 -0
- package/dist/cjs/services/friends/FriendService.cjs +28 -0
- package/dist/cjs/services/friends/FriendService.cjs.map +1 -0
- package/dist/cjs/services/integrations/IntegrationService.cjs +27 -0
- package/dist/cjs/services/integrations/IntegrationService.cjs.map +1 -0
- package/dist/cjs/services/invoices/InvoiceService.cjs +271 -0
- package/dist/cjs/services/invoices/InvoiceService.cjs.map +1 -0
- package/dist/cjs/services/loyalty/LoyaltyProgramService.cjs +197 -0
- package/dist/cjs/services/loyalty/LoyaltyProgramService.cjs.map +1 -0
- package/dist/cjs/services/notifications/NotificationService.cjs +75 -0
- package/dist/cjs/services/notifications/NotificationService.cjs.map +1 -0
- package/dist/cjs/services/oauth/AccessTokenResponse.cjs +16 -0
- package/dist/cjs/services/oauth/AccessTokenResponse.cjs.map +1 -0
- package/dist/cjs/services/oauth/AuthorizationCodeResponse.cjs +25 -0
- package/dist/cjs/services/oauth/AuthorizationCodeResponse.cjs.map +1 -0
- package/dist/cjs/services/oauth/OAuthService.cjs +44 -0
- package/dist/cjs/services/oauth/OAuthService.cjs.map +1 -0
- package/dist/cjs/services/payment-methods/PaymentMethodService.cjs +40 -0
- package/dist/cjs/services/payment-methods/PaymentMethodService.cjs.map +1 -0
- package/dist/cjs/services/receipts/ReceiptService.cjs +294 -0
- package/dist/cjs/services/receipts/ReceiptService.cjs.map +1 -0
- package/dist/cjs/services/settlements/SettlementService.cjs +29 -0
- package/dist/cjs/services/settlements/SettlementService.cjs.map +1 -0
- package/dist/cjs/services/transactions/TransactionService.cjs +20 -0
- package/dist/cjs/services/transactions/TransactionService.cjs.map +1 -0
- package/dist/cjs/services/user/UserService.cjs +42 -0
- package/dist/cjs/services/user/UserService.cjs.map +1 -0
- package/dist/cjs/services/users/UserService.cjs +34 -0
- package/dist/cjs/services/users/UserService.cjs.map +1 -0
- package/dist/cjs/services/vendors/VendorService.cjs +40 -0
- package/dist/cjs/services/vendors/VendorService.cjs.map +1 -0
- package/dist/esm/_virtual/__polyfill-node.util.mjs +7 -0
- package/dist/esm/_virtual/__polyfill-node.util.mjs.map +1 -0
- package/dist/esm/_virtual/_commonjsHelpers.mjs +33 -0
- package/dist/esm/_virtual/_commonjsHelpers.mjs.map +1 -0
- package/dist/esm/_virtual/_polyfill-node._inherits.mjs +26 -0
- package/dist/esm/_virtual/_polyfill-node._inherits.mjs.map +1 -0
- package/dist/esm/_virtual/_polyfill-node.buffer.mjs +1981 -0
- package/dist/esm/_virtual/_polyfill-node.buffer.mjs.map +1 -0
- package/dist/esm/_virtual/_polyfill-node.global.mjs +6 -0
- package/dist/esm/_virtual/_polyfill-node.global.mjs.map +1 -0
- package/dist/esm/_virtual/_polyfill-node.process.mjs +226 -0
- package/dist/esm/_virtual/_polyfill-node.process.mjs.map +1 -0
- package/dist/esm/_virtual/_polyfill-node.util.mjs +679 -0
- package/dist/esm/_virtual/_polyfill-node.util.mjs.map +1 -0
- package/dist/esm/_virtual/index.mjs +4 -0
- package/dist/esm/_virtual/index.mjs.map +1 -0
- package/dist/esm/client/SBClient.mjs +257 -0
- package/dist/esm/client/SBClient.mjs.map +1 -0
- package/dist/esm/client/SBCredentials.mjs +57 -0
- package/dist/esm/client/SBCredentials.mjs.map +1 -0
- package/dist/esm/client/SBEnvironment.mjs +13 -0
- package/dist/esm/client/SBEnvironment.mjs.map +1 -0
- package/dist/esm/client/SBException.mjs +35 -0
- package/dist/esm/client/SBException.mjs.map +1 -0
- package/dist/esm/client/SBInstance.mjs +57 -0
- package/dist/esm/client/SBInstance.mjs.map +1 -0
- package/dist/esm/client/SBLogger.mjs +14 -0
- package/dist/esm/client/SBLogger.mjs.map +1 -0
- package/dist/esm/client/SBPermission.mjs +50 -0
- package/dist/esm/client/SBPermission.mjs.map +1 -0
- package/dist/esm/client/SBServiceOptions.mjs +19 -0
- package/dist/esm/client/SBServiceOptions.mjs.map +1 -0
- package/dist/esm/client/constants.mjs +5 -0
- package/dist/esm/client/constants.mjs.map +1 -0
- package/dist/esm/constants/login/LoginError.mjs +9 -0
- package/dist/esm/constants/login/LoginError.mjs.map +1 -0
- package/dist/esm/entities/account/SBGenderEnum.mjs +9 -0
- package/dist/esm/entities/account/SBGenderEnum.mjs.map +1 -0
- package/dist/esm/entities/banks/SBBankState.mjs +10 -0
- package/dist/esm/entities/banks/SBBankState.mjs.map +1 -0
- package/dist/esm/entities/barcode/SBBarcodeType.mjs +28 -0
- package/dist/esm/entities/barcode/SBBarcodeType.mjs.map +1 -0
- package/dist/esm/entities/businesses/fees/SBFeeType.mjs +8 -0
- package/dist/esm/entities/businesses/fees/SBFeeType.mjs.map +1 -0
- package/dist/esm/entities/businesses/team/invitations/SBTeamMemberInvitationStatus.mjs +10 -0
- package/dist/esm/entities/businesses/team/invitations/SBTeamMemberInvitationStatus.mjs.map +1 -0
- package/dist/esm/entities/businesses/team/members/SBTeamMemberRole.mjs +11 -0
- package/dist/esm/entities/businesses/team/members/SBTeamMemberRole.mjs.map +1 -0
- package/dist/esm/entities/businesses/team/members/SBTeamMemberStatus.mjs +11 -0
- package/dist/esm/entities/businesses/team/members/SBTeamMemberStatus.mjs.map +1 -0
- package/dist/esm/entities/cards/SBCardType.mjs +10 -0
- package/dist/esm/entities/cards/SBCardType.mjs.map +1 -0
- package/dist/esm/entities/payment-methods/SBPaymentMethod.mjs +8 -0
- package/dist/esm/entities/payment-methods/SBPaymentMethod.mjs.map +1 -0
- package/dist/esm/entities/payment-methods/SBPaymentMethodFingerprintProvider.mjs +8 -0
- package/dist/esm/entities/payment-methods/SBPaymentMethodFingerprintProvider.mjs.map +1 -0
- package/dist/esm/entities/receipts/SBReceiptSource.mjs +11 -0
- package/dist/esm/entities/receipts/SBReceiptSource.mjs.map +1 -0
- package/dist/esm/entities/receipts/SBReceiptType.mjs +8 -0
- package/dist/esm/entities/receipts/SBReceiptType.mjs.map +1 -0
- package/dist/esm/entities/receipts/payments/SBReceiptPaymentCardAvsResult.mjs +16 -0
- package/dist/esm/entities/receipts/payments/SBReceiptPaymentCardAvsResult.mjs.map +1 -0
- package/dist/esm/entities/receipts/payments/SBReceiptPaymentCardCvvResult.mjs +9 -0
- package/dist/esm/entities/receipts/payments/SBReceiptPaymentCardCvvResult.mjs.map +1 -0
- package/dist/esm/entities/receipts/payments/SBReceiptPaymentCardEntryMethod.mjs +11 -0
- package/dist/esm/entities/receipts/payments/SBReceiptPaymentCardEntryMethod.mjs.map +1 -0
- package/dist/esm/entities/receipts/payments/SBReceiptPaymentExternalType.mjs +18 -0
- package/dist/esm/entities/receipts/payments/SBReceiptPaymentExternalType.mjs.map +1 -0
- package/dist/esm/entities/receipts/payments/SBReceiptPaymentRiskLevel.mjs +9 -0
- package/dist/esm/entities/receipts/payments/SBReceiptPaymentRiskLevel.mjs.map +1 -0
- package/dist/esm/entities/receipts/payments/SBReceiptPaymentStatus.mjs +11 -0
- package/dist/esm/entities/receipts/payments/SBReceiptPaymentStatus.mjs.map +1 -0
- package/dist/esm/entities/receipts/payments/SBReceiptPaymentType.mjs +12 -0
- package/dist/esm/entities/receipts/payments/SBReceiptPaymentType.mjs.map +1 -0
- package/dist/esm/entities/transactions/SBTransactionType.mjs +10 -0
- package/dist/esm/entities/transactions/SBTransactionType.mjs.map +1 -0
- package/dist/esm/index.mjs +76 -0
- package/dist/esm/index.mjs.map +1 -0
- package/dist/esm/node_modules/@babel/runtime/helpers/esm/defineProperty.mjs +13 -0
- package/dist/esm/node_modules/@babel/runtime/helpers/esm/defineProperty.mjs.map +1 -0
- package/dist/esm/node_modules/@babel/runtime/helpers/esm/toPrimitive.mjs +15 -0
- package/dist/esm/node_modules/@babel/runtime/helpers/esm/toPrimitive.mjs.map +1 -0
- package/dist/esm/node_modules/@babel/runtime/helpers/esm/toPropertyKey.mjs +10 -0
- package/dist/esm/node_modules/@babel/runtime/helpers/esm/toPropertyKey.mjs.map +1 -0
- package/dist/esm/node_modules/@babel/runtime/helpers/esm/typeof.mjs +12 -0
- package/dist/esm/node_modules/@babel/runtime/helpers/esm/typeof.mjs.map +1 -0
- package/dist/esm/node_modules/call-bind/index.mjs +29 -0
- package/dist/esm/node_modules/call-bind/index.mjs.map +1 -0
- package/dist/esm/node_modules/call-bind-apply-helpers/actualApply.mjs +15 -0
- package/dist/esm/node_modules/call-bind-apply-helpers/actualApply.mjs.map +1 -0
- package/dist/esm/node_modules/call-bind-apply-helpers/applyBind.mjs +15 -0
- package/dist/esm/node_modules/call-bind-apply-helpers/applyBind.mjs.map +1 -0
- package/dist/esm/node_modules/call-bind-apply-helpers/functionApply.mjs +13 -0
- package/dist/esm/node_modules/call-bind-apply-helpers/functionApply.mjs.map +1 -0
- package/dist/esm/node_modules/call-bind-apply-helpers/functionCall.mjs +13 -0
- package/dist/esm/node_modules/call-bind-apply-helpers/functionCall.mjs.map +1 -0
- package/dist/esm/node_modules/call-bind-apply-helpers/index.mjs +20 -0
- package/dist/esm/node_modules/call-bind-apply-helpers/index.mjs.map +1 -0
- package/dist/esm/node_modules/call-bind-apply-helpers/reflectApply.mjs +5 -0
- package/dist/esm/node_modules/call-bind-apply-helpers/reflectApply.mjs.map +1 -0
- package/dist/esm/node_modules/call-bound/index.mjs +21 -0
- package/dist/esm/node_modules/call-bound/index.mjs.map +1 -0
- package/dist/esm/node_modules/define-data-property/index.mjs +54 -0
- package/dist/esm/node_modules/define-data-property/index.mjs.map +1 -0
- package/dist/esm/node_modules/dunder-proto/get.mjs +29 -0
- package/dist/esm/node_modules/dunder-proto/get.mjs.map +1 -0
- package/dist/esm/node_modules/es-define-property/index.mjs +16 -0
- package/dist/esm/node_modules/es-define-property/index.mjs.map +1 -0
- package/dist/esm/node_modules/es-errors/eval.mjs +5 -0
- package/dist/esm/node_modules/es-errors/eval.mjs.map +1 -0
- package/dist/esm/node_modules/es-errors/index.mjs +5 -0
- package/dist/esm/node_modules/es-errors/index.mjs.map +1 -0
- package/dist/esm/node_modules/es-errors/range.mjs +5 -0
- package/dist/esm/node_modules/es-errors/range.mjs.map +1 -0
- package/dist/esm/node_modules/es-errors/ref.mjs +5 -0
- package/dist/esm/node_modules/es-errors/ref.mjs.map +1 -0
- package/dist/esm/node_modules/es-errors/syntax.mjs +5 -0
- package/dist/esm/node_modules/es-errors/syntax.mjs.map +1 -0
- package/dist/esm/node_modules/es-errors/type.mjs +5 -0
- package/dist/esm/node_modules/es-errors/type.mjs.map +1 -0
- package/dist/esm/node_modules/es-errors/uri.mjs +5 -0
- package/dist/esm/node_modules/es-errors/uri.mjs.map +1 -0
- package/dist/esm/node_modules/function-bind/implementation.mjs +75 -0
- package/dist/esm/node_modules/function-bind/implementation.mjs.map +1 -0
- package/dist/esm/node_modules/function-bind/index.mjs +14 -0
- package/dist/esm/node_modules/function-bind/index.mjs.map +1 -0
- package/dist/esm/node_modules/get-intrinsic/index.mjs +339 -0
- package/dist/esm/node_modules/get-intrinsic/index.mjs.map +1 -0
- package/dist/esm/node_modules/gopd/gOPD.mjs +5 -0
- package/dist/esm/node_modules/gopd/gOPD.mjs.map +1 -0
- package/dist/esm/node_modules/gopd/index.mjs +16 -0
- package/dist/esm/node_modules/gopd/index.mjs.map +1 -0
- package/dist/esm/node_modules/has-property-descriptors/index.mjs +24 -0
- package/dist/esm/node_modules/has-property-descriptors/index.mjs.map +1 -0
- package/dist/esm/node_modules/has-symbols/index.mjs +31 -0
- package/dist/esm/node_modules/has-symbols/index.mjs.map +1 -0
- package/dist/esm/node_modules/has-symbols/shams.mjs +70 -0
- package/dist/esm/node_modules/has-symbols/shams.mjs.map +1 -0
- package/dist/esm/node_modules/hasown/index.mjs +18 -0
- package/dist/esm/node_modules/hasown/index.mjs.map +1 -0
- package/dist/esm/node_modules/object-inspect/index.mjs +533 -0
- package/dist/esm/node_modules/object-inspect/index.mjs.map +1 -0
- package/dist/esm/node_modules/object-inspect/util.inspect.mjs +6 -0
- package/dist/esm/node_modules/object-inspect/util.inspect.mjs.map +1 -0
- package/dist/esm/node_modules/qs/lib/formats.mjs +22 -0
- package/dist/esm/node_modules/qs/lib/formats.mjs.map +1 -0
- package/dist/esm/node_modules/qs/lib/index.mjs +17 -0
- package/dist/esm/node_modules/qs/lib/index.mjs.map +1 -0
- package/dist/esm/node_modules/qs/lib/parse.mjs +263 -0
- package/dist/esm/node_modules/qs/lib/parse.mjs.map +1 -0
- package/dist/esm/node_modules/qs/lib/stringify.mjs +251 -0
- package/dist/esm/node_modules/qs/lib/stringify.mjs.map +1 -0
- package/dist/esm/node_modules/qs/lib/utils.mjs +229 -0
- package/dist/esm/node_modules/qs/lib/utils.mjs.map +1 -0
- package/dist/esm/node_modules/set-function-length/index.mjs +45 -0
- package/dist/esm/node_modules/set-function-length/index.mjs.map +1 -0
- package/dist/esm/node_modules/side-channel/index.mjs +48 -0
- package/dist/esm/node_modules/side-channel/index.mjs.map +1 -0
- package/dist/esm/node_modules/side-channel-list/index.mjs +117 -0
- package/dist/esm/node_modules/side-channel-list/index.mjs.map +1 -0
- package/dist/esm/node_modules/side-channel-map/index.mjs +74 -0
- package/dist/esm/node_modules/side-channel-map/index.mjs.map +1 -0
- package/dist/esm/node_modules/side-channel-weakmap/index.mjs +90 -0
- package/dist/esm/node_modules/side-channel-weakmap/index.mjs.map +1 -0
- package/dist/esm/packages/sdk/package.json.mjs +4 -0
- package/dist/esm/packages/sdk/package.json.mjs.map +1 -0
- package/dist/esm/services/SBService.mjs +159 -0
- package/dist/esm/services/SBService.mjs.map +1 -0
- package/dist/esm/services/api-logs/LogService.mjs +17 -0
- package/dist/esm/services/api-logs/LogService.mjs.map +1 -0
- package/dist/esm/services/attachments/AttachmentService.mjs +84 -0
- package/dist/esm/services/attachments/AttachmentService.mjs.map +1 -0
- package/dist/esm/services/banks/BankService.mjs +181 -0
- package/dist/esm/services/banks/BankService.mjs.map +1 -0
- package/dist/esm/services/banks/accounts/BankAccountService.mjs +23 -0
- package/dist/esm/services/banks/accounts/BankAccountService.mjs.map +1 -0
- package/dist/esm/services/banks/institutions/BankInstitutionService.mjs +17 -0
- package/dist/esm/services/banks/institutions/BankInstitutionService.mjs.map +1 -0
- package/dist/esm/services/banks/transactions/BankTransactionService.mjs +26 -0
- package/dist/esm/services/banks/transactions/BankTransactionService.mjs.map +1 -0
- package/dist/esm/services/billing/subscriptions/SubscriptionService.mjs +127 -0
- package/dist/esm/services/billing/subscriptions/SubscriptionService.mjs.map +1 -0
- package/dist/esm/services/businesses/BusinessService.mjs +96 -0
- package/dist/esm/services/businesses/BusinessService.mjs.map +1 -0
- package/dist/esm/services/businesses/customers/CustomerService.mjs +92 -0
- package/dist/esm/services/businesses/customers/CustomerService.mjs.map +1 -0
- package/dist/esm/services/businesses/customers/balance-transactions/CustomerBalanceTransactionService.mjs +80 -0
- package/dist/esm/services/businesses/customers/balance-transactions/CustomerBalanceTransactionService.mjs.map +1 -0
- package/dist/esm/services/businesses/customers/payment-methods/CustomerPaymentMethodService.mjs +80 -0
- package/dist/esm/services/businesses/customers/payment-methods/CustomerPaymentMethodService.mjs.map +1 -0
- package/dist/esm/services/businesses/departments/DepartmentService.mjs +157 -0
- package/dist/esm/services/businesses/departments/DepartmentService.mjs.map +1 -0
- package/dist/esm/services/businesses/departments/Employees/DepartmentEmployeeService.mjs +79 -0
- package/dist/esm/services/businesses/departments/Employees/DepartmentEmployeeService.mjs.map +1 -0
- package/dist/esm/services/businesses/domains/DomainService.mjs +19 -0
- package/dist/esm/services/businesses/domains/DomainService.mjs.map +1 -0
- package/dist/esm/services/businesses/fees/FeeService.mjs +91 -0
- package/dist/esm/services/businesses/fees/FeeService.mjs.map +1 -0
- package/dist/esm/services/businesses/locations/LocationService.mjs +137 -0
- package/dist/esm/services/businesses/locations/LocationService.mjs.map +1 -0
- package/dist/esm/services/businesses/prices/PriceService.mjs +22 -0
- package/dist/esm/services/businesses/prices/PriceService.mjs.map +1 -0
- package/dist/esm/services/businesses/products/ProductService.mjs +121 -0
- package/dist/esm/services/businesses/products/ProductService.mjs.map +1 -0
- package/dist/esm/services/businesses/products/images/ProductImageService.mjs +97 -0
- package/dist/esm/services/businesses/products/images/ProductImageService.mjs.map +1 -0
- package/dist/esm/services/businesses/products/modifiers/ProductModifierService.mjs +92 -0
- package/dist/esm/services/businesses/products/modifiers/ProductModifierService.mjs.map +1 -0
- package/dist/esm/services/businesses/products/options/ProductOptionService.mjs +92 -0
- package/dist/esm/services/businesses/products/options/ProductOptionService.mjs.map +1 -0
- package/dist/esm/services/businesses/products/variants/ProductVariantService.mjs +81 -0
- package/dist/esm/services/businesses/products/variants/ProductVariantService.mjs.map +1 -0
- package/dist/esm/services/businesses/promo-codes/PromoCodeService.mjs +92 -0
- package/dist/esm/services/businesses/promo-codes/PromoCodeService.mjs.map +1 -0
- package/dist/esm/services/businesses/reviews/BusinessReviewService.mjs +30 -0
- package/dist/esm/services/businesses/reviews/BusinessReviewService.mjs.map +1 -0
- package/dist/esm/services/businesses/tables/TableService.mjs +27 -0
- package/dist/esm/services/businesses/tables/TableService.mjs.map +1 -0
- package/dist/esm/services/businesses/taxes/TaxService.mjs +87 -0
- package/dist/esm/services/businesses/taxes/TaxService.mjs.map +1 -0
- package/dist/esm/services/businesses/team/invitations/TeamMemberInvitationService.mjs +32 -0
- package/dist/esm/services/businesses/team/invitations/TeamMemberInvitationService.mjs.map +1 -0
- package/dist/esm/services/businesses/team/members/TeamMemberService.mjs +24 -0
- package/dist/esm/services/businesses/team/members/TeamMemberService.mjs.map +1 -0
- package/dist/esm/services/businesses/vendors/VendorService.mjs +89 -0
- package/dist/esm/services/businesses/vendors/VendorService.mjs.map +1 -0
- package/dist/esm/services/cards/CardService.mjs +38 -0
- package/dist/esm/services/cards/CardService.mjs.map +1 -0
- package/dist/esm/services/documents/DocumentService.mjs +38 -0
- package/dist/esm/services/documents/DocumentService.mjs.map +1 -0
- package/dist/esm/services/expenses/ExpenseService.mjs +66 -0
- package/dist/esm/services/expenses/ExpenseService.mjs.map +1 -0
- package/dist/esm/services/explore/ExploreService.mjs +14 -0
- package/dist/esm/services/explore/ExploreService.mjs.map +1 -0
- package/dist/esm/services/friends/FriendService.mjs +26 -0
- package/dist/esm/services/friends/FriendService.mjs.map +1 -0
- package/dist/esm/services/integrations/IntegrationService.mjs +25 -0
- package/dist/esm/services/integrations/IntegrationService.mjs.map +1 -0
- package/dist/esm/services/invoices/InvoiceService.mjs +269 -0
- package/dist/esm/services/invoices/InvoiceService.mjs.map +1 -0
- package/dist/esm/services/loyalty/LoyaltyProgramService.mjs +195 -0
- package/dist/esm/services/loyalty/LoyaltyProgramService.mjs.map +1 -0
- package/dist/esm/services/notifications/NotificationService.mjs +73 -0
- package/dist/esm/services/notifications/NotificationService.mjs.map +1 -0
- package/dist/esm/services/oauth/AccessTokenResponse.mjs +14 -0
- package/dist/esm/services/oauth/AccessTokenResponse.mjs.map +1 -0
- package/dist/esm/services/oauth/AuthorizationCodeResponse.mjs +23 -0
- package/dist/esm/services/oauth/AuthorizationCodeResponse.mjs.map +1 -0
- package/dist/esm/services/oauth/OAuthService.mjs +42 -0
- package/dist/esm/services/oauth/OAuthService.mjs.map +1 -0
- package/dist/esm/services/payment-methods/PaymentMethodService.mjs +38 -0
- package/dist/esm/services/payment-methods/PaymentMethodService.mjs.map +1 -0
- package/dist/esm/services/receipts/ReceiptService.mjs +292 -0
- package/dist/esm/services/receipts/ReceiptService.mjs.map +1 -0
- package/dist/esm/services/settlements/SettlementService.mjs +27 -0
- package/dist/esm/services/settlements/SettlementService.mjs.map +1 -0
- package/dist/esm/services/transactions/TransactionService.mjs +18 -0
- package/dist/esm/services/transactions/TransactionService.mjs.map +1 -0
- package/dist/esm/services/user/UserService.mjs +40 -0
- package/dist/esm/services/user/UserService.mjs.map +1 -0
- package/dist/esm/services/users/UserService.mjs +32 -0
- package/dist/esm/services/users/UserService.mjs.map +1 -0
- package/dist/esm/services/vendors/VendorService.mjs +38 -0
- package/dist/esm/services/vendors/VendorService.mjs.map +1 -0
- package/dist/umd/index.js +9459 -0
- package/dist/umd/index.js.map +1 -0
- package/package.json +2 -2
|
@@ -0,0 +1,257 @@
|
|
|
1
|
+
import _defineProperty from '../node_modules/@babel/runtime/helpers/esm/defineProperty.mjs';
|
|
2
|
+
import { ApiLogService } from '../services/api-logs/LogService.mjs';
|
|
3
|
+
import { BankAccountService } from '../services/banks/accounts/BankAccountService.mjs';
|
|
4
|
+
import { BankTransactionService } from '../services/banks/transactions/BankTransactionService.mjs';
|
|
5
|
+
import { BankService } from '../services/banks/BankService.mjs';
|
|
6
|
+
import { BankInstitutionService } from '../services/banks/institutions/BankInstitutionService.mjs';
|
|
7
|
+
import { CardService } from '../services/cards/CardService.mjs';
|
|
8
|
+
import { DocumentService } from '../services/documents/DocumentService.mjs';
|
|
9
|
+
import { DepartmentService } from '../services/businesses/departments/DepartmentService.mjs';
|
|
10
|
+
import { FriendService } from '../services/friends/FriendService.mjs';
|
|
11
|
+
import 'node-html-parser';
|
|
12
|
+
import { OAuthService } from '../services/oauth/OAuthService.mjs';
|
|
13
|
+
import { BusinessService } from '../services/businesses/BusinessService.mjs';
|
|
14
|
+
import { defaultAPIServiceOptions } from './SBServiceOptions.mjs';
|
|
15
|
+
import 'query-string';
|
|
16
|
+
import 'axios';
|
|
17
|
+
import { TableService } from '../services/businesses/tables/TableService.mjs';
|
|
18
|
+
import { PaymentMethodService } from '../services/payment-methods/PaymentMethodService.mjs';
|
|
19
|
+
import { ReceiptService } from '../services/receipts/ReceiptService.mjs';
|
|
20
|
+
import { SettlementService } from '../services/settlements/SettlementService.mjs';
|
|
21
|
+
import { TransactionService } from '../services/transactions/TransactionService.mjs';
|
|
22
|
+
import { CurrentUserService } from '../services/user/UserService.mjs';
|
|
23
|
+
import { UserService } from '../services/users/UserService.mjs';
|
|
24
|
+
import { v4 } from 'uuid';
|
|
25
|
+
import { SBLogger } from './SBLogger.mjs';
|
|
26
|
+
import { API_URL } from './constants.mjs';
|
|
27
|
+
import { ExploreService } from '../services/explore/ExploreService.mjs';
|
|
28
|
+
import { AttachmentService } from '../services/attachments/AttachmentService.mjs';
|
|
29
|
+
import { InvoiceService } from '../services/invoices/InvoiceService.mjs';
|
|
30
|
+
import { NotificationService } from '../services/notifications/NotificationService.mjs';
|
|
31
|
+
import { SubscriptionService } from '../services/billing/subscriptions/SubscriptionService.mjs';
|
|
32
|
+
import { VendorService } from '../services/vendors/VendorService.mjs';
|
|
33
|
+
import { LoyaltyProgramService } from '../services/loyalty/LoyaltyProgramService.mjs';
|
|
34
|
+
import { IntegrationService } from '../services/integrations/IntegrationService.mjs';
|
|
35
|
+
import { ExpenseService } from '../services/expenses/ExpenseService.mjs';
|
|
36
|
+
|
|
37
|
+
/**
|
|
38
|
+
* Client for the Smartbills API.
|
|
39
|
+
*/
|
|
40
|
+
const defaultOptions = {
|
|
41
|
+
endpoints: {
|
|
42
|
+
api: API_URL,
|
|
43
|
+
auth: API_URL
|
|
44
|
+
},
|
|
45
|
+
debug: false,
|
|
46
|
+
logger: new SBLogger(false),
|
|
47
|
+
sessionId: v4(),
|
|
48
|
+
locale: "en"
|
|
49
|
+
};
|
|
50
|
+
class SBClient {
|
|
51
|
+
/**
|
|
52
|
+
* @constructor
|
|
53
|
+
* Creates an instance of the Smartbills API client.
|
|
54
|
+
*/
|
|
55
|
+
constructor(options = defaultAPIServiceOptions) {
|
|
56
|
+
_defineProperty(this, "logger", void 0);
|
|
57
|
+
_defineProperty(this, "options", void 0);
|
|
58
|
+
_defineProperty(this, "user", void 0);
|
|
59
|
+
_defineProperty(this, "logs", void 0);
|
|
60
|
+
_defineProperty(this, "banks", void 0);
|
|
61
|
+
_defineProperty(this, "bankAccounts", void 0);
|
|
62
|
+
_defineProperty(this, "bankInstitutions", void 0);
|
|
63
|
+
_defineProperty(this, "bankTransactions", void 0);
|
|
64
|
+
_defineProperty(this, "cards", void 0);
|
|
65
|
+
_defineProperty(this, "documents", void 0);
|
|
66
|
+
_defineProperty(this, "domains", void 0);
|
|
67
|
+
_defineProperty(this, "departments", void 0);
|
|
68
|
+
_defineProperty(this, "explore", void 0);
|
|
69
|
+
_defineProperty(this, "invoices", void 0);
|
|
70
|
+
_defineProperty(this, "businesses", void 0);
|
|
71
|
+
_defineProperty(this, "notifications", void 0);
|
|
72
|
+
_defineProperty(this, "oauth", void 0);
|
|
73
|
+
_defineProperty(this, "loyaltyPrograms", void 0);
|
|
74
|
+
_defineProperty(this, "receipts", void 0);
|
|
75
|
+
_defineProperty(this, "transactions", void 0);
|
|
76
|
+
_defineProperty(this, "paymentMethods", void 0);
|
|
77
|
+
_defineProperty(this, "settlements", void 0);
|
|
78
|
+
_defineProperty(this, "friends", void 0);
|
|
79
|
+
_defineProperty(this, "users", void 0);
|
|
80
|
+
_defineProperty(this, "attachments", void 0);
|
|
81
|
+
_defineProperty(this, "subscriptions", void 0);
|
|
82
|
+
_defineProperty(this, "integrations", void 0);
|
|
83
|
+
_defineProperty(this, "tables", void 0);
|
|
84
|
+
_defineProperty(this, "expenses", void 0);
|
|
85
|
+
_defineProperty(this, "vendors", void 0);
|
|
86
|
+
this.options = {
|
|
87
|
+
...defaultOptions,
|
|
88
|
+
...options
|
|
89
|
+
};
|
|
90
|
+
this.logger = options.logger ?? new SBLogger(options.debug);
|
|
91
|
+
this.configureServices();
|
|
92
|
+
this.logger.log(options);
|
|
93
|
+
}
|
|
94
|
+
async initialize() {
|
|
95
|
+
if (this.options.credentials) {
|
|
96
|
+
await this.options.credentials?.getAccessToken(this.oauth);
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
get accessToken() {
|
|
100
|
+
return this.options?.credentials?.accessToken;
|
|
101
|
+
}
|
|
102
|
+
get refreshToken() {
|
|
103
|
+
return this.options?.credentials?.refreshToken;
|
|
104
|
+
}
|
|
105
|
+
setCredentials(credentials) {
|
|
106
|
+
this.options.credentials = credentials;
|
|
107
|
+
this.configureServices();
|
|
108
|
+
}
|
|
109
|
+
setLocale(locale) {
|
|
110
|
+
this.options.locale = locale;
|
|
111
|
+
}
|
|
112
|
+
configureServices() {
|
|
113
|
+
this.oauth = new OAuthService({
|
|
114
|
+
...this.options,
|
|
115
|
+
logger: this.logger,
|
|
116
|
+
url: this.options?.endpoints?.auth
|
|
117
|
+
});
|
|
118
|
+
this.cards = new CardService({
|
|
119
|
+
...this.options,
|
|
120
|
+
logger: this.logger,
|
|
121
|
+
url: this.options?.endpoints?.api
|
|
122
|
+
});
|
|
123
|
+
this.notifications = new NotificationService({
|
|
124
|
+
...this.options,
|
|
125
|
+
logger: this.logger,
|
|
126
|
+
url: this.options?.endpoints?.api
|
|
127
|
+
});
|
|
128
|
+
this.user = new CurrentUserService({
|
|
129
|
+
...this.options,
|
|
130
|
+
logger: this.logger,
|
|
131
|
+
url: this.options?.endpoints?.api
|
|
132
|
+
});
|
|
133
|
+
this.invoices = new InvoiceService({
|
|
134
|
+
...this.options,
|
|
135
|
+
logger: this.logger,
|
|
136
|
+
url: this.options?.endpoints?.api
|
|
137
|
+
});
|
|
138
|
+
this.logs = new ApiLogService({
|
|
139
|
+
...this.options,
|
|
140
|
+
logger: this.logger,
|
|
141
|
+
url: this.options?.endpoints?.api
|
|
142
|
+
});
|
|
143
|
+
this.banks = new BankService({
|
|
144
|
+
...this.options,
|
|
145
|
+
logger: this.logger,
|
|
146
|
+
url: this.options?.endpoints?.api
|
|
147
|
+
});
|
|
148
|
+
this.bankAccounts = new BankAccountService({
|
|
149
|
+
...this.options,
|
|
150
|
+
logger: this.logger,
|
|
151
|
+
url: this.options?.endpoints?.api
|
|
152
|
+
});
|
|
153
|
+
this.bankInstitutions = new BankInstitutionService({
|
|
154
|
+
...this.options,
|
|
155
|
+
logger: this.logger,
|
|
156
|
+
url: this.options?.endpoints?.api
|
|
157
|
+
});
|
|
158
|
+
this.bankTransactions = new BankTransactionService({
|
|
159
|
+
...this.options,
|
|
160
|
+
logger: this.logger,
|
|
161
|
+
url: this.options?.endpoints?.api
|
|
162
|
+
});
|
|
163
|
+
this.documents = new DocumentService({
|
|
164
|
+
...this.options,
|
|
165
|
+
logger: this.logger,
|
|
166
|
+
url: this.options?.endpoints?.api
|
|
167
|
+
});
|
|
168
|
+
this.friends = new FriendService({
|
|
169
|
+
...this.options,
|
|
170
|
+
logger: this.logger,
|
|
171
|
+
url: this.options?.endpoints?.api
|
|
172
|
+
});
|
|
173
|
+
this.businesses = new BusinessService({
|
|
174
|
+
...this.options,
|
|
175
|
+
logger: this.logger,
|
|
176
|
+
url: this.options?.endpoints?.api
|
|
177
|
+
});
|
|
178
|
+
this.businesses = new BusinessService({
|
|
179
|
+
...this.options,
|
|
180
|
+
logger: this.logger,
|
|
181
|
+
url: this.options?.endpoints?.api
|
|
182
|
+
});
|
|
183
|
+
this.departments = new DepartmentService({
|
|
184
|
+
...this.options,
|
|
185
|
+
logger: this.logger,
|
|
186
|
+
url: this.options?.endpoints?.api
|
|
187
|
+
});
|
|
188
|
+
this.explore = new ExploreService({
|
|
189
|
+
...this.options,
|
|
190
|
+
logger: this.logger,
|
|
191
|
+
url: this.options?.endpoints?.api
|
|
192
|
+
});
|
|
193
|
+
this.receipts = new ReceiptService({
|
|
194
|
+
...this.options,
|
|
195
|
+
logger: this.logger,
|
|
196
|
+
url: this.options?.endpoints?.api
|
|
197
|
+
});
|
|
198
|
+
this.transactions = new TransactionService({
|
|
199
|
+
...this.options,
|
|
200
|
+
logger: this.logger,
|
|
201
|
+
url: this.options?.endpoints?.api
|
|
202
|
+
});
|
|
203
|
+
this.paymentMethods = new PaymentMethodService({
|
|
204
|
+
...this.options,
|
|
205
|
+
logger: this.logger,
|
|
206
|
+
url: this.options?.endpoints?.api
|
|
207
|
+
});
|
|
208
|
+
this.settlements = new SettlementService({
|
|
209
|
+
...this.options,
|
|
210
|
+
logger: this.logger,
|
|
211
|
+
url: this.options?.endpoints?.api
|
|
212
|
+
});
|
|
213
|
+
this.users = new UserService({
|
|
214
|
+
...this.options,
|
|
215
|
+
logger: this.logger,
|
|
216
|
+
url: this.options?.endpoints?.api
|
|
217
|
+
});
|
|
218
|
+
this.attachments = new AttachmentService({
|
|
219
|
+
...this.options,
|
|
220
|
+
logger: this.logger,
|
|
221
|
+
url: this.options?.endpoints?.api
|
|
222
|
+
});
|
|
223
|
+
this.subscriptions = new SubscriptionService({
|
|
224
|
+
...this.options,
|
|
225
|
+
logger: this.logger,
|
|
226
|
+
url: this.options?.endpoints?.api
|
|
227
|
+
});
|
|
228
|
+
this.loyaltyPrograms = new LoyaltyProgramService({
|
|
229
|
+
...this.options,
|
|
230
|
+
logger: this.logger,
|
|
231
|
+
url: this.options?.endpoints?.api
|
|
232
|
+
});
|
|
233
|
+
this.integrations = new IntegrationService({
|
|
234
|
+
...this.options,
|
|
235
|
+
logger: this.logger,
|
|
236
|
+
url: this.options?.endpoints?.api
|
|
237
|
+
});
|
|
238
|
+
this.tables = new TableService({
|
|
239
|
+
...this.options,
|
|
240
|
+
logger: this.logger,
|
|
241
|
+
url: this.options?.endpoints?.api
|
|
242
|
+
});
|
|
243
|
+
this.expenses = new ExpenseService({
|
|
244
|
+
...this.options,
|
|
245
|
+
logger: this.logger,
|
|
246
|
+
url: this.options?.endpoints?.api
|
|
247
|
+
});
|
|
248
|
+
this.vendors = new VendorService({
|
|
249
|
+
...this.options,
|
|
250
|
+
logger: this.logger,
|
|
251
|
+
url: this.options?.endpoints?.api
|
|
252
|
+
});
|
|
253
|
+
}
|
|
254
|
+
}
|
|
255
|
+
|
|
256
|
+
export { SBClient };
|
|
257
|
+
//# sourceMappingURL=SBClient.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SBClient.mjs","sources":["../../../src/client/SBClient.ts"],"sourcesContent":["import { ApiLogService } from \"@/services/api-logs\";\nimport { BankAccountService } from \"@/services/banks/accounts\";\nimport { BankTransactionService } from \"@/services/banks/transactions\";\nimport { BankService } from \"@/services/banks\";\nimport { CardService } from \"@/services/cards/CardService\";\nimport { DocumentService } from \"@/services/documents\";\nimport { DomainService } from \"@/services/businesses/domains\";\nimport { DepartmentService } from \"@/services/businesses/departments\";\nimport { FriendService } from \"@/services/friends/FriendService\";\nimport { OAuthService } from \"@/services/oauth\";\nimport { BusinessService } from \"@/services/businesses\";\nimport { PaymentMethodService } from \"@/services/payment-methods\";\nimport { ReceiptService } from \"@/services/receipts\";\nimport { SettlementService } from \"@/services/settlements\";\nimport { TransactionService } from \"@/services/transactions\";\nimport { CurrentUserService } from \"@/services/user\";\nimport { UserService } from \"@/services/users\";\nimport { v4 } from \"uuid\";\nimport { SBClientOptions } from \"./SBClientOptions\";\nimport { SBCredentialProvider } from \"./SBCredentials\";\nimport { SBLogger } from \"./SBLogger\";\nimport { defaultAPIServiceOptions } from \"./SBServiceOptions\";\nimport { API_URL } from \"./constants\";\nimport { ExploreService } from \"../services/explore\";\nimport {\n\tBankInstitutionService,\n\tInvoiceService,\n\tLoyaltyProgramService,\n\tNotificationService,\n} from \"@/services\";\nimport { AttachmentService } from \"@/services/attachments\";\nimport { SubscriptionService } from \"@/services/billing/subscriptions/SubscriptionService\";\nimport { IntegrationService } from \"@/services/integrations\";\nimport { TableService } from \"@/services/businesses/tables\";\nimport { ExpenseService } from \"@/services/expenses\";\nimport { VendorService } from \"@/services/vendors\";\n\n/**\n * Client for the Smartbills API.\n */\nconst defaultOptions: SBClientOptions = {\n\tendpoints: {\n\t\tapi: API_URL,\n\t\tauth: API_URL,\n\t},\n\tdebug: false,\n\tlogger: new SBLogger(false),\n\tsessionId: v4(),\n\tlocale: \"en\",\n};\n\nexport class SBClient {\n\tpublic logger: SBLogger;\n\tpublic options: SBClientOptions;\n\tpublic user: CurrentUserService;\n\tpublic logs: ApiLogService;\n\tpublic banks: BankService;\n\tpublic bankAccounts: BankAccountService;\n\tpublic bankInstitutions: BankInstitutionService;\n\tpublic bankTransactions: BankTransactionService;\n\tpublic cards: CardService;\n\tpublic documents: DocumentService;\n\tpublic domains: DomainService;\n\tpublic departments: DepartmentService;\n\tpublic explore: ExploreService;\n\tpublic invoices: InvoiceService;\n\tpublic businesses: BusinessService;\n\tpublic notifications: NotificationService;\n\n\tpublic oauth: OAuthService;\n\n\tpublic loyaltyPrograms: LoyaltyProgramService;\n\n\tpublic receipts: ReceiptService;\n\tpublic transactions: TransactionService;\n\tpublic paymentMethods: PaymentMethodService;\n\tpublic settlements: SettlementService;\n\tpublic friends: FriendService;\n\tpublic users: UserService;\n\tpublic attachments: AttachmentService;\n\n\tpublic subscriptions: SubscriptionService;\n\tpublic integrations: IntegrationService;\n\tpublic tables: TableService;\n\tpublic expenses: ExpenseService;\n\tpublic vendors: VendorService;\n\n\t/**\n\t * @constructor\n\t * Creates an instance of the Smartbills API client.\n\t */\n\tpublic constructor(options: SBClientOptions = defaultAPIServiceOptions) {\n\t\tthis.options = { ...defaultOptions, ...options };\n\t\tthis.logger = options.logger ?? new SBLogger(options.debug);\n\t\tthis.configureServices();\n\t\tthis.logger.log(options);\n\t}\n\n\tpublic async initialize() {\n\t\tif (this.options.credentials) {\n\t\t\tawait this.options.credentials?.getAccessToken(this.oauth);\n\t\t}\n\t}\n\n\tpublic get accessToken(): string {\n\t\treturn this.options?.credentials?.accessToken;\n\t}\n\n\tpublic get refreshToken(): string {\n\t\treturn this.options?.credentials?.refreshToken;\n\t}\n\n\tpublic setCredentials(credentials: SBCredentialProvider) {\n\t\tthis.options.credentials = credentials;\n\t\tthis.configureServices();\n\t}\n\n\tpublic setLocale(locale: string) {\n\t\tthis.options.locale = locale;\n\t}\n\n\tprotected configureServices() {\n\t\tthis.oauth = new OAuthService({\n\t\t\t...this.options,\n\t\t\tlogger: this.logger,\n\t\t\turl: this.options?.endpoints?.auth,\n\t\t});\n\t\tthis.cards = new CardService({\n\t\t\t...this.options,\n\t\t\tlogger: this.logger,\n\t\t\turl: this.options?.endpoints?.api,\n\t\t});\n\n\t\tthis.notifications = new NotificationService({\n\t\t\t...this.options,\n\t\t\tlogger: this.logger,\n\t\t\turl: this.options?.endpoints?.api,\n\t\t});\n\t\tthis.user = new CurrentUserService({\n\t\t\t...this.options,\n\t\t\tlogger: this.logger,\n\t\t\turl: this.options?.endpoints?.api,\n\t\t});\n\t\tthis.invoices = new InvoiceService({\n\t\t\t...this.options,\n\t\t\tlogger: this.logger,\n\t\t\turl: this.options?.endpoints?.api,\n\t\t});\n\t\tthis.logs = new ApiLogService({\n\t\t\t...this.options,\n\t\t\tlogger: this.logger,\n\t\t\turl: this.options?.endpoints?.api,\n\t\t});\n\t\tthis.banks = new BankService({\n\t\t\t...this.options,\n\t\t\tlogger: this.logger,\n\t\t\turl: this.options?.endpoints?.api,\n\t\t});\n\t\tthis.bankAccounts = new BankAccountService({\n\t\t\t...this.options,\n\t\t\tlogger: this.logger,\n\t\t\turl: this.options?.endpoints?.api,\n\t\t});\n\t\tthis.bankInstitutions = new BankInstitutionService({\n\t\t\t...this.options,\n\t\t\tlogger: this.logger,\n\t\t\turl: this.options?.endpoints?.api,\n\t\t});\n\t\tthis.bankTransactions = new BankTransactionService({\n\t\t\t...this.options,\n\t\t\tlogger: this.logger,\n\t\t\turl: this.options?.endpoints?.api,\n\t\t});\n\n\t\tthis.documents = new DocumentService({\n\t\t\t...this.options,\n\t\t\tlogger: this.logger,\n\t\t\turl: this.options?.endpoints?.api,\n\t\t});\n\n\t\tthis.friends = new FriendService({\n\t\t\t...this.options,\n\t\t\tlogger: this.logger,\n\t\t\turl: this.options?.endpoints?.api,\n\t\t});\n\n\t\tthis.businesses = new BusinessService({\n\t\t\t...this.options,\n\t\t\tlogger: this.logger,\n\t\t\turl: this.options?.endpoints?.api,\n\t\t});\n\t\tthis.businesses = new BusinessService({\n\t\t\t...this.options,\n\t\t\tlogger: this.logger,\n\t\t\turl: this.options?.endpoints?.api,\n\t\t});\n\t\tthis.departments = new DepartmentService({\n\t\t\t...this.options,\n\t\t\tlogger: this.logger,\n\t\t\turl: this.options?.endpoints?.api,\n\t\t});\n\n\t\tthis.explore = new ExploreService({\n\t\t\t...this.options,\n\t\t\tlogger: this.logger,\n\t\t\turl: this.options?.endpoints?.api,\n\t\t});\n\n\t\tthis.receipts = new ReceiptService({\n\t\t\t...this.options,\n\t\t\tlogger: this.logger,\n\t\t\turl: this.options?.endpoints?.api,\n\t\t});\n\t\tthis.transactions = new TransactionService({\n\t\t\t...this.options,\n\t\t\tlogger: this.logger,\n\t\t\turl: this.options?.endpoints?.api,\n\t\t});\n\t\tthis.paymentMethods = new PaymentMethodService({\n\t\t\t...this.options,\n\t\t\tlogger: this.logger,\n\t\t\turl: this.options?.endpoints?.api,\n\t\t});\n\t\tthis.settlements = new SettlementService({\n\t\t\t...this.options,\n\t\t\tlogger: this.logger,\n\t\t\turl: this.options?.endpoints?.api,\n\t\t});\n\n\t\tthis.users = new UserService({\n\t\t\t...this.options,\n\t\t\tlogger: this.logger,\n\t\t\turl: this.options?.endpoints?.api,\n\t\t});\n\t\tthis.attachments = new AttachmentService({\n\t\t\t...this.options,\n\t\t\tlogger: this.logger,\n\t\t\turl: this.options?.endpoints?.api,\n\t\t});\n\t\tthis.subscriptions = new SubscriptionService({\n\t\t\t...this.options,\n\t\t\tlogger: this.logger,\n\t\t\turl: this.options?.endpoints?.api,\n\t\t});\n\t\tthis.loyaltyPrograms = new LoyaltyProgramService({\n\t\t\t...this.options,\n\t\t\tlogger: this.logger,\n\t\t\turl: this.options?.endpoints?.api,\n\t\t});\n\t\tthis.integrations = new IntegrationService({\n\t\t\t...this.options,\n\t\t\tlogger: this.logger,\n\t\t\turl: this.options?.endpoints?.api,\n\t\t});\n\t\tthis.tables = new TableService({\n\t\t\t...this.options,\n\t\t\tlogger: this.logger,\n\t\t\turl: this.options?.endpoints?.api,\n\t\t});\n\t\tthis.expenses = new ExpenseService({\n\t\t\t...this.options,\n\t\t\tlogger: this.logger,\n\t\t\turl: this.options?.endpoints?.api,\n\t\t});\n\t\tthis.vendors = new VendorService({\n\t\t\t...this.options,\n\t\t\tlogger: this.logger,\n\t\t\turl: this.options?.endpoints?.api,\n\t\t});\n\t}\n}\n"],"names":["defaultOptions","endpoints","api","API_URL","auth","debug","logger","SBLogger","sessionId","v4","locale","SBClient","constructor","options","defaultAPIServiceOptions","_defineProperty","configureServices","log","initialize","credentials","getAccessToken","oauth","accessToken","refreshToken","setCredentials","setLocale","OAuthService","url","cards","CardService","notifications","NotificationService","user","CurrentUserService","invoices","InvoiceService","logs","ApiLogService","banks","BankService","bankAccounts","BankAccountService","bankInstitutions","BankInstitutionService","bankTransactions","BankTransactionService","documents","DocumentService","friends","FriendService","businesses","BusinessService","departments","DepartmentService","explore","ExploreService","receipts","ReceiptService","transactions","TransactionService","paymentMethods","PaymentMethodService","settlements","SettlementService","users","UserService","attachments","AttachmentService","subscriptions","SubscriptionService","loyaltyPrograms","LoyaltyProgramService","integrations","IntegrationService","tables","TableService","expenses","ExpenseService","vendors","VendorService"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAqCA;;AAEG;AACH,MAAMA,cAAc,GAAoB;AACvCC,EAAAA,SAAS,EAAE;AACVC,IAAAA,GAAG,EAAEC,OAAO;AACZC,IAAAA,IAAI,EAAED;GACN;AACDE,EAAAA,KAAK,EAAE,KAAK;AACZC,EAAAA,MAAM,EAAE,IAAIC,QAAQ,CAAC,KAAK,CAAC;EAC3BC,SAAS,EAAEC,EAAE,EAAE;AACfC,EAAAA,MAAM,EAAE;CACR;MAEYC,QAAQ,CAAA;AAoCpB;;;AAGG;AACHC,EAAAA,WAAAA,CAAmBC,UAA2BC,wBAAwB,EAAA;IAAAC,eAAA,CAAA,IAAA,EAAA,QAAA,EAAA,KAAA,CAAA,CAAA;IAAAA,eAAA,CAAA,IAAA,EAAA,SAAA,EAAA,KAAA,CAAA,CAAA;IAAA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+
import _defineProperty from '../node_modules/@babel/runtime/helpers/esm/defineProperty.mjs';
|
|
2
|
+
|
|
3
|
+
class SBClientCredentials {
|
|
4
|
+
constructor(clientId, clientSecret, scopes) {
|
|
5
|
+
_defineProperty(this, "clientId", void 0);
|
|
6
|
+
_defineProperty(this, "clientSecret", void 0);
|
|
7
|
+
_defineProperty(this, "scopes", []);
|
|
8
|
+
_defineProperty(this, "accessToken", void 0);
|
|
9
|
+
_defineProperty(this, "refreshToken", void 0);
|
|
10
|
+
this.clientId = clientId;
|
|
11
|
+
this.clientSecret = clientSecret;
|
|
12
|
+
this.scopes = scopes;
|
|
13
|
+
}
|
|
14
|
+
async getAccessToken(service) {
|
|
15
|
+
const request = {
|
|
16
|
+
client_id: this?.clientId,
|
|
17
|
+
client_secret: this?.clientSecret,
|
|
18
|
+
scope: this.scopes.join(" "),
|
|
19
|
+
grant_type: "client_credentials"
|
|
20
|
+
};
|
|
21
|
+
const response = await service.getToken(request);
|
|
22
|
+
this.accessToken = response.access_token;
|
|
23
|
+
this.refreshToken = response.refresh_token;
|
|
24
|
+
this.scopes = response.scope.split(",");
|
|
25
|
+
return response;
|
|
26
|
+
}
|
|
27
|
+
refresh() {}
|
|
28
|
+
}
|
|
29
|
+
class SBAccessToken {
|
|
30
|
+
constructor(accessToken, refreshToken) {
|
|
31
|
+
_defineProperty(this, "accessToken", void 0);
|
|
32
|
+
_defineProperty(this, "refreshToken", void 0);
|
|
33
|
+
this.accessToken = accessToken;
|
|
34
|
+
this.refreshToken = refreshToken;
|
|
35
|
+
}
|
|
36
|
+
getAccessToken(service) {
|
|
37
|
+
return Promise.resolve({
|
|
38
|
+
access_token: this?.accessToken,
|
|
39
|
+
refresh_token: this?.refreshToken
|
|
40
|
+
});
|
|
41
|
+
}
|
|
42
|
+
async refresh() {
|
|
43
|
+
// if (this.refreshToken) {
|
|
44
|
+
// const refreshTokenRequest: RefreshTokenRequest = {
|
|
45
|
+
// client_id: "smartbills",
|
|
46
|
+
// grant_type: "authorization_code",
|
|
47
|
+
// refresh_token: this?.refreshToken,
|
|
48
|
+
// }
|
|
49
|
+
// return await this.authService.refreshToken(refreshTokenRequest);
|
|
50
|
+
// } else {
|
|
51
|
+
// throw new Error();
|
|
52
|
+
// }
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
export { SBAccessToken, SBClientCredentials };
|
|
57
|
+
//# sourceMappingURL=SBCredentials.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SBCredentials.mjs","sources":["../../../src/client/SBCredentials.ts"],"sourcesContent":["import {\n\tAccessTokenResponse,\n\tTokenExchangeRequest,\n\tOAuthService,\n} from \"@/services/oauth\";\n\nexport interface SBCredentialProvider {\n\taccessToken: string;\n\trefreshToken?: string;\n\trefresh();\n\tgetAccessToken(service: OAuthService): Promise<AccessTokenResponse>;\n}\n\nexport class SBClientCredentials implements SBCredentialProvider {\n\tpublic clientId: string;\n\tpublic clientSecret?: string;\n\tpublic scopes: string[] = [];\n\n\tpublic accessToken: string;\n\tpublic constructor(\n\t\tclientId: string,\n\t\tclientSecret?: string,\n\t\tscopes?: string[],\n\t) {\n\t\tthis.clientId = clientId;\n\t\tthis.clientSecret = clientSecret;\n\t\tthis.scopes = scopes;\n\t}\n\n\tasync getAccessToken(service: OAuthService): Promise<AccessTokenResponse> {\n\t\tconst request: TokenExchangeRequest = {\n\t\t\tclient_id: this?.clientId,\n\t\t\tclient_secret: this?.clientSecret,\n\t\t\tscope: this.scopes.join(\" \"),\n\t\t\tgrant_type: \"client_credentials\",\n\t\t};\n\t\tconst response = await service.getToken(request);\n\t\tthis.accessToken = response.access_token;\n\t\tthis.refreshToken = response.refresh_token;\n\t\tthis.scopes = response.scope.split(\",\");\n\t\treturn response;\n\t}\n\n\tpublic refreshToken: string;\n\n\trefresh() {}\n}\n\nexport class SBAccessToken implements SBCredentialProvider {\n\tpublic accessToken: string;\n\tpublic refreshToken: string;\n\n\tpublic constructor(accessToken: string, refreshToken?: string) {\n\t\tthis.accessToken = accessToken;\n\t\tthis.refreshToken = refreshToken;\n\t}\n\tgetAccessToken(service: OAuthService): Promise<AccessTokenResponse> {\n\t\treturn Promise.resolve({\n\t\t\taccess_token: this?.accessToken,\n\t\t\trefresh_token: this?.refreshToken,\n\t\t});\n\t}\n\n\tasync refresh() {\n\t\t// if (this.refreshToken) {\n\t\t// \tconst refreshTokenRequest: RefreshTokenRequest = {\n\t\t// \t\tclient_id: \"smartbills\",\n\t\t// \t\tgrant_type: \"authorization_code\",\n\t\t// \t\trefresh_token: this?.refreshToken,\n\t\t// \t}\n\t\t// \treturn await this.authService.refreshToken(refreshTokenRequest);\n\t\t// } else {\n\t\t// \tthrow new Error();\n\t\t// }\n\t}\n}\n"],"names":["SBClientCredentials","constructor","clientId","clientSecret","scopes","_defineProperty","getAccessToken","service","request","client_id","client_secret","scope","join","grant_type","response","getToken","accessToken","access_token","refreshToken","refresh_token","split","refresh","SBAccessToken","Promise","resolve"],"mappings":";;MAaaA,mBAAmB,CAAA;AAM/BC,EAAAA,WAAAA,CACCC,QAAgB,EAChBC,YAAqB,EACrBC,MAAiB,EAAA;IAAAC,eAAA,CAAA,IAAA,EAAA,UAAA,EAAA,KAAA,CAAA,CAAA;IAAAA,eAAA,CAAA,IAAA,EAAA,cAAA,EAAA,KAAA,CAAA,CAAA;AAAAA,IAAAA,eAAA,iBANQ,EAAE,CAAA;IAAAA,eAAA,CAAA,IAAA,EAAA,aAAA,EAAA,KAAA,CAAA,CAAA;IAAAA,eAAA,CAAA,IAAA,EAAA,cAAA,EAAA,KAAA,CAAA,CAAA;IAQ3B,IAAI,CAACH,QAAQ,GAAGA,QAAQ;IACxB,IAAI,CAACC,YAAY,GAAGA,YAAY;IAChC,IAAI,CAACC,MAAM,GAAGA,MAAM;AACrB;EAEA,MAAME,cAAcA,CAACC,OAAqB,EAAA;AACzC,IAAA,MAAMC,OAAO,GAAyB;MACrCC,SAAS,EAAE,IAAI,EAAEP,QAAQ;MACzBQ,aAAa,EAAE,IAAI,EAAEP,YAAY;MACjCQ,KAAK,EAAE,IAAI,CAACP,MAAM,CAACQ,IAAI,CAAC,GAAG,CAAC;AAC5BC,MAAAA,UAAU,EAAE;KACZ;IACD,MAAMC,QAAQ,GAAG,MAAMP,OAAO,CAACQ,QAAQ,CAACP,OAAO,CAAC;AAChD,IAAA,IAAI,CAACQ,WAAW,GAAGF,QAAQ,CAACG,YAAY;AACxC,IAAA,IAAI,CAACC,YAAY,GAAGJ,QAAQ,CAACK,aAAa;IAC1C,IAAI,CAACf,MAAM,GAAGU,QAAQ,CAACH,KAAK,CAACS,KAAK,CAAC,GAAG,CAAC;AACvC,IAAA,OAAON,QAAQ;AAChB;EAIAO,OAAOA;AACP;MAEYC,aAAa,CAAA;AAIzBrB,EAAAA,WAAmBA,CAAAe,WAAmB,EAAEE,YAAqB,EAAA;IAAAb,eAAA,CAAA,IAAA,EAAA,aAAA,EAAA,KAAA,CAAA,CAAA;IAAAA,eAAA,CAAA,IAAA,EAAA,cAAA,EAAA,KAAA,CAAA,CAAA;IAC5D,IAAI,CAACW,WAAW,GAAGA,WAAW;IAC9B,IAAI,CAACE,YAAY,GAAGA,YAAY;AACjC;EACAZ,cAAcA,CAACC,OAAqB,EAAA;IACnC,OAAOgB,OAAO,CAACC,OAAO,CAAC;MACtBP,YAAY,EAAE,IAAI,EAAED,WAAW;MAC/BG,aAAa,EAAE,IAAI,EAAED;AACrB,KAAA,CAAC;AACH;EAEA,MAAMG,OAAOA,GAAA;AACZ;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AAAA;AAED;;;;"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import _defineProperty from '../node_modules/@babel/runtime/helpers/esm/defineProperty.mjs';
|
|
2
|
+
|
|
3
|
+
class SBEnvironment {
|
|
4
|
+
constructor(url, authUrl) {
|
|
5
|
+
_defineProperty(this, "url", void 0);
|
|
6
|
+
_defineProperty(this, "authUrl", void 0);
|
|
7
|
+
this.url = url;
|
|
8
|
+
this.authUrl = authUrl;
|
|
9
|
+
}
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
export { SBEnvironment };
|
|
13
|
+
//# sourceMappingURL=SBEnvironment.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SBEnvironment.mjs","sources":["../../../src/client/SBEnvironment.ts"],"sourcesContent":["export class SBEnvironment {\n\tpublic constructor(url: string, authUrl: string) {\n\t\tthis.url = url;\n\t\tthis.authUrl = authUrl;\n\t}\n\turl: string;\n\tauthUrl: string;\n}\n"],"names":["SBEnvironment","constructor","url","authUrl","_defineProperty"],"mappings":";;MAAaA,aAAa,CAAA;AACzBC,EAAAA,WAAmBA,CAAAC,GAAW,EAAEC,OAAe,EAAA;IAAAC,eAAA,CAAA,IAAA,EAAA,KAAA,EAAA,KAAA,CAAA,CAAA;IAAAA,eAAA,CAAA,IAAA,EAAA,SAAA,EAAA,KAAA,CAAA,CAAA;IAC9C,IAAI,CAACF,GAAG,GAAGA,GAAG;IACd,IAAI,CAACC,OAAO,GAAGA,OAAO;AACvB;AAGA;;;;"}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import _defineProperty from '../node_modules/@babel/runtime/helpers/esm/defineProperty.mjs';
|
|
2
|
+
|
|
3
|
+
class SBException extends Error {
|
|
4
|
+
constructor(code, message) {
|
|
5
|
+
super(message);
|
|
6
|
+
_defineProperty(this, "code", void 0);
|
|
7
|
+
this.code = code;
|
|
8
|
+
}
|
|
9
|
+
}
|
|
10
|
+
class SBApiException extends Error {
|
|
11
|
+
constructor(error) {
|
|
12
|
+
super();
|
|
13
|
+
_defineProperty(this, "code", void 0);
|
|
14
|
+
_defineProperty(this, "status", void 0);
|
|
15
|
+
_defineProperty(this, "requestId", void 0);
|
|
16
|
+
_defineProperty(this, "response", void 0);
|
|
17
|
+
this.requestId = error.config.headers["Request-Id"];
|
|
18
|
+
if (error.response) {
|
|
19
|
+
let response = error.response?.data;
|
|
20
|
+
try {
|
|
21
|
+
response = JSON.parse(error.response.data);
|
|
22
|
+
} catch {}
|
|
23
|
+
this.code = response?.code;
|
|
24
|
+
this.response = response;
|
|
25
|
+
this.status = error?.response?.status;
|
|
26
|
+
this.message = `[Smartbills API] [${error.code}] ${response?.message ?? error.message}`;
|
|
27
|
+
} else {
|
|
28
|
+
this.code = error.code;
|
|
29
|
+
this.message = error.message;
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
export { SBApiException, SBException };
|
|
35
|
+
//# sourceMappingURL=SBException.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SBException.mjs","sources":["../../../src/client/SBException.ts"],"sourcesContent":["import { AxiosError, AxiosRequestConfig } from \"axios\";\nimport { SBErrorResponse } from \"./SBErrorResponse\";\n\nexport class SBException extends Error {\n\tpublic code: string;\n\n\tpublic constructor(code: string, message: string) {\n\t\tsuper(message);\n\t\tthis.code = code;\n\t}\n}\n\nexport class SBApiException extends Error {\n\tpublic code: string;\n\tpublic status?: number;\n\tpublic requestId: string;\n\tpublic response: SBErrorResponse;\n\tpublic constructor(error: AxiosError<SBErrorResponse>) {\n\t\tsuper();\n\t\tthis.requestId = error.config.headers[\"Request-Id\"];\n\t\tif (error.response) {\n\t\t\tlet response = error.response?.data;\n\t\t\ttry {\n\t\t\t\tresponse = JSON.parse(error.response.data as unknown as string);\n\t\t\t} catch {}\n\t\t\tthis.code = response?.code;\n\t\t\tthis.response = response;\n\t\t\tthis.status = error?.response?.status;\n\t\t\tthis.message = `[Smartbills API] [${error.code}] ${response?.message ?? error.message}`;\n\t\t} else {\n\t\t\tthis.code = error.code;\n\t\t\tthis.message = error.message;\n\t\t}\n\t}\n}\n"],"names":["SBException","Error","constructor","code","message","_defineProperty","SBApiException","error","requestId","config","headers","response","data","JSON","parse","status"],"mappings":";;AAGM,MAAOA,WAAY,SAAQC,KAAK,CAAA;AAGrCC,EAAAA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AA,IAAI,CAACC,OAAO,GAAGG,KAAK,CAACH,OAAO;AAC7B;AACD;AACA;;;;"}
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
import _defineProperty from '../node_modules/@babel/runtime/helpers/esm/defineProperty.mjs';
|
|
2
|
+
import axios from 'axios';
|
|
3
|
+
import { v4 } from 'uuid';
|
|
4
|
+
import { SBApiException, SBException } from './SBException.mjs';
|
|
5
|
+
import { SBLogger } from './SBLogger.mjs';
|
|
6
|
+
import { defaultAPIServiceOptions } from './SBServiceOptions.mjs';
|
|
7
|
+
import { version } from '../packages/sdk/package.json.mjs';
|
|
8
|
+
|
|
9
|
+
const isBrowser = typeof window !== "undefined";
|
|
10
|
+
class SBInstance {
|
|
11
|
+
constructor(options = defaultAPIServiceOptions) {
|
|
12
|
+
_defineProperty(this, "axios", void 0);
|
|
13
|
+
_defineProperty(this, "logger", void 0);
|
|
14
|
+
_defineProperty(this, "options", void 0);
|
|
15
|
+
this.logger = options.logger ?? new SBLogger(options.debug);
|
|
16
|
+
this.options = options;
|
|
17
|
+
this.axios = axios.create({
|
|
18
|
+
baseURL: options.url,
|
|
19
|
+
headers: !isBrowser ? {
|
|
20
|
+
"User-Agent": `Smartbills JS v${version}`
|
|
21
|
+
} : {}
|
|
22
|
+
});
|
|
23
|
+
this.axios.defaults.headers["Accept-Language"] = options.locale;
|
|
24
|
+
this.axios.defaults.headers["Session-Id"] = options?.sessionId;
|
|
25
|
+
if (options.credentials) this.axios.interceptors.request.use(config => {
|
|
26
|
+
config.headers["Authorization"] = "bearer " + options?.credentials?.accessToken;
|
|
27
|
+
this.logger.log("Request", config.method, config.url, config.data);
|
|
28
|
+
return config;
|
|
29
|
+
});
|
|
30
|
+
const addRequestId = (data, headers) => {
|
|
31
|
+
headers["Request-Id"] = v4();
|
|
32
|
+
return data;
|
|
33
|
+
};
|
|
34
|
+
this.axios.defaults.transformRequest = [addRequestId].concat(this.axios.defaults.transformRequest);
|
|
35
|
+
this.axios.interceptors.response.use(response => {
|
|
36
|
+
this.logger.log("response", response.config.method, response.config.url, response?.status, response?.data);
|
|
37
|
+
return response;
|
|
38
|
+
}, async error => {
|
|
39
|
+
this.logger.log("REQUEST FAILED", error.config.headers["Request-Id"]);
|
|
40
|
+
try {
|
|
41
|
+
if (error?.response) {
|
|
42
|
+
throw new SBApiException(error);
|
|
43
|
+
}
|
|
44
|
+
throw error;
|
|
45
|
+
} catch (error) {
|
|
46
|
+
if (axios.isAxiosError(error)) {
|
|
47
|
+
throw new SBApiException(error);
|
|
48
|
+
} else {
|
|
49
|
+
throw new SBException(error.code, error.message);
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
});
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
export { SBInstance };
|
|
57
|
+
//# sourceMappingURL=SBInstance.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SBInstance.mjs","sources":["../../../src/client/SBInstance.ts"],"sourcesContent":["import axios, { AxiosError, AxiosInstance } from \"axios\";\nimport { v4 } from \"uuid\";\nimport { SBApiException, SBException } from \"./SBException\";\nimport { SBLogger } from \"./SBLogger\";\nimport { SBServiceOptions, defaultAPIServiceOptions } from \"./SBServiceOptions\";\nimport { version } from \"../../package.json\";\nconst isBrowser = typeof window !== \"undefined\";\n\nexport class SBInstance {\n\tpublic readonly axios: AxiosInstance;\n\tprivate logger: SBLogger;\n\tprivate options: SBServiceOptions;\n\n\tpublic constructor(options: SBServiceOptions = defaultAPIServiceOptions) {\n\t\tthis.logger = options.logger ?? new SBLogger(options.debug);\n\t\tthis.options = options;\n\t\tthis.axios = axios.create({\n\t\t\tbaseURL: options.url,\n\t\t\theaders: !isBrowser\n\t\t\t\t? {\n\t\t\t\t\t\t\"User-Agent\": `Smartbills JS v${version}`,\n\t\t\t\t\t}\n\t\t\t\t: {},\n\t\t});\n\t\tthis.axios.defaults.headers[\"Accept-Language\"] = options.locale;\n\t\tthis.axios.defaults.headers[\"Session-Id\"] = options?.sessionId;\n\n\t\tif (options.credentials)\n\t\t\tthis.axios.interceptors.request.use((config) => {\n\t\t\t\tconfig.headers[\"Authorization\"] =\n\t\t\t\t\t\"bearer \" + options?.credentials?.accessToken;\n\n\t\t\t\tthis.logger.log(\n\t\t\t\t\t\"Request\",\n\t\t\t\t\tconfig.method,\n\t\t\t\t\tconfig.url,\n\t\t\t\t\tconfig.data,\n\t\t\t\t);\n\t\t\t\treturn config;\n\t\t\t});\n\n\t\tconst addRequestId = (data, headers) => {\n\t\t\theaders[\"Request-Id\"] = v4();\n\t\t\treturn data;\n\t\t};\n\n\t\tthis.axios.defaults.transformRequest = [addRequestId].concat(\n\t\t\tthis.axios.defaults.transformRequest,\n\t\t);\n\t\tthis.axios.interceptors.response.use(\n\t\t\t(response) => {\n\t\t\t\tthis.logger.log(\n\t\t\t\t\t\"response\",\n\t\t\t\t\tresponse.config.method,\n\t\t\t\t\tresponse.config.url,\n\t\t\t\t\tresponse?.status,\n\t\t\t\t\tresponse?.data,\n\t\t\t\t);\n\t\t\t\treturn response;\n\t\t\t},\n\t\t\tasync (error: AxiosError<any>) => {\n\t\t\t\tthis.logger.log(\n\t\t\t\t\t\"REQUEST FAILED\",\n\t\t\t\t\terror.config.headers[\"Request-Id\"],\n\t\t\t\t);\n\n\t\t\t\ttry {\n\t\t\t\t\tif (error?.response) {\n\t\t\t\t\t\tthrow new SBApiException(error);\n\t\t\t\t\t}\n\t\t\t\t\tthrow error;\n\t\t\t\t} catch (error) {\n\t\t\t\t\tif (axios.isAxiosError(error)) {\n\t\t\t\t\t\tthrow new SBApiException(error);\n\t\t\t\t\t} else {\n\t\t\t\t\t\tthrow new SBException(error.code, error.message);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t},\n\t\t);\n\t}\n}\n"],"names":["isBrowser","window","SBInstance","constructor","options","defaultAPIServiceOptions","_defineProperty","logger","SBLogger","debug","axios","create","baseURL","url","headers","version","defaults","locale","sessionId","credentials","interceptors","request","use","config","accessToken","log","method","data","addRequestId","v4","transformRequest","concat","response","status","error","SBApiException","isAxiosError","SBException","code","message"],"mappings":";;;;;;;;AAMA,MAAMA,SAAS,GAAG,OAAOC,MAAM,KAAK,WAAW;MAElCC,UAAU,CAAA;AAKtBC,EAAAA,WAAAA,CAAmBC,UAA4BC,wBAAwB,EAAA;IAAAC,eAAA,CAAA,IAAA,EAAA,OAAA,EAAA,KAAA,CAAA,CAAA;IAAAA,eAAA,CAAA,IAAA,EAAA,QAAA,EAAA,KAAA,CAAA,CAAA;IAAAA,eAAA,CAAA,IAAA,EAAA,SAAA,EAAA,KAAA,CAAA,CAAA;AACtE,IAAA,IAAI,CAACC,MAAM,GAAGH,OAAO,CAACG,MAAM,IAAI,IAAIC,QAAQ,CAACJ,OAAO,CAACK,KAAK,CAAC;IAC3D,IAAI,CAACL,OAAO,GAAGA,OAAO;AACtB,IAAA,IAAI,CAACM,KAAK,GAAGA,KAAK,CAACC,MAAM,CAAC;MACzBC,OAAO,EAAER,OAAO,CAACS,GAAG;MACpBC,OAAO,EAAE,CAACd,SAAS,GAChB;QACA,YAAY,EAAE,kBAAkBe,OAAO,CAAA;AACvC,OAAA,GACA;AACH,KAAA,CAAC;AACF,IAAA,IAAI,CAACL,KAAK,CAACM,QAAQ,CAACF,OAAO,CAAC,iBAAiB,CAAC,GAAGV,OAAO,CAACa,MAAM;AAC/D,IAAA,IAAI,CAACP,KAAK,CAACM,QAAQ,CAACF,OAAO,CAAC,YAAY,CAAC,GAAGV,OAAO,EAAEc,SAAS;AAE9D,IAAA,IAAId,OAAO,CAACe,WAAW,EACtB,IAAI,CAACT,KAAK,CAACU,YAAY,CAACC,OAAO,CAACC,GAAG,CAAEC,MAAM,IAAI;AAC9CA,MAAAA,MAAM,CAACT,OAAO,CAAC,eAAe,CAAC,GAC9B,SAAS,GAAGV,OAAO,EAAEe,WAAW,EAAEK,WAAW;AAE9C,MAAA,IAAI,CAACjB,MAAM,CAACkB,GAAG,CACd,SAAS,EACTF,MA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D;AACD;AACD,KAAC,CACD;AACF;AACA;;;;"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import _defineProperty from '../node_modules/@babel/runtime/helpers/esm/defineProperty.mjs';
|
|
2
|
+
|
|
3
|
+
class SBLogger {
|
|
4
|
+
constructor(debug) {
|
|
5
|
+
_defineProperty(this, "debug", void 0);
|
|
6
|
+
this.debug = debug;
|
|
7
|
+
}
|
|
8
|
+
log(...args) {
|
|
9
|
+
if (this.debug) ;
|
|
10
|
+
}
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
export { SBLogger };
|
|
14
|
+
//# sourceMappingURL=SBLogger.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SBLogger.mjs","sources":["../../../src/client/SBLogger.ts"],"sourcesContent":["export class SBLogger {\n\tprivate readonly debug: boolean;\n\tpublic constructor(debug: boolean) {\n\t\tthis.debug = debug;\n\t}\n\n\tpublic log(...args: any[]) {\n\t\tif (this.debug) {\n\t\t\tconsole.debug(`[SMARTBILLS] ${new Date().toDateString()}`, ...args);\n\t\t}\n\t}\n}\n"],"names":["SBLogger","constructor","debug","_defineProperty","log","args"],"mappings":";;MAAaA,QAAQ,CAAA;EAEpBC,WAAAA,CAAmBC,KAAc,EAAA;IAAAC,eAAA,CAAA,IAAA,EAAA,OAAA,EAAA,KAAA,CAAA,CAAA;IAChC,IAAI,CAACD,KAAK,GAAGA,KAAK;AACnB;EAEOE,GAAGA,CAAC,GAAGC,IAAW,EAAA;AACxB,IAAA,IAAI,IAAI,CAACH,KAAK,EAAE;AAGjB;AACA;;;;"}
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
var SBPermission;
|
|
2
|
+
(function (SBPermission) {
|
|
3
|
+
SBPermission["CUSTOMERS_READ"] = "customers:read";
|
|
4
|
+
SBPermission["CUSTOMERS_CREATE"] = "customers:create";
|
|
5
|
+
SBPermission["CUSTOMERS_DELETE"] = "customers:delete";
|
|
6
|
+
SBPermission["CUSTOMERS_UPDATE"] = "customers:update";
|
|
7
|
+
SBPermission["EMPLOYEES_READ"] = "employees:read";
|
|
8
|
+
SBPermission["EMPLOYEES_CREATE"] = "employees:create";
|
|
9
|
+
SBPermission["EMPLOYEES_DELETE"] = "employees:delete";
|
|
10
|
+
SBPermission["EMPLOYEES_UPDATE"] = "employees:update";
|
|
11
|
+
SBPermission["LOCATIONS_READ"] = "locations:read";
|
|
12
|
+
SBPermission["LOCATIONS_CREATE"] = "locations:create";
|
|
13
|
+
SBPermission["LOCATIONS_DELETE"] = "locations:delete";
|
|
14
|
+
SBPermission["LOCATIONS_UPDATE"] = "locations:update";
|
|
15
|
+
SBPermission["PRODUCTS_READ"] = "products:read";
|
|
16
|
+
SBPermission["PRODUCTS_CREATE"] = "products:create";
|
|
17
|
+
SBPermission["PRODUCTS_DELETE"] = "products:delete";
|
|
18
|
+
SBPermission["PRODUCTS_UPDATE"] = "products:update";
|
|
19
|
+
SBPermission["PAYMENTS_READ"] = "payments:read";
|
|
20
|
+
SBPermission["PAYMENTS_CREATE"] = "payments:create";
|
|
21
|
+
SBPermission["PAYMENTS_DELETE"] = "payments:delete";
|
|
22
|
+
SBPermission["PAYMENTS_UPDATE"] = "payments:update";
|
|
23
|
+
SBPermission["MERCHANTS_READ"] = "businessread";
|
|
24
|
+
SBPermission["MERCHANTS_CREATE"] = "business:create";
|
|
25
|
+
SBPermission["MERCHANTS_DELETE"] = "business:delete";
|
|
26
|
+
SBPermission["MERCHANTS_UPDATE"] = "business:update";
|
|
27
|
+
SBPermission["RECEIPTS_READ"] = "receipts:read";
|
|
28
|
+
SBPermission["RECEIPTS_CREATE"] = "receipts:create";
|
|
29
|
+
SBPermission["RECEIPTS_DELETE"] = "receipts:delete";
|
|
30
|
+
SBPermission["RECEIPTS_UPDATE"] = "receipts:update";
|
|
31
|
+
SBPermission["REVIEWS_READ"] = "reviews:read";
|
|
32
|
+
SBPermission["REVIEWS_CREATE"] = "reviews:create";
|
|
33
|
+
SBPermission["REVIEWS_DELETE"] = "reviews:delete";
|
|
34
|
+
SBPermission["REVIEWS_UPDATE"] = "reviews:update";
|
|
35
|
+
SBPermission["PROMO_CODES_READ"] = "promo_codes:read";
|
|
36
|
+
SBPermission["PROMO_CODES_CREATE"] = "promo_codes:create";
|
|
37
|
+
SBPermission["PROMO_CODES_DELETE"] = "promo_codes:delete";
|
|
38
|
+
SBPermission["PROMO_CODES_UPDATE"] = "promo_codes:update";
|
|
39
|
+
SBPermission["FEES_READ"] = "fees:read";
|
|
40
|
+
SBPermission["FEES_CREATE"] = "fees:create";
|
|
41
|
+
SBPermission["FEES_DELETE"] = "fees:delete";
|
|
42
|
+
SBPermission["FEES_UPDATE"] = "fees:update";
|
|
43
|
+
SBPermission["TAXES_READ"] = "taxes:read";
|
|
44
|
+
SBPermission["TAXES_CREATE"] = "taxes:create";
|
|
45
|
+
SBPermission["TAXES_DELETE"] = "taxes:delete";
|
|
46
|
+
SBPermission["TAXES_UPDATE"] = "taxes:update";
|
|
47
|
+
})(SBPermission || (SBPermission = {}));
|
|
48
|
+
|
|
49
|
+
export { SBPermission };
|
|
50
|
+
//# sourceMappingURL=SBPermission.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SBPermission.mjs","sources":["../../../src/client/SBPermission.ts"],"sourcesContent":["export enum SBPermission {\n\tCUSTOMERS_READ = \"customers:read\",\n\tCUSTOMERS_CREATE = \"customers:create\",\n\tCUSTOMERS_DELETE = \"customers:delete\",\n\tCUSTOMERS_UPDATE = \"customers:update\",\n\n\tEMPLOYEES_READ = \"employees:read\",\n\tEMPLOYEES_CREATE = \"employees:create\",\n\tEMPLOYEES_DELETE = \"employees:delete\",\n\tEMPLOYEES_UPDATE = \"employees:update\",\n\n\tLOCATIONS_READ = \"locations:read\",\n\tLOCATIONS_CREATE = \"locations:create\",\n\tLOCATIONS_DELETE = \"locations:delete\",\n\tLOCATIONS_UPDATE = \"locations:update\",\n\n\tPRODUCTS_READ = \"products:read\",\n\tPRODUCTS_CREATE = \"products:create\",\n\tPRODUCTS_DELETE = \"products:delete\",\n\tPRODUCTS_UPDATE = \"products:update\",\n\n\tPAYMENTS_READ = \"payments:read\",\n\tPAYMENTS_CREATE = \"payments:create\",\n\tPAYMENTS_DELETE = \"payments:delete\",\n\tPAYMENTS_UPDATE = \"payments:update\",\n\n\tMERCHANTS_READ = \"businessread\",\n\tMERCHANTS_CREATE = \"business:create\",\n\tMERCHANTS_DELETE = \"business:delete\",\n\tMERCHANTS_UPDATE = \"business:update\",\n\n\tRECEIPTS_READ = \"receipts:read\",\n\tRECEIPTS_CREATE = \"receipts:create\",\n\tRECEIPTS_DELETE = \"receipts:delete\",\n\tRECEIPTS_UPDATE = \"receipts:update\",\n\n\tREVIEWS_READ = \"reviews:read\",\n\tREVIEWS_CREATE = \"reviews:create\",\n\tREVIEWS_DELETE = \"reviews:delete\",\n\tREVIEWS_UPDATE = \"reviews:update\",\n\n\tPROMO_CODES_READ = \"promo_codes:read\",\n\tPROMO_CODES_CREATE = \"promo_codes:create\",\n\tPROMO_CODES_DELETE = \"promo_codes:delete\",\n\tPROMO_CODES_UPDATE = \"promo_codes:update\",\n\n\tFEES_READ = \"fees:read\",\n\tFEES_CREATE = \"fees:create\",\n\tFEES_DELETE = \"fees:delete\",\n\tFEES_UPDATE = \"fees:update\",\n\n\tTAXES_READ = \"taxes:read\",\n\tTAXES_CREATE = \"taxes:create\",\n\tTAXES_DELETE = \"taxes:delete\",\n\tTAXES_UPDATE = \"taxes:update\",\n}\n"],"names":["SBPermission"],"mappings":"IAAYA;AAAZ,CAAA,UAAYA,YAAY,EAAA;AACvBA,EAAAA,YAAA,CAAA,gBAAA,CAAA,GAAA,gBAAiC;AACjCA,EAAAA,YAAA,CAAA,kBAAA,CAAA,GAAA,kBAAqC;AACrCA,EAAAA,YAAA,CAAA,kBAAA,CAAA,GAAA,kBAAqC;AACrCA,EAAAA,YAAA,CAAA,kBAAA,CAAA,GAAA,kBAAqC;AAErCA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BAAmC;AACnCA,EAAAA,YAAA,CAAA,iBAAA,CAAA,GAAA,iBAAmC;AAEnCA,EAAAA,YAAA,CAAA,cAAA,CAAA,GAAA,cAA6B;AAC7BA,EAAAA,YAAA,CAAA,gBAAA,CAAA,GAAA,gBAAiC;AACjCA,EAAAA,YAAA,CAAA,gBAAA,CAAA,GAAA,gBAAiC;AACjCA,EAAAA,YAAA,CAAA,gBAAA,CAAA,GAAA,gBAAiC;AAEjCA,EAAAA,YAAA,CAAA,kBAAA,CAAA,GAAA,kBAAqC;AACrCA,EAAAA,YAAA,CAAA,oBAAA,CAAA,GAAA,oBAAyC;AACzCA,EAAAA,YAAA,CAAA,oBAAA,CAAA,GAAA,oBAAyC;AACzCA,EAAAA,YAAA,CAAA,oBAAA,CAAA,GAAA,oBAAyC;AAEzCA,EAAAA,YAAA,CAAA,WAAA,CAAA,GAAA,WAAuB;AACvBA,EAAAA,YAAA,CAAA,aAAA,CAAA,GAAA,aAA2B;AAC3BA,EAAAA,YAAA,CAAA,aAAA,CAAA,GAAA,aAA2B;AAC3BA,EAAAA,YAAA,CAAA,aAAA,CAAA,GAAA,aAA2B;AAE3BA,EAAAA,YAAA,CAAA,YAAA,CAAA,GAAA,YAAyB;AACzBA,EAAAA,YAAA,CAAA,cAAA,CAAA,GAAA,cAA6B;AAC7BA,EAAAA,YAAA,CAAA,cAAA,CAAA,GAAA,cAA6B;AAC7BA,EAAAA,YAAA,CAAA,cAAA,CAAA,GAAA,cAA6B;AAC9B,CAAC,EAvDWA,YAAY,KAAZA,YAAY,GAuDvB,EAAA,CAAA,CAAA;;;;"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { v4 } from 'uuid';
|
|
2
|
+
import { SBLogger } from './SBLogger.mjs';
|
|
3
|
+
import { API_URL, AUTH_URL } from './constants.mjs';
|
|
4
|
+
|
|
5
|
+
const defaultAPIServiceOptions = {
|
|
6
|
+
url: API_URL,
|
|
7
|
+
debug: false,
|
|
8
|
+
logger: new SBLogger(false),
|
|
9
|
+
sessionId: v4()
|
|
10
|
+
};
|
|
11
|
+
const defaultAuthServiceoptions = {
|
|
12
|
+
url: AUTH_URL,
|
|
13
|
+
debug: false,
|
|
14
|
+
logger: new SBLogger(false),
|
|
15
|
+
sessionId: v4()
|
|
16
|
+
};
|
|
17
|
+
|
|
18
|
+
export { defaultAPIServiceOptions, defaultAuthServiceoptions };
|
|
19
|
+
//# sourceMappingURL=SBServiceOptions.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SBServiceOptions.mjs","sources":["../../../src/client/SBServiceOptions.ts"],"sourcesContent":["import { v4 } from \"uuid\";\nimport { SBClientOptions } from \"./SBClientOptions\";\nimport { SBLogger } from \"./SBLogger\";\nimport { API_URL, AUTH_URL } from \"./constants\";\n\nexport type SBServiceOptions = Omit<SBClientOptions, \"endpoints\"> & {\n\turl: string;\n\tlocale?: string;\n};\n\nexport const defaultAPIServiceOptions: SBServiceOptions = {\n\turl: API_URL,\n\tdebug: false,\n\tlogger: new SBLogger(false),\n\tsessionId: v4(),\n};\n\nexport const defaultAuthServiceoptions: SBServiceOptions = {\n\turl: AUTH_URL,\n\tdebug: false,\n\tlogger: new SBLogger(false),\n\tsessionId: v4(),\n};\n"],"names":["defaultAPIServiceOptions","url","API_URL","debug","logger","SBLogger","sessionId","v4","defaultAuthServiceoptions","AUTH_URL"],"mappings":";;;;AAUO,MAAMA,wBAAwB,GAAqB;AACzDC,EAAAA,GAAG,EAAEC,OAAO;AACZC,EAAAA,KAAK,EAAE,KAAK;AACZC,EAAAA,MAAM,EAAE,IAAIC,QAAQ,CAAC,KAAK,CAAC;EAC3BC,SAAS,EAAEC,EAAE;;AAGP,MAAMC,yBAAyB,GAAqB;AAC1DP,EAAAA,GAAG,EAAEQ,QAAQ;AACbN,EAAAA,KAAK,EAAE,KAAK;AACZC,EAAAA,MAAM,EAAE,IAAIC,QAAQ,CAAC,KAAK,CAAC;EAC3BC,SAAS,EAAEC,EAAE;;;;;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"constants.mjs","sources":["../../../src/client/constants.ts"],"sourcesContent":["export const API_URL = \"https://api.smartbills.io\";\nexport const AUTH_URL = \"https://api.smartbills.io/auth\";\n"],"names":["API_URL","AUTH_URL"],"mappings":"AAAO,MAAMA,OAAO,GAAG;AAChB,MAAMC,QAAQ,GAAG;;;;"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
var LOGIN_ERRORS;
|
|
2
|
+
(function (LOGIN_ERRORS) {
|
|
3
|
+
LOGIN_ERRORS["InvalidLoginErrors"] = "invalid_return_url";
|
|
4
|
+
LOGIN_ERRORS["InvalidCredentials"] = "invalid_credentials";
|
|
5
|
+
LOGIN_ERRORS["EmailNotConfirmed"] = "email_not_confirmed";
|
|
6
|
+
})(LOGIN_ERRORS || (LOGIN_ERRORS = {}));
|
|
7
|
+
|
|
8
|
+
export { LOGIN_ERRORS };
|
|
9
|
+
//# sourceMappingURL=LoginError.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"LoginError.mjs","sources":["../../../../src/constants/login/LoginError.ts"],"sourcesContent":["export enum LOGIN_ERRORS {\n\tInvalidLoginErrors = \"invalid_return_url\",\n\tInvalidCredentials = \"invalid_credentials\",\n\tEmailNotConfirmed = \"email_not_confirmed\",\n}\n"],"names":["LOGIN_ERRORS"],"mappings":"IAAYA;AAAZ,CAAA,UAAYA,YAAY,EAAA;AACvBA,EAAAA,YAAA,CAAA,oBAAA,CAAA,GAAA,oBAAyC;AACzCA,EAAAA,YAAA,CAAA,oBAAA,CAAA,GAAA,qBAA0C;AAC1CA,EAAAA,YAAA,CAAA,mBAAA,CAAA,GAAA,qBAAyC;AAC1C,CAAC,EAJWA,YAAY,KAAZA,YAAY,GAIvB,EAAA,CAAA,CAAA;;;;"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
var SBGenderEnum;
|
|
2
|
+
(function (SBGenderEnum) {
|
|
3
|
+
SBGenderEnum["Male"] = "MALE";
|
|
4
|
+
SBGenderEnum["Female"] = "FEMALE";
|
|
5
|
+
SBGenderEnum["Other"] = "OTHER";
|
|
6
|
+
})(SBGenderEnum || (SBGenderEnum = {}));
|
|
7
|
+
|
|
8
|
+
export { SBGenderEnum };
|
|
9
|
+
//# sourceMappingURL=SBGenderEnum.mjs.map
|