# Update branch status check

```http
PUT /projects/{project_reference}/branches/{branch_id}/status-checks/{check_name}
```

Create or replace one named status check on a branch. Requires project.files.write.

## Parameters

| Name                | In   | Required | Description                                                |
| ------------------- | ---- | -------- | ---------------------------------------------------------- |
| `project_reference` | path | Yes      | Project slug, UUID, or domain that identifies the project. |
| `branch_id`         | path | Yes      |                                                            |
| `check_name`        | path | Yes      |                                                            |

## Request body

| Field          | Type   | Required | Description                                   |
| -------------- | ------ | -------- | --------------------------------------------- |
| `status`       | string | Yes      | State to report: pending, success or failure. |
| `description`  | string |          | Description of the result.                    |
| `external_url` | string |          | Link to the external result.                  |

## Responses

| Status | Description                                                                                                 |
| ------ | ----------------------------------------------------------------------------------------------------------- |
| 200    | Status check created or replaced.                                                                           |
| 400    | Bad request                                                                                                 |
| 401    | Unauthorized                                                                                                |
| 403    | Forbidden                                                                                                   |
| 404    | Not found                                                                                                   |
| 413    | Payload too large                                                                                           |
| 500    | Server error                                                                                                |
| 503    | internal: authentication state is temporarily unavailable and the request was not processed; retry shortly. |
