Method: subscriptions.create
Yêu cầu HTTP
POST https://workspaceevents.googleapis.com/v1/subscriptions
URL sử dụng cú pháp Chuyển mã gRPC.
Tham số truy vấn
Tham số |
validateOnly |
boolean
Không bắt buộc. Nếu bạn đặt thành true , thì sẽ xác thực và xem trước yêu cầu nhưng không tạo gói thuê bao.
|
Nội dung yêu cầu
Nội dung yêu cầu chứa một bản sao của Subscription
.
Nội dung phản hồi
Nếu thành công, nội dung phản hồi sẽ chứa một thực thể mới tạo của Operation
.
- Trường
metadata
chứa một mảng trống. - Trường
response
chứa một thực thể mới của Subscription
.
Phạm vi uỷ quyền
Yêu cầu một trong các phạm vi OAuth sau đây:
https://www.googleapis.com/auth/chat.spaces
https://www.googleapis.com/auth/chat.spaces.readonly
https://www.googleapis.com/auth/chat.messages
https://www.googleapis.com/auth/chat.messages.readonly
https://www.googleapis.com/auth/chat.messages.reactions
https://www.googleapis.com/auth/chat.messages.reactions.readonly
https://www.googleapis.com/auth/chat.memberships
https://www.googleapis.com/auth/chat.memberships.readonly
https://www.googleapis.com/auth/meetings.space.created
https://www.googleapis.com/auth/meetings.space.readonly
Để biết thêm thông tin, hãy xem bài viết Hướng dẫn uỷ quyền.
Trừ phi có lưu ý khác, nội dung của trang này được cấp phép theo Giấy phép ghi nhận tác giả 4.0 của Creative Commons và các mẫu mã lập trình được cấp phép theo Giấy phép Apache 2.0. Để biết thông tin chi tiết, vui lòng tham khảo Chính sách trang web của Google Developers. Java là nhãn hiệu đã đăng ký của Oracle và/hoặc các đơn vị liên kết với Oracle.
Cập nhật lần gần đây nhất: 2024-05-03 UTC.
[null,null,["Cập nhật lần gần đây nhất: 2024-05-03 UTC."],[[["This method creates a Google Workspace subscription and provides instructions on how to use it through a provided link."],["The request can be previewed without creating a subscription by setting the `validateOnly` query parameter to `true`."],["A successful response includes an `Operation` object containing the newly created `Subscription` details."],["Authorization requires one of the listed OAuth scopes, such as `https://www.googleapis.com/auth/chat.spaces` or others related to chat, messages, memberships, and meetings, with more information available in the Authorization guide."]]],["This describes how to create a Google Workspace subscription via a `POST` request to `https://workspaceevents.googleapis.com/v1/subscriptions`. The request includes an instance of `Subscription` in the body. The `validateOnly` query parameter can be used to preview the request. Successful responses contain an `Operation` instance, where `response` field has a new `Subscription`. This process requires one of several listed OAuth scopes for authorization.\n"]]