# Getting job status

### Endpoint

```url
GET https://api.socialdata.tools/jobs/[job_id]
```

### Endpoint parameters

| Name                                          | Description                                                                | Example |
| --------------------------------------------- | -------------------------------------------------------------------------- | ------- |
| <p>job\_id<br><strong>(Required)</strong></p> | A numeric ID of a job you created earlier using one of the async endpoints | 42      |

### Response codes

* **HTTP 200 OK -** succeeded
* **HTTP 403 Forbidden** - requested job belongs to another user
* **HTTP 404 Not Found** - requested job does not exist
* **HTTP 500** **Internal Server Error** - other error (highly unlikely)

### Example request

```bash
curl "https://api.socialdata.tools/jobs/42
-H 'Authorization: Bearer API_KEY'
-H 'Accept: application/json'
```

### Example response

```json
// Job pending, processing not started yet: 
{
    "job_id": 42,
    "status": "pending"
}

// Job still being processed: 
{
    "job_id": 42,
    "status": "processing"
}


// Job finished successfully: 
{
    "job_id": 42,
    "status": "success",
    "result": {
        "datafile_url": "https://s3.amazonaws.com/..."    
    }
}

// Job failed: 
{
    "job_id": 42,
    "status": "error"
    "message": "Insufficient balance"
}


```
