# Get Policy Compliance For Job

Launch stage: GA

`GET /api/2.0/policies/jobs/get-compliance`

Returns the policy compliance status of a job. Jobs could be out of
 compliance if a cluster policy they use was updated after the job was
 last edited and some of its job clusters no longer comply with
 their updated policies.

API scopes: jobs

## Query parameters

- `job_id` (int64, optional)
  The ID of the job whose compliance status you are requesting.

## Returns

- `is_compliant` (boolean, optional)
  Whether the job is compliant with its policies or not. Jobs could be out of
   compliance if a policy they are using was updated after the job was
   last edited and some of its job clusters no longer comply with
   their updated policies.
- `violations` (object, optional)
  An object containing key-value mappings representing the first 200 policy
   validation errors.
   The keys indicate the path where the policy validation error is occurring.
   An identifier for the job cluster is prepended to the path.
   The values indicate an error message describing the policy validation error.

## Response

```json
{
  "is_compliant": true,
  "violations": {
    "job_clusters[job_cluster_key].new_cluster.custom_tags.test_tag": "Validation failed for custom_tags.test_tag, the value cannot be present"
  }
}
```

