> ## 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.

# nsc reservation wait

Waits for a reservation to be fulfilled, returning the instance id.

`reservation wait` blocks until a pending capacity reservation is fulfilled,
then prints the resulting instance ID. This is useful in scripts that need to
wait for capacity to become available before proceeding — start a
reservation, hand its ID to `reservation wait`, and continue once an instance
is actually ready rather than polling `reservation describe` in a loop.

## Usage

```bash theme={null}
nsc reservation wait <reservation_id> [--cidfile <path>] [--wait_timeout <duration>]
```

### Example

<Steps titleSize="h4">
  <Step title="Wait for the reservation">
    Wait for the reservation and write the instance ID to a file:

    ```bash theme={null}
    nsc reservation wait rsv_8f3k2m9p1q --cidfile /tmp/instance_id
    ```

    ```text nocopy Output theme={null}
    Instance ready: h9am86n6gi25m
    ```
  </Step>

  <Step title="Read the instance ID">
    Read the instance ID from the file:

    ```bash theme={null}
    cat /tmp/instance_id
    ```

    ```text nocopy Output theme={null}
    h9am86n6gi25m
    ```
  </Step>
</Steps>

## Options

<h3 id="--cidfile-path">
  \--cidfile \<path>
</h3>

If specified, write the resulting instance ID to this file. If the file
already exists, it will be overwritten. This is useful for automation that
needs to capture the ID of the instance backing a fulfilled reservation
without parsing the terminal output — see the example above.

<h3 id="--wait_timeout-duration">
  \--wait\_timeout \<duration>
</h3>

For how long to wait until the reservation is fulfilled. Defaults to `10m`.
Set to `0` to wait until the reservation's own deadline instead of applying a
separate client-side timeout — useful when you'd rather let the reservation
itself decide how long is too long.

## Related Topics

* [nsc reservation list](/docs/reference/cli/reservation-list) - List your reservations.
* [nsc reservation describe](/docs/reference/cli/reservation-describe) - Check on a reservation's current state without blocking.
