# Xanoレスポンス

***

## **オブジェクトを 'As Self' として返す:**

{% hint style="warning" %}
Xano ユーザーに通知を送信する場合、ユーザーの GET ALL エンドポイントはレスポンスを 'As Self' として送信する必要があります。そうしないと通知を受信できません。
{% endhint %}

Xano でオブジェクトを 'As Self' として返すことを選択すると、特定の属性を含む単一で包括的なオブジェクトを提供する効率的なアプローチを選択しています。これは、単一のレコードやエンティティに関する詳細な情報を受け取ることが期待される場合に特に有用です。

**使用例:** ユーザー ID をクエリして詳細なユーザープロファイルを取得します。レスポンスは、関連するすべてのユーザー属性を含む単一のオブジェクトで構成されます。

**実装手順:**

1. エンドポイントのレスポンス定義で、希望する属性を指定します。
2. これらの属性をデータソース内の対応するフィールドにマッピングします。
3. 単一で詳細なオブジェクトを受け取るために 'As Self' を選択します。

## **結果キーを持つ配列を返す:**

{% hint style="warning" %}
外部コレクションを設定する際に使用する必要があります。
{% endhint %}

結果キーを持つデータを配列として返すことを選択すると、クエリに一致するレコードが1つだけであっても、一貫したオブジェクトの配列としてレスポンスが構造化されます。配列内の各オブジェクトは、クエリされたデータのインスタンスを表します。

**使用例:** 特定のカテゴリ内の製品のリストを取得します。製品の数に関係なく、レスポンスは一貫しており、データ管理を円滑にします。

**実装手順:**

1. レスポンスに含める属性を定義します。
2. これらの属性をデータソース内の対応するフィールドにマッピングします。
3. "Results Key" オプションを有効にし、意味のある名前を割り当てます（例: "products"）。

**選択のためのガイドライン:**

1. **'As Self' を使用する場合:**
   * ユーザープロファイルやユニークなレコードなど、単一のエンティティに関する詳細情報が必要な場合。
   * Xano コレクションを使用する場合。
2. **結果キーを持つ配列を使用する場合:**
   * アイテムのリスト、カテゴリ、またはデータセットなど、レコードのコレクションを処理する場合。
   * 外部コレクションを介して Xano エンドポイントを使用する場合。


---

# Agent Instructions: 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://help.adalo.com/ja/integrations/xano/xano-response.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.
