UNPKG

xero-node

Version:

Xero NodeJS OAuth 2.0 client for xero-node

1,391 lines 118 kB
/** * Accounting API * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 2.0.0 * Contact: api@xero.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech * Do not edit the class manually. */ /// <reference types="node" /> import http = require('http'); import fs = require('fs'); import { Account } from '../model/accounting/account'; import { Accounts } from '../model/accounting/accounts'; import { Allocation } from '../model/accounting/allocation'; import { Allocations } from '../model/accounting/allocations'; import { Attachments } from '../model/accounting/attachments'; import { BankTransaction } from '../model/accounting/bankTransaction'; import { BankTransactions } from '../model/accounting/bankTransactions'; import { BankTransfers } from '../model/accounting/bankTransfers'; import { BatchPayments } from '../model/accounting/batchPayments'; import { BrandingThemes } from '../model/accounting/brandingThemes'; import { CISOrgSetting } from '../model/accounting/cISOrgSetting'; import { CISSettings } from '../model/accounting/cISSettings'; import { Contact } from '../model/accounting/contact'; import { ContactGroups } from '../model/accounting/contactGroups'; import { Contacts } from '../model/accounting/contacts'; import { CreditNote } from '../model/accounting/creditNote'; import { CreditNotes } from '../model/accounting/creditNotes'; import { Currencies } from '../model/accounting/currencies'; import { Currency } from '../model/accounting/currency'; import { Employee } from '../model/accounting/employee'; import { Employees } from '../model/accounting/employees'; import { ExpenseClaims } from '../model/accounting/expenseClaims'; import { HistoryRecords } from '../model/accounting/historyRecords'; import { Invoice } from '../model/accounting/invoice'; import { InvoiceReminders } from '../model/accounting/invoiceReminders'; import { Invoices } from '../model/accounting/invoices'; import { Item } from '../model/accounting/item'; import { Items } from '../model/accounting/items'; import { Journals } from '../model/accounting/journals'; import { LinkedTransaction } from '../model/accounting/linkedTransaction'; import { LinkedTransactions } from '../model/accounting/linkedTransactions'; import { ManualJournal } from '../model/accounting/manualJournal'; import { ManualJournals } from '../model/accounting/manualJournals'; import { OnlineInvoices } from '../model/accounting/onlineInvoices'; import { Organisations } from '../model/accounting/organisations'; import { Overpayments } from '../model/accounting/overpayments'; import { Payment } from '../model/accounting/payment'; import { PaymentService } from '../model/accounting/paymentService'; import { PaymentServices } from '../model/accounting/paymentServices'; import { Payments } from '../model/accounting/payments'; import { Prepayments } from '../model/accounting/prepayments'; import { PurchaseOrder } from '../model/accounting/purchaseOrder'; import { PurchaseOrders } from '../model/accounting/purchaseOrders'; import { Quotes } from '../model/accounting/quotes'; import { Receipts } from '../model/accounting/receipts'; import { RepeatingInvoices } from '../model/accounting/repeatingInvoices'; import { ReportWithRows } from '../model/accounting/reportWithRows'; import { Reports } from '../model/accounting/reports'; import { RequestEmpty } from '../model/accounting/requestEmpty'; import { TaxRates } from '../model/accounting/taxRates'; import { TrackingCategories } from '../model/accounting/trackingCategories'; import { TrackingCategory } from '../model/accounting/trackingCategory'; import { TrackingOption } from '../model/accounting/trackingOption'; import { TrackingOptions } from '../model/accounting/trackingOptions'; import { Users } from '../model/accounting/users'; import { Authentication } from '../model/accounting/models'; import { OAuth } from '../model/accounting/models'; export declare enum AccountingApiApiKeys { } export declare class AccountingApi { protected _basePath: string; protected defaultHeaders: any; protected _useQuerystring: boolean; protected binaryHeaders: any; protected authentications: { 'default': Authentication; 'OAuth2': OAuth; }; constructor(basePath?: string); set useQuerystring(value: boolean); set basePath(basePath: string); get basePath(): string; setDefaultAuthentication(auth: Authentication): void; setApiKey(key: AccountingApiApiKeys, value: string): void; set accessToken(token: string); /** * * @summary Allows you to create a new chart of accounts * @param xeroTenantId Xero identifier for Tenant * @param account Request of type Account */ createAccount(xeroTenantId: string, account: Account, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: Accounts; }>; /** * * @summary Allows you to create Attachment on Account * @param xeroTenantId Xero identifier for Tenant * @param accountID Unique identifier for Account object * @param fileName Name of the attachment * @param body Byte array of file in body of request */ createAccountAttachmentByFileName(xeroTenantId: string, accountID: string, fileName: string, body: fs.ReadStream, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: Attachments; }>; /** * * @summary Allows you to create a spend or receive money transaction * @param xeroTenantId Xero identifier for Tenant * @param bankTransaction */ createBankTransaction(xeroTenantId: string, bankTransaction: BankTransaction, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: BankTransactions; }>; /** * * @summary Allows you to createa an Attachment on BankTransaction by Filename * @param xeroTenantId Xero identifier for Tenant * @param bankTransactionID Xero generated unique identifier for a bank transaction * @param fileName The name of the file being attached * @param body Byte array of file in body of request */ createBankTransactionAttachmentByFileName(xeroTenantId: string, bankTransactionID: string, fileName: string, body: fs.ReadStream, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: Attachments; }>; /** * * @summary Allows you to create history record for a bank transactions * @param xeroTenantId Xero identifier for Tenant * @param bankTransactionID Xero generated unique identifier for a bank transaction * @param historyRecords */ createBankTransactionHistoryRecord(xeroTenantId: string, bankTransactionID: string, historyRecords: HistoryRecords, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: HistoryRecords; }>; /** * * @summary Allows you to create a spend or receive money transaction * @param xeroTenantId Xero identifier for Tenant * @param bankTransactions * @param summarizeErrors response format that shows validation errors for each bank transaction */ createBankTransactions(xeroTenantId: string, bankTransactions: BankTransactions, summarizeErrors?: boolean, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: BankTransactions; }>; /** * * @summary Allows you to create a bank transfers * @param xeroTenantId Xero identifier for Tenant * @param bankTransfers */ createBankTransfer(xeroTenantId: string, bankTransfers: BankTransfers, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: BankTransfers; }>; /** * * @param xeroTenantId Xero identifier for Tenant * @param bankTransferID Xero generated unique identifier for a bank transfer * @param fileName The name of the file being attached to a Bank Transfer * @param body Byte array of file in body of request */ createBankTransferAttachmentByFileName(xeroTenantId: string, bankTransferID: string, fileName: string, body: fs.ReadStream, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: Attachments; }>; /** * * @param xeroTenantId Xero identifier for Tenant * @param bankTransferID Xero generated unique identifier for a bank transfer * @param historyRecords */ createBankTransferHistoryRecord(xeroTenantId: string, bankTransferID: string, historyRecords: HistoryRecords, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: HistoryRecords; }>; /** * * @summary Create one or many BatchPayments for invoices * @param xeroTenantId Xero identifier for Tenant * @param batchPayments Request of type BatchPayments containing a Payments array with one or more Payment objects */ createBatchPayment(xeroTenantId: string, batchPayments: BatchPayments, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: BatchPayments; }>; /** * * @summary Allows you to create a history record for a Batch Payment * @param xeroTenantId Xero identifier for Tenant * @param batchPaymentID Unique identifier for BatchPayment * @param historyRecords */ createBatchPaymentHistoryRecord(xeroTenantId: string, batchPaymentID: string, historyRecords: HistoryRecords, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: HistoryRecords; }>; /** * * @summary Allow for the creation of new custom payment service for specified Branding Theme * @param xeroTenantId Xero identifier for Tenant * @param brandingThemeID Unique identifier for a Branding Theme * @param paymentService */ createBrandingThemePaymentServices(xeroTenantId: string, brandingThemeID: string, paymentService: PaymentService, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: PaymentServices; }>; /** * * @summary Allows you to create a single contact in a Xero organisation * @param xeroTenantId Xero identifier for Tenant * @param contact */ createContact(xeroTenantId: string, contact: Contact, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: Contacts; }>; /** * * @param xeroTenantId Xero identifier for Tenant * @param contactID Unique identifier for a Contact * @param fileName Name for the file you are attaching * @param body Byte array of file in body of request */ createContactAttachmentByFileName(xeroTenantId: string, contactID: string, fileName: string, body: fs.ReadStream, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: Attachments; }>; /** * * @summary Allows you to create a contact group * @param xeroTenantId Xero identifier for Tenant * @param contactGroups an array of contact groups with names specified */ createContactGroup(xeroTenantId: string, contactGroups: ContactGroups, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: ContactGroups; }>; /** * * @summary Allows you to add Contacts to a Contract Group * @param xeroTenantId Xero identifier for Tenant * @param contactGroupID Unique identifier for a Contact Group * @param contacts an array of contacts with ContactID to be added to ContactGroup */ createContactGroupContacts(xeroTenantId: string, contactGroupID: string, contacts: Contacts, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: Contacts; }>; /** * * @summary Allows you to retrieve a history records of an Contact * @param xeroTenantId Xero identifier for Tenant * @param contactID Unique identifier for a Contact * @param historyRecords */ createContactHistory(xeroTenantId: string, contactID: string, historyRecords: HistoryRecords, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: HistoryRecords; }>; /** * * @summary Allows you to create a multiple contacts (bulk) in a Xero organisation * @param xeroTenantId Xero identifier for Tenant * @param contacts * @param summarizeErrors response format that shows validation errors for each bank transaction */ createContacts(xeroTenantId: string, contacts: Contacts, summarizeErrors?: boolean, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: Contacts; }>; /** * * @summary Allows you to create a credit note * @param xeroTenantId Xero identifier for Tenant * @param creditNote an array of Credit Notes with a single CreditNote object. */ createCreditNote(xeroTenantId: string, creditNote: CreditNote, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: CreditNotes; }>; /** * * @summary Allows you to create Allocation on CreditNote * @param xeroTenantId Xero identifier for Tenant * @param creditNoteID Unique identifier for a Credit Note * @param allocations an array of Allocations with single Allocation object defined. */ createCreditNoteAllocation(xeroTenantId: string, creditNoteID: string, allocations: Allocations, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: Allocations; }>; /** * * @summary Allows you to create Attachments on CreditNote by file name * @param xeroTenantId Xero identifier for Tenant * @param creditNoteID Unique identifier for a Credit Note * @param fileName Name of the file you are attaching to Credit Note * @param body Byte array of file in body of request */ createCreditNoteAttachmentByFileName(xeroTenantId: string, creditNoteID: string, fileName: string, body: fs.ReadStream, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: Attachments; }>; /** * * @summary Allows you to retrieve a history records of an CreditNote * @param xeroTenantId Xero identifier for Tenant * @param creditNoteID Unique identifier for a Credit Note * @param historyRecords */ createCreditNoteHistory(xeroTenantId: string, creditNoteID: string, historyRecords: HistoryRecords, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: HistoryRecords; }>; /** * * @summary Allows you to create a credit note * @param xeroTenantId Xero identifier for Tenant * @param creditNotes an array of Credit Notes with a single CreditNote object. * @param summarizeErrors shows validation errors for each credit note */ createCreditNotes(xeroTenantId: string, creditNotes: CreditNotes, summarizeErrors?: boolean, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: CreditNotes; }>; /** * * @param xeroTenantId Xero identifier for Tenant * @param currency */ createCurrency(xeroTenantId: string, currency: Currency, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: Currencies; }>; /** * * @summary Allows you to create new employees used in Xero payrun * @param xeroTenantId Xero identifier for Tenant * @param employee */ createEmployee(xeroTenantId: string, employee: Employee, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: Employees; }>; /** * * @summary Allows you to create new employees used in Xero payrun * @param xeroTenantId Xero identifier for Tenant * @param employees */ createEmployees(xeroTenantId: string, employees: Employees, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: Employees; }>; /** * * @summary Allows you to create a history records of an ExpenseClaim * @param xeroTenantId Xero identifier for Tenant * @param expenseClaimID Unique identifier for a ExpenseClaim * @param historyRecords */ createExpenseClaimHistory(xeroTenantId: string, expenseClaimID: string, historyRecords: HistoryRecords, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: HistoryRecords; }>; /** * * @summary Allows you to retrieve expense claims * @param xeroTenantId Xero identifier for Tenant * @param expenseClaims */ createExpenseClaims(xeroTenantId: string, expenseClaims: ExpenseClaims, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: ExpenseClaims; }>; /** * * @summary Allows you to create any sales invoices or purchase bills * @param xeroTenantId Xero identifier for Tenant * @param invoice */ createInvoice(xeroTenantId: string, invoice: Invoice, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: Invoices; }>; /** * * @summary Allows you to create an Attachment on invoices or purchase bills by it\'s filename * @param xeroTenantId Xero identifier for Tenant * @param invoiceID Unique identifier for an Invoice * @param fileName Name of the file you are attaching * @param body Byte array of file in body of request */ createInvoiceAttachmentByFileName(xeroTenantId: string, invoiceID: string, fileName: string, body: fs.ReadStream, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: Attachments; }>; /** * * @summary Allows you to retrieve a history records of an invoice * @param xeroTenantId Xero identifier for Tenant * @param invoiceID Unique identifier for an Invoice * @param historyRecords */ createInvoiceHistory(xeroTenantId: string, invoiceID: string, historyRecords: HistoryRecords, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: HistoryRecords; }>; /** * * @summary Allows you to create any sales invoices or purchase bills * @param xeroTenantId Xero identifier for Tenant * @param invoices * @param summarizeErrors shows validation errors for each invoice */ createInvoices(xeroTenantId: string, invoices: Invoices, summarizeErrors?: boolean, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: Invoices; }>; /** * * @summary Allows you to create an item * @param xeroTenantId Xero identifier for Tenant * @param item */ createItem(xeroTenantId: string, item: Item, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: Items; }>; /** * * @summary Allows you to create a history record for items * @param xeroTenantId Xero identifier for Tenant * @param itemID Unique identifier for an Item * @param historyRecords */ createItemHistory(xeroTenantId: string, itemID: string, historyRecords: HistoryRecords, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: HistoryRecords; }>; /** * * @summary Allows you to create an item * @param xeroTenantId Xero identifier for Tenant * @param items * @param summarizeErrors response format that shows validation errors for each bank transaction */ createItems(xeroTenantId: string, items: Items, summarizeErrors?: boolean, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: Items; }>; /** * * @summary Allows you to create linked transactions (billable expenses) * @param xeroTenantId Xero identifier for Tenant * @param linkedTransaction */ createLinkedTransaction(xeroTenantId: string, linkedTransaction: LinkedTransaction, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: LinkedTransactions; }>; /** * * @summary Allows you to create linked transactions (billable expenses) * @param xeroTenantId Xero identifier for Tenant * @param linkedTransactions */ createLinkedTransactions(xeroTenantId: string, linkedTransactions: LinkedTransactions, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: LinkedTransactions; }>; /** * * @summary Allows you to create a manual journal * @param xeroTenantId Xero identifier for Tenant * @param manualJournal */ createManualJournal(xeroTenantId: string, manualJournal: ManualJournal, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: ManualJournals; }>; /** * * @summary Allows you to create a specified Attachment on ManualJournal by file name * @param xeroTenantId Xero identifier for Tenant * @param manualJournalID Unique identifier for a ManualJournal * @param fileName The name of the file being attached to a ManualJournal * @param body Byte array of file in body of request */ createManualJournalAttachmentByFileName(xeroTenantId: string, manualJournalID: string, fileName: string, body: fs.ReadStream, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: Attachments; }>; /** * * @summary Allows you to create a manual journal * @param xeroTenantId Xero identifier for Tenant * @param manualJournals */ createManualJournals(xeroTenantId: string, manualJournals: ManualJournals, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: ManualJournals; }>; /** * * @summary Allows you to retrieve Allocations for overpayments * @param xeroTenantId Xero identifier for Tenant * @param overpaymentID Unique identifier for a Overpayment * @param allocation */ createOverpaymentAllocation(xeroTenantId: string, overpaymentID: string, allocation: Allocation, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: Allocations; }>; /** * * @summary Allows you to retrieve Allocations for overpayments * @param xeroTenantId Xero identifier for Tenant * @param overpaymentID Unique identifier for a Overpayment * @param allocations */ createOverpaymentAllocations(xeroTenantId: string, overpaymentID: string, allocations: Allocations, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: Allocations; }>; /** * * @summary Allows you to create history records of an Overpayment * @param xeroTenantId Xero identifier for Tenant * @param overpaymentID Unique identifier for a Overpayment * @param historyRecords */ createOverpaymentHistory(xeroTenantId: string, overpaymentID: string, historyRecords: HistoryRecords, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: HistoryRecords; }>; /** * * @summary Allows you to create payments for invoices and credit notes * @param xeroTenantId Xero identifier for Tenant * @param payment */ createPayment(xeroTenantId: string, payment: Payment, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: Payments; }>; /** * * @summary Allows you to create a history record for a payment * @param xeroTenantId Xero identifier for Tenant * @param paymentID Unique identifier for a Payment * @param historyRecords */ createPaymentHistory(xeroTenantId: string, paymentID: string, historyRecords: HistoryRecords, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: HistoryRecords; }>; /** * * @summary Allows you to create payment services * @param xeroTenantId Xero identifier for Tenant * @param paymentServices */ createPaymentService(xeroTenantId: string, paymentServices: PaymentServices, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: PaymentServices; }>; /** * * @summary Allows you to create payments for invoices and credit notes * @param xeroTenantId Xero identifier for Tenant * @param payments */ createPayments(xeroTenantId: string, payments: Payments, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: Payments; }>; /** * * @summary Allows you to create an Allocation for prepayments * @param xeroTenantId Xero identifier for Tenant * @param prepaymentID * @param allocations */ createPrepaymentAllocation(xeroTenantId: string, prepaymentID: string, allocations: Allocations, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: Allocations; }>; /** * * @summary Allows you to create a history record for an Prepayment * @param xeroTenantId Xero identifier for Tenant * @param prepaymentID Unique identifier for a PrePayment * @param historyRecords */ createPrepaymentHistory(xeroTenantId: string, prepaymentID: string, historyRecords: HistoryRecords, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: HistoryRecords; }>; /** * * @summary Allows you to create purchase orders * @param xeroTenantId Xero identifier for Tenant * @param purchaseOrder */ createPurchaseOrder(xeroTenantId: string, purchaseOrder: PurchaseOrder, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: PurchaseOrders; }>; /** * * @summary Allows you to create HistoryRecord for purchase orders * @param xeroTenantId Xero identifier for Tenant * @param purchaseOrderID Unique identifier for a PurchaseOrder * @param historyRecords */ createPurchaseOrderHistory(xeroTenantId: string, purchaseOrderID: string, historyRecords: HistoryRecords, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: HistoryRecords; }>; /** * * @summary Allows you to create purchase orders * @param xeroTenantId Xero identifier for Tenant * @param purchaseOrders * @param summarizeErrors shows validation errors for each purchase order. */ createPurchaseOrders(xeroTenantId: string, purchaseOrders: PurchaseOrders, summarizeErrors?: boolean, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: PurchaseOrders; }>; /** * * @summary Allows you to create draft expense claim receipts for any user * @param xeroTenantId Xero identifier for Tenant * @param receipts */ createReceipt(xeroTenantId: string, receipts: Receipts, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: Receipts; }>; /** * * @summary Allows you to create Attachment on expense claim receipts by file name * @param xeroTenantId Xero identifier for Tenant * @param receiptID Unique identifier for a Receipt * @param fileName The name of the file being attached to the Receipt * @param body Byte array of file in body of request */ createReceiptAttachmentByFileName(xeroTenantId: string, receiptID: string, fileName: string, body: fs.ReadStream, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: Attachments; }>; /** * * @summary Allows you to retrieve a history records of an Receipt * @param xeroTenantId Xero identifier for Tenant * @param receiptID Unique identifier for a Receipt * @param historyRecords */ createReceiptHistory(xeroTenantId: string, receiptID: string, historyRecords: HistoryRecords, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: HistoryRecords; }>; /** * * @summary Allows you to create attachment on repeating invoices by file name * @param xeroTenantId Xero identifier for Tenant * @param repeatingInvoiceID Unique identifier for a Repeating Invoice * @param fileName The name of the file being attached to a Repeating Invoice * @param body Byte array of file in body of request */ createRepeatingInvoiceAttachmentByFileName(xeroTenantId: string, repeatingInvoiceID: string, fileName: string, body: fs.ReadStream, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: Attachments; }>; /** * * @summary Allows you to create history for a repeating invoice * @param xeroTenantId Xero identifier for Tenant * @param repeatingInvoiceID Unique identifier for a Repeating Invoice * @param historyRecords */ createRepeatingInvoiceHistory(xeroTenantId: string, repeatingInvoiceID: string, historyRecords: HistoryRecords, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: HistoryRecords; }>; /** * * @summary Allows you to create one or more Tax Rates * @param xeroTenantId Xero identifier for Tenant * @param taxRates */ createTaxRates(xeroTenantId: string, taxRates: TaxRates, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: TaxRates; }>; /** * * @summary Allows you to create tracking categories * @param xeroTenantId Xero identifier for Tenant * @param trackingCategory */ createTrackingCategory(xeroTenantId: string, trackingCategory: TrackingCategory, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: TrackingCategories; }>; /** * * @summary Allows you to create options for a specified tracking category * @param xeroTenantId Xero identifier for Tenant * @param trackingCategoryID Unique identifier for a TrackingCategory * @param trackingOption */ createTrackingOptions(xeroTenantId: string, trackingCategoryID: string, trackingOption: TrackingOption, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: TrackingOptions; }>; /** * * @summary Allows you to delete a chart of accounts * @param xeroTenantId Xero identifier for Tenant * @param accountID Unique identifier for retrieving single object */ deleteAccount(xeroTenantId: string, accountID: string, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: Accounts; }>; /** * * @summary Allows you to delete a specific Contact from a Contract Group * @param xeroTenantId Xero identifier for Tenant * @param contactGroupID Unique identifier for a Contact Group * @param contactID Unique identifier for a Contact */ deleteContactGroupContact(xeroTenantId: string, contactGroupID: string, contactID: string, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body?: any; }>; /** * * @summary Allows you to delete all Contacts from a Contract Group * @param xeroTenantId Xero identifier for Tenant * @param contactGroupID Unique identifier for a Contact Group */ deleteContactGroupContacts(xeroTenantId: string, contactGroupID: string, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body?: any; }>; /** * * @summary Allows you to delete a specified item * @param xeroTenantId Xero identifier for Tenant * @param itemID Unique identifier for an Item */ deleteItem(xeroTenantId: string, itemID: string, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body?: any; }>; /** * * @summary Allows you to delete a specified linked transactions (billable expenses) * @param xeroTenantId Xero identifier for Tenant * @param linkedTransactionID Unique identifier for a LinkedTransaction */ deleteLinkedTransaction(xeroTenantId: string, linkedTransactionID: string, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body?: any; }>; /** * * @summary Allows you to update a specified payment for invoices and credit notes * @param xeroTenantId Xero identifier for Tenant * @param paymentID Unique identifier for a Payment * @param payments */ deletePayment(xeroTenantId: string, paymentID: string, payments: Payments, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: Payments; }>; /** * * @summary Allows you to delete tracking categories * @param xeroTenantId Xero identifier for Tenant * @param trackingCategoryID Unique identifier for a TrackingCategory */ deleteTrackingCategory(xeroTenantId: string, trackingCategoryID: string, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: TrackingCategories; }>; /** * * @summary Allows you to delete a specified option for a specified tracking category * @param xeroTenantId Xero identifier for Tenant * @param trackingCategoryID Unique identifier for a TrackingCategory * @param trackingOptionID Unique identifier for a Tracking Option */ deleteTrackingOptions(xeroTenantId: string, trackingCategoryID: string, trackingOptionID: string, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: TrackingOptions; }>; /** * * @summary Allows you to email a copy of invoice to related Contact * @param xeroTenantId Xero identifier for Tenant * @param invoiceID Unique identifier for an Invoice * @param requestEmpty */ emailInvoice(xeroTenantId: string, invoiceID: string, requestEmpty: RequestEmpty, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body?: any; }>; /** * * @summary Allows you to retrieve a single chart of accounts * @param xeroTenantId Xero identifier for Tenant * @param accountID Unique identifier for retrieving single object */ getAccount(xeroTenantId: string, accountID: string, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: Accounts; }>; /** * * @summary Allows you to retrieve Attachment on Account by Filename * @param xeroTenantId Xero identifier for Tenant * @param accountID Unique identifier for Account object * @param fileName Name of the attachment * @param contentType The mime type of the attachment file you are retrieving i.e image/jpg, application/pdf */ getAccountAttachmentByFileName(xeroTenantId: string, accountID: string, fileName: string, contentType: string, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: Buffer; }>; /** * * @summary Allows you to retrieve specific Attachment on Account * @param xeroTenantId Xero identifier for Tenant * @param accountID Unique identifier for Account object * @param attachmentID Unique identifier for Attachment object * @param contentType The mime type of the attachment file you are retrieving i.e image/jpg, application/pdf */ getAccountAttachmentById(xeroTenantId: string, accountID: string, attachmentID: string, contentType: string, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: Buffer; }>; /** * * @summary Allows you to retrieve Attachments for accounts * @param xeroTenantId Xero identifier for Tenant * @param accountID Unique identifier for Account object */ getAccountAttachments(xeroTenantId: string, accountID: string, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: Attachments; }>; /** * * @summary Allows you to retrieve the full chart of accounts * @param xeroTenantId Xero identifier for Tenant * @param ifModifiedSince Only records created or modified since this timestamp will be returned * @param where Filter by an any element * @param order Order by an any element */ getAccounts(xeroTenantId: string, ifModifiedSince?: Date, where?: string, order?: string, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: Accounts; }>; /** * * @summary Allows you to retrieve a single spend or receive money transaction * @param xeroTenantId Xero identifier for Tenant * @param bankTransactionID Xero generated unique identifier for a bank transaction */ getBankTransaction(xeroTenantId: string, bankTransactionID: string, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: BankTransactions; }>; /** * * @summary Allows you to retrieve Attachments on BankTransaction by Filename * @param xeroTenantId Xero identifier for Tenant * @param bankTransactionID Xero generated unique identifier for a bank transaction * @param fileName The name of the file being attached * @param contentType The mime type of the attachment file you are retrieving i.e image/jpg, application/pdf */ getBankTransactionAttachmentByFileName(xeroTenantId: string, bankTransactionID: string, fileName: string, contentType: string, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: Buffer; }>; /** * * @summary Allows you to retrieve Attachments on a specific BankTransaction * @param xeroTenantId Xero identifier for Tenant * @param bankTransactionID Xero generated unique identifier for a bank transaction * @param attachmentID Xero generated unique identifier for an attachment * @param contentType The mime type of the attachment file you are retrieving i.e image/jpg, application/pdf */ getBankTransactionAttachmentById(xeroTenantId: string, bankTransactionID: string, attachmentID: string, contentType: string, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: Buffer; }>; /** * * @summary Allows you to retrieve any attachments to bank transactions * @param xeroTenantId Xero identifier for Tenant * @param bankTransactionID Xero generated unique identifier for a bank transaction */ getBankTransactionAttachments(xeroTenantId: string, bankTransactionID: string, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: Attachments; }>; /** * * @summary Allows you to retrieve any spend or receive money transactions * @param xeroTenantId Xero identifier for Tenant * @param ifModifiedSince Only records created or modified since this timestamp will be returned * @param where Filter by an any element * @param order Order by an any element * @param page e.g. page&#x3D;1 – Up to 100 bank transactions will be returned in a single API call with line items shown for each bank transaction * @param unitdp e.g. unitdp&#x3D;4 – You can opt in to use four decimal places for unit amounts */ getBankTransactions(xeroTenantId: string, ifModifiedSince?: Date, where?: string, order?: string, page?: number, unitdp?: number, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: BankTransactions; }>; /** * * @summary Allows you to retrieve history from a bank transactions * @param xeroTenantId Xero identifier for Tenant * @param bankTransactionID Xero generated unique identifier for a bank transaction */ getBankTransactionsHistory(xeroTenantId: string, bankTransactionID: string, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: HistoryRecords; }>; /** * * @summary Allows you to retrieve any bank transfers * @param xeroTenantId Xero identifier for Tenant * @param bankTransferID Xero generated unique identifier for a bank transfer */ getBankTransfer(xeroTenantId: string, bankTransferID: string, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: BankTransfers; }>; /** * * @summary Allows you to retrieve Attachments on BankTransfer by file name * @param xeroTenantId Xero identifier for Tenant * @param bankTransferID Xero generated unique identifier for a bank transfer * @param fileName The name of the file being attached to a Bank Transfer * @param contentType The mime type of the attachment file you are retrieving i.e image/jpg, application/pdf */ getBankTransferAttachmentByFileName(xeroTenantId: string, bankTransferID: string, fileName: string, contentType: string, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: Buffer; }>; /** * * @summary Allows you to retrieve Attachments on BankTransfer * @param xeroTenantId Xero identifier for Tenant * @param bankTransferID Xero generated unique identifier for a bank transfer * @param attachmentID Xero generated unique identifier for an Attachment to a bank transfer * @param contentType The mime type of the attachment file you are retrieving i.e image/jpg, application/pdf */ getBankTransferAttachmentById(xeroTenantId: string, bankTransferID: string, attachmentID: string, contentType: string, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: Buffer; }>; /** * * @summary Allows you to retrieve Attachments from bank transfers * @param xeroTenantId Xero identifier for Tenant * @param bankTransferID Xero generated unique identifier for a bank transfer */ getBankTransferAttachments(xeroTenantId: string, bankTransferID: string, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: Attachments; }>; /** * * @summary Allows you to retrieve history from a bank transfers * @param xeroTenantId Xero identifier for Tenant * @param bankTransferID Xero generated unique identifier for a bank transfer */ getBankTransferHistory(xeroTenantId: string, bankTransferID: string, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: HistoryRecords; }>; /** * * @summary Allows you to retrieve all bank transfers * @param xeroTenantId Xero identifier for Tenant * @param ifModifiedSince Only records created or modified since this timestamp will be returned * @param where Filter by an any element * @param order Order by an any element */ getBankTransfers(xeroTenantId: string, ifModifiedSince?: Date, where?: string, order?: string, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: BankTransfers; }>; /** * * @summary Allows you to retrieve history from a Batch Payment * @param xeroTenantId Xero identifier for Tenant * @param batchPaymentID Unique identifier for BatchPayment */ getBatchPaymentHistory(xeroTenantId: string, batchPaymentID: string, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: HistoryRecords; }>; /** * * @summary Retrieve either one or many BatchPayments for invoices * @param xeroTenantId Xero identifier for Tenant * @param ifModifiedSince Only records created or modified since this timestamp will be returned * @param where Filter by an any element * @param order Order by an any element */ getBatchPayments(xeroTenantId: string, ifModifiedSince?: Date, where?: string, order?: string, options?: { headers: { [name: string]: string; }; }): Promise<{ response: http.IncomingMessage; body: BatchPayments; }>; /** * * @summary Allows you to retrieve a specific BrandingThemes