> For the complete documentation index, see [llms.txt](https://docs.nexthink.com/platform/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.nexthink.com/platform/ja/user-guide/remote-actions/remote-actions-nql-examples.md).

# リモート アクションの NQL 機能

このNQLの例は、必要に応じてRemote Actionsを実行するのに役立ちます。 以下のクエリを確認し、あなたのユースケースに最も似たものを選び、それをコピーして必要に応じて調整してください。

<details>

<summary>すべてのデバイスを返します。</summary>

```
デバイス
```

</details>

<details>

<summary>特定のデバイスを返します。</summary>

```
デバイス 
| where name == "Device-Name"
| list name
```

</details>

<details>

<summary>システム内のすべてのRemote Actionの実行を返し、新しい順に並べ替えます。</summary>

```
remote_action.executions
|list remote_action.name, device.name, trigger_method ,time, status, status_details, outputs
|sort time desc
```

</details>

<details>

<summary>過去1時間の特定のRemote Actionの実行を返し、新しい順に並べ替えます。</summary>

探しているRemote Actionの名前を`Remote-Action-Name`に置き換えます。

```
remote_action.executions during past 60min
|where remote_action.name == "Remote-Action-Name"
|list remote_action.name, device.name, trigger_method, time, status, status_details, outputs
|sort time desc
```

</details>

<details>

<summary>過去1時間の特定のデバイスでのRemote Actionの実行を、新しい順に並べ替えて返します。</summary>

探しているデバイスの名前を`Device-Name`に置き換えます。

```
remote_action.executions during past 60min
|where device.name == "Device-Name" 
|list remote_action.name, device.name, trigger_method, time, status, status_details, outputs
|sort time desc
```

</details>

<details>

<summary>リモートアクションの最後の成功した実行からの値を取得します。例: #Get_Battery_Status。</summary>

```
デバイス過去7日間
| list remote_action.get_battery_status.execution.outputs.BatteryHealth
```

</details>

<details>

<summary>Windowsデバイスのバッテリー健全性の状態を返します。</summary>

```
remote_action.get_battery_status.executions 
| list device.name, outputs.BatteryHealth
```

</details>

<details>

<summary>特定の内部ソースのすべてのトリガーされたRemote Actionsを返します。</summary>

```
remote_action.executions during past 7d
| where internal_source == "Amplify"
| list remote_action.name , device.name , time , trigger_method , status
```

</details>

<details>

<summary>特定のトリガーメソッドのすべてのトリガーされたRemote Actionsを返します。</summary>

```
remote_action.executions during past 7d
| where trigger_method == manual
| list remote_action.name , device.name , time , trigger_method , status
```

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

```
GET https://docs.nexthink.com/platform/ja/user-guide/remote-actions/remote-actions-nql-examples.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.
