1.0.3 • Published 1 month ago

@laboratoria/hubspot v1.0.3

Weekly downloads
-
License
MIT
Repository
-
Last release
1 month ago

Unofficial Hubspot Node.js client

Node.js CI

:warning: This tool is still in draft stage and is likely to change without notice.

Installation

npm i --save @laboratoria/hubspot

Usage

import { createClient as createHubSpotClient } from '@laboratoria/hubspot';

const hubspot = createHubSpotClient('<YOUR-HUBSPOT-PRIVATE-APP-TOKEN>');
const resultsStream = hubspot.deals.search({
  limit: 10,
  sorts: [{
    propertyName: 'hs_lastmodifieddate',
    direction: 'DESCENDING',
  }],
  properties: ['dealname', 'industria'],
  filterGroups: [{
    filters: [{
      value: '1546080',
      propertyName: 'pipeline',
      operator: 'EQ',
    }],
  }],
});

resultsStream.on('error', (err) => {
  // ...
});

resultsStream.on('data', (results) => {
  // ...
});

resultsStream.on('end', () => {
  // ...
});
hubspot.deals.getAll()
  .on('error', (error) => {
    console.error(error);
  })
  .on('data', (deals) => {
    console.log(deals);
  })
  .on('end', () => {
    console.log('ended!');
  });
1.0.3

1 month ago

1.0.2

9 months ago

1.0.1

10 months ago

1.0.0

1 year ago

0.7.1

2 years ago

0.5.0

2 years ago

0.7.0

2 years ago

0.6.0

2 years ago

0.4.0

2 years ago

0.3.0

2 years ago

0.2.0

2 years ago