> ## Documentation Index
> Fetch the complete documentation index at: https://namespace.so/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Labels

> Label Devboxes by agent run, team, or task, and find them again later.

An agent can create many Devboxes in a single run, for example one per test shard when you ask it to run a test suite in parallel. Label each one as it's created, and you can list, check on, or clean up the whole set by its label.

## Add labels when you create a Devbox

```typescript TS SDK theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
const devbox = await client.devboxes.create({
  name: "my-devbox",
  imageName: "builtin:default",
  labels: { run: "482", team: "web" },
});
```

## Find Devboxes by label

```typescript TS SDK theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
const page = await client.devboxes.list({
  labelFilters: [{ name: "run", value: "482" }],
});
```

A Devbox must match every filter. Filters can also match a label that isn't equal to a value, or that exists with any value. See [`list()`](https://namespace.so/docs/reference/typescript-sdk/devbox/manage#devboxes-list).

## Related

* [Lifecycle](https://namespace.so/docs/devbox/lifecycle.md) to create, stop, and delete Devboxes.
* Reference: [`devboxes.create()`](https://namespace.so/docs/reference/typescript-sdk/devbox/manage), [`devboxes.list()`](https://namespace.so/docs/reference/typescript-sdk/devbox/manage#devboxes-list).


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.