> For the complete documentation index, see [llms.txt](https://docs.ngsurvey.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.ngsurvey.com/ar/installation-setup/system-settings/google/service-account.md).

# حساب الخدمة

حساب الخدمة من Google هو حساب خاص يسمح لـ ngSurvey باستخدام الخدمات أو التطبيقات المرتبطة بحساب Google الخاص بك مثل Google Sheets أو Google Drive.

{% hint style="warning" %}
سيتمكن ngSurvey فقط من استخدام الخدمات التي تمنحها حق الوصول إليها.&#x20;
{% endhint %}

## إنشاء المشروع

قبل البدء تأكد من أنك أنشأت مشروعًا لـ API الخاص بك. افتح وحدة تحكم المطور و <https://console.developers.google.com/apis> وباستخدام قائمة الهامبرغر في أعلى اليسار اختر إدارة الموارد، في شاشة إدارة الموارد قد تنقر على **Create project** لإنشاء مشروع جدي&#x62F;**.**

![](https://848173432-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-M8fLhS0bmfBRyq0HdUm%2F-MCAx0tmVIVDcJF2JU9Q%2F-MCAzVydQlHvaK7YSHKX%2Fimage.png?alt=media\&token=9c604ce8-9fde-49fd-9553-858b591bd7ec)

## إنشاء حساب الخدمة

افتح Google Developer Console : <https://console.developers.google.com/apis/library> واختر مشروعك

![](https://848173432-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-M8fLhS0bmfBRyq0HdUm%2F-MCAx0tmVIVDcJF2JU9Q%2F-MCB-Xaj7VAOT_Vq7Zl8%2Fimage.png?alt=media\&token=3fbdbdbe-e6a2-4427-978f-cc1d151ed4a8)

ابحث عن Google Sheets API، اختره وقم بتمكينه

![](https://848173432-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-M8fLhS0bmfBRyq0HdUm%2F-MCAx0tmVIVDcJF2JU9Q%2F-MCAy0F0fwDHBB-MShUZ%2Fimage.png?alt=media\&token=ef96cc57-aa6f-4d1a-b89a-5361b246cf5d)

الآن قم بإنشاء بيانات اعتماد للوصول إلى API.

![](https://848173432-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-M8fLhS0bmfBRyq0HdUm%2F-MCAx0tmVIVDcJF2JU9Q%2F-MCB06wZ5ujaBP27bydL%2Fimage.png?alt=media\&token=100b23ee-43b7-4d0d-9e6e-ab1874f4234f)

![](https://848173432-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-M8fLhS0bmfBRyq0HdUm%2F-MCAx0tmVIVDcJF2JU9Q%2F-MCB0CA8pIwWCC0F4RPH%2Fimage.png?alt=media\&token=052182ca-297d-448e-85a0-bc8c5ae85862)

انقر على Create Credentials واختر Service Account

![](https://848173432-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-M8fLhS0bmfBRyq0HdUm%2F-MCAx0tmVIVDcJF2JU9Q%2F-MCB0NnhlQcd_CrYRN0G%2Fimage.png?alt=media\&token=4ac9e79e-e658-4492-ad6a-cc6f8998985c)

أدخل اسم الحساب وService account ID، أنشئ الحساب واستمر.

![](https://848173432-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-M8fLhS0bmfBRyq0HdUm%2F-MCAx0tmVIVDcJF2JU9Q%2F-MCB0W_p2nMAjQJ5-4km%2Fimage.png?alt=media\&token=1ee5af1f-488b-4747-9faa-4ba9ac06fdee)

{% hint style="warning" %}
تأكد من نسخ وحفظ البريد الإلكتروني الخاص بـ Service Account ID لأنك ستحتاجه لمشاركة جدول البيانات الخاص بك
{% endhint %}

بمجرد إنشاء الحساب سيُدرج في حسابات الخدمة، عدّل الحساب وفي تفاصيل حساب الخدمة ضمن Keys أضف مفتاحًا جديدًا

![](https://848173432-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-M8fLhS0bmfBRyq0HdUm%2F-MCAx0tmVIVDcJF2JU9Q%2F-MCB15511a56YiPLi-pY%2Fimage.png?alt=media\&token=6fa58a14-cd6c-4549-960b-dd19c9755203)

اختر تنسيق ملف JSON للمفتاح

![](https://848173432-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-M8fLhS0bmfBRyq0HdUm%2F-MCAx0tmVIVDcJF2JU9Q%2F-MCB1IeZb7OZKT7HL7oI%2Fimage.png?alt=media\&token=2646ed1a-8187-4da9-964a-4ce0768e08e1)

سيحفظ هذا ملف مفتاح على جهاز الكمبيوتر الخاص بك، احتفظ بالملف لأنك ستحتاج إلى رفعه إلى حساب ngSurvey الخاص بك.

الآن عد إلى الصفحة الرئيسية في Google Developer Console وابحث عن Google Drive API، فهو مطلوب لعرض جداول البيانات المتاحة. اختره وقم بتمكينه.

## إعداد NGSURVEY

افتح صفحة إعدادات ngSurvey وقم بتحميل ملف المفتاح هذا إلى حسابك.

![](https://848173432-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-M8fLhS0bmfBRyq0HdUm%2F-MCAx0tmVIVDcJF2JU9Q%2F-MCB27dJtBt68lYuJ63y%2Fimage.png?alt=media\&token=97b78fd4-cccb-44bc-9649-9c5016ae132d)

هذا كل شيء! يمكنك الآن استخدام ngSurvey مع خدمات Google الخاصة بك.

## Google Sheets

* افتح Google Sheets واختر الجدول الذي تريد استخدامه مع ngSurvey.
* انقر على زر المشاركة وشارك الجدول مع البريد الإلكتروني الخاص بحساب خدمة Google الذي أنشأته أعلاه.

![](https://848173432-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-M8fLhS0bmfBRyq0HdUm%2F-MCAx0tmVIVDcJF2JU9Q%2F-MCB2LgqNEmQu-f1CYpl%2Fimage.png?alt=media\&token=9c932cc6-5a13-47ad-aae5-457d06aa0cc4)

![](https://848173432-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-M8fLhS0bmfBRyq0HdUm%2F-MCAx0tmVIVDcJF2JU9Q%2F-MCB2epqpA9IaHVtlUGu%2Fimage.png?alt=media\&token=579c9c00-f737-4ef6-8d77-d117ac5beec4)

## Google Drive

لاستخدام أحد مجلدات Google Drive الخاصة بك في ngSurvey عليك مشاركته مع البريد الإلكتروني الخاص بحساب خدمة Google الذي أنشأته أعلاه. في Google Drive انقر بزر الماوس الأيمن على المجلد واختر Share.&#x20;

![](https://848173432-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-M8fLhS0bmfBRyq0HdUm%2F-MCB2iZ7HW_fa9tYPfR9%2F-MCB3ExfmeRzK4U8i4-w%2Fimage.png?alt=media\&token=50a1d669-682f-4678-8ed8-3fd4e8300fbc)


---

# 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.ngsurvey.com/ar/installation-setup/system-settings/google/service-account.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.
