> For the complete documentation index, see [llms.txt](https://docs.apono.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.apono.io/docs/access-requests-and-approvals/cli/access-a-resource-from-the-cli.md).

# Access a resource from the CLI

After access is granted, you can use the Apono CLI to launch a session with commands or use the interactive flow to select a resource and choose how to access it.

<details>

<summary><strong>Commands</strong></summary>

Use this approach when you know the session ID and client name for the session you want to launch.

Follow these steps to access the resource:

1. In Terminal, run the following `apono access` command to list all your session IDs.

{% hint style="info" %}
The session ID is listed under **ID**.
{% endhint %}

```shellscript
apono access list
```

2. Run the following `apono` command to display the list of valid `--client` values to use to launch your session.

```shellscript
apono --help
```

3. Run the following `apono access` command to launch your session.

```shellscript
apono access use <Session ID> --client <Client Name>
```

</details>

<details>

<summary><strong>Interactive</strong></summary>

Use the interactive flow to select an available resource and choose how to access it from the CLI.

Follow these steps to access the resource:

1. In Terminal, enter `apono access`. The **Select access** prompt and a list of resources appears.

```shellscript
apono access 
```

2. Select and submit the resource to access.The **Select how to use access** prompt appears.
3. Select and submit an option.

<table><thead><tr><th width="196.81640625">Option</th><th>Description</th></tr></thead><tbody><tr><td><strong>Connect</strong></td><td><p>Connects the user directly to the database</p><p>Once you have connected to the database, you can make queries directly from the CLI prompt.</p></td></tr><tr><td><strong>Instructions</strong></td><td>Prints instructions to access the database to the screen</td></tr></tbody></table>

</details>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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, and the optional `goal` query parameter:

```
GET https://docs.apono.io/docs/access-requests-and-approvals/cli/access-a-resource-from-the-cli.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
