> For the complete documentation index, see [llms.txt](https://docs.geopard.tech/geopard-tutorials/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.geopard.tech/geopard-tutorials/ar/wthaeq-wajhh-brmjh-alttbyqat/geopard-api-requests-overview/83.-query-collect-platform-context.md).

# 83. استعلام: جمع سياق المنصة

عند معالجة عدد كبير من مجموعات البيانات (مئات أو آلاف، مثل "SatelliteImage" و"AsAppliedDataset" و"YieldDataset" و"SoilDataset" وغيرها)، تبرز الحاجة دائمًا إلى معرفة حالة معالجة كل مجموعة بيانات وجمع ملخص المعالجة. ويمكن الاطلاع على هذه التفاصيل باستخدام `getPlatformContext` استعلام.

الحالات الشائعة:

* تتبّع تقدّم المعالجة
* جمع ملخص المعالجة والإحصاءات
* رصد الأخطاء والتحذيرات أثناء المعالجة لإجراء تحقيق أعمق لاحقًا في مجموعات البيانات المتأثرة

{% code overflow="wrap" lineNumbers="true" %}

```graphql
query CollectPlatformContext {
 getPlatformContext(input: {
   userUuids: ["<placeholder_of_user_uuid>"],
   statuses: [Start, Done, Warning, Error, Ignored],
   dateFrom: "2023-05-25T12:49:00.000Z", 
   dateTo: "2023-05-30T06:35:00.000Z", 
 }) {
   events {
     fieldUuid
     subFieldUuid
     subFieldType
     operationId
     status 
     executionDate
     messageKey
     optional
   }
 }
}
```

{% endcode %}

مرشحات الإدخال المدعومة:

* `dateFrom` كتاريخ ووقت بتنسيق ISO 8601 (مثال: `"2023-05-25T12:49:00.000Z"`)
* `dateTo` كتاريخ ووقت بتنسيق ISO 8601 (مثال: `"2023-05-30T06:35:00.000Z"`)
* `operationIds` كمصفوفة من معرّفات العمليات (`Strings`)
* `statuses` كمصفوفة تتضمن قيمًا من `ContextEventStatus` تعداد يضم جميع حالات المعالجة، بما فيها الحالات الوسيطة؛ ويُوصى باستخدام الحالات الأساسية `[Start, Done, Warning, Error, Ignored]`
* `subFieldTypes` كمصفوفة تتضمن قيمًا من تعداد `TreeNodeEntity` الذي يضم جميع كيانات GeoPard
* `subFieldUuids` كمصفوفة من معرّفات UUID المرتبطة بالكيانات المحددة ضمن `subFieldTypes`
* `userUuids` كمصفوفة من معرّفات UUID الخاصة بـ "User" للبحث عنها

{% hint style="info" %}
يجب تهيئة مرشح واحد على الأقل من المرشحات التالية: `userUuids`, `fieldUuids`, `subFieldUuids`، أو `operationIds`.
{% endhint %}

{% hint style="info" %}
إذا لم يتم تحديد `dateFrom` و `dateTo` ، فستكون مدة الاستعلام الافتراضية 12 ساعة. والحد الأقصى الموصى به للفترة الزمنية لاسترجاع البيانات هو 24 ساعة.
{% endhint %}

{% hint style="info" %}
يوجد حد أقصى يبلغ 10,000 صف للبيانات المُرسلة.
{% endhint %}

{% hint style="info" %}
لمعاينة أحدث القيم المتاحة لجميع التعدادات (مثل: `TreeNodeEntity`, `ContextEventStatus, ContextMessageKey`)، يُوصى باستخدام [Altair](https://docs.geopard.tech/geopard-tutorials/ar/wthaeq-wajhh-brmjh-alttbyqat/getting-started-with-the-geopard-api.md).
{% endhint %}

يتضمن كائن الإخراج السمات التالية:

* `fieldUuid` يمثل المعرّف الفريد عالميًا (UUID) للحقل المرتبط
* `subFieldUuid` يشير إلى المعرّف الفريد عالميًا (UUID) لمجموعة البيانات المعالَجة المرتبطة (مثل "SatelliteImage" و"AsAppliedDataset" و"YieldDataset" و"SoilDataset" وغيرها)
* `subFieldType` بوصفه تعدادًا مرتبطًا بـ `TreeNodeEntity`
* `operationId` سلسلة نصية تتضمن معرّف العملية. ويظل هذا المعرّف ثابتًا في جميع سلاسل المعالجة ذات الصلة؛ لذا يُنصح بالتجميع حسبه لتتبّع جميع مراحل المعالجة.
* `status` بوصفه تعدادًا مرتبطًا بـ `ContextEventStatus`
* `executionDate` سلسلة نصية بتنسيق ISO 8601 تشير إلى وقت التنفيذ
* `messageKey` بوصفه تعدادًا مرتبطًا بـ `ContextMessageKey` الذي يصف نتيجة التنفيذ
* `optional` سلسلة نصية تقدم وصفًا تقنيًا (عند الاقتضاء)، وتُستخدم أساسًا لتصحيح الأخطاء والإبلاغ عنها.


---

# 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 by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.geopard.tech/geopard-tutorials/ar/wthaeq-wajhh-brmjh-alttbyqat/geopard-api-requests-overview/83.-query-collect-platform-context.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

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.
