new_releases بهروزرسانیها :
یادداشتهای انتشار را برای ویژگیهای جدید و بهروزرسانیهای محصول بررسی کنید.
Method: phones.agentMessages.delete
با مجموعهها، منظم بمانید
ذخیره و طبقهبندی محتوا براساس اولویتهای شما.
پیام عاملی را که ارسال شده اما هنوز تحویل داده نشده است باطل می کند.
اگر پلتفرم RBM با موفقیت یک پیام را لغو کند، پیام از صف پیام کاربر حذف می شود و هرگز تحویل داده نمی شود.
این روش فوراً 200 OK را برمیگرداند، چه پیام با موفقیت لغو شده باشد یا نه.
در حالی که پلتفرم RBM در حال تحویل پیام است، احتمال کمی وجود دارد که عامل شروع به ابطال کند. در این موارد نادر، نماینده بلافاصله پس از شروع درخواست ابطال، یک رویداد کاربر DELIVERED برای پیام دریافت می کند.
درخواست HTTP
DELETE https://rcsbusinessmessaging.googleapis.com/v1/{name=phones/*/agentMessages/*}
URL از دستور GRPC Transcoding استفاده می کند.
پارامترهای مسیر
پارامترها |
---|
name | string "phones/{E.164}/agentMessages/{messageId}"، که در آن {E.164} شماره تلفن کاربر در قالب E.164 و {messageId} شناسه اختصاص داده شده توسط نماینده پیام نماینده است که باید لغو شود. به عنوان مثال، با شماره تلفن ایالات متحده +1-222-333-4444 و یک پیام نماینده با شناسه "12345xyz"، نقطه پایانی حاصل می شود https://rcsbusinessmessaging.googleapis.com/v1/phones/+12223334444/agentMessages/12345xyz . |
پارامترهای پرس و جو
پارامترها |
---|
agentId | string مورد نیاز. شناسه منحصر به فرد عامل. |
درخواست بدن
بدنه درخواست باید خالی باشد.
بدن پاسخگو
در صورت موفقیت آمیز بودن، بدنه پاسخ یک شی JSON خالی است.
محدوده مجوز
به محدوده OAuth زیر نیاز دارد:
-
https://www.googleapis.com/auth/rcsbusinessmessaging
برای اطلاعات بیشتر، بهOAuth 2.0 Overview .
جز در مواردی که غیر از این ذکر شده باشد،محتوای این صفحه تحت مجوز Creative Commons Attribution 4.0 License است. نمونه کدها نیز دارای مجوز Apache 2.0 License است. برای اطلاع از جزئیات، به خطمشیهای سایت Google Developers مراجعه کنید. جاوا علامت تجاری ثبتشده Oracle و/یا شرکتهای وابسته به آن است.
تاریخ آخرین بهروزرسانی 2025-07-24 بهوقت ساعت هماهنگ جهانی.
[null,null,["تاریخ آخرین بهروزرسانی 2025-07-24 بهوقت ساعت هماهنگ جهانی."],[[["\u003cp\u003eThis function allows agents to revoke an undelivered message, removing it from the user's message queue.\u003c/p\u003e\n"],["\u003cp\u003eA successful message revocation results in the message being deleted and never delivered to the user, but a 200 OK response is always returned regardless of success.\u003c/p\u003e\n"],["\u003cp\u003eIn rare cases, a message revocation might be initiated while the message is being delivered, possibly leading to the agent receiving a DELIVERED event shortly after.\u003c/p\u003e\n"],["\u003cp\u003eThe revocation is performed via a DELETE request to a specific URL endpoint, which requires the user's phone number in E.164 format and the agent-assigned ID of the message.\u003c/p\u003e\n"],["\u003cp\u003eThe request requires the agent's unique identifier as a query parameter and must use the specified OAuth scope for authorization.\u003c/p\u003e\n"]]],[],null,["# Method: phones.agentMessages.delete\n\nRevokes an agent message that has been sent but not yet delivered.\n\nIf the RBM platform successfully revokes a message, then the message is deleted from the user's message queue and is never delivered.\n\nThis method immediately returns 200 OK, whether or not the message was successfully revoked.\n\nThere is a small chance that the agent may initiate a revocation while the RBM platform is in the process of delivering the message. In these rare cases, the agent receives a DELIVERED user event for the message shortly after initiating the revocation request.\n\n### HTTP request\n\n`DELETE https://rcsbusinessmessaging.googleapis.com/v1/{name=phones/*/agentMessages/*}`\n\nThe URL uses [gRPC Transcoding](https://google.aip.dev/127) syntax.\n\n### Path parameters\n\n| Parameters ||\n|--------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `name` | `string` \"phones/{E.164}/agentMessages/{messageId}\", where {E.164} is the user's phone number in E.164 format and {messageId} is the agent-assigned ID of the agent message that should be revoked. For example, with the US phone number +1-222-333-4444 and an agent message with the ID \"12345xyz\", the resulting endpoint would be \u003chttps://rcsbusinessmessaging.googleapis.com/v1/phones/+12223334444/agentMessages/12345xyz\u003e. |\n\n### Query parameters\n\n| Parameters ||\n|-----------|---------------------------------------------------|\n| `agentId` | `string` Required. The agent's unique identifier. |\n\n### Request body\n\nThe request body must be empty.\n\n### Response body\n\nIf successful, the response body is an empty JSON object.\n\n### Authorization scopes\n\nRequires the following OAuth scope:\n\n- `https://www.googleapis.com/auth/rcsbusinessmessaging`\n\nFor more information, see the [OAuth 2.0 Overview](/identity/protocols/OAuth2)."]]