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

# Send New Attempt

> [!TIP]
>
> Grants the candidate a new attempt at a completed interview. The attempt is created under the same interview `id`, the candidate is moved back to **Invited**, and a fresh interview link is sent to them.
>
> A new attempt is only allowed once the interview (or the previous attempt) is completed and analysed. Use [Get Interview](https://docs.tidyhire.app/api-reference/endpoint/get-interview.md) to fetch the latest attempt's results.

> [!WARNING]
>
> This action is irreversible. The new attempt supersedes the previous one — earlier results are no longer accessible through the API.

```bash cURL theme={null} theme={"system"}
curl --request POST \
  --url https://api.tidyhire.app/api/public/v1/interview/64a1b2c3d4e5f6a7b8c9d0e3/send-new-attempt \
  --header 'x-tidyhire-api-key: <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "reason": "Technical Issues",
  "note_for_candidate": "We would like to offer you a new attempt at your convenience."
}'
```

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

url = "https://api.tidyhire.app/api/public/v1/interview/64a1b2c3d4e5f6a7b8c9d0e3/send-new-attempt"

headers = {
    "x-tidyhire-api-key": "<token>",
    "Content-Type": "application/json"
}

payload = {
    "reason": "Technical Issues",
    "note_for_candidate": "We would like to offer you a new attempt at your convenience."
}

response = requests.post(url, json=payload, headers=headers)
print(response.json())
```

```javascript JavaScript theme={null} theme={"system"}
fetch('https://api.tidyhire.app/api/public/v1/interview/64a1b2c3d4e5f6a7b8c9d0e3/send-new-attempt', {
  method: 'POST',
  headers: {
    'x-tidyhire-api-key': '<token>',
    'Content-Type': 'application/json',
  },
  body: JSON.stringify({
    reason: 'Technical Issues',
    note_for_candidate: 'We would like to offer you a new attempt at your convenience.',
  }),
})
  .then((response) => response.json())
  .then((data) => console.log(data))
  .catch((error) => console.error('Error:', error));
```

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

$url = 'https://api.tidyhire.app/api/public/v1/interview/64a1b2c3d4e5f6a7b8c9d0e3/send-new-attempt';

$data = [
    'reason' => 'Technical Issues',
    'note_for_candidate' => 'We would like to offer you a new attempt at your convenience.'
];

$ch = curl_init($url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_POST, true);
curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($data));
curl_setopt($ch, CURLOPT_HTTPHEADER, [
    'x-tidyhire-api-key: <token>',
    'Content-Type: application/json'
]);

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

echo $response;
?>
```

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

import (
    "bytes"
    "encoding/json"
    "fmt"
    "io"
    "net/http"
)

func main() {
    url := "https://api.tidyhire.app/api/public/v1/interview/64a1b2c3d4e5f6a7b8c9d0e3/send-new-attempt"

    payload := map[string]interface{}{
        "reason":         "Technical Issues",
        "note_for_candidate": "We would like to offer you a new attempt at your convenience.",
    }

    jsonData, _ := json.Marshal(payload)

    req, _ := http.NewRequest("POST", url, bytes.NewBuffer(jsonData))
    req.Header.Set("x-tidyhire-api-key", "<token>")
    req.Header.Set("Content-Type", "application/json")

    client := &http.Client{}
    resp, err := client.Do(req)
    if err != nil {
        fmt.Println("Error:", err)
        return
    }
    defer resp.Body.Close()

    body, _ := io.ReadAll(resp.Body)
    fmt.Println(string(body))
}
```

```java Java theme={null} theme={"system"}
import java.io.OutputStream;
import java.net.HttpURLConnection;
import java.net.URL;
import java.nio.charset.StandardCharsets;

public class RetakeInterview {
    public static void main(String[] args) {
        try {
            URL url = new URL("https://api.tidyhire.app/api/public/v1/interview/64a1b2c3d4e5f6a7b8c9d0e3/send-new-attempt");
            HttpURLConnection con = (HttpURLConnection) url.openConnection();

            con.setRequestMethod("POST");
            con.setRequestProperty("x-tidyhire-api-key", "<token>");
            con.setRequestProperty("Content-Type", "application/json");
            con.setDoOutput(true);

            String jsonInputString = "{\n" +
                "  \"reason\": \"Technical Issues\",\n" +
                "  \"note_for_candidate\": \"We would like to offer you a new attempt at your convenience.\"\n" +
                "}";

            try (OutputStream os = con.getOutputStream()) {
                byte[] input = jsonInputString.getBytes(StandardCharsets.UTF_8);
                os.write(input, 0, input.length);
            }

            int status = con.getResponseCode();
            System.out.println("Response Status: " + status);
        } catch (Exception e) {
            e.printStackTrace();
        }
    }
}
```

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

uri = URI('https://api.tidyhire.app/api/public/v1/interview/64a1b2c3d4e5f6a7b8c9d0e3/send-new-attempt')

http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true

request = Net::HTTP::Post.new(uri.path)
request['x-tidyhire-api-key'] = '<token>'
request['Content-Type'] = 'application/json'

request.body = {
  reason: 'Technical Issues',
  note_for_candidate: 'We would like to offer you a new attempt at your convenience.'
}.to_json

response = http.request(request)
puts response.body
```

```json Response theme={null} theme={"system"}
{
  "success": true,
  "message": "New attempt initiated",
  "data": {
    "interview_id": "64a1b2c3d4e5f6a7b8c9d0e3",
    "internal_id": "64a1b2c3d4e5f6a7b8c9d0e6",
    "retry_attempt": 1
  }
}
```

***

### Authorizations

**Authorizations** `string | header` *required*

API key of the form `<token>`, passed as the `x-tidyhire-api-key` header.

### Path Parameters

**interview\_id** `string` *required*

Interview ID returned by the Interview Invite API.

Example: `"64a1b2c3d4e5f6a7b8c9d0e3"`

### Body

**reason** `string` *required*

Reason for the new attempt. Max 500 characters. Matches the dashboard reasons: `Technical Issues`, `Candidate Requested`, `Recruiter Requested`, `Other`. Used for audit and reporting.

Example: `"Technical Issues"`

**note\_for\_candidate** `string` *required*

Note included in the new attempt email. Max 1000 characters.

Example: `"We would like to offer you a new attempt at your convenience."`

### Response

New attempt initiated

**success** `boolean`

Indicates if the request was successful. Example: `true`

**message** `string`

Example: `"New attempt initiated"`

**data** `object`

**child attributes**

**data.interview\_id** `string`

Interview ID. Same as before the new attempt.

**data.internal\_id** `string`

Internal interview ID of the new attempt.

**data.retry\_attempt** `number`

Attempt number (`1` = first new attempt).

***

## Common Errors

> [tab] 401 Unauthorized
>
> **Reason:** Missing or invalid `x-tidyhire-api-key` header.
>
> ```json theme={"system"}
> {
>   "success": false,
>   "message": "Unauthorized, Please reach out at support@tidyhire.app"
> }
> ```

> [tab] 404 Not Found
>
> **Reason:** No interview with this ID exists in your workspace.
>
> ```json theme={"system"}
> {
>   "success": false,
>   "message": "Interview not found"
> }
> ```

> [tab] 409 Conflict
>
> **Reason:** The interview is not completed yet, or a new attempt was already sent and the candidate has not completed it.
>
> ```json theme={"system"}
> {
>   "success": false,
>   "message": "A new attempt is only allowed after the interview is completed."
> }
> ```
>
> ```json theme={"system"}
> {
>   "success": false,
>   "message": "A new attempt is already in progress. The candidate needs to complete it first."
> }
> ```

> [tab] 422 Validation Error
>
> **Reason:** Missing or invalid fields — each entry in `errors` points to a specific field.
>
> ```json theme={"system"}
> {
>   "success": false,
>   "message": "Validation error: Reason is required",
>   "errors": [
>     { "path": "reason", "message": "Reason is required" }
>   ]
> }
> ```


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