تنظيم صفحاتك في مجموعات يمكنك حفظ المحتوى وتصنيفه حسب إعداداتك المفضّلة.
تتيح لك Google Docs API إنشاء المستندات وتعديلها في "مستندات Google".
يمكن دمج التطبيقات مع Docs API لإنشاء مستندات ملفتة من البيانات المقدَّمة من المستخدم والنظام. تتيح لك واجهة برمجة التطبيقات Docs API:
التشغيل التلقائي للعمليات
إنشاء مستندات بشكل مجمّع
تنسيق المستندات
إنشاء فواتير أو عقود
استرداد سمات معيّنة للكائنات
في ما يلي قائمة بالمصطلحات الشائعة المستخدَمة في Docs API:
معرّف المستند
المعرّف الفريد للمستند وهو سلسلة معيّنة تحتوي على أحرف وأرقام وبعض الأحرف الخاصة التي تشير إلى مستند، ويمكن استخراجها من عنوان URL الخاص بالمستند. تكون معرّفات المستندات ثابتة، حتى إذا تغيّر اسم المستند. لمزيد من المعلومات عن كيفية العثور على رقم التعريف، يُرجى الاطّلاع على مقالة رقم تعريف المستند.
البنية التي تشكّل المستند تشمل عناصر المستوى الأعلى في المستند Body، DocumentStyle، List.
مستند Google Workspace
ملف ينشئه أحد تطبيقات Google Workspace، مثل "مستندات Google" تنسيق نوع MIME في "مستندات Google" هو application/vnd.google-apps.document. للحصول على قائمة بأنواع MIME، يُرجى الاطّلاع على أنواع MIME المتوافقة مع Google Workspace وGoogle Drive.
الفهرس
تحتوي معظم العناصر ضمن نص المحتوى على السمتَين startIndex وendIndex. تشير هذه القيم إلى إزاحة بداية العنصر ونهايته مقارنةً ببداية القسم المحيط به.
صورة مضمَّنة
صورة تظهر في سياق النص ضمن مستند وليس مرفقًا.
النطاق المُعنوَن
نطاق متّصل من النص NamedRange هو مجموعة من النطاقات التي لها namedRangeId نفسه. تسمح النطاقات المُسمّاة للمطوّرين بربط أجزاء من مستند بتصنيف مُعيّن يحدّده المستخدم كي يتمكّنوا من قراءة محتوياتها أو تعديلها برمجيًا لاحقًا. يمكن أن يحتوي الوثيقة على نطاقات مُعنوَنة متعددة تحمل الاسم نفسه، ولكن لكل نطاق مُعنوَن رقم تعريف فريد.
الشريحة
Body أو Header أو Footer أو Footnote التي تحتوي على عناصر بنية أو محتوى تكون الفهرس للعناصر ضمن القسم نسبيةً إلى بداية ذلك القسم.
اقتراح
التغييرات التي تطرأ على مستند بدون تغيير النص الأصلي وإذا وافق المالك على اقتراحاتك، ستحل محل النص الأصلي.
مواضيع ذات صلة
للتعرّف على كيفية التطوير باستخدام واجهات برمجة تطبيقات Google Workspace، بما في ذلك التعامل مع مصادقة وتفويض، يُرجى الاطّلاع على مقالة التطوير على Google Workspace.
للحصول على نظرة عامة على المستند، يُرجى الاطّلاع على المستند.
تاريخ التعديل الأخير: 2025-08-01 (حسب التوقيت العالمي المتفَّق عليه)
[[["يسهُل فهم المحتوى.","easyToUnderstand","thumb-up"],["ساعَدني المحتوى في حلّ مشكلتي.","solvedMyProblem","thumb-up"],["غير ذلك","otherUp","thumb-up"]],[["لا يحتوي على المعلومات التي أحتاج إليها.","missingTheInformationINeed","thumb-down"],["الخطوات معقدة للغاية / كثيرة جدًا.","tooComplicatedTooManySteps","thumb-down"],["المحتوى قديم.","outOfDate","thumb-down"],["ثمة مشكلة في الترجمة.","translationIssue","thumb-down"],["مشكلة في العيّنات / التعليمات البرمجية","samplesCodeIssue","thumb-down"],["غير ذلك","otherDown","thumb-down"]],["تاريخ التعديل الأخير: 2025-08-01 (حسب التوقيت العالمي المتفَّق عليه)"],[],[],null,["# Google Docs API overview\n\nThe Google Docs API lets you create and modify documents in Google Docs.\n\nApplications can integrate with the Docs API to create polished\ndocuments from both user and system-provided data. The Docs API lets\nyou:\n\n- Automate processes\n- Create documentation in bulk\n- Format documents\n- Generate invoices or contracts\n- Retrieve specific attributes of objects\n\nThe following is a list of common terms used in the Docs API:\n\n*Document ID*\n\n: The unique identifier for a document. It's a particular string containing\n letters, numbers, and some special characters that reference a document and\n it can be derived from the document's URL. Document IDs are stable, even if\n the document name changes. For more information on how to find the ID, see\n [Document ID](/workspace/docs/api/concepts/document#document-id).\n\n https://docs.google.com/document/d/\u003cvar translate=\"no\"\u003eDOCUMENT_ID\u003c/var\u003e/edit\n\n*Element*\n\n: The structure that makes up a document. Top-level elements of a document\n include the [`Body`](/workspace/docs/api/reference/rest/v1/documents#body),\n [`DocumentStyle`](/workspace/docs/api/reference/rest/v1/documents#documentstyle), and\n [`List`](/workspace/docs/api/reference/rest/v1/documents#list).\n\n*Google Workspace document*\n\n: A file that a Google Workspace application, like Google Docs, creates.\n The MIME type format for Docs is\n `application/vnd.google-apps.document`. For a list of MIME types, see [Google Workspace and Google Drive supported MIME types](/drive/api/guides/mime-types).\n\n*Index*\n\n: Most *elements* within the content body have the `startIndex` and `endIndex`\n properties. These indicate the offset of an element's beginning and end,\n relative to the beginning of its enclosing *segment*.\n\n*Inline image*\n\n: An image that appears in the flow of text within a document. It's not an\n attachment.\n\n*Named range*\n\n: A contiguous range of text. A\n [`NamedRange`](/workspace/docs/api/reference/rest/v1/documents#namedrange) is a\n collection of ranges with the same `namedRangeId`. Named ranges allow\n developers to associate parts of a document with an arbitrary user-defined\n label so their contents can be programmatically read or edited later. A\n document can contain multiple named ranges with the same name, but every\n named range has a unique ID.\n\n*Segment*\n\n: The `Body`, [`Header`](/workspace/docs/api/reference/rest/v1/documents#header),\n [`Footer`](/workspace/docs/api/reference/rest/v1/documents#footer), or\n [`Footnote`](/workspace/docs/api/reference/rest/v1/documents#footnote) containing\n structural or content *elements* . The *indexes* of the elements within a\n segment are relative to the beginning of that segment.\n\n*Suggestion*\n\n: Changes to a document without changing the original text. If the owner\n approves your suggestions, they replace the original text.\n\nRelated topics\n--------------\n\n- To learn about developing with Google Workspace APIs, including handling\n authentication and authorization, refer to [Develop on\n Google Workspace](/workspace/guides/get-started).\n\n- To get a conceptual overview of a document, see\n [Document](/workspace/docs/api/concepts/document).\n\n- To learn how to configure and run a Docs API app, try the\n [JavaScript quickstart](/workspace/docs/api/quickstart/js)."]]