Method: users.drafts.update
طلب HTTP
- معرّف الموارد المنتظم (URI) للتحميل، لطلبات تحميل الوسائط:
PUT https://gmail.googleapis.com/upload/gmail/v1/users/{userId}/drafts/{id}
- معرّف الموارد المنتظم (URI) للبيانات الوصفية، لطلبات البيانات الوصفية فقط:
PUT https://gmail.googleapis.com/gmail/v1/users/{userId}/drafts/{id}
يستخدِم عنوان URL بنية تحويل ترميز gRPC.
مَعلمات المسار
المَعلمات |
userId |
string
عنوان البريد الإلكتروني للمستخدم يمكن استخدام القيمة الخاصة me للإشارة إلى المستخدم الذي تمت مصادقته.
|
id |
string
رقم تعريف المسودة المطلوب تحديثها.
|
نص الطلب
يحتوي نص الطلب على مثال Draft
.
نص الاستجابة
إذا كانت الاستجابة ناجحة، يحتوي نص الاستجابة على مثال Draft
.
نطاقات التفويض
يتطلب استخدام أحد نطاقات OAuth التالية:
https://mail.google.com/
https://www.googleapis.com/auth/gmail.modify
https://www.googleapis.com/auth/gmail.compose
لمزيد من المعلومات، راجِع دليل التفويض.
إنّ محتوى هذه الصفحة مرخّص بموجب ترخيص Creative Commons Attribution 4.0 ما لم يُنصّ على خلاف ذلك، ونماذج الرموز مرخّصة بموجب ترخيص Apache 2.0. للاطّلاع على التفاصيل، يُرجى مراجعة سياسات موقع Google Developers. إنّ Java هي علامة تجارية مسجَّلة لشركة Oracle و/أو شركائها التابعين.
تاريخ التعديل الأخير: 2024-09-05 (حسب التوقيت العالمي المتفَّق عليه)
[null,null,["تاريخ التعديل الأخير: 2024-09-05 (حسب التوقيت العالمي المتفَّق عليه)"],[[["This method replaces the content of an existing draft using either a media upload URI for attachments or a metadata URI for metadata-only updates."],["It requires specifying the user ID (`userId`) and the draft ID (`id`) as path parameters in the request URL."],["The request body must contain a `Draft` object representing the new draft content."],["Upon successful execution, the API returns the updated `Draft` object in the response body."],["Authorization is necessary and requires one of the specified OAuth scopes related to Gmail access and modification."]]],[]]