> For the complete documentation index, see [llms.txt](https://docs-embed.anyflow.jp/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs-embed.anyflow.jp/wizard-editor/widget/assist.md).

# アシスト

## 概要

アシストは、対象SaaSのAPIを呼び出して動的にエンドユーザーに選択肢を提示するウィジェットです。

エンドユーザーごとに異なるSlackのチャンネル名、Salesforceのフィールド、GoogleDriveのフォルダ一覧、スプレッドシート一覧などを選択肢として表示し、エンドユーザーがそこから選択を行うことができます。

以下の例は、Slackのチャンネル名一覧をエンドユーザーがウィザードで選択する画面です。

<figure><img src="https://files.readme.io/aa37cf5-assist-sample.png" alt="605" width="375"><figcaption><p>アシストの例</p></figcaption></figure>

## 使い方

ウィザードエディターでアシストを使うためには、エンドユーザー変数の入力方法をアシストに選択します。\
入力方法をアシストに選択すると以下のスクリーンショットのように、「どのアシストを使うのか」を選択することができます。

<figure><img src="https://files.readme.io/0e6962d-assist.png" alt="362" width="375"><figcaption><p>どのアシストを使うのかを選択する画面</p></figcaption></figure>

アシストは、ソリューションの中で使用しているコネクタの中から選択することができます。

選択された値は、他のエンドユーザー変数と同様にソリューション内で利用できます。

<figure><img src="https://files.readme.io/aee4ac2-image.png" alt=""><figcaption></figcaption></figure>

ただしアシストでは、エンドユーザーに表示される文字列（ラベル）とソリューション内で使用する値は基本的に異なります。

例えばスプレッドシートの「スプレッドシート一覧」アシストでは、\
**エンドユーザーへの表示：スプレッドシート名（無題のスプレッドシート 等）**\
**ソリューション内での値：スプレッドシートID（1blz3HY........ 等）**\
となります。

{% hint style="warning" %}

### アシストを使う場合の注意点

エンドユーザーがアシストで選択した値は、Anyflow Embed のシステムにより**静的**に保存されます。エンドユーザーがウィザードの設定を済ませた後は、選択された値を固定値としてソリューションを実行します。

これにより、**連携先SaaSの中で**アシストで選択した値が削除されるなどの理由で**無効**となった場合、ソリューションがエラーとなる可能性があります。\
例えばSlackチャンネルをアシストで指定した後で、そのSlackチャンネルが削除された場合はソリューションがエラーとなります。

これを防ぐためには、ソリューションの中で [ifステップ](/solution-editor/logic/if.md) や [エラー監視ステップ](/solution-editor/logic/error-monitoring.md) を使い、無効な値が指定されても回避できるように設計を行ってください。\
ご不明な点があればAnyflow CSチームにご連絡ください。
{% endhint %}

### 依存関係が存在するアシストについて

アシストによっては、依存関係が存在するものがあります。\
例えば、スプレッドシートのシート一覧取得アシストを選択すると、以下のスクリーンショットのように表示されます。

<figure><img src="https://files.readme.io/8df37dd-dependence-assist.png" alt="" width="375"><figcaption></figcaption></figure>

アシストによって、赤枠で囲っている部分が変わります。\
スプレッドシートのシートは、以下のスクリーンショットのように、スプレッドシートに依存しています。

<figure><img src="https://files.readme.io/a91f408-google_sheets.jpg" alt="" width="563"><figcaption></figcaption></figure>

したがって、スプレッドシートのシートの一覧を取得するためには、親であるスプレッドシートを指定する必要があります。

以下のスクリーンショットの例では、スクリーン1に配置されている `スプレッドシート` というエンドユーザー変数を選択します。

スクリーン1 に配置されている`スプレッドシート` というエンドユーザー変数には、スプレッドシート一覧のアシストが設定されているため、スプレッドシートの情報がエンドユーザーから入力され、スプレッドシートのシートの一覧がアシストできるようになります。<br>

<figure><img src="https://files.readme.io/0b0b70a-assist-field-path.png" alt="" width="375"><figcaption></figcaption></figure>


---

# 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-embed.anyflow.jp/wizard-editor/widget/assist.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.
