UNPKG

@gnosticdev/highlevel-sdk

Version:
1,849 lines 187 kB
//#region src/v2/types/invoices.d.ts interface paths { '/invoices/': { parameters: { query?: never; header?: never; path?: never; cookie?: never; }; /** * List invoices * @description API to get list of invoices */ get: operations['list-invoices']; put?: never; /** * Create Invoice * @description API to create an invoice */ post: operations['create-invoice']; delete?: never; options?: never; head?: never; patch?: never; trace?: never; }; '/invoices/{invoiceId}': { parameters: { query?: never; header?: never; path?: never; cookie?: never; }; /** * Get invoice * @description API to get invoice by invoice id */ get: operations['get-invoice']; /** * Update invoice * @description API to update invoice by invoice id */ put: operations['update-invoice']; post?: never; /** * Delete invoice * @description API to delete invoice by invoice id */ delete: operations['delete-invoice']; options?: never; head?: never; patch?: never; trace?: never; }; '/invoices/{invoiceId}/late-fees-configuration': { parameters: { query?: never; header?: never; path?: never; cookie?: never; }; get?: never; put?: never; post?: never; delete?: never; options?: never; head?: never; /** * Update invoice late fees configuration * @description API to update invoice late fees configuration by invoice id */ patch: operations['update-invoice-late-fees-configuration']; trace?: never; }; '/invoices/{invoiceId}/record-payment': { parameters: { query?: never; header?: never; path?: never; cookie?: never; }; get?: never; put?: never; /** * Record a manual payment for an invoice * @description API to record manual payment for an invoice by invoice id */ post: operations['record-invoice']; delete?: never; options?: never; head?: never; patch?: never; trace?: never; }; '/invoices/{invoiceId}/send': { parameters: { query?: never; header?: never; path?: never; cookie?: never; }; get?: never; put?: never; /** * Send invoice * @description API to send invoice by invoice id */ post: operations['send-invoice']; delete?: never; options?: never; head?: never; patch?: never; trace?: never; }; '/invoices/{invoiceId}/void': { parameters: { query?: never; header?: never; path?: never; cookie?: never; }; get?: never; put?: never; /** * Void invoice * @description API to delete invoice by invoice id */ post: operations['void-invoice']; delete?: never; options?: never; head?: never; patch?: never; trace?: never; }; '/invoices/estimate': { parameters: { query?: never; header?: never; path?: never; cookie?: never; }; get?: never; put?: never; /** * Create New Estimate * @description Create a new estimate with the provided details */ post: operations['create-new-estimate']; delete?: never; options?: never; head?: never; patch?: never; trace?: never; }; '/invoices/estimate/{estimateId}': { parameters: { query?: never; header?: never; path?: never; cookie?: never; }; get?: never; /** * Update Estimate * @description Update an existing estimate with new details */ put: operations['update-estimate']; post?: never; /** * Delete Estimate * @description Delete an existing estimate */ delete: operations['delete-estimate']; options?: never; head?: never; patch?: never; trace?: never; }; '/invoices/estimate/{estimateId}/invoice': { parameters: { query?: never; header?: never; path?: never; cookie?: never; }; get?: never; put?: never; /** * Create Invoice from Estimate * @description Create a new invoice from an existing estimate */ post: operations['create-invoice-from-estimate']; delete?: never; options?: never; head?: never; patch?: never; trace?: never; }; '/invoices/estimate/{estimateId}/send': { parameters: { query?: never; header?: never; path?: never; cookie?: never; }; get?: never; put?: never; /** * Send Estimate * @description API to send estimate by estimate id */ post: operations['send-estimate']; delete?: never; options?: never; head?: never; patch?: never; trace?: never; }; '/invoices/estimate/list': { parameters: { query?: never; header?: never; path?: never; cookie?: never; }; /** * List Estimates * @description Get a paginated list of estimates */ get: operations['list-estimates']; put?: never; post?: never; delete?: never; options?: never; head?: never; patch?: never; trace?: never; }; '/invoices/estimate/number/generate': { parameters: { query?: never; header?: never; path?: never; cookie?: never; }; /** * Generate Estimate Number * @description Get the next estimate number for the given location */ get: operations['generate-estimate-number']; put?: never; post?: never; delete?: never; options?: never; head?: never; patch?: never; trace?: never; }; '/invoices/estimate/stats/last-visited-at': { parameters: { query?: never; header?: never; path?: never; cookie?: never; }; get?: never; put?: never; post?: never; delete?: never; options?: never; head?: never; /** * Update estimate last visited at * @description API to update estimate last visited at by estimate id */ patch: operations['update-estimate-last-visited-at']; trace?: never; }; '/invoices/estimate/template': { parameters: { query?: never; header?: never; path?: never; cookie?: never; }; /** * List Estimate Templates * @description Get a list of estimate templates or a specific template by ID */ get: operations['list-estimate-templates']; put?: never; /** * Create Estimate Template * @description Create a new estimate template */ post: operations['create-estimate-template']; delete?: never; options?: never; head?: never; patch?: never; trace?: never; }; '/invoices/estimate/template/{templateId}': { parameters: { query?: never; header?: never; path?: never; cookie?: never; }; get?: never; /** * Update Estimate Template * @description Update an existing estimate template */ put: operations['update-estimate-template']; post?: never; /** * Delete Estimate Template * @description Delete an existing estimate template */ delete: operations['delete-estimate-template']; options?: never; head?: never; patch?: never; trace?: never; }; '/invoices/estimate/template/preview': { parameters: { query?: never; header?: never; path?: never; cookie?: never; }; /** * Preview Estimate Template * @description Get a preview of an estimate template */ get: operations['preview-estimate-template']; put?: never; post?: never; delete?: never; options?: never; head?: never; patch?: never; trace?: never; }; '/invoices/generate-invoice-number': { parameters: { query?: never; header?: never; path?: never; cookie?: never; }; /** * Generate Invoice Number * @description Get the next invoice number for the given location */ get: operations['generate-invoice-number']; put?: never; post?: never; delete?: never; options?: never; head?: never; patch?: never; trace?: never; }; '/invoices/schedule': { parameters: { query?: never; header?: never; path?: never; cookie?: never; }; /** * List schedules * @description API to get list of schedules */ get: operations['list-invoice-schedules']; put?: never; /** * Create Invoice Schedule * @description API to create an invoice Schedule */ post: operations['create-invoice-schedule']; delete?: never; options?: never; head?: never; patch?: never; trace?: never; }; '/invoices/schedule/{scheduleId}': { parameters: { query?: never; header?: never; path?: never; cookie?: never; }; /** * Get an schedule * @description API to get an schedule by schedule id */ get: operations['get-invoice-schedule']; /** * Update schedule * @description API to update an schedule by schedule id */ put: operations['update-invoice-schedule']; post?: never; /** * Delete schedule * @description API to delete an schedule by schedule id */ delete: operations['delete-invoice-schedule']; options?: never; head?: never; patch?: never; trace?: never; }; '/invoices/schedule/{scheduleId}/auto-payment': { parameters: { query?: never; header?: never; path?: never; cookie?: never; }; get?: never; put?: never; /** * Manage Auto payment for an schedule invoice * @description API to manage auto payment for a schedule */ post: operations['auto-payment-invoice-schedule']; delete?: never; options?: never; head?: never; patch?: never; trace?: never; }; '/invoices/schedule/{scheduleId}/cancel': { parameters: { query?: never; header?: never; path?: never; cookie?: never; }; get?: never; put?: never; /** * Cancel an scheduled invoice * @description API to cancel a scheduled invoice by schedule id */ post: operations['cancel-invoice-schedule']; delete?: never; options?: never; head?: never; patch?: never; trace?: never; }; '/invoices/schedule/{scheduleId}/schedule': { parameters: { query?: never; header?: never; path?: never; cookie?: never; }; get?: never; put?: never; /** * Schedule an schedule invoice * @description API to schedule an schedule invoice to start sending to the customer */ post: operations['schedule-invoice-schedule']; delete?: never; options?: never; head?: never; patch?: never; trace?: never; }; '/invoices/schedule/{scheduleId}/updateAndSchedule': { parameters: { query?: never; header?: never; path?: never; cookie?: never; }; get?: never; put?: never; /** * Update scheduled recurring invoice * @description API to update scheduled recurring invoice */ post: operations['update-and-schedule-invoice-schedule']; delete?: never; options?: never; head?: never; patch?: never; trace?: never; }; '/invoices/stats/last-visited-at': { parameters: { query?: never; header?: never; path?: never; cookie?: never; }; get?: never; put?: never; post?: never; delete?: never; options?: never; head?: never; /** * Update invoice last visited at * @description API to update invoice last visited at by invoice id */ patch: operations['update-invoice-last-visited-at']; trace?: never; }; '/invoices/template': { parameters: { query?: never; header?: never; path?: never; cookie?: never; }; /** * List templates * @description API to get list of templates */ get: operations['list-invoice-templates']; put?: never; /** * Create template * @description API to create a template */ post: operations['create-invoice-template']; delete?: never; options?: never; head?: never; patch?: never; trace?: never; }; '/invoices/template/{templateId}': { parameters: { query?: never; header?: never; path?: never; cookie?: never; }; /** * Get an template * @description API to get an template by template id */ get: operations['get-invoice-template']; /** * Update template * @description API to update an template by template id */ put: operations['update-invoice-template']; post?: never; /** * Delete template * @description API to update an template by template id */ delete: operations['delete-invoice-template']; options?: never; head?: never; patch?: never; trace?: never; }; '/invoices/template/{templateId}/late-fees-configuration': { parameters: { query?: never; header?: never; path?: never; cookie?: never; }; get?: never; put?: never; post?: never; delete?: never; options?: never; head?: never; /** * Update template late fees configuration * @description API to update template late fees configuration by template id */ patch: operations['update-invoice-template-late-fees-configuration']; trace?: never; }; '/invoices/template/{templateId}/payment-methods-configuration': { parameters: { query?: never; header?: never; path?: never; cookie?: never; }; get?: never; put?: never; post?: never; delete?: never; options?: never; head?: never; /** * Update template late fees configuration * @description API to update template late fees configuration by template id */ patch: operations['update-invoice-payment-methods-configuration']; trace?: never; }; '/invoices/text2pay': { parameters: { query?: never; header?: never; path?: never; cookie?: never; }; get?: never; put?: never; /** * Create & Send * @description API to create or update a text2pay invoice */ post: operations['text2pay-invoice']; delete?: never; options?: never; head?: never; patch?: never; trace?: never; }; } type webhooks = Record<string, never>; interface components { schemas: { AdditionalEmailsDto: { /** @example alex@example.com */email: string; }; AddressDto: { /** * @description Address Line 1 * @example 9931 Beechwood */ addressLine1?: string; /** * @description Address Line 2 * @example Beechwood */ addressLine2?: string; /** * @description City * @example St. Houston */ city?: string; /** * @description Country Code * @example US */ countryCode?: string; /** * @description Postal Code * @example 559-6993 */ postalCode?: string; /** * @description State * @example TX */ state?: string; }; AltDto: { /** * @description Location Id or Agency Id * @example 6578278e879ad2646715ba9c */ altId: string; /** @enum {string} */ altType: 'location'; }; AttachmentsDto: { /** * @description Id of the file selected * @example 6241712be68f7a98102ba272 */ id: string; /** * @description Name of the file * @example Electronics.pdf */ name: string; /** * @description Size of the file * @example 10000 */ size: number; /** @description Type of the file */ type: string; /** * @description URL of the file * @example https://example.com/digital-delivery */ url: string; }; AutoInvoice: Record<string, never>; AutoInvoicingDto: { /** * @description Direct Payments * @example true */ directPayments?: boolean; /** * @description Enable Auto Invoice * @example true */ enabled: boolean; }; AutoPaymentDetailsDto: { bacsDirectDebit?: components['schemas']['BacsDirectDebitDTO']; becsDirectDebit?: components['schemas']['BecsDirectDebitDTO']; card?: components['schemas']['CardDto']; cardId?: string; customerId?: string; enable: boolean; paymentMethodId?: string; sepaDirectDebit?: components['schemas']['SepaDirectDebitDTO']; type?: string; usBankAccount?: components['schemas']['USBankAccountDto']; }; AutoPaymentInvoiceScheduleResponseDto: { /** * @description Schedule Id * @example 6578278e879ad2646715ba9c */ _id: string; /** * @description Location Id or Agency Id * @example 6578278e879ad2646715ba9c */ altId: string; /** @enum {string} */ altType: 'location'; /** * @description Business Details * @example { * "name": "Alex", * "address": { * "addressLine1": "9931 Beechwood", * "city": "St. Houston", * "state": "TX", * "countryCode": "USA", * "postalCode": "559-6993" * }, * "phoneNo": "+1-214-559-6993", * "website": "www.example.com" * } */ businessDetails: components['schemas']['BusinessDetailsDto']; /** * @description Compiled terms notes * @example Confidential */ compiledTermsNotes: string; /** * @description Contact Details * @example { * "id": "c6tZZU0rJBf30ZXx9Gli", * "phoneNo": "+1-214-559-6993", * "email": "alex@example.com", * "customFields": [], * "name": "Alex", * "address": { * "countryCode": "US" * } * } */ contactDetails: components['schemas']['ContactDetailsDto']; /** * @description created at * @example 2023-12-12T09:27:42.355Z */ createdAt: string; /** * @description Currency * @example USD */ currency: string; /** * @description Discount * @example { * "type": "percentage", * "value": 0 * } */ discount?: components['schemas']['DiscountDto']; /** @description List of invoices */ invoices: components['schemas']['DefaultInvoiceResponseDto'][]; /** * @description Invoice Items * @example [ * { * "taxes": [], * "_id": "c6tZZU0rJBf30ZXx9Gli", * "productId": "c6tZZU0rJBf30ZXx9Gli", * "priceId": "c6tZZU0rJBf30ZXx9Gli", * "currency": "USD", * "name": "Macbook Pro", * "qty": 1, * "amount": 999 * } * ] */ items: string[]; /** * @description Live Mode * @example false */ liveMode: boolean; /** * @description Name of the invoice * @example New Invoice */ name: string; schedule?: components['schemas']['ScheduleOptionsDto']; /** * @description Schedule Status * @example draft */ status: Record<string, never>; /** * @description Terms notes * @example Confidential */ termsNotes: string; /** * @description Title * @example INVOICE */ title: string; /** * @description Total Amount * @example 999 */ total: number; /** * @description updated at * @example 2023-12-12T09:27:42.355Z */ updatedAt: string; }; AutoPaymentScheduleDto: { /** * @description location Id / company Id based on altType * @example 6578278e879ad2646715ba9c */ altId: string; /** * @description Alt Type * @example location * @enum {string} */ altType: 'location'; /** @description auto-payment configuration */ autoPayment: components['schemas']['AutoPaymentDetailsDto']; id: string; }; BacsDirectDebitDTO: { last4: string; sort_code: string; }; BadRequestDTO: { /** @example Bad Request */message?: string; /** @example 400 */ statusCode?: number; }; BecsDirectDebitDTO: { bsb_number: string; last4: string; }; BusinessDetails: Record<string, never>; BusinessDetailsDto: { /** * @description Business Address * @example 9931 Beechwood, TX */ address?: components['schemas']['AddressDto']; /** @description Custom Values */ customValues?: string[]; /** * @description Business Logo URL * @example https://example.com/logo.png */ logoUrl?: string; /** * @description Business Name * @example ABC Corp. */ name?: string; /** * @description Business Phone Number * @example +1-214-559-6993 */ phoneNo?: string; /** * @description Business Website Link * @example wwww.example.com */ website?: string; }; CancelInvoiceScheduleDto: { /** * @description location Id / company Id based on altType * @example 6578278e879ad2646715ba9c */ altId: string; /** * @description Alt Type * @example location * @enum {string} */ altType: 'location'; }; CancelInvoiceScheduleResponseDto: { /** * @description Schedule Id * @example 6578278e879ad2646715ba9c */ _id: string; /** * @description Location Id or Agency Id * @example 6578278e879ad2646715ba9c */ altId: string; /** @enum {string} */ altType: 'location'; /** * @description Business Details * @example { * "name": "Alex", * "address": { * "addressLine1": "9931 Beechwood", * "city": "St. Houston", * "state": "TX", * "countryCode": "USA", * "postalCode": "559-6993" * }, * "phoneNo": "+1-214-559-6993", * "website": "www.example.com" * } */ businessDetails: components['schemas']['BusinessDetailsDto']; /** * @description Compiled terms notes * @example Confidential */ compiledTermsNotes: string; /** * @description Contact Details * @example { * "id": "c6tZZU0rJBf30ZXx9Gli", * "phoneNo": "+1-214-559-6993", * "email": "alex@example.com", * "customFields": [], * "name": "Alex", * "address": { * "countryCode": "US" * } * } */ contactDetails: components['schemas']['ContactDetailsDto']; /** * @description created at * @example 2023-12-12T09:27:42.355Z */ createdAt: string; /** * @description Currency * @example USD */ currency: string; /** * @description Discount * @example { * "type": "percentage", * "value": 0 * } */ discount?: components['schemas']['DiscountDto']; /** @description List of invoices */ invoices: components['schemas']['DefaultInvoiceResponseDto'][]; /** * @description Invoice Items * @example [ * { * "taxes": [], * "_id": "c6tZZU0rJBf30ZXx9Gli", * "productId": "c6tZZU0rJBf30ZXx9Gli", * "priceId": "c6tZZU0rJBf30ZXx9Gli", * "currency": "USD", * "name": "Macbook Pro", * "qty": 1, * "amount": 999 * } * ] */ items: string[]; /** * @description Live Mode * @example false */ liveMode: boolean; /** * @description Name of the invoice * @example New Invoice */ name: string; schedule?: components['schemas']['ScheduleOptionsDto']; /** * @description Schedule Status * @example draft */ status: Record<string, never>; /** * @description Terms notes * @example Confidential */ termsNotes: string; /** * @description Title * @example INVOICE */ title: string; /** * @description Total Amount * @example 999 */ total: number; /** * @description updated at * @example 2023-12-12T09:27:42.355Z */ updatedAt: string; }; CardDto: { brand: string; last4: string; }; ChequeDto: { /** * @description check number * @example 129-129-129-912 */ number: string; }; ContactDetails: Record<string, never>; ContactDetailsDto: { /** @description Secondary email addresses for the contact to be saved */additionalEmails?: components['schemas']['AdditionalEmailsDto'][]; address?: components['schemas']['AddressDto']; /** * @description Contact Company Name * @example ABC Corp. */ companyName?: string; /** @description Custom Values */ customFields?: string[]; /** * @description Contact Email * @example alex@example.com */ email: string; /** * @description Contact ID * @example 6578278e879ad2646715ba9c */ id: string; /** * @description Contact Name * @example Alex */ name: string; /** * @description Contact Phone Number * @example +1234567890 */ phoneNo: string; }; CreateEstimatesDto: { /** * @description Location Id or Agency Id * @example 6578278e879ad2646715ba9c */ altId: string; /** @enum {string} */ altType: 'location'; /** @description attachments for the invoice */ attachments?: components['schemas']['AttachmentsDto'][]; /** * @description Auto invoice for the estimate * @example { * "enabled": true, * "directPayments": true * } */ autoInvoice?: components['schemas']['AutoInvoicingDto']; /** * @description Automatic taxes enabled for the Estimate * @default false * @example true */ automaticTaxesEnabled: boolean; businessDetails: components['schemas']['BusinessDetailsDto']; /** @description Contact information to send the estimate to */ contactDetails: components['schemas']['ContactDetailsDto']; /** * @description Currency code * @example USD */ currency: string; discount: components['schemas']['DiscountDto']; /** * @description Estimate Number, if not specified will take in the next valid estimate number * @example 1001 */ estimateNumber?: number; /** * @description Prefix for the estimate number * @default EST- * @example EST- */ estimateNumberPrefix: string; /** * @description expiry date estimate * @example 2024-08-10 */ expiryDate?: string; /** @description frequency settings for the estimate */ frequencySettings: components['schemas']['FrequencySettingsDto']; /** * @description issue date estimate * @example 2024-08-07 */ issueDate?: string; /** @description An array of items for the estimate. */ items: components['schemas']['InvoiceItemDto'][]; /** * @description livemode for estimate * @default true * @example true */ liveMode: boolean; /** * @description Meta data for the estimate * @example { * "key": "value" * } */ meta?: Record<string, never>; /** @description miscellaneous charges for the estimate */ miscellaneousCharges?: components['schemas']['ProcessingFeeDto']; /** * @description Estimate Name * @example Home Service Estimate */ name: string; /** @description Payment Schedule Config for the estimate */ paymentScheduleConfig?: components['schemas']['PaymentScheduleConfigDto']; /** @description When sending estimate directly while saving */ sendEstimateDetails?: components['schemas']['SendEstimateDto']; /** @description Email and sent to details for the estimate */ sentTo?: components['schemas']['SentToDto']; /** * @description Terms notes, Also supports HTML markups * @example <p>This is a default terms.</p> */ termsNotes?: string; /** * @description Title for the estimate * @example ESTIMATE */ title?: string; /** * @description User Id * @example 6578278e879ad2646715ba9c */ userId?: string; }; CreateInvoiceDto: { /** * @description location Id / company Id based on altType * @example 6578278e879ad2646715ba9c */ altId: string; /** * @description Alt Type * @example location * @enum {string} */ altType: 'location'; /** @description attachments for the invoice */ attachments?: components['schemas']['AttachmentsDto'][]; /** * @description Automatic taxes enabled for the Invoice * @example true */ automaticTaxesEnabled?: boolean; businessDetails: components['schemas']['BusinessDetailsDto']; /** @description Contact information to send the invoice to */ contactDetails: components['schemas']['ContactDetailsDto']; /** * @description Currency code * @example USD */ currency: string; discount: components['schemas']['DiscountDto']; /** * @description Due date in YYYY-MM-DD format * @example 2023-01-14 */ dueDate?: string; /** * @description Invoice Number * @example 1001 */ invoiceNumber?: string; /** * @description prefix for invoice number * @example INV- */ invoiceNumberPrefix?: string; /** * @description Issue date in YYYY-MM-DD format * @example 2023-01-01 */ issueDate: string; /** @description An array of items for the invoice. */ items: components['schemas']['InvoiceItemDto'][]; /** @description late fees configuration */ lateFeesConfiguration?: components['schemas']['LateFeesConfigurationDto']; liveMode: boolean; /** @description miscellaneous charges for the invoice */ miscellaneousCharges?: components['schemas']['ProcessingFeeDto']; /** * @description Invoice Name * @example New Invoice */ name: string; /** @description Payment Methods for Invoices */ paymentMethods?: components['schemas']['PaymentMethodDto']; /** @description split invoice into payment schedule summing up to full invoice amount */ paymentSchedule?: components['schemas']['PaymentScheduleDto']; sentTo: components['schemas']['SentToDto']; /** * @description Terms notes, Also supports HTML markups * @example <p>This is a default terms.</p> */ termsNotes?: string; /** @description tips configuration for the invoice */ tipsConfiguration?: components['schemas']['TipsConfigurationDto']; /** * @description Title for the invoice * @example INVOICE */ title?: string; }; CreateInvoiceFromEstimateDto: { /** * @description Location Id or Agency Id * @example 6578278e879ad2646715ba9c */ altId: string; /** @enum {string} */ altType: 'location'; /** * @description Mark Estimate as Invoiced * @example true */ markAsInvoiced: boolean; /** * @description Version of the update request * @example v2 * @enum {string} */ version?: 'v1' | 'v2'; }; CreateInvoiceFromEstimateResponseDTO: { /** @description Estimate details */estimate: components['schemas']['EstimateResponseDto']; /** @description Invoice details */ invoice: components['schemas']['DefaultInvoiceResponseDto']; }; CreateInvoiceResponseDto: { /** * @description Invoice Id * @example 6578278e879ad2646715ba9c */ _id: string; /** * @description Location Id or Agency Id * @example 6578278e879ad2646715ba9c */ altId: string; /** @enum {string} */ altType: 'location'; /** * @description Total Amount Due * @example 999 */ amountDue: number; /** * @description Amount Paid * @example 0 */ amountPaid: number; /** * @description Is Automatic taxes calculated for the Invoice items * @example true */ automaticTaxesCalculated?: boolean; /** * @description Automatic taxes enabled for the Invoice * @example true */ automaticTaxesEnabled?: boolean; /** * @description Business Details * @example { * "name": "Alex", * "address": { * "addressLine1": "9931 Beechwood", * "city": "St. Houston", * "state": "TX", * "countryCode": "USA", * "postalCode": "559-6993" * }, * "phoneNo": "+1-214-559-6993", * "website": "www.example.com" * } */ businessDetails: Record<string, never>; /** * @description Contact Details * @example { * "id": "c6tZZU0rJBf30ZXx9Gli", * "phoneNo": "+1-214-559-6993", * "email": "alex@example.com", * "customFields": [], * "name": "Alex", * "address": { * "countryCode": "US" * } * } */ contactDetails: Record<string, never>; /** * @description created at * @example 2023-12-12T09:27:42.355Z */ createdAt: string; /** * @description Currency * @example USD */ currency: string; /** * @description Discount * @example { * "type": "percentage", * "value": 0 * } */ discount?: Record<string, never>; /** * @description Due date in YYYY-MM-DD format * @example 2023-01-01 */ dueDate: string; /** * @description Invoice Items * @example [ * { * "taxes": [], * "_id": "c6tZZU0rJBf30ZXx9Gli", * "productId": "c6tZZU0rJBf30ZXx9Gli", * "priceId": "c6tZZU0rJBf30ZXx9Gli", * "currency": "USD", * "name": "Macbook Pro", * "qty": 1, * "amount": 999 * } * ] */ invoiceItems: string[]; /** * @description Invoice Number * @example 19 */ invoiceNumber: number; /** * @description Issue date in YYYY-MM-DD format * @example 2023-01-01 */ issueDate: string; /** * @description Live Mode * @example false */ liveMode: boolean; /** * @description Name of the invoice * @example New Invoice */ name: string; /** @description split invoice into payment schedule summing up to full invoice amount */ paymentSchedule?: Record<string, never>; /** * @description Invoice Status * @example draft * @enum {string} */ status: 'draft' | 'sent' | 'payment_processing' | 'paid' | 'void' | 'partially_paid'; /** * @description Title * @example INVOICE */ title: string; /** * @description Total Amount * @example 999 */ total: number; /** * @description updated at * @example 2023-12-12T09:27:42.355Z */ updatedAt: string; }; CreateInvoiceScheduleDto: { /** * @description location Id / company Id based on altType * @example 6578278e879ad2646715ba9c */ altId: string; /** * @description Alt Type * @example location * @enum {string} */ altType: 'location'; /** @description attachments for the invoice */ attachments?: components['schemas']['AttachmentsDto'][]; /** * @description Automatic taxes enabled for the Invoice * @example true */ automaticTaxesEnabled?: boolean; businessDetails: components['schemas']['BusinessDetailsDto']; contactDetails: components['schemas']['ContactDetailsDto']; currency: string; discount: components['schemas']['DiscountDto']; /** * @description prefix for invoice number * @example INV- */ invoiceNumberPrefix?: string; items: components['schemas']['InvoiceItemDto'][]; /** @description Late fees configuration for the invoices */ lateFeesConfiguration?: components['schemas']['LateFeesConfigurationDto']; liveMode: boolean; /** @description miscellaneous charges for the invoice */ miscellaneousCharges?: components['schemas']['ProcessingFeeDto']; name: string; /** @description Payment Methods for Invoices */ paymentMethods?: components['schemas']['PaymentMethodDto']; schedule: components['schemas']['ScheduleOptionsDto']; termsNotes?: string; /** @description Configuration for tips on invoices */ tipsConfiguration?: components['schemas']['TipsConfigurationDto']; title?: string; }; CreateInvoiceScheduleResponseDto: { /** * @description Schedule Id * @example 6578278e879ad2646715ba9c */ _id: string; /** * @description Location Id or Agency Id * @example 6578278e879ad2646715ba9c */ altId: string; /** @enum {string} */ altType: 'location'; /** * @description Business Details * @example { * "name": "Alex", * "address": { * "addressLine1": "9931 Beechwood", * "city": "St. Houston", * "state": "TX", * "countryCode": "USA", * "postalCode": "559-6993" * }, * "phoneNo": "+1-214-559-6993", * "website": "www.example.com" * } */ businessDetails: components['schemas']['BusinessDetailsDto']; /** * @description Compiled terms notes * @example Confidential */ compiledTermsNotes: string; /** * @description Contact Details * @example { * "id": "c6tZZU0rJBf30ZXx9Gli", * "phoneNo": "+1-214-559-6993", * "email": "alex@example.com", * "customFields": [], * "name": "Alex", * "address": { * "countryCode": "US" * } * } */ contactDetails: components['schemas']['ContactDetailsDto']; /** * @description created at * @example 2023-12-12T09:27:42.355Z */ createdAt: string; /** * @description Currency * @example USD */ currency: string; /** * @description Discount * @example { * "type": "percentage", * "value": 0 * } */ discount?: components['schemas']['DiscountDto']; /** @description List of invoices */ invoices: components['schemas']['DefaultInvoiceResponseDto'][]; /** * @description Invoice Items * @example [ * { * "taxes": [], * "_id": "c6tZZU0rJBf30ZXx9Gli", * "productId": "c6tZZU0rJBf30ZXx9Gli", * "priceId": "c6tZZU0rJBf30ZXx9Gli", * "currency": "USD", * "name": "Macbook Pro", * "qty": 1, * "amount": 999 * } * ] */ items: string[]; /** * @description Live Mode * @example false */ liveMode: boolean; /** * @description Name of the invoice * @example New Invoice */ name: string; schedule?: components['schemas']['ScheduleOptionsDto']; /** * @description Schedule Status * @example draft */ status: Record<string, never>; /** * @description Terms notes * @example Confidential */ termsNotes: string; /** * @description Title * @example INVOICE */ title: string; /** * @description Total Amount * @example 999 */ total: number; /** * @description updated at * @example 2023-12-12T09:27:42.355Z */ updatedAt: string; }; CreateInvoiceTemplateDto: { /** * @description location Id / company Id based on altType * @example 6578278e879ad2646715ba9c */ altId: string; /** * @description Alt Type * @example location * @enum {string} */ altType: 'location'; /** @description attachments for the invoice */ attachments?: string[]; /** * @description Automatic taxes enabled for the Invoice * @example true */ automaticTaxesEnabled?: boolean; businessDetails: components['schemas']['BusinessDetailsDto']; currency: string; discount?: components['schemas']['DiscountDto']; internal?: boolean; /** * @description prefix for invoice number * @example INV- */ invoiceNumberPrefix?: string; items: components['schemas']['InvoiceItemDto'][]; /** @description Late fees configuration for the invoices */ lateFeesConfiguration?: components['schemas']['LateFeesConfigurationDto']; /** @description miscellaneous charges for the invoice */ miscellaneousCharges?: components['schemas']['ProcessingFeeDto']; /** * @description Name of the template * @example New Template */ name: string; /** @description Payment Methods for Invoices */ paymentMethods?: components['schemas']['PaymentMethodDto']; termsNotes?: string; /** @description Configuration for tips on invoices */ tipsConfiguration?: components['schemas']['TipsConfigurationDto']; /** * @description Template title * @example New Template */ title?: string; }; CreateInvoiceTemplateResponseDto: { /** * @description Template Id * @example 6578278e879ad2646715ba9c */ _id: string; /** * @description Location Id or Agency Id * @example 6578278e879ad2646715ba9c */ altId: string; /** @enum {string} */ altType: 'location'; /** * @description Business Details * @example { * "name": "Alex", * "address": { * "addressLine1": "9931 Beechwood", * "city": "St. Houston", * "state": "TX", * "countryCode": "USA", * "postalCode": "559-6993" * }, * "phoneNo": "+1-214-559-6993", * "website": "www.example.com" * } */ businessDetails: components['schemas']['BusinessDetailsDto']; /** * @description created at * @example 2023-12-12T09:27:42.355Z */ createdAt: string; /** * @description Currency * @example USD */ currency: string; /** * @description Discount * @example { * "type": "percentage", * "value": 0 * } */ discount?: components['schemas']['DiscountDto']; /** * @description prefix for invoice number * @example INV- */ invoiceNumberPrefix?: string; /** * @description Invoice Items * @example [ * { * "taxes": [], * "_id": "c6tZZU0rJBf30ZXx9Gli", * "productId": "c6tZZU0rJBf30ZXx9Gli", * "priceId": "c6tZZU0rJBf30ZXx9Gli", * "currency": "USD", * "name": "Macbook Pro", * "qty": 1, * "amount": 999 * } * ] */ items: string[]; /** * @description Name of the Template * @example New Template */ name: string; /** * @description Total Amount * @example 999 */ total: number; /** * @description updated at * @example 2023-12-12T09:27:42.355Z */ updatedAt: string; }; CustomRRuleOptionsDto: { /** * @description Max number of task executions * @example 10 */ count?: number; /** * @description -1, 1, 2, 3, ..., 27, 28 * @example 15 */ dayOfMonth?: number; /** * @example mo * @enum {string} */ dayOfWeek?: 'mo' | 'tu' | 'we' | 'th' | 'fr' | 'sa' | 'su'; /** * @description Execute task number of days before * @example 5 */ daysBefore?: number; /** * @description End date in YYYY-MM-DD format * @example 2029-11-01 */ endDate?: string; /** * @description End time in HH:mm:ss format * @example 18:45:00 */ endTime?: string; /** * @description End type like after, by, count * @example by */ endType?: string; /** @example 2 */ interval: number; /** * @example monthly * @enum {string} */ intervalType: 'yearly' | 'monthly' | 'weekly' | 'daily' | 'hourly' | 'minutely' | 'secondly'; /** * @example jan * @enum {string} */ monthOfYear?: 'jan' | 'feb' | 'mar' | 'apr' | 'may' | 'jun' | 'jul' | 'aug' | 'sep' | 'oct' | 'nov' | 'dec'; /** * @description -1, 1, 2, 3, 4 * @example -1 */ numOfWeek?: number; /** * @description Start date in YYYY-MM-DD format * @example 2023-01-01 */ startDate: string; /** * @description Start time in HH:mm:ss format * @example 20:45:00 */ startTime?: string; /** * @description Start as primary user accepted date * @example true */ useStartAsPrimaryUserAccepted?: boolean; }; DefaultInvoiceResponseDto: { /** * @description Invoice Id * @example 6578278e879ad2646715ba9c */ _id: string; /** * @description Location Id or Agency Id * @example 6578278e879ad2646715ba9c */ altId: string; /** @enum {string} */ altType: 'location'; /** * @description Total Amount Due * @example 999 */ amountDue: number; /** * @description Amount Paid * @example 0 */ amountPaid: number; /** * @description Is Automatic taxes calculated for the Invoice items * @example true */ automaticTaxesCalculated?: boolean; /** * @description Automatic taxes enabled for the Invoice * @example true */ automaticTaxesEnabled?: boolean; /** * @description Business Details * @example { * "name": "Alex", * "address": { * "addressLine1": "9931 Beechwood", * "city": "St. Houston", * "state": "TX", * "countryCode": "USA", * "postalCode": "559-6993" * }, * "phoneNo": "+1-214-559-6993", * "website": "www.example.com" * } */ businessDetails: Record<string, never>; /** * @description Contact Details * @example { * "id": "c6tZZU0rJBf30ZXx9Gli", * "phoneNo": "+1-214-559-6993", * "email": "alex@example.com", * "customFields": [], * "name": "Alex", * "address": { * "countryCode": "US" * } * } */ contactDetails: Record<string, never>; /** * @description created at * @example 2023-12-12T09:27:42.355Z */ createdAt: string; /** * @description Currency * @example USD */ currency: string; /** * @description Discount * @example { * "type": "percentage", * "value": 0 * } */ discount?: Record<string, never>; /** * @description Due date in YYYY-MM-DD format * @example 2023-01-01 */ dueDate: string; /** * @description Invoice Items * @example [ * { * "taxes": [], * "_id": "c6tZZU0rJBf30ZXx9Gli", * "productId": "c6tZZU0rJBf30ZXx9Gli", * "priceId": "c6tZZU0rJBf30ZXx9Gli", * "currency": "USD", * "name": "Macbook