REST Resource: customEmojis
จัดทุกอย่างให้เป็นระเบียบอยู่เสมอด้วยคอลเล็กชัน
บันทึกและจัดหมวดหมู่เนื้อหาตามค่ากำหนดของคุณ
ทรัพยากร: CustomEmoji
การแสดง JSON |
{
"name": string,
"uid": string,
"emojiName": string,
"temporaryImageUri": string,
"payload": {
object (CustomEmojiPayload )
}
} |
ช่อง |
name |
string
ตัวระบุ ชื่อทรัพยากรของอีโมจิที่กำหนดเองซึ่งเซิร์ฟเวอร์กำหนด รูปแบบ: customEmojis/{customEmoji}
|
uid |
string
เอาต์พุตเท่านั้น คีย์ที่ไม่ซ้ำกันสำหรับแหล่งข้อมูลอีโมจิที่กำหนดเอง
|
emojiName |
string
ไม่บังคับ เปลี่ยนแปลงไม่ได้ ชื่อที่ผู้ใช้ระบุสำหรับอีโมจิที่กำหนดเอง ซึ่งต้องไม่ซ้ำกันภายในองค์กร ต้องระบุเมื่อสร้างอีโมจิที่กำหนดเอง ไม่เช่นนั้นให้แสดงผลเท่านั้น ชื่ออีโมจิต้องขึ้นต้นและลงท้ายด้วยโคลอน ต้องเป็นตัวพิมพ์เล็ก และมีได้เฉพาะอักขระที่เป็นตัวอักษรและตัวเลขคละกัน เครื่องหมายขีดกลาง และเครื่องหมายขีดล่างเท่านั้น ควรใช้ขีดกลางและขีดล่างเพื่อแยกคำ แต่จะใช้ต่อกันไม่ได้ ตัวอย่าง: :valid-emoji-name:
|
temporaryImageUri |
string
เอาต์พุตเท่านั้น URL รูปภาพชั่วคราวสำหรับอีโมจิที่กำหนดเอง ซึ่งใช้งานได้อย่างน้อย 10 นาที โปรดทราบว่าระบบจะไม่ป้อนข้อมูลนี้ในการตอบกลับเมื่อสร้างอีโมจิที่กำหนดเอง
|
payload |
object (CustomEmojiPayload )
ไม่บังคับ อินพุตเท่านั้น ข้อมูลเพย์โหลด ต้องระบุเมื่อสร้างอีโมจิที่กำหนดเอง
|
CustomEmojiPayload
ข้อมูลเพย์โหลดสำหรับอีโมจิที่กำหนดเอง
การแสดง JSON |
{
"fileContent": string,
"filename": string
} |
ช่อง |
fileContent |
string (bytes format)
ต้องระบุ อินพุตเท่านั้น รูปภาพที่ใช้สําหรับอีโมจิที่กําหนดเอง เพย์โหลดต้องมีขนาดไม่เกิน 256 KB และขนาดของรูปภาพต้องเป็นสี่เหลี่ยมจัตุรัสและมีขนาดระหว่าง 64 ถึง 500 พิกเซล ข้อจำกัดเหล่านี้อาจมีการเปลี่ยนแปลง
|
filename |
string
ต้องระบุ อินพุตเท่านั้น ชื่อไฟล์ภาพ นามสกุลไฟล์ที่รองรับ ได้แก่ .png , .jpg , .gif
|
เมธอด |
|
สร้างอีโมจิที่กำหนดเอง |
|
ลบอีโมจิที่กำหนดเอง |
|
แสดงรายละเอียดเกี่ยวกับอีโมจิที่กำหนดเอง |
|
แสดงรายการอีโมจิที่กำหนดเองที่ผู้ใช้ที่ผ่านการตรวจสอบสิทธิ์มองเห็นได้ |
เนื้อหาของหน้าเว็บนี้ได้รับอนุญาตภายใต้ใบอนุญาตที่ต้องระบุที่มาของครีเอทีฟคอมมอนส์ 4.0 และตัวอย่างโค้ดได้รับอนุญาตภายใต้ใบอนุญาต Apache 2.0 เว้นแต่จะระบุไว้เป็นอย่างอื่น โปรดดูรายละเอียดที่นโยบายเว็บไซต์ Google Developers Java เป็นเครื่องหมายการค้าจดทะเบียนของ Oracle และ/หรือบริษัทในเครือ
อัปเดตล่าสุด 2025-07-25 UTC
[null,null,["อัปเดตล่าสุด 2025-07-25 UTC"],[[["\u003cp\u003eThis documentation outlines the \u003ccode\u003eCustomEmoji\u003c/code\u003e resource, representing a custom emoji within Google Chat, including its properties and JSON representation.\u003c/p\u003e\n"],["\u003cp\u003eIt describes the \u003ccode\u003eCustomEmojiPayload\u003c/code\u003e, detailing the data required for creating a custom emoji, specifically focusing on image content and filename.\u003c/p\u003e\n"],["\u003cp\u003eDevelopers can utilize the provided methods to create, delete, retrieve, or list custom emojis using the Google Chat API.\u003c/p\u003e\n"],["\u003cp\u003eThese functionalities are currently part of the Google Workspace Developer Preview Program, granting early access for testing and development purposes.\u003c/p\u003e\n"]]],["Custom emojis, part of the Google Workspace Developer Preview, are defined by a name, unique identifier (`uid`), and user-provided `emojiName` that must be enclosed in colons. A `temporaryImageUri` is provided. The `payload` contains the image's `fileContent` (under 256 KB) and `filename` (.png, .jpg, .gif). Key actions include: creating custom emojis, deleting them, retrieving details, and listing all visible custom emojis. All these actions are performed through the corresponding methods.\n"],null,["# REST Resource: customEmojis\n\n- [Resource: CustomEmoji](#CustomEmoji)\n - [JSON representation](#CustomEmoji.SCHEMA_REPRESENTATION)\n - [CustomEmojiPayload](#CustomEmoji.CustomEmojiPayload)\n - [JSON representation](#CustomEmoji.CustomEmojiPayload.SCHEMA_REPRESENTATION)\n- [Methods](#METHODS_SUMMARY)\n\nResource: CustomEmoji\n---------------------\n\nRepresents a [custom emoji](https://support.google.com/chat/answer/12800149).\n\n| JSON representation |\n|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| ``` { \"name\": string, \"uid\": string, \"emojiName\": string, \"temporaryImageUri\": string, \"payload\": { object (/workspace/chat/api/reference/rest/v1/customEmojis#CustomEmoji.CustomEmojiPayload) } } ``` |\n\n| Fields ||\n|---------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `name` | `string` Identifier. The resource name of the custom emoji, assigned by the server. Format: `customEmojis/{customEmoji}` |\n| `uid` | `string` Output only. Unique key for the custom emoji resource. |\n| `emojiName` | `string` Optional. Immutable. User-provided name for the custom emoji, which is unique within the organization. Required when the custom emoji is created, output only otherwise. Emoji names must start and end with colons, must be lowercase and can only contain alphanumeric characters, hyphens, and underscores. Hyphens and underscores should be used to separate words and cannot be used consecutively. Example: `:valid-emoji-name:` |\n| `temporaryImageUri` | `string` Output only. A temporary image URL for the custom emoji, valid for at least 10 minutes. Note that this is not populated in the response when the custom emoji is created. |\n| `payload` | `object (`[CustomEmojiPayload](/workspace/chat/api/reference/rest/v1/customEmojis#CustomEmoji.CustomEmojiPayload)`)` Optional. Input only. Payload data. Required when the custom emoji is created. |\n\n### CustomEmojiPayload\n\nPayload data for the custom emoji.\n\n| JSON representation |\n|-------------------------------------------------------|\n| ``` { \"fileContent\": string, \"filename\": string } ``` |\n\n| Fields ||\n|---------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `fileContent` | `string (`[bytes](https://developers.google.com/discovery/v1/type-format)` format)` Required. Input only. The image used for the custom emoji. The payload must be under 256 KB and the dimension of the image must be square and between 64 and 500 pixels. The restrictions are subject to change. |\n| `filename` | `string` Required. Input only. The image file name. Supported file extensions: `.png`, `.jpg`, `.gif`. |\n\n| Methods ------- ||\n|-------------------------------------------------------------------------|--------------------------------------------------------|\n| ### [create](/workspace/chat/api/reference/rest/v1/customEmojis/create) | Creates a custom emoji. |\n| ### [delete](/workspace/chat/api/reference/rest/v1/customEmojis/delete) | Deletes a custom emoji. |\n| ### [get](/workspace/chat/api/reference/rest/v1/customEmojis/get) | Returns details about a custom emoji. |\n| ### [list](/workspace/chat/api/reference/rest/v1/customEmojis/list) | Lists custom emojis visible to the authenticated user. |"]]