Method: presentations.pages.getThumbnail
تنظيم صفحاتك في مجموعات
يمكنك حفظ المحتوى وتصنيفه حسب إعداداتك المفضّلة.
تُنشئ هذه الدالة صورة مصغّرة لأحدث إصدار من الصفحة المحدّدة في العرض التقديمي، وتُعرِض عنوان URL للصورة المصغّرة.
يتم احتساب هذا الطلب على أنّه طلب قراءة باهظ التكلفة لأغراض الحصة.
طلب HTTP
GET https://slides.googleapis.com/v1/presentations/{presentationId}/pages/{pageObjectId}/thumbnail
يستخدِم عنوان URL بنية تحويل ترميز gRPC.
مَعلمات المسار
المعلمات |
presentationId |
string
معرّف العرض التقديمي المطلوب استرجاعه
|
pageObjectId |
string
رقم تعريف العنصر للصفحة التي تريد استرداد صورتها المصغّرة.
|
مَعلمات طلب البحث
المعلمات |
thumbnailProperties |
object (ThumbnailProperties )
خصائص الصورة المصغّرة
|
نص الطلب
يجب أن يكون نص الطلب فارغًا.
نص الاستجابة
الصورة المصغّرة للصفحة
إذا كانت الاستجابة ناجحة، سيحتوي نص الاستجابة على بيانات بالبنية التالية:
تمثيل JSON |
{
"width": integer,
"height": integer,
"contentUrl": string
} |
الحقول |
width |
integer
العرض الإيجابي بالبكسل للصورة المصغّرة
|
height |
integer
الارتفاع الإيجابي بالبكسل للصورة المصغّرة
|
contentUrl |
string
عنوان URL للمحتوى الخاص بالصورة المصغّرة يكون لمدّة صلاحية عنوان URL للصورة 30 دقيقة تلقائيًا. تمّ وضع علامة على عنوان URL هذا بالحساب الخاص بمقدّم الطلب. يمكن لأي شخص لديه عنوان URL الوصول إلى الصورة بفعالية بصفته مقدّم الطلب الأصلي. قد لا تتمكّن من الوصول إلى الصورة في حال تغيير إعدادات مشاركة العرض التقديمي. يكون نوع mime للصورة المصغّرة هو نفسه النوع المحدّد في GetPageThumbnailRequest .
|
نطاقات التفويض
يتطلب أحد نطاقات OAuth التالية:
https://www.googleapis.com/auth/drive
https://www.googleapis.com/auth/drive.file
https://www.googleapis.com/auth/drive.readonly
https://www.googleapis.com/auth/presentations
https://www.googleapis.com/auth/presentations.readonly
لمزيد من المعلومات، يمكنك الاطّلاع على دليل التفويض.
ThumbnailProperties
يوفّر إمكانية التحكّم في إنشاء الصور المصغّرة للصفحات.
الحقول |
mimeType |
enum (MimeType )
نوع بروتوكول MIME الاختياري للصورة المصغّرة إذا لم تحدّد نوع بروتوكول MIME، سيتم ضبطه تلقائيًا على PNG.
|
thumbnailSize |
enum (ThumbnailSize )
حجم الصورة المصغّرة الاختياري إذا لم تحدّد حجم الصورة، سيختار الخادم حجمًا تلقائيًا لها.
|
MimeType
عمليات التعداد |
PNG |
نوع MIME التلقائي |
ThumbnailSize
أحجام الصور المصغّرة المحدّدة مسبقًا
عمليات التعداد |
THUMBNAIL_SIZE_UNSPECIFIED |
حجم الصورة المصغّرة التلقائي يشير حجم الصورة المصغّرة غير المحدّد إلى أنّ الخادم يختار حجم الصورة بطريقة قد تختلف في المستقبل. |
LARGE |
يجب أن يكون عرض الصورة المصغّرة 1600 بكسل. |
MEDIUM |
يجب أن يكون عرض الصورة المصغّرة 800 بكسل. |
SMALL |
يجب أن يكون عرض الصورة المصغّرة 200 بكسل. |
إنّ محتوى هذه الصفحة مرخّص بموجب ترخيص Creative Commons Attribution 4.0 ما لم يُنصّ على خلاف ذلك، ونماذج الرموز مرخّصة بموجب ترخيص Apache 2.0. للاطّلاع على التفاصيل، يُرجى مراجعة سياسات موقع Google Developers. إنّ Java هي علامة تجارية مسجَّلة لشركة Oracle و/أو شركائها التابعين.
تاريخ التعديل الأخير: 2025-03-25 (حسب التوقيت العالمي المتفَّق عليه)
[null,null,["تاريخ التعديل الأخير: 2025-03-25 (حسب التوقيت العالمي المتفَّق عليه)"],[],[],null,["# Method: presentations.pages.getThumbnail\n\n- [HTTP request](#body.HTTP_TEMPLATE)\n- [Path parameters](#body.PATH_PARAMETERS)\n- [Query parameters](#body.QUERY_PARAMETERS)\n- [Request body](#body.request_body)\n- [Response body](#body.response_body)\n - [JSON representation](#body.Thumbnail.SCHEMA_REPRESENTATION)\n- [Authorization scopes](#body.aspect)\n- [ThumbnailProperties](#ThumbnailProperties)\n - [JSON representation](#ThumbnailProperties.SCHEMA_REPRESENTATION)\n- [MimeType](#MimeType)\n- [ThumbnailSize](#ThumbnailSize)\n- [Try it!](#try-it)\n\nGenerates a thumbnail of the latest version of the specified page in the presentation and returns a URL to the thumbnail image.\n\nThis request counts as an [expensive read request](https://developers.google.com/workspace/slides/limits) for quota purposes.\n\n### HTTP request\n\n`GET https://slides.googleapis.com/v1/presentations/{presentationId}/pages/{pageObjectId}/thumbnail`\n\nThe URL uses [gRPC Transcoding](https://google.aip.dev/127) syntax.\n\n### Path parameters\n\n| Parameters ||\n|------------------|-----------------------------------------------------------------|\n| `presentationId` | `string` The ID of the presentation to retrieve. |\n| `pageObjectId` | `string` The object ID of the page whose thumbnail to retrieve. |\n\n### Query parameters\n\n| Parameters ||\n|-----------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `thumbnailProperties` | `object (`[ThumbnailProperties](/workspace/slides/api/reference/rest/v1/presentations.pages/getThumbnail#ThumbnailProperties)`)` The thumbnail properties. |\n\n### Request body\n\nThe request body must be empty.\n\n### Response body\n\nThe thumbnail of a page.\n\nIf successful, the response body contains data with the following structure:\n\n| JSON representation |\n|-----------------------------------------------------------------------|\n| ``` { \"width\": integer, \"height\": integer, \"contentUrl\": string } ``` |\n\n| Fields ||\n|--------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `width` | `integer` The positive width in pixels of the thumbnail image. |\n| `height` | `integer` The positive height in pixels of the thumbnail image. |\n| `contentUrl` | `string` The content URL of the thumbnail image. The URL to the image has a default lifetime of 30 minutes. This URL is tagged with the account of the requester. Anyone with the URL effectively accesses the image as the original requester. Access to the image may be lost if the presentation's sharing settings change. The mime type of the thumbnail image is the same as specified in the `GetPageThumbnailRequest`. |\n\n### Authorization scopes\n\nRequires one of the following OAuth scopes:\n\n- `https://www.googleapis.com/auth/drive`\n- `https://www.googleapis.com/auth/drive.file`\n- `https://www.googleapis.com/auth/drive.readonly`\n- `https://www.googleapis.com/auth/presentations`\n- `https://www.googleapis.com/auth/presentations.readonly`\n\nFor more information, see the [Authorization guide](/workspace/guides/configure-oauth-consent).\n\nThumbnailProperties\n-------------------\n\nProvides control over page thumbnail creation.\n\n| JSON representation |\n|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| ``` { \"mimeType\": enum (/workspace/slides/api/reference/rest/v1/presentations.pages/getThumbnail#MimeType), \"thumbnailSize\": enum (/workspace/slides/api/reference/rest/v1/presentations.pages/getThumbnail#ThumbnailSize) } ``` |\n\n| Fields ||\n|-----------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `mimeType` | `enum (`[MimeType](/workspace/slides/api/reference/rest/v1/presentations.pages/getThumbnail#MimeType)`)` The optional mime type of the thumbnail image. If you don't specify the mime type, the mime type defaults to PNG. |\n| `thumbnailSize` | `enum (`[ThumbnailSize](/workspace/slides/api/reference/rest/v1/presentations.pages/getThumbnail#ThumbnailSize)`)` The optional thumbnail image size. If you don't specify the size, the server chooses a default size of the image. |\n\nMimeType\n--------\n\nThe mime type of the thumbnail image.\n\n| Enums ||\n|-------|------------------------|\n| `PNG` | The default mime type. |\n\nThumbnailSize\n-------------\n\nThe predefined thumbnail image sizes.\n\n| Enums ||\n|------------------------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `THUMBNAIL_SIZE_UNSPECIFIED` | The default thumbnail image size. The unspecified thumbnail size implies that the server chooses the size of the image in a way that might vary in the future. |\n| `LARGE` | The thumbnail image width of 1600px. |\n| `MEDIUM` | The thumbnail image width of 800px. |\n| `SMALL` | The thumbnail image width of 200px. |"]]