Erstellt ein Google Workspace-Abo. Informationen zur Verwendung dieser Methode finden Sie unter Google Workspace-Abo erstellen.
Für ein Abo für eine Chat-Zielressource können Sie ein Abo als Folgendes erstellen:
Eine Chat-App, die Ereignisse in Projektbereichen abonniert, in denen die App Mitglied ist. Dazu müssen Sie einen Autorisierungsbereich angeben, der mit
chat.appbeginnt, und eine einmalige Administratorgenehmigung einholen. Weitere Informationen finden Sie unter Als Chat-App mit Administratorgenehmigung autorisieren.Entwicklervorschau: Eine Chat-App, die alle Ereignisse in einer Google Workspace-Organisation abonniert. Dazu müssen Sie einen Autorisierungsbereich angeben, der mit
chat.app.allbeginnt, und eine einmalige Administratorgenehmigung einholen. Weitere Informationen finden Sie unter Alle Google Chat-Ereignisse in einer Workspace-Organisation abonnieren .Ein Nutzer, indem Sie einen Autorisierungsbereich angeben, dessen Name nicht
appenthält. Weitere Informationen finden Sie unter Als Chat-Nutzer autorisieren.
HTTP-Anfrage
POST https://workspaceevents.googleapis.com/v1beta/subscriptions
Die URL verwendet die Syntax der gRPC-Transcodierung.
Abfrageparameter
| Parameter | |
|---|---|
validateOnly |
Optional. Wenn auf |
Anfragetext
Der Anfragetext enthält eine Instanz von Subscription.
Antworttext
Wenn der Vorgang erfolgreich abgeschlossen wurde, enthält der Antworttext eine neu erstellte Instanz von Operation.
- Das Feld
metadataenthält ein leeres Array. - Das Feld
responseenthält eine neue Instanz vonSubscription.
Autorisierungsbereiche
Erfordert einen der folgenden OAuth-Bereiche:
https://www.googleapis.com/auth/chat.spaceshttps://www.googleapis.com/auth/chat.spaces.readonlyhttps://www.googleapis.com/auth/chat.messageshttps://www.googleapis.com/auth/chat.messages.readonlyhttps://www.googleapis.com/auth/chat.messages.reactionshttps://www.googleapis.com/auth/chat.messages.reactions.readonlyhttps://www.googleapis.com/auth/chat.membershipshttps://www.googleapis.com/auth/chat.memberships.readonlyhttps://www.googleapis.com/auth/chat.app.membershipshttps://www.googleapis.com/auth/chat.app.memberships.readonlyhttps://www.googleapis.com/auth/chat.app.all.memberships.readonlyhttps://www.googleapis.com/auth/chat.app.messages.readonlyhttps://www.googleapis.com/auth/chat.app.all.messages.readonlyhttps://www.googleapis.com/auth/chat.app.spaceshttps://www.googleapis.com/auth/chat.app.spaces.readonlyhttps://www.googleapis.com/auth/chat.app.all.spaces.readonlyhttps://www.googleapis.com/auth/chat.app.all.users.readstate.readonlyhttps://www.googleapis.com/auth/meetings.space.createdhttps://www.googleapis.com/auth/meetings.space.readonlyhttps://www.googleapis.com/auth/drivehttps://www.googleapis.com/auth/drive.filehttps://www.googleapis.com/auth/drive.metadatahttps://www.googleapis.com/auth/drive.metadata.readonlyhttps://www.googleapis.com/auth/drive.readonly
Weitere Informationen finden Sie im Autorisierungsleitfaden.