ballerinax/quickbooks.online Ballerina library

1.5.2

Overview

The QuickBooks API v3 connector(https://developer.intuit.com/app/developer/qbo/docs/get-started) OpenAPI specification.

The QuickBooks Online Accounting API utilizes the REST architecture. It lets you seamlessly integrate your app with QuickBooks Online and the Intuit Financial Ecosystem

Key Features

  • Programmatic access to create and manage resources via REST API
  • Manage user accounts and profiles
  • Secure authentication with API key or OAuth support

Prerequisites

Before using this connector in your Ballerina application, complete the following:

Quickstart

To use the QuickBooks Online connector in your Ballerina application, update the .bal file as follows:

Step 1: Import connector

Import the ballerinax/quickbooks.online module into the Ballerina project.

Copy
import ballerinax/quickbooks.online as quickbooks;

Step 2: Create a new connector instance

Create a configuration file named Config.toml and add the tokens obtained through the OAuth 2.0 Playground to it as follows:

Copy
[authConfig]
clientId=<CLIENT_ID>
clientSecret=<CLIENT_SECRET>
refreshToken=<REFRESH_TOKEN>

Create a quickbooks:ClientConfig and initialize the connector with it.

Copy
configurable quickbooks:OAuth2RefreshTokenGrantConfig & readonly authConfig = ?;
quickbooks:ClientConfig clientConfig = {auth : authConfig};

quickbooks:Client baseClient = 
        check new(clientConfig, "https://sandbox-quickbooks.api.intuit.com");

Step 3: Invoke connector operation

Now you can use the operations available within the connector. Note that they are available as remote operations.

For example, you can fetch a quickbook customer by ID as follows:

```ballerina
public function main() returns error? {
    quickbooks:CustomerResponse response = check baseClient->readCustomer("<REALM_ID>", "<CUSTOMER_ID>");
    log:printInfo("Customer Info : " + response.toString());
}
```

Use bal run command to compile and run the Ballerina program.

Import

import ballerinax/quickbooks.online;Copy

Other versions

See more...

Metadata

Released date: 3 days ago

Version: 1.5.2

License: Apache-2.0


Compatibility

Platform: any

Ballerina version: 2201.8.0

GraalVM compatible: Yes


Pull count

Total: 2014

Current verison: 0


Weekly downloads


Source repository


Keywords

Type/Connector

Vendor/Intuit

Area/Finance & Accounting

Finance/Accounting

Cost/Paid


Contributors