---
type: api
title: Disable Attack Discovery schedule
description: **Spaces method and path for this operation:**
url: https://www.elastic.co/elastic/docs-builder/docs/4371/api/doc/kibana/v9/operation/operation-disableattackdiscoveryschedules
resource: https://www.elastic.co/elastic/docs-builder/docs/4371/api/doc/kibana/v9/operation/operation-disableattackdiscoveryschedules
products:
  - Kibana
---

# Disable Attack Discovery schedule

- Server: `https://{kibana_url}`

## Paths

- `POST` `/api/attack_discovery/schedules/{id}/_disable`
- `POST` `/s/{space_id}/api/attack_discovery/schedules/{id}/_disable`

- [Api key auth](/elastic/docs-builder/docs/4371/api/doc/kibana/v9/authentication#apikeyauth)
- [Basic auth](/elastic/docs-builder/docs/4371/api/doc/kibana/v9/authentication#basicauth)

#### Path Parameters

- `id` (string · min: 1)
  The unique identifier (UUID) of the Attack Discovery schedule to disable. This ID is returned when creating a schedule and can be found in schedule listings.

## Description

Refer to [Spaces](https://www.elastic.co/docs/deploy-manage/manage-spaces) for more information.

Disables an Attack Discovery schedule, preventing it from running according to its configured interval. The schedule configuration is preserved and can be re-enabled later. Any currently running executions will complete, but no new executions will be started.

## Responses

#### `200`

Successfully disabled Attack Discovery schedule, returning the schedule ID for confirmation

`application/json`

- `id` (string · min: 1)
  A string that does not contain only whitespace characters.
#### `400`

Bad Request response.

`application/json`

- `error` (string)
  Error type
- `message` (string)
  Human-readable error message describing what went wrong
- `status_code` (number)
  HTTP status code
## Code Examples

#### curl

```curl
curl \
 --request POST 'http://localhost:5601/api/attack_discovery/schedules/12345678-1234-1234-1234-123456789012/_disable' \
 --header "Authorization: $API_KEY" \
 --header "Content-Type: application/json"
```

## Response Examples

#### Confirmation returned after disabling an Attack Discovery schedule.

```json
{
  "id": "12345678-1234-1234-1234-123456789012"
}
```

#### Bad Request error returned when the disable schedule request is invalid.

```json
{
  "error": "Bad Request",
  "message": "Invalid request parameters.",
  "status_code": 400
}
```

