This is a Singer tap that produces JSON-formatted data following the Singer spec.
This tap:
- Pulls raw data from HubSpot's REST API
- Extracts the following resources from HubSpot
- Outputs a schema that is relational database compatible for each resource
- Incrementally pulls data based on the input state
This tap requires a config.json
which specifies details regarding OAuth 2.0 authentication, a cutoff date for syncing historical data, and an optional flag which controls collection of anonymous usage metrics. See config.sample.json for an example. You may specify an API key instead of OAuth parameters for development purposes, as detailed below.
You can specify a maximum number of pages that are retrieved for each stream that is synchronized.
The fields available to be specified in the config file are specified here.
Field | Type | Default | Details |
---|---|---|---|
redirect_uri |
["string"] |
N/A |
|
refresh_token |
["string"] |
N/A |
Token that will be used to get a new access token. |
client_id |
["string"] |
N/A |
|
client_secret |
["string"] |
N/A |
|
start_date |
["string"] |
N/A |
|
disable_collection |
["string", "null"] |
false |
Include true in your config to disable Singer Usage Logging. |
Example of config.json:
{
"redirect_uri": "https://api.hubspot.com/",
"client_id": 123456789000,
"client_secret": "my_secret",
"refresh_token": "my_token",
"start_date": "2017-01-01T00:00:00Z",
"disable_collection": false
}
This format of config.json is reccomanded in a production environment, but for development purposes an API Key Authentication can be use instead of OAuth 2.0. More information below.
As an alternative to OAuth 2.0 authentication during development, you may specify an API key (HAPIKEY
) to authenticate with the HubSpot API. This should be used only for low-volume development work, as the HubSpot API Usage Guidelines specify that integrations should use OAuth for authentication.
To use an API key, include a hapikey
configuration variable in your config.json
and set it to the value of your HubSpot API key. Any OAuth authentication parameters in your config.json
will be ignored if this key is present!
To run rdb-comp-tap-hubspot
with the configuration file, use this command:
› rdb-com-tap-hubspot -c my-config.json
This is an adapted version of tap-hubspot (https://github.com/singer-io/tap-hubspot). All copyrights belong to Stitch. Copyright © 2017 Stitch