1. Get Your API Key

Go to this page and click the New API Key button. Copy and save the key to a secure place.

2. Create a Dataset

Before you can start your job, you need to create a dataset. You can do that with the Upsert Dataset endpoint. Because you are creating a new dataset, be sure to pass id_column and name in the request body.

Make sure to take note of the dataset_id in the response as you'll need it for starting a job with the API. You can always get the dataset_id by using the Get Datasets endpoint.

3. Start a Categorize Job

Once your dataset has been created, it’s time to kick off a categorize job. You can do that with the Start Categorize Job endpoint. Because you are creating a new categorize job, be sure to pass in the dataset_id, name, and categories parameters in the body.

Since categorizing can take a while, the system will return a response that contains the job_id, which you can then use to poll for the status of the job with the Get Categorize Job Status endpoint. Alternatively you can pass in a callback_url to the Start Categorize Job request and the system will POST a request there once it is complete.

4. Retrieving Your Categorizations

Once a categorize job is complete, you can call the Get All Categories endpoint with the job_id from the previous step.

When retrieving results with the api, the response will be paginated. Here's an example of how you can handle that in python to retrieve all of the results:

import requests

page = 1
data = []
while page is not None:
    response = requests.get(
        f"https://app.getaugerdata.com/api/v1/{job_type}/all/{job_id}?page={page}",
        headers={"Authorization": "Bearer xxxxx"},
    )
    response.raise_for_status()
    response = response.json()
    page += 1
    data.extend(response['results'])
    if page > response['pagination']['total_pages']:
        page = None