---
schema_version: "1"
id: 208a80f7bf41c7df53e888a1bbe00cfda3dfd2e90c857290a2390e3a54f0a99d
title: agent adl update
collection: developer
version: current
locale: en-us
portal_url: https://docs.salesforce.com/developer/current/en-us/salesforcedx/sfclireference/guides/agent/cli_reference_agent_adl_update.md
canonical_url: https://developer.salesforce.com/docs/platform/salesforce-cli-reference/guide/cli_reference_agent_adl_update.html
source_site: developer.salesforce.com
content_type: documentation
content_hash: 1a93ab058e3afc347512ea7c1f9158e1a5e6b627b742401257e01a2b1255ae09
products:
  - Salesforce CLI Command Reference
  - salesforcedx
---
<!-- prettier-ignore-start -->

# agent adl update

Update an Agentforce Data Library.

## Description for agent adl update

Updates the label, description, or other mutable properties of an existing data library.

## Flags

| Flag Name (Long) | Flag Name (Short) | Description |
|------------------|-------------------|-------------|
| <code>&#8209;&#8209;api&#8209;version</code> | N/A | **Type:** Value<br><br>Override the api version used for api requests made by this command |
| <code>&#8209;&#8209;content&#8209;fields</code> | N/A | **Type:** Value<br><br>Comma-separated list of content fields for KNOWLEDGE libraries (triggers re-indexing). |
| <code>&#8209;&#8209;data&#8209;category&#8209;rule</code> | N/A | **Type:** Boolean<br><br>Enable or disable data category filtering for KNOWLEDGE libraries. Use --no-data-category-rule to disable. |
| <code>&#8209;&#8209;description</code> | N/A | **Type:** Value<br><br>New description for the data library (max 255 characters). |
| <code>&#8209;&#8209;flags&#8209;dir</code> | N/A | **Type:** Value<br><br>Import flag values from a directory. |
| <code>&#8209;&#8209;json</code> | N/A | **Type:** Boolean<br><br>Format output as json. |
| <code>&#8209;&#8209;library&#8209;id</code> | <code>&#8209;i</code> | **Type:** Value<br>**Required**<br><br>Agentforce Data Library ID (18-char Salesforce ID with prefix 1JD). |
| <code>&#8209;&#8209;name</code> | <code>&#8209;n</code> | **Type:** Value<br><br>New display name for the data library (max 80 characters). |
| <code>&#8209;&#8209;restrict&#8209;to&#8209;public&#8209;articles</code> | N/A | **Type:** Boolean<br><br>Restrict to public Knowledge articles only (KNOWLEDGE libraries, triggers re-indexing). |
| <code>&#8209;&#8209;retriever&#8209;id</code> | N/A | **Type:** Value<br><br>Swap the retriever for a RETRIEVER library (must be an active Custom Retriever ID). |
| <code>&#8209;&#8209;target&#8209;org</code> | <code>&#8209;o</code> | **Type:** Value<br>**Required**<br><br>Username or alias of the target org. Not required if the `target-org` configuration variable is already set. |

## Examples for agent adl update

Update the label of a data library:

```shell
sf agent adl update --library-id 1JDSG000007IbWX4A0 --name "New Name" --target-org myOrg
```

Update the description:

```shell
sf agent adl update --library-id 1JDSG000007IbWX4A0 --description "Updated description" --target-org myOrg
```

Update Knowledge library content fields (triggers re-indexing):

```shell
sf agent adl update --library-id 1JDSG000007IbWX4A0 --content-fields "Answer**c,Summary**c" --target-org myOrg
```

Restrict Knowledge library to public articles:

```shell
sf agent adl update --library-id 1JDSG000007IbWX4A0 --restrict-to-public-articles --target-org myOrg
```
<!-- prettier-ignore-end -->
