Forum Discussion

mahdibm's avatar
mahdibm
New Contributor
7 months ago

CLI requires internet

I'm doing a bit of networking and it's really a pain that the `op` CLI requires a proper internet connection to work, as I don't always have a connection.

Any ways around that?

Example for `op read`:

```
[ERROR] 0000/00/00 00:00:00 could not read secret 'op://my-vault/thing/password': error initializing client: RequestDelegatedSession: cannot setup session. Please check the logs of the 1Password app.
```

3 Replies

  • nickhammond's avatar
    nickhammond
    New Contributor

    Just came across this as well, I'm tethering on a train and trying to work on something locally with the CLI. It'd be great to at least fallback to the local data if a connection isn't present. 

    op item get  --account my.1password.com 1Password --debug
    12:20PM | DEBUG | Session delegation enabled
    12:20PM | DEBUG | NM request: NmRequestAccounts
    12:20PM | DEBUG | NM response: Success
    12:20PM | DEBUG | NM request: NmRequestAccounts
    12:20PM | DEBUG | NM response: Success
    [ERROR] 2025/10/05 12:20:34 error initializing client: Get "https://my.1password.com/api/v2/account/keysets?__t=x": dial tcp: lookup my.1password.com: no such host

     

  • pgardella's avatar
    pgardella
    New Contributor

    I just ran into this `feature`. I too need to be able to use `op` in an offline mode regularly.

  • mahdibm's avatar
    mahdibm
    New Contributor

    Optimally it would just work like how the app does.
    I can see the password in the app with no connection. I should be able to read it through the CLI as well.