- Update dependencies
- Breaking: Drop support for Node 10.x. It may still work, but development tooling requires Node 12
- Update dependencies
- Fix
export
method to return a stream - Fix export options to convert Date objects to Amplitude string format of YYYYMMDDTHH
- Security update for
axios
- Update all dev dependencies
- Security update for
lodash
- Security update for
y18n
- Update
axios
to latest to fix the issue of missingProgressEvent
when using Typescript
- Update
axios
andnode-fetch
- Add LICENSE file
- Update devDependencies
- Use
unknown
in place ofobject | string
As of 2020-05-30, Amplitude reported issues with their SSL certificate, so they set up an endpoint and alternate endpoint at https://api2.amplitude.com
. Read about it on Amplitude's Status Page and affected devices here.
- Add option to set token endpoint via an environment variable, i.e.
AMPLITUDE_TOKEN_ENDPOINT="https://api2.amplitude.com"
- Add option to set token endpoint via constructor options, i.e.
https://api2.amplitude.com
- Convert to typescript (this shouldn't break anything as it's being exported just like before)
- Implement the Amplitude HTTP V2 API
IMPORTANT: There aren't any breaking changes in the code, but the Amplitude V2 API has a few stricter validations server side. For example, in one project where I was using this, I was passing a timestamp generated from Swift, so it was a float. However, the time param only allows type of long
, i.e. integer
.
From Amplitude's docs:
- Validation on Content-type header (must be set to application/json)
- Validation on proper JSON request body
- Validation on event_type name (cannot be event names that are reserved for Amplitude use)
- Validation on device_id length (must be 5 or more characters unless overrided with min_id_length)
- Validation on user_id length (must be 5 or more characters unless overrided with min_id_length)
- Validation on time field in event payload (must be number of milliseconds since the start of epoch time)
- Update README
- Changes maintainer
See the releases from the original repo: crookedneighbor/amplitude