openapi: 3.0.1 info: title: Zoho Books API description: > This is a generated connector for [Zoho Books API] OpenAPI specification. Zoho Books is online accounting software that manages your finances, automates business workflows, and helps you work collectively across departments. x-ballerina-init-description: > The connector initialization requires setting the API credentials. Create an [Zoho account](https://www.zoho.com/books/signup/) and obtain tokens following [this guide](https://www.zoho.com/books/api/v3/#oauth). x-ballerina-display: label: Zoho Books iconPath: "icon.png" version: "v3" servers: - url: https://books.zoho.com security: - OAuth2: [] - Bearer: [] paths: /api/v3/contacts: get: summary: List contacts. operationId: listContacts parameters: - in: query name: organization_id schema: type: integer required: true description: Unique identifier for an organization responses: 200: description: Returns list of contacts available content: application/json: schema: $ref: '#/schemas/ContactList' post: summary: Add a contact. operationId: addContact parameters: - in: query name: organization_id schema: type: integer required: true description: Unique identifier for an organization requestBody: content: application/json: schema: $ref: '#/components/schemas/Contact' description: Input contact data in JSON format responses: '200': content: application/json: schema: $ref: '#/components/schemas/Contact' description: Success /api/v3/contacts/{contacts_id}: get: summary: Get Contact. operationId: getContact parameters: - in: path name: contacts_id schema: type: integer required: true description: Unique identifier for an contact - in: query name: organization_id schema: type: integer required: true description: Unique identifier for an organization responses: 200: description: Returns information of a contact content: application/json: schema: $ref: '#/schemas/Contact' put: summary: Update a contact. operationId: updateContact parameters: - in: path name: contacts_id schema: type: integer required: true description: Unique identifier for an contact - in: query name: organization_id schema: type: integer required: true description: Unique identifier for an organization requestBody: content: application/json: schema: $ref: '#/components/schemas/Contact' description: Update contact data in JSON format responses: '200': content: application/json: schema: $ref: '#/components/schemas/Contact' description: Success delete: summary: Delete a contact. operationId: deleteContact parameters: - in: path name: contacts_id schema: type: integer required: true description: Unique identifier for an contact - in: query name: organization_id schema: type: integer required: true description: Unique identifier for an organization responses: '200': description: Successful response content: application/json: schema: $ref: "#/components/schemas/SuccessOperation" /api/v3/invoices: get: summary: List Invoices. operationId: listInvoices parameters: - in: query name: organization_id schema: type: integer required: true description: Unique identifier for an organization responses: 200: description: Returns list of invoices available content: application/json: schema: $ref: '#/schemas/InvoiceList' post: summary: Add an invoice. operationId: addInvoice parameters: - in: query name: organization_id schema: type: integer required: true description: Unique identifier for an organization requestBody: content: application/json: schema: $ref: '#/components/schemas/Invoice' description: Input invoice data in JSON format responses: '200': content: application/json: schema: $ref: '#/components/schemas/Invoice' description: Success /api/v3/invoices/{invoice_id}: get: summary: Get Invoice. operationId: getInvoice parameters: - in: path name: invoice_id schema: type: integer required: true description: Unique identifier for an invoice - in: query name: organization_id schema: type: integer required: true description: Unique identifier for an organization responses: 200: description: Returns information of a invoice content: application/json: schema: $ref: '#/schemas/Invoice' put: summary: Update an invoice. operationId: updateInvoice parameters: - in: path name: invoice_id schema: type: integer required: true description: Unique identifier for an invoice - in: query name: organization_id schema: type: integer required: true description: Unique identifier for an organization requestBody: content: application/json: schema: $ref: '#/components/schemas/Invoice' description: Update invoice data in JSON format responses: '200': content: application/json: schema: $ref: '#/components/schemas/Invoice' description: Success delete: summary: Delete an invoice. operationId: deleteInvoice parameters: - in: path name: invoice_id schema: type: integer required: true description: Unique identifier for an invoice - in: query name: organization_id schema: type: integer required: true description: Unique identifier for an organization responses: '200': description: Successful response content: application/json: schema: $ref: "#/components/schemas/SuccessOperation" components: securitySchemes: OAuth2: type: oauth2 flows: authorizationCode: authorizationUrl: https://accounts.zoho.com/oauth/v2/auth tokenUrl: https://accounts.zoho.com/oauth/v2/token scopes: {} Bearer: type: http scheme: bearer schemas: Contact: type: object properties: code: type: integer message: type: string contact: type: array items: $ref: '#/schemas/ContactInfo' ContactList: type: object properties: code: type: integer message: type: string contacts: type: array items: $ref: '#/schemas/ContactInfo' page_context: type: object properties: page: type: integer per_page: type: integer has_more_page: type: boolean applied_filter: type: string sort_column: type: string sort_order: type: string ContactInfo: type: object properties: contact_id: type: integer contact_name: type: string company_name: type: string contact_type: type: string status: type: string payment_terms: type: integer payment_terms_label: type: string currency_id: type: integer currency_code: type: string outstanding_receivable_amount: type: integer unused_credits_receivable_amount: type: number first_name: type: string last_name: type: string email: type: string phone: type: string mobile: type: string created_time: type: string last_modified_time: type: string Invoice: type: object properties: code: type: integer message: type: string contact: type: array items: $ref: '#/schemas/InvoiceInfo' InvoiceList: type: object properties: code: type: integer message: type: string invoices: type: array items: $ref: '#/schemas/InvoiceInfo' page_context: type: object properties: page: type: integer per_page: type: integer has_more_page: type: boolean report_name: type: string applied_filter: type: string sort_column: type: string sort_order: type: string InvoiceInfo: type: object properties: invoice_id: type: integer ach_payment_initiated: type: boolean customer_name: type: string customer_id: type: integer status: type: string invoice_number: type: string SuccessOperation: properties: code: description: Operation status type: integer message: description: Message type: string Errors: properties: code: type: integer message: type: string