airflow.providers.segment.hooks.segment
¶
Connect to your Segment account, retrieve data from it or write to that file.
- NOTE: this hook also relies on the Segment analytics package:
Module Contents¶
Classes¶
Create new connection to Segment and allows you to pull data out of Segment or write to it. |
- class airflow.providers.segment.hooks.segment.SegmentHook(segment_conn_id='segment_default', segment_debug_mode=False, *args, **kwargs)[source]¶
Bases:
airflow.hooks.base.BaseHook
Create new connection to Segment and allows you to pull data out of Segment or write to it.
You can then use that file with other Airflow operators to move the data around or interact with segment.
- Parameters
Note
You must include a JSON structure in the Extras field. We need a user’s security token to connect to Segment. So we define it in the Extras field as: {“write_key”:”YOUR_SECURITY_TOKEN”}