REST Resource: users.messages.attachments
با مجموعهها، منظم بمانید
ذخیره و طبقهبندی محتوا براساس اولویتهای شما.
منبع: MessagePartBody
نمایندگی JSON |
---|
{
"attachmentId": string,
"size": integer,
"data": string
} |
فیلدها |
---|
attachmentId | string در صورت وجود، حاوی شناسه یک پیوست خارجی است که می تواند در یک درخواست messages.attachments.get جداگانه بازیابی شود. وقتی وجود ندارد، کل محتوای متن قسمت پیام در فیلد داده قرار می گیرد. |
size | integer تعداد بایتها برای دادههای بخش پیام (بهرغم کدگذاری). |
data | string ( bytes format) دادههای بدنه یک بخش پیام MIME بهعنوان یک رشته کدگذاریشده با پایه 64url. ممکن است برای انواع محفظه MIME که متن پیام ندارند یا زمانی که دادههای بدنه بهعنوان پیوست جداگانه ارسال میشوند خالی باشد. اگر دادههای بدنه در پیوست جداگانه وجود داشته باشد، شناسه پیوست وجود دارد. رشته ای با کد base64. |
روش ها |
---|
| پیوست پیام مشخص شده را دریافت می کند. |
جز در مواردی که غیر از این ذکر شده باشد،محتوای این صفحه تحت مجوز Creative Commons Attribution 4.0 License است. نمونه کدها نیز دارای مجوز Apache 2.0 License است. برای اطلاع از جزئیات، به خطمشیهای سایت Google Developers مراجعه کنید. جاوا علامت تجاری ثبتشده Oracle و/یا شرکتهای وابسته به آن است.
تاریخ آخرین بهروزرسانی 2025-07-25 بهوقت ساعت هماهنگ جهانی.
[null,null,["تاریخ آخرین بهروزرسانی 2025-07-25 بهوقت ساعت هماهنگ جهانی."],[],[],null,["# REST Resource: users.messages.attachments\n\n- [Resource: MessagePartBody](#MessagePartBody)\n - [JSON representation](#MessagePartBody.SCHEMA_REPRESENTATION)\n- [Methods](#METHODS_SUMMARY)\n\nResource: MessagePartBody\n-------------------------\n\nThe body of a single MIME message part.\n\n| JSON representation |\n|---------------------------------------------------------------------|\n| ``` { \"attachmentId\": string, \"size\": integer, \"data\": string } ``` |\n\n| Fields ||\n|----------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `attachmentId` | `string` When present, contains the ID of an external attachment that can be retrieved in a separate `messages.attachments.get` request. When not present, the entire content of the message part body is contained in the data field. |\n| `size` | `integer` Number of bytes for the message part data (encoding notwithstanding). |\n| `data` | `string (`[bytes](https://developers.google.com/discovery/v1/type-format)` format)` The body data of a MIME message part as a base64url encoded string. May be empty for MIME container types that have no message body or when the body data is sent as a separate attachment. An attachment ID is present if the body data is contained in a separate attachment. A base64-encoded string. |\n\n| Methods ------- ||\n|----------------------------------------------------------------------------------|----------------------------------------|\n| ### [get](/workspace/gmail/api/reference/rest/v1/users.messages.attachments/get) | Gets the specified message attachment. |"]]