# Next Available Index

## Description

The next available index selector allows you to target the next available index of an array.

You can think of this as appending to a list.

## Usage

{% hint style="info" %}
This is only available in [put](/v1/usage/put.md) commands.
{% endhint %}

```shell
.[]
```

## Example

```shell
$ echo '{"x": [1, 2]}' | dasel put int -p json '.x.[]' 3
{
  "x": [
    1,
    2,
    3
  ]
}
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://daseldocs.tomwright.me/v1/selectors/next-available-index.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
