Skip to content
This repository was archived by the owner on Jul 15, 2024. It is now read-only.

Commit 889aa74

Browse files
authored
Merge pull request #23 from ultizet/PLUGIN-1039
Enable authorization via an access token
2 parents 6c4295f + 0490069 commit 889aa74

23 files changed

Lines changed: 741 additions & 478 deletions

docs/Hubspot-batchsink.md

Lines changed: 13 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,23 @@
1-
# Hubspot Batch Bink
2-
1+
# Hubspot Batch Sink
32
Description
43
-----------
5-
The plugin allows users to put data to HubSpot CRM.
4+
A batch sink that inserts objects into Hubspot.
5+
6+
### Authorization
7+
8+
**Authorization method:** Select either Hubspot account API Key or Private App Access Token option.
9+
10+
**API Key:** Hubspot account API Key (Deprecated. See this [guide](https://developers.hubspot.com/docs/api/migrate-an-api-key-integration-to-a-private-app) for migrating to using a Private App Access Token).
11+
12+
**Private App Access Token:** The app should be allowed to write the respective type (selected below) of Hubspot objects.
613

7-
Properties
8-
----------
9-
### Basic
14+
### Properties
1015

1116
**Reference Name:** Name used to uniquely identify this source for lineage, annotating metadata, etc.
1217

13-
**API Key:** OAuth2 API Key.
18+
**Object type:** The type of Hubspot objects to be inserted.
1419

15-
**Object(s) to pull:** Name of Object(s) to put to Hubspot. Select from Contact Lists, Contacts, Companies, Deals, Deal Pipelines, Marketing Email, Products, Tickets
16-
Object json format according documentation
20+
The currently available options are below (follow the links for Hubspot documentation):
1721
[Contact Lists](https://developers.hubspot.com/docs/methods/lists/create_list)
1822
[Contacts](https://developers.hubspot.com/docs/methods/contacts/create_contact)
1923
[Companies](https://developers.hubspot.com/docs/methods/companies/create_company)

docs/Hubspot-batchsource.md

Lines changed: 72 additions & 44 deletions
Original file line numberDiff line numberDiff line change
@@ -1,58 +1,86 @@
11
# Hubspot Batch Source
2-
32
Description
43
-----------
5-
The plugin allows users to pull data from HubSpot CRM.
4+
This source reads data from HubSpot CRM in batches.
65

76
Properties
87
----------
9-
### Basic
10-
11-
**Reference Name:** Name used to uniquely identify this source for lineage, annotating metadata, etc.
12-
13-
**API Key:** OAuth2 API Key.
8+
### Authorization
149

15-
**Object to pull:** Name of object to pull from Hubspot. Select from Contact Lists, Contacts, Email Events,
16-
Email Subscription, Recent Companies, Analytics, Companies, Deals, Deal Pipelines, Marketing Email, Products, Tickets.
10+
**Authorization method:** Select either Hubspot account API Key or Private App Access Token option.
1711

18-
### Analytics
12+
**API Key:** Hubspot account API Key (Deprecated. See this [guide](https://developers.hubspot.com/docs/api/migrate-an-api-key-integration-to-a-private-app) for migrating to using a Private App Access Token.)
1913

20-
**Time Period:** Time period used to group the data. See [reference documentation](https://developers.hubspot.com/docs/methods/analytics/get-analytics-data-breakdowns). Must be one of:
21-
* total - Data is rolled up to totals covering the specified time.
22-
* daily - Grouped by day.
23-
* weekly - Grouped by week.
24-
* monthly - Grouped by month.
25-
* summarize/daily - Grouped by day, data is rolled up across all breakdowns.
26-
* summarize/weekly - Grouped by week, data is rolled up across all breakdowns.
27-
* summarize/monthly - Grouped by month, data is rolled up across all breakdowns.
28-
29-
NOTE: When using daily, weekly, or monthly for the Time Period, you must include at least one filter
30-
31-
**Report Type:** Analytics report target to get data for.
14+
**Private App Access Token:** The app should be allowed to read the respective type (selected below) of Hubspot objects.
3215

33-
**Report Content:** Analytics report type of content that you want to get data for. See [reference documentation](https://developers.hubspot.com/docs/methods/analytics/get-data-for-hubspot-content). Must be one of:
34-
* landing-pages - Pull data for landing pages.
35-
* standard-pages - Pull data for website pages.
36-
* blog-posts - Pull data for individual blog posts.
37-
* listing-pages - Pull data for blog listing pages.
38-
* knowledge-articles - Pull data for knowledge base articles.
16+
### Common properties
3917

18+
**Reference Name:** Name used to uniquely identify this source for lineage, annotating metadata, etc.
4019

41-
**Report Category:** Analytics report category used to break down the analytics data. See [reference documentation](https://developers.hubspot.com/docs/methods/analytics/get-analytics-data-breakdowns). Must be one of:
42-
* totals - Data will be the totals rolled up from.
43-
* sessions - Data broken down by session details.
44-
* sources - Data broken down by traffic source.
45-
* geolocation - Data broken down by geographic location.
46-
* utm-:utm_type - Data broken down by the standard UTM parameters. :utm_type must be one of campaigns, contents, mediums, sources, or terms (i.e. utm-campaigns).
47-
48-
**Report Type of object:** Analytics report type of object that you want the analytics data for. See [reference documentation](https://developers.hubspot.com/docs/methods/analytics/get-analytics-data-by-object). Must be one of:
49-
* event-completions - Get data for analytics events. The results are broken down by the event ID. You can get the details for the events using this endpoint.
50-
* forms - Get data for your HubSpot forms. The results are broken down by form guids. You can get the details for the forms through the Forms API.
51-
* pages - Get data for all URLs with data collected by HubSpot tracking code. The results are broken down by URL.
52-
* social-assists - Get data for messages published through the social publishing tools. The results are broken down by the broadcastGuid of the messages. You can get the details of those messages through the Social Media API.
53-
54-
**Start Date:** Start date for the report data. YYYYMMDD format.
55-
56-
**End Date:** End date for the report data. YYYYMMDD format.
20+
**Object type:** Type of the objects to pull from Hubspot.
21+
22+
Should be one of (follow the links for Hubspot documentation):
23+
- [Analytics](https://legacydocs.hubspot.com/docs/methods/analytics/analytics-overview)
24+
- [Contact Lists](https://developers.hubspot.com/docs/methods/lists/create_list)
25+
- [Contacts](https://developers.hubspot.com/docs/api/crm/contacts)
26+
- [Companies](https://developers.hubspot.com/docs/api/crm/companies)
27+
- [Deals](https://developers.hubspot.com/docs/api/crm/deals)
28+
- [Deal Pipelines](https://developers.hubspot.com/docs/api/crm/pipelines)
29+
- [Email events](https://legacydocs.hubspot.com/docs/methods/email/email_events_overview)
30+
- [Email Subscription](https://legacydocs.hubspot.com/docs/methods/email/email_subscriptions_overview)
31+
- [Marketing Email](https://legacydocs.hubspot.com/docs/methods/lists/marketing-email-overview)
32+
- [Products](https://developers.hubspot.com/docs/api/crm/products)
33+
- [Recently Modified Companies](https://legacydocs.hubspot.com/docs/methods/companies/get_companies_modified)
34+
- [Tickets](https://developers.hubspot.com/docs/api/crm/tickets)
35+
36+
### Analytics properties
37+
38+
**Time Period:** Time period used to group the data
39+
(to get examples and more details [documentation](https://developers.hubspot.com/docs/methods/analytics/get-analytics-data-breakdowns)).
40+
Must be one of:
41+
- total - Data is rolled up to totals covering the specified time.
42+
- daily - Grouped by day.
43+
- weekly - Grouped by week.
44+
- monthly - Grouped by month.
45+
- summarize/daily - Grouped by day, data is rolled up across all breakdowns.
46+
- summarize/weekly - Grouped by week, data is rolled up across all breakdowns.
47+
- summarize/monthly - Grouped by month, data is rolled up across all breakdowns.
48+
49+
NOTE: When using daily, weekly, or monthly as a Time Period, at least one filter must be present.
5750

5851
**Filters:** Keywords to filter the analytics report data to include only the specified breakdowns.
52+
53+
**Report Type:** Analytics report target to get data for.
54+
Must be one of (see below the details for each option):
55+
- Content
56+
- Category
57+
- Object
58+
59+
**Report Content:** The type of content that you want to get data for
60+
(to get examples and more details see [documentation](https://legacydocs.hubspot.com/docs/methods/analytics/get-data-for-hubspot-content))
61+
Must be one of:
62+
- landing-pages - Pull data for landing pages.
63+
- standard-pages - Pull data for website pages.
64+
- blog-posts - Pull data for individual blog posts.
65+
- listing-pages - Pull data for blog listing pages.
66+
- knowledge-articles - Pull data for knowledge base articles.
67+
68+
69+
**Report Category:** Analytics report category used to break down the analytics data
70+
(to get examples and more details see [documentation](https://legacydocs.hubspot.com/docs/methods/analytics/get-analytics-data-breakdowns)). Must be one of:
71+
- totals - Data will be the totals rolled up from.
72+
- sessions - Data broken down by session details.
73+
- sources - Data broken down by traffic source.
74+
- geolocation - Data broken down by geographic location.
75+
- utm-:utm_type - Data broken down by the standard UTM parameters. :utm_type must be one of campaigns, contents, mediums, sources, or terms (i.e. utm-campaigns).
76+
77+
**Report Object:** Analytics report type of object that you want the analytics data for
78+
(to get examples and more details see [documentation](https://developers.hubspot.com/docs/methods/analytics/get-analytics-data-by-object)). Must be one of:
79+
- event-completions - Get data for analytics events. The results are broken down by the event ID. You can get the details for the events using this endpoint.
80+
- forms - Get data for your HubSpot forms. The results are broken down by form guids. You can get the details for the forms through the Forms API.
81+
- pages - Get data for all URLs with data collected by HubSpot tracking code. The results are broken down by URL.
82+
- social-assists - Get data for messages published through the social publishing tools. The results are broken down by the broadcastGuid of the messages. You can get the details of those messages through the Social Media API.
83+
84+
**Start Date:** A start date for the report data. YYYYMMDD format.
85+
86+
**End Date:** An end date for the report data. YYYYMMDD format.

docs/Hubspot-streamingsource.md

Lines changed: 75 additions & 45 deletions
Original file line numberDiff line numberDiff line change
@@ -1,61 +1,91 @@
1-
# Hubspot Batch Source
1+
# Hubspot Streaming Source
22

33
Description
44
-----------
5-
The plugin allows users to stream data from HubSpot CRM. After initial pull, which fetches
5+
The plugin allows users to stream data from HubSpot CRM. After the initial pull, which fetches
66
all the data, updates will periodically be pulled.
77

88
Properties
99
----------
10-
### Basic
1110

12-
**Reference Name:** Name used to uniquely identify this source for lineage, annotating metadata, etc.
13-
14-
**API Key:** OAuth2 API Key.
15-
16-
**Object(s) to pull:** Names of Object(s) to pull from Hubspot. Select from Contact Lists, Contacts, Email Events,
17-
Email Subscription, Recent Companies, Analytics, Companies, Deals, Deal Pipelines, Marketing Email, Products, Tickets.
18-
19-
**Pull frequency:** Delay between polling of Hubspot API for updates.
20-
21-
### Analytics
22-
23-
**Time Period:** Time period used to group the data. See [reference documentation](https://developers.hubspot.com/docs/methods/analytics/get-analytics-data-breakdowns). Must be one of:
24-
* total - Data is rolled up to totals covering the specified time.
25-
* daily - Grouped by day.
26-
* weekly - Grouped by week.
27-
* monthly - Grouped by month.
28-
* summarize/daily - Grouped by day, data is rolled up across all breakdowns.
29-
* summarize/weekly - Grouped by week, data is rolled up across all breakdowns.
30-
* summarize/monthly - Grouped by month, data is rolled up across all breakdowns.
11+
### Authorization
3112

32-
NOTE: When using daily, weekly, or monthly for the Time Period, you must include at least one filter
33-
34-
**Report Type:** Analytics report target to get data for.
35-
36-
**Report Content:** Analytics report type of content that you want to get data for. See [reference documentation](https://developers.hubspot.com/docs/methods/analytics/get-data-for-hubspot-content). Must be one of:
37-
* landing-pages - Pull data for landing pages.
38-
* standard-pages - Pull data for website pages.
39-
* blog-posts - Pull data for individual blog posts.
40-
* listing-pages - Pull data for blog listing pages.
41-
* knowledge-articles - Pull data for knowledge base articles.
13+
**Authorization method:** Select either Hubspot account API Key or Private App Access Token option.
4214

15+
**API Key:** Hubspot account API Key (Deprecated. See this [guide](https://developers.hubspot.com/docs/api/migrate-an-api-key-integration-to-a-private-app) for migrating to using a Private App Access Token.)
4316

44-
**Report Category:** Analytics report category used to break down the analytics data. See [reference documentation](https://developers.hubspot.com/docs/methods/analytics/get-analytics-data-breakdowns). Must be one of:
45-
* totals - Data will be the totals rolled up from.
46-
* sessions - Data broken down by session details.
47-
* sources - Data broken down by traffic source.
48-
* geolocation - Data broken down by geographic location.
49-
* utm-:utm_type - Data broken down by the standard UTM parameters. :utm_type must be one of campaigns, contents, mediums, sources, or terms (i.e. utm-campaigns).
17+
**Private App Access Token:** The app should be allowed to read the respective type (selected below) of Hubspot objects.
5018

51-
**Report Type of object:** Analytics report type of object that you want the analytics data for. See [reference documentation](https://developers.hubspot.com/docs/methods/analytics/get-analytics-data-by-object). Must be one of:
52-
* event-completions - Get data for analytics events. The results are broken down by the event ID. You can get the details for the events using this endpoint.
53-
* forms - Get data for your HubSpot forms. The results are broken down by form guids. You can get the details for the forms through the Forms API.
54-
* pages - Get data for all URLs with data collected by HubSpot tracking code. The results are broken down by URL.
55-
* social-assists - Get data for messages published through the social publishing tools. The results are broken down by the broadcastGuid of the messages. You can get the details of those messages through the Social Media API.
19+
### Common properties
5620

57-
**Start Date:** Start date for the report data. YYYYMMDD format.
21+
**Reference Name:** Name used to uniquely identify this source for lineage, annotating metadata, etc.
5822

59-
**End Date:** End date for the report data. YYYYMMDD format.
23+
**Object type:** Type of the objects to pull from Hubspot.
24+
25+
Should be one of (follow the links for Hubspot documentation):
26+
- [Analytics](https://legacydocs.hubspot.com/docs/methods/analytics/analytics-overview)
27+
- [Contact Lists](https://developers.hubspot.com/docs/methods/lists/create_list)
28+
- [Contacts](https://developers.hubspot.com/docs/api/crm/contacts)
29+
- [Companies](https://developers.hubspot.com/docs/api/crm/companies)
30+
- [Deals](https://developers.hubspot.com/docs/api/crm/deals)
31+
- [Deal Pipelines](https://developers.hubspot.com/docs/api/crm/pipelines)
32+
- [Email events](https://legacydocs.hubspot.com/docs/methods/email/email_events_overview)
33+
- [Email Subscription](https://legacydocs.hubspot.com/docs/methods/email/email_subscriptions_overview)
34+
- [Marketing Email](https://legacydocs.hubspot.com/docs/methods/lists/marketing-email-overview)
35+
- [Products](https://developers.hubspot.com/docs/api/crm/products)
36+
- [Recently Modified Companies](https://legacydocs.hubspot.com/docs/methods/companies/get_companies_modified)
37+
- [Tickets](https://developers.hubspot.com/docs/api/crm/tickets)
38+
39+
**Pull frequency:** Delay interval in between Hubspot API polling for updates.
40+
41+
### Analytics properties
42+
43+
**Time Period:** Time period used to group the data
44+
(to get examples and more details [documentation](https://developers.hubspot.com/docs/methods/analytics/get-analytics-data-breakdowns)).
45+
Must be one of:
46+
- total - Data is rolled up to totals covering the specified time.
47+
- daily - Grouped by day.
48+
- weekly - Grouped by week.
49+
- monthly - Grouped by month.
50+
- summarize/daily - Grouped by day, data is rolled up across all breakdowns.
51+
- summarize/weekly - Grouped by week, data is rolled up across all breakdowns.
52+
- summarize/monthly - Grouped by month, data is rolled up across all breakdowns.
53+
54+
NOTE: When using daily, weekly, or monthly as a Time Period, at least one filter must be present.
6055

6156
**Filters:** Keywords to filter the analytics report data to include only the specified breakdowns.
57+
58+
**Report Type:** Analytics report target to get data for.
59+
Must be one of (see below the details for each option):
60+
- Content
61+
- Category
62+
- Object
63+
64+
**Report Content:** The type of content that you want to get data for
65+
(to get examples and more details see [documentation](https://legacydocs.hubspot.com/docs/methods/analytics/get-data-for-hubspot-content))
66+
Must be one of:
67+
- landing-pages - Pull data for landing pages.
68+
- standard-pages - Pull data for website pages.
69+
- blog-posts - Pull data for individual blog posts.
70+
- listing-pages - Pull data for blog listing pages.
71+
- knowledge-articles - Pull data for knowledge base articles.
72+
73+
74+
**Report Category:** Analytics report category used to break down the analytics data
75+
(to get examples and more details see [documentation](https://legacydocs.hubspot.com/docs/methods/analytics/get-analytics-data-breakdowns)). Must be one of:
76+
- totals - Data will be the totals rolled up from.
77+
- sessions - Data broken down by session details.
78+
- sources - Data broken down by traffic source.
79+
- geolocation - Data broken down by geographic location.
80+
- utm-:utm_type - Data broken down by the standard UTM parameters. :utm_type must be one of campaigns, contents, mediums, sources, or terms (i.e. utm-campaigns).
81+
82+
**Report Object:** Analytics report type of object that you want the analytics data for
83+
(to get examples and more details see [documentation](https://developers.hubspot.com/docs/methods/analytics/get-analytics-data-by-object)). Must be one of:
84+
- event-completions - Get data for analytics events. The results are broken down by the event ID. You can get the details for the events using this endpoint.
85+
- forms - Get data for your HubSpot forms. The results are broken down by form guids. You can get the details for the forms through the Forms API.
86+
- pages - Get data for all URLs with data collected by HubSpot tracking code. The results are broken down by URL.
87+
- social-assists - Get data for messages published through the social publishing tools. The results are broken down by the broadcastGuid of the messages. You can get the details of those messages through the Social Media API.
88+
89+
**Start Date:** A start date for the report data. YYYYMMDD format.
90+
91+
**End Date:** An end date for the report data. YYYYMMDD format.

0 commit comments

Comments
 (0)