Skip to content

chrisradek/analytics-node-http-client

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

This repo illustrates how to pass a custom HTTP client to @segment/analytics-node.

There are currently 2 examples using different 3rd party http clients:

To run the axios sample, run:

WRITE_KEY=YOUR_WRITE_KEY node axios-example.js

Note: The axios library does not conform to the fetch spec. Importantly, the request does not accept body, so we need to alias body to data.

To run the node-fetch sample, run:

WRITE_KEY=YOUR_WRITE_KEY node node-fetch-example.js

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published