Upgrading to Conductor's new Node.js SDK
How to migrate from the old conductor-node
package to Conductor’s new Node.js SDK and QuickBooks Desktop API v2.
We’re excited to announce a major update to conductor-node
that brings full support for Conductor’s new QuickBooks Desktop API v2. This new version introduces significant improvements in usability, consistency, and functionality.
Though the old version of conductor-node
will continue to work, it will not
receive any further updates. We strongly recommend upgrading to take advantage
of the new features and improvements.
Key improvements
Our new QuickBooks Desktop API v2 has been completely redesigned from the ground up. We’ve carefully chosen every field name, parameter, and method description to be significantly more intuitive and clearer than QuickBooks’s original documentation. The API structure has been simplified while maintaining full functionality.
Major improvements include:
- Automatic pagination support
- Automatic retries with exponential backoff
- Configurable timeouts
- Improved parameter and fields names
- Completely rewritten inline documentation
- New methods like
.retrieve()
and.delete()
- All fields included in responses
- Consistent array handling
How to upgrade
Breaking changes
No QuickBooks or Conductor business logic has changed! We’ve simply made the interface simpler, more intuitive, and more robust, while adding new features like automatic pagination and retries.
⚠️ Functional Changes
1. Missing QuickBooks Desktop types
1. Missing QuickBooks Desktop types
Several less common QuickBooks Desktop types/endpoints from the previous version of conductor-node
are not yet available in the new SDK. If the type is listed in the left sidebar of this page, it is supported in the new SDK.
Need a missing QBD type? Contact us and we’ll add it ASAP.
2. Pagination limited to 150 records per page
2. Pagination limited to 150 records per page
Previously, the API would return all matching records by default. This could lead to performance issues when unintentionally retrieving thousands of records, potentially causing long response times, overloading QuickBooks Desktop, and consuming excessive memory.
To prevent these issues, Conductor now limits responses to a maximum of 150 records per page by default. This limit was carefully determined through extensive testing across different scenarios and system configurations to optimize performance while avoiding timeouts and resource constraints.
With the new automatic pagination, you can efficiently retrieve all records when needed, without worrying about these performance concerns.
⚠️ Naming and Structure Changes
1. Restructured constructor parameters
1. Restructured constructor parameters
Old:
New: You can now automatically load your secret key from the CONDUCTOR_SECRET_KEY
environment variable (or pass it to the constructor as an argument like before):
2. Renamed resources
2. Renamed resources
Old: Singular resource names.
New: Plural resource names and clearer naming.
3. Renamed methods
3. Renamed methods
Old: Odd naming conventions.
New: Intuitive naming following REST conventions.
4. Moved end-user ID parameter
4. Moved end-user ID parameter
Old: Required as its own argument.
New: Required as a conductorEndUserId
parameter in the parameters object.
5. Renamed request parameters
5. Renamed request parameters
All request parameters are now in camelCase and have been renamed for clarity and consistency. Most of the changes are straightforward that you can find using autocomplete in your IDE or checking the APIs in the sidebar.
Old: Odd naming conventions.
New: camelCase and clearer naming.
6. Renamed response fields
6. Renamed response fields
All output fields are now in camelCase and have been renamed for clarity and consistency. Most of the changes are straightforward that you can find using autocomplete in your IDE or checking the APIs in the sidebar.
Here are some key renamed fields:
TxnID
andListID
→id
TimeCreated
andTimeModified
→createdAt
andupdatedAt
EditSequence
→revisionNumber
*Ref
fields (e.g.,CustomerRef
) → simplified (e.g.,customer
)
Old: Odd naming conventions.
New: camelCase and clearer naming.
7. Restructured query/list request parameters
7. Restructured query/list request parameters
Old: Odd naming conventions and complex structure.
New: Significantly simplified structure and clearer naming.
8. Restructured query/list responses
8. Restructured query/list responses
To support automatic pagination, the query/list method now returns results in an object wrapper with properties for pagination metadata.
Old: Returns an array of results directly.
New: Returns results in an object wrapper with properties for pagination metadata.
9. Consistent array responses
9. Consistent array responses
Fields that can have multiple values are now always arrays, even when there’s only one record:
New features
Automatic pagination
Automatic pagination
You can now easily paginate through all results. See the automatic pagination section of the README for more details.
Automatic retries with exponential backoff
Automatic retries with exponential backoff
Intelligently retries requests, but only those requests that can potentially succeed when retried (such as network errors).
New retrieve and delete methods
New retrieve and delete methods
All objects now have a retrieve
method and all transaction objects have a delete
method.
Complete field returns
Complete field returns
The new API now returns a consistent response structure with all possible fields, making it easier to work with the data. Fields that have no value are explicitly set to null
rather than being omitted, and empty array fields return []
instead of being excluded. This means you can reliably access any field without checking if it exists first, and array operations will work consistently without special handling for missing fields.
More information
For more detailed information about the new Node.js SDK, please check its GitHub repository.