> For the complete documentation index, see [llms.txt](https://manual.dxable.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://manual.dxable.com/1password/integrate-with-the-1password-app.md).

# 1Passwordデスクトップアプリ統合でCLIにサインイン

### 1Passwordデスクトップアプリ統合でCLIにサインイン <a href="#o1h1fkcc4yub" id="o1h1fkcc4yub"></a>

1Passwordアプリとの統合をオンにすると、[1Passwordデスクトップアプリ](https://support.1password.com/get-the-apps/)に追加したアカウントを使って[1Password CLI](https://developer.1password.com/docs/cli/get-started/)にサインインできます。その後、指紋、顔、Apple Watch、Windows Hello PIN、デバイスユーザーパスワードなど、デバイスのロックを解除するのと同じ方法で1Password CLIを認証できます。

### [必要条件](https://developer.1password.com/docs/cli/app-integration/#requirements) <a href="#viy8a45cgod6" id="viy8a45cgod6"></a>

Mac

* [1Passwordサブスクリプション](https://start.1password.com/sign-up/plan)
* [1Password for Mac](https://support.1password.com/get-the-apps/?mac)

Windows

* [1Passwordサブスクリプション](https://start.1password.com/sign-up/plan)
* [1Password for Windows](https://support.1password.com/get-the-apps/?windows)

Linux

* [1Passwordサブスクリプション](https://start.1password.com/sign-up/plan)
* [1Password for Linux](https://support.1password.com/get-the-apps/?linux)
* [PolKit](https://gitlab.freedesktop.org/polkit/polkit)（多くの人気ディストリビューションに含まれています）
* PolKit認証エージェントが稼働していること

### ステップ1: アプリの統合をオンにする <a href="#j98ozy5wi210" id="j98ozy5wi210"></a>

Mac

1. [1Passwordアプリ](https://support.1password.com/get-the-apps/)を開いてロックを解除します。
2. サイドバーの上部にあるアカウントまたはコレクションをクリックします。
3. \[Settings] > \[Developer]と移動します。
4. \[Integrate with 1Password CLI]を選択します。
5. 1Password CLIを指紋で認証する場合は、アプリで[Touch IDをオンにします。](https://support.1password.com/touch-id-mac/)\
   ![](/files/sGwOWkGDXAqqm201umv3)

Windows

1. [1Password アプリ](https://support.1password.com/get-the-apps/)を開いてロックを解除します。
2. サイドバーの上部にあるアカウントまたはコレクションをクリックします。
3. アプリで[Windows Hello](https://support.1password.com/windows-hello/)をオンにします。
4. \[Settings] > \[Developer]と移動します。
5. Integrate with 1Password CLIを選択します。\
   ![](/files/U0xU7coE85IqSNyuq4iz)

Linux

1. [1Password アプリ](https://support.1password.com/get-the-apps/)を開いてロックを解除します。
2. サイドバーの上部にあるアカウントまたはコレクションをクリックします。
3. \[Settings] > \[Security]と移動します。
4. \[Unlock using system authentication]をオンにします。
5. \[Settings] > \[Developer]と移動します。
6. Integrate with 1Password CLIを選択します。\
   ![](/files/d5XVc63EmLBPvfZ3Ir9e)

### ステップ2：何かコマンドを入力してサインする <a href="#a1tbi3rjvbu" id="a1tbi3rjvbu"></a>

![](/files/AuLldCRFXCpCisBbL1QY)

<https://drive.google.com/file/d/1mMrXyOudfio4bdSrdK_sxIBhVp_wRxcI/view?usp=drive_link>

アプリの統合をオンにした後、何か任意のコマンドを入力すると、認証を求められます。

アカウント内の全保管庫を表示するには、次のコマンドを実行します。

$ op vault list

[複数のアカウントを使う](https://developer.1password.com/docs/cli/use-multiple-accounts/)場合は、[op signin](https://developer.1password.com/docs/cli/reference/commands/signin/)を入力してアカウントを切り替えます。フラグ--accountを使うか、環境変数OP\_ACCOUNTを設定することで、サインインするアカウントを指定することもできます。

### ステップ3：前に追加したアカウントの詳細を削除する <a href="#m3lk8gkplkju" id="m3lk8gkplkju"></a>

⚠️注意：

設定ファイルからアカウントの詳細を削除する前に、Secret Keyとアカウントパスワードにアクセスできることを確認してください。

以前に[1Password CLIにアカウントを手動で追加していて](https://developer.1password.com/docs/cli/sign-in-manually/)、サインインにアプリ統合のみを使う場合は、設定ファイルからアカウントの詳細を削除できます。

構成ファイルは次のいずれかの場所にあります。

* \~/.op/config
* \~/.config/op/config
* \~/.config/.op/config

設定ファイルから保存済みのアカウント情報をすべて削除するには、[account forget](https://developer.1password.com/docs/cli/reference/management-commands/account/#account-forget)コマンドを使います。これは、1Passwordデスクトップ アプリに追加されたアカウントには影響しません。\
$op account forget --all

### オプション：生体認証ロック解除環境変数 <a href="#id-933uic7hzs86" id="id-933uic7hzs86"></a>

環境変数OP\_BIOMETRIC\_UNLOCK\_ENABLEDを使って、アプリの統合を一時的にオンまたはオフに切り替えることができます。

**Bash、Zsh、sh**

統合を有効にするには次のように入力します：

$ export OP\_BIOMETRIC\_UNLOCK\_ENABLED=true

統合をオフにするには次のように入力します：

$ export OP\_BIOMETRIC\_UNLOCK\_ENABLED=false

**fish**

統合を有効にするには次のように入力します：

$ set -x OP\_BIOMETRIC\_UNLOCK\_ENABLED true

統合をオフにするには次のように入力します：

$ set -x OP\_BIOMETRIC\_UNLOCK\_ENABLED false

**PowerShell**\
統合を有効にするには次のように入力します：

PS C:¥> $Env:OP\_BIOMETRIC\_UNLOCK\_ENABLED = "true"

統合をオフにするには次のように入力します：

PS C:¥> $Env:OP\_BIOMETRIC\_UNLOCK\_ENABLED = "false"

### トラブルシューティング <a href="#id-2sku1g5db9rj" id="id-2sku1g5db9rj"></a>

#### op signinでアカウントが表示されない場合 <a href="#w6nhkalbkjbv" id="w6nhkalbkjbv"></a>

op signinコマンドは、1Passwordデスクトップアプリに追加した全アカウントのリストを返します。 新しい1Passwordアカウントで1Password CLIにサインインするには、[そのアカウントをアプリに追加する](https://support.1password.com/add-account/)必要があります。

#### 接続エラーが表示された場合 <a href="#n19bbhrxui93" id="n19bbhrxui93"></a>

connectionresetエラーが表示された場合、または1Password CLIが1Password デスクトップアプリに接続できなかったというエラーが表示された場合は、次の操Createを試してください。

**Mac**

\[System Settings] > \[General] > \[Login Items]を開き、1Passwordに対し\[Allow in background]がオンになっていることを確認します。

それでもエラーが表示される場合は、次の操Createを試してください。

1. 1Passwordデスクトップアプリの最新版を使っていることを確認してください。
2. アプリを再起動してください。

1Password for Mac バージョン8.10.12以前を使っている場合は、1Password CLIのバイナリーが/usr/local/bin/ディレクトリー内に配置されている必要があります。

**Windows**

1. 1Passwordデスクトップアプリの最新版を使っていることを確認してください。
2. アプリを再起動してください。

**Linux**

1. 1Passwordデスクトップアプリの最新版を使っていることを確認してください。
2. アプリを再起動してください。

認証を試みたときにLostConnectionToAppエラーが表示される場合:

**Mac**

メニューバーに1Passwordを保持するオプションがオンになっていることを確認してください。

1. 1Passwordデスクトップアプリを開いてロックを解除します。
2. サイドバーの上部にあるアカウントまたはコレクションを選択します。
3. \[Settings] > \[General]を選択します。
4. “Keep 1Password in the menu bar”が選択されていることを確認します。

**Windows**

1Passwordを通知領域に保持するオプションがオンになっていることを確認します。

1. 1Passwordデスクトップアプリを開いてロックを解除します。
2. サイドバーの上部にあるアカウントまたはコレクションを選択します。
3. \[Settings] > \[General]を選択します。
4. “Keep 1Password in the notification area”が選択されていることを確認します。。

**Linux**

1Passwordをシステムトレイに保持するオプションがオンになっていることを確認します。

1. 1Passwordデスクトップ アプリを開いてロックを解除します。
2. サイドバーの上部にあるアカウントまたはコレクションを選択します。
3. \[Settings] > \[General]を選択します。
4. "Keep 1Password in the system tray"が選択されていることを確認します。

#### お好みの方法で認証するようプロンプトが表示されない場合 <a href="#jibjez3sw11k" id="jibjez3sw11k"></a>

アプリ統合をオンにしたのに、期待する認証方法で1Password CLIにサインインするように求められない場合：

**Mac**

Macで1Passwordのロックを解除するには、[Touch ID](https://support.1password.com/touch-id-mac/)または[Apple Watch](https://support.1password.com/apple-watch-mac/)が設定されていることを確認してください。

**Windows**

Windows PCで1Passwordのロックを解除するには、[Windows Hello](https://support.1password.com/windows-hello/)が設定されていることを確認してください。

**Linux**

1. Linux コンピュータで1Passwordのロックを解除するには、[システム認証](https://support.1password.com/system-authentication-linux/)が設定されていることを確認してください。
2. Linux設定の認証方法を更新して、Linuxユーザーパスワードの代わりに[指紋またはその他の生体認証](https://help.ubuntu.com/stable/ubuntu-help/session-fingerprint.html.en)を使うようにしてください。

### さらに詳しく知るには <a href="#id-89lk1yxqmayf" id="id-89lk1yxqmayf"></a>

* [複数のアカウントを使う](https://developer.1password.com/docs/cli/use-multiple-accounts/)
* [1Passwordアプリにアカウントを追加する](https://support.1password.com/add-account/)
* [1Password アプリ統合セキュリティ](https://developer.1password.com/docs/cli/app-integration-security/)ー


---

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

```
GET https://manual.dxable.com/1password/integrate-with-the-1password-app.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.
