Raw Data Export Problem

Hi
I am attempting to create a new Raw Data Export request. However, after executing the command line below

curl --user {UNITY_PROJECT_ID}:{API_KEY}
–request POST
–header “Content-Type: application/json”
–data ‘{
“startDate” : {START_DATE}, "endDate" : {END_DATE},
“format” : {FORMAT}, "dataset" : {DATASET}
}’

It keep return {“error”:“400 Bad Request”}. I am sure my upid and api key are correct, and I have already try all different combination in data section.
Really need help
Thank you

Are you replacing the environment variables with yours? The API key can be found on the Raw Data Export page.

The startDate and endDate is in yyyy-MM-dd format.

Format is either json or tsv.

1 Like

Ok i already find out the problem
First, endDate can not set surpass today.
Second, dataset can not set to your customer event name, but “custom”

1 Like

Correct…the first is probably a bug on our end. We should gracefully accept future dates and truncate. The second is a matter of language: we think of events as “custom”, “appStart”, “deviceInfo”, etc, which are the top-level event types. In a future iteration, we may add the ability to query on specific custom event names, but not yet.

Thanks for using the feature. Hope it’s helpful!

1 Like