Method: subscriptions.create

ينشئ هذا الطلب اشتراكًا في Google Workspace. للتعرّف على كيفية استخدام هذه الطريقة، يُرجى الاطّلاع على المقالة إنشاء اشتراك في Google Workspace.

بالنسبة إلى اشتراك في مصدر مستهدف على Chat، يمكنك إنشاء اشتراك على النحو التالي:

طلب HTTP

POST https://workspaceevents.googleapis.com/v1/subscriptions

يستخدم عنوان URL بنية تحويل الترميز إلى gRPC.

معامِلات طلب البحث

المعلمات
validateOnly

boolean

اختياريّ. إذا تم ضبط هذه المعلمة على true، يتم التحقّق من الطلب ومعاينته، ولكن لا يتم إنشاء الاشتراك.

نص الطلب

يحتوي نص الطلب على مثال Subscription.

نص الاستجابة

إذا كانت الاستجابة ناجحة، سيحتوي نصها على مثال جديد تم إنشاؤه من Operation.

  • يحتوي حقل metadata على مصفوفة فارغة.
  • يحتوي حقل response على مثال جديد من Subscription.

نطاقات الأذونات

يجب توفير أحد نطاقات OAuth التالية:

  • 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/chat.app.memberships
  • https://www.googleapis.com/auth/chat.app.memberships.readonly
  • https://www.googleapis.com/auth/chat.app.all.memberships.readonly
  • https://www.googleapis.com/auth/chat.app.messages.readonly
  • https://www.googleapis.com/auth/chat.app.all.messages.readonly
  • https://www.googleapis.com/auth/chat.app.spaces
  • https://www.googleapis.com/auth/chat.app.spaces.readonly
  • https://www.googleapis.com/auth/chat.app.all.spaces.readonly
  • https://www.googleapis.com/auth/chat.app.all.users.readstate.readonly
  • https://www.googleapis.com/auth/meetings.space.created
  • https://www.googleapis.com/auth/meetings.space.readonly
  • https://www.googleapis.com/auth/drive
  • https://www.googleapis.com/auth/drive.file
  • https://www.googleapis.com/auth/drive.metadata
  • https://www.googleapis.com/auth/drive.metadata.readonly
  • https://www.googleapis.com/auth/drive.readonly

لمزيد من المعلومات، يُرجى الاطّلاع على دليل التفويض.