# rpk ai env add

> For the complete documentation index, see [llms.txt](https://docs.redpanda.com/llms.txt). Component-specific: [agentic-data-plane-full.txt](https://docs.redpanda.com/agentic-data-plane-full.txt)

---
title: rpk ai env add
latest-operator-version: v26.2.1
latest-console-tag: v3.10.0
latest-connect-version: 4.104.0
latest-redpanda-tag: v26.2.1
docname: rpk/rpk-ai/rpk-ai-env-add
page-component-name: agentic-data-plane
page-version: master
page-component-version: master
page-component-title: Agentic Data Plane
page-relative-src-path: rpk/rpk-ai/rpk-ai-env-add.adoc
page-edit-url: https://github.com/redpanda-data/adp-docs/edit/main/modules/reference/pages/rpk/rpk-ai/rpk-ai-env-add.adoc
description: Add a manual <code>rpk</code> ai environment with explicit URLs.
page-git-created-date: "2026-07-02"
page-git-modified-date: "2026-08-06"
---

<!-- Source: https://docs.redpanda.com/agentic-data-plane/reference/rpk/rpk-ai/rpk-ai-env-add.md -->

Add a manual `rpk` ai environment with explicit URLs.

## [](#usage)Usage

```bash
rpk ai env add [flags]
```

## [](#flags)Flags

| Value | Type | Description |
| --- | --- | --- |
| --adp-api-url | string | adp-api base URL (optional; derived from the AI Gateway URL when omitted). |
| --ai-gateway-url | string | AI Gateway base URL (required). |
| --auth-mode | string | auth mode: device|rpk|token|none (default device). device borrows your logged-in org’s token; use none/token for a local aigw. |
| --description | string | optional human-readable description. |
| --from | string | copy an existing manual environment as the base. |

## [](#global-flags)Global flags

| Value | Type | Description |
| --- | --- | --- |
| --config | string | Redpanda or rpk config file; default search paths are ~/.config/rpk/rpk.yaml, $PWD/redpanda.yaml, and /etc/redpanda/redpanda.yaml. |
| -X, --config-opt | stringArray | Override rpk configuration settings; -X help for detail or -X list for terser detail. |
| --ignore-profile | bool | Ignore rpk.yaml and redpanda.yaml; use default settings. |
| --profile | string | rpk profile to use. |
| -v, --verbose | bool | Enable verbose logging. |