Getting Started
If you don't have an API key yet, see the API Keys & Authentication section first.
Construct an API call
The Data API endpoints are:
Environment | API endpoint |
---|---|
Production/Live | https://data-api.witcontests.com |
A basic, authorized API call using curl looks like this:
curl https://data-api.witcontests.com/activations/list \
-H 'Authorization: Api-Key <API KEY>'
All API calls, successful or not, will return a JSON response.
Error handling
Error responses (4xx/5xx status code) will contain a JSON "error" key with detailed information about what went wrong:
{ "error": "The resource could not be found." }
Rate limit exceeded
When the rate limit is exceeded, you'll receive the following 429 response until the limiting period is over:
{ "error": "Rate limit exceeded, try again in 60 seconds" }
Listing your activations
To get a list of all activations you've run or will run on Wit, use
the GET /activations/list
call. It supports a
number of filtering options to help find the activations you're looking for.
To get participant entry data for an activation, you will need to retrieve the specific activation separately.
Getting a specific activation and its entries
To get a specific activation by its ID (which can be found using the list call
above), use the GET /activation/:id
call.
To get the most recently-started activation, a convenience call named
GET /activations/latest
exists. This call
has the same response format as the ID call above, but it always returns data
for the activation that launched most recently by start date, as of the time
you make this API call.
Getting experience participants
To get a list of all participants, a convenience call named
GET /experience/participants
exists.
It supports a number of filtering options to help find the participants you're looking for.
This call is a premium data feature that can be used to list all of your participants across every activation.
Contact your WIT representative for more information on unlocking this feature along with other premium data capabilities.