---
type: api
title: Get an agent's effective config
description: **Spaces method and path for this operation:**
url: https://www.elastic.co/elastic/docs-builder/docs/4641/api/doc/kibana/v9/operation/operation-get-fleet-agents-agentid-effective-config
resource: https://www.elastic.co/elastic/docs-builder/docs/4641/api/doc/kibana/v9/operation/operation-get-fleet-agents-agentid-effective-config
products:
  - Kibana
---

# Get an agent's effective config

Authentication: required

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

## Paths

- `GET` `/api/fleet/agents/{agentId}/effective_config`
- `GET` `/s/{space_id}/api/fleet/agents/{agentId}/effective_config`

#### Path parameters

- `space_id` (string) — optional
  An identifier for the space. If `space_id` is not provided in the URL, the default space is used. Refer to [Spaces](https://www.elastic.co/docs/deploy-manage/manage-spaces) for more information.
- `agentId` (string) — required
  The agent ID to get effective config of

## Description

Get an agent's effective config by ID.

## Required authorization

- Privileges: `fleet-agents-read`

## Responses

#### `200`

OK: A successful request.

`application/json`

- `effective_config` (object)
#### `400`

A bad request.

`application/json`

- `attributes` (object)
- `error` (string)
- `errorType` (string)
- `message` (string)
- `statusCode` (number)
## Code examples

#### Console

```console
GET kbn:/api/fleet/agents/AGENT_ID/effective_config
```

#### curl

```curl
curl -X GET "${KIBANA_URL}/api/fleet/agents/${AGENT_ID}/effective_config" \
  -H "Authorization: ApiKey ${API_KEY}"
```

## Response examples

#### Success

`application/json`

```json
{
  "effective_config": {}
}
```

#### Bad request

`application/json`

```json
{
  "message": "Bad Request"
}
```

