> ## Documentation Index
> Fetch the complete documentation index at: https://docs.mygigsters.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Initiate police check

> This endpoint initiates a new national police check application. It registers the applicant's basic details and returns a unique check ID along with a continuation URL where the applicant can complete the process.

### Headers

**X-API-Version** `string` *required* (default: 1.2)

The API version to use. Supported versions are `1.1` and `1.2`.

### Request Body Parameters

**first\_name** `string` *required*

The first name of the applicant.

**last\_name** `string` *required*

The last name of the applicant.

**email** `string` *required*

The email address of the applicant.

**type** `string` *required*

The type of check (e.g. "EMPLOYMENT").

**reason** `string` *required*

The reason for the police check (e.g. "Driver").

### Response Body

| Field | Type | Description |
| - | - | - |
| `message` | string | A message describing the response status (e.g. "Verification Created, please follow the link to continue"). |
| `data`object | object | The created police check details. |
| ↳`id` | number | The unique identifier for the created police check. |
| ↳`continueUrl` | string | URL for the applicant to continue or resume the police check process. |

### Response Codes

| Code | Description |
| - | - |
| 200 | The police check was successfully initiated. |
| 400 | Bad Request. Missing or invalid required fields. |
| 401 | Unauthorized. Missing or invalid credentials. |
| 500 | Internal Server Error. |

```bash cURL theme={null}
curl -X POST https://qa-payments.mygigsters.com.au/api/v1/create/police-check \
  -u "YOUR_UUID:YOUR_SECRET" \
  -H "X-API-Version: 1.2" \
  -H "Content-Type: application/json" \
  -d '{
  "first_name": "John",
  "last_name": "Smith",
  "email": "john.smith@example.com",
  "type": "EMPLOYMENT",
  "reason": "Driver"
}'
```

```javascript Node.js theme={null}
const response = await fetch("https://qa-payments.mygigsters.com.au/api/v1/create/police-check", {
  method: "POST",
  headers: {
    Authorization: "Basic " + Buffer.from("YOUR_UUID:YOUR_SECRET").toString("base64"),
    "X-API-Version": "1.2",
    "Content-Type": "application/json",
  },
  body: JSON.stringify({
    "first_name": "John",
    "last_name": "Smith",
    "email": "john.smith@example.com",
    "type": "EMPLOYMENT",
    "reason": "Driver"
  }),
});

const data = await response.json();
console.log(data);
```

```python Python theme={null}
import requests

response = requests.post(
    "https://qa-payments.mygigsters.com.au/api/v1/create/police-check",
    auth=("YOUR_UUID", "YOUR_SECRET"),
    headers={
        "X-API-Version": "1.2",
    },
    json={
        "first_name": "John",
        "last_name": "Smith",
        "email": "john.smith@example.com",
        "type": "EMPLOYMENT",
        "reason": "Driver",
    },
)

print(response.json())
```

```ruby Ruby theme={null}
require "net/http"
require "json"
require "uri"

uri = URI("https://qa-payments.mygigsters.com.au/api/v1/create/police-check")
request = Net::HTTP::Post.new(uri)
request.basic_auth("YOUR_UUID", "YOUR_SECRET")
request["X-API-Version"] = "1.2"
request["Content-Type"] = "application/json"
request.body = <<~JSON
  {
    "first_name": "John",
    "last_name": "Smith",
    "email": "john.smith@example.com",
    "type": "EMPLOYMENT",
    "reason": "Driver"
  }
JSON

response = Net::HTTP.start(uri.hostname, uri.port, use_ssl: true) do |http|
  http.request(request)
end

puts JSON.parse(response.body)
```

```php PHP theme={null}
<?php

$ch = curl_init("https://qa-payments.mygigsters.com.au/api/v1/create/police-check");

curl_setopt_array($ch, [
    CURLOPT_RETURNTRANSFER => true,
    CURLOPT_CUSTOMREQUEST => "POST",
    CURLOPT_USERPWD => "YOUR_UUID:YOUR_SECRET",
    CURLOPT_HTTPHEADER => [
        "X-API-Version: 1.2",
        "Content-Type: application/json",
    ],
    CURLOPT_POSTFIELDS => <<<'JSON'
{
  "first_name": "John",
  "last_name": "Smith",
  "email": "john.smith@example.com",
  "type": "EMPLOYMENT",
  "reason": "Driver"
}
JSON,
]);

$response = curl_exec($ch);
curl_close($ch);

print_r(json_decode($response, true));
```

```java Java theme={null}
import java.net.URI;
import java.net.http.HttpClient;
import java.net.http.HttpRequest;
import java.net.http.HttpResponse;
import java.util.Base64;

public class Example {
    public static void main(String[] args) throws Exception {
        String credentials = Base64.getEncoder()
            .encodeToString("YOUR_UUID:YOUR_SECRET".getBytes());

        String body = String.join("\n",
            "{",
            "  \"first_name\": \"John\",",
            "  \"last_name\": \"Smith\",",
            "  \"email\": \"john.smith@example.com\",",
            "  \"type\": \"EMPLOYMENT\",",
            "  \"reason\": \"Driver\"",
            "}"
        );

        HttpRequest request = HttpRequest.newBuilder()
            .uri(URI.create("https://qa-payments.mygigsters.com.au/api/v1/create/police-check"))
            .header("Authorization", "Basic " + credentials)
            .header("X-API-Version", "1.2")
            .header("Content-Type", "application/json")
            .method("POST", HttpRequest.BodyPublishers.ofString(body))
            .build();

        HttpResponse<String> response = HttpClient.newHttpClient()
            .send(request, HttpResponse.BodyHandlers.ofString());

        System.out.println(response.body());
    }
}
```

```go Go theme={null}
package main

import (
	"fmt"
	"io"
	"net/http"
	"strings"
)

func main() {
	body := strings.NewReader(`{
  "first_name": "John",
  "last_name": "Smith",
  "email": "john.smith@example.com",
  "type": "EMPLOYMENT",
  "reason": "Driver"
}`)

	req, err := http.NewRequest("POST", "https://qa-payments.mygigsters.com.au/api/v1/create/police-check", body)
	if err != nil {
		panic(err)
	}
	req.SetBasicAuth("YOUR_UUID", "YOUR_SECRET")
	req.Header.Set("X-API-Version", "1.2")
	req.Header.Set("Content-Type", "application/json")

	res, err := http.DefaultClient.Do(req)
	if err != nil {
		panic(err)
	}
	defer res.Body.Close()

	data, _ := io.ReadAll(res.Body)
	fmt.Println(string(data))
}
```

```csharp .NET theme={null}
using System.Net.Http.Headers;
using System.Text;

using var client = new HttpClient();

var request = new HttpRequestMessage(HttpMethod.Post, "https://qa-payments.mygigsters.com.au/api/v1/create/police-check");
request.Headers.Authorization = new AuthenticationHeaderValue(
    "Basic", Convert.ToBase64String(Encoding.UTF8.GetBytes("YOUR_UUID:YOUR_SECRET")));
request.Headers.Add("X-API-Version", "1.2");
request.Content = new StringContent(@"{
  ""first_name"": ""John"",
  ""last_name"": ""Smith"",
  ""email"": ""john.smith@example.com"",
  ""type"": ""EMPLOYMENT"",
  ""reason"": ""Driver""
}", Encoding.UTF8, "application/json");

var response = await client.SendAsync(request);
Console.WriteLine(await response.Content.ReadAsStringAsync());
```

```json Response theme={null}
{
  "message": "Verification Created, please follow the link to continue",
  "data": {
    "id": 14005580,
    "continueUrl": "https://app.nationalcrimecheck.com.au/api-test/fake-start-link/14005580/WTTPBZXP"
  }
}
```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.