Skip to content

Import functionality is broken #106

@antulik

Description

@antulik

In short: import method succeeds but no data is stored.

Longer version

tracker.import('SECRET", '123', "Event", {"time" => 1517048470 })

This returns success result, but the event is not created in mixpanel.

Curl also does not work if api_key is passed as a param. For example

curl https://api.mixpanel.com/import \
-d data=abc \
-d verbose=1 \
-d api_key=123

The documentation uses curl example with basic authentication and it works like that: https://mixpanel.com/help/reference/importing-old-events

curl https://api.mixpanel.com/import \
-u YOUR_API_SECRET: \
-d data=eyJldmVudCI6ICIkc2lnbnVwIiwgInByb3BlcnRpZXMiOiB7ImRpc3RpbmN0X2lkIjogIjQ4MSIsICJ0aW1lIjogMTMyMTQ5OTM3MSwgInRva2VuIjogIjEzZmUzZGRjODZlYjZmOTBjNGVlN2QwZDQ3NTYzMTUwIn19 \
-d verbose=1

So my assumption that api_key param is ignored and basic authentication should be used instead

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions