Admin SDK

Managing Groups Settings

When updating and retrieving group settings, an API request requires the authentication and APIs Console key as described in Authorizing requests. Also, this document assumes you have successfully completed the API prerequisites.

Updating settings for a group

To update a group's settings, use the following PUT HTTP request. Include the Authorization header, and, if using OAuth 1.0, an APIs Console key as described in Authorizing requests:

PUT https://www.googleapis.com/groups/v1/groups/group email address

The following Groups Settings API example updates the salesgroup@example.com group settings:

PUT https://www.googleapis.com/groups/v1/groups/salesgroup@example.com

The request body is in the JSON format. The example below shows all possible settings. If updating a subset of these settings, use the HTTP PATCH verb for a partial update. For more information about partial updates, see Performance Tips.

{
 "kind": "groupsSettings#groups",
 "id": "salesgroup@example.com",
 "email": "salesgroup@example.com",
 "name": "Sales Group",
 "description": "This is the sales group",
 "whoCanViewMembership": "ALL_IN_DOMAIN_CAN_VIEW",
 "whoCanInvite": "ALL_MANAGERS_CAN_INVITE",
 "allowExternalMembers": "false",
 "whoCanPostMessage": "ALL_IN_DOMAIN_CAN_POST",
 "allowWebPosting": "true",
 "primaryLanguage": "en",
 "maxMessageBytes": 10240,
 "isArchived": "true",
 "archiveOnly": "false",
 "messageModerationLevel": "MODERATE_NONE",
 "spamModerationLevel": "ALLOW",
 "replyTo": "REPLY_TO_IGNORE",
 "customReplyTo": "sales@example.com",
 "sendMessageDenyNotification": "true",
 "defaultMessageDenyNotificationText": "Your Message has been denied.",
 "showInGroupDirectory": "false",
 "allowGoogleCommunication": "false",
 "membersCanPostAsTheGroup": "false",
 "messageDisplayFont": "DEFAULT_FONT",
 "includeInGlobalAddressList": "false"
}

A successful response returns a 200 HTTP status code. Along with the status code, the response returns the updated group settings. For more information about these settings see the API's Reference.

JSON Response

{
 "kind": "groupsSettings#groups",
 "id": "salesgroup@example.com",
 "email": "salesgroup@example.com",
 "name": "Sales Group",
 "description": "This is the sales group",
 "whoCanViewMembership": "ALL_IN_DOMAIN_CAN_VIEW",
 "whoCanInvite": "ALL_MANAGERS_CAN_INVITE",
 "allowExternalMembers": "false",
 "whoCanPostMessage": "ALL_IN_DOMAIN_CAN_POST",
 "allowWebPosting": "true",
 "primaryLanguage": "en",
 "maxMessageBytes": 10240,
 "isArchived": "true",
 "archiveOnly": "false",
 "messageModerationLevel": "MODERATE_NONE",
 "spamModerationLevel": "ALLOW",
 "replyTo": "REPLY_TO_IGNORE",
 "customReplyTo": "sales@example.com",
 "sendMessageDenyNotification": "true",
 "defaultMessageDenyNotificationText": "Your Message has been denied.",
 "showInGroupDirectory": "false",
 "allowGoogleCommunication": "false",
 "membersCanPostAsTheGroup": "false",
 "messageDisplayFont": "DEFAULT_FONT",
 "includeInGlobalAddressList": "false"
}

Retrieving settings for a group

To retrieve a group's settings, use the following GET HTTP request. Include the Authorization header as described in Authorizing requests.

GET https://www.googleapis.com/groups/v1/groups/group email address

The following example gets the salesgroup@example.com group settings:

GET https://www.googleapis.com/groups/v1/groups/salesgroup@example.com

A successful response returns a 200 HTTP status code. Along with the status code, the response returns the salesgroup@example.com group's settings. For more information about these settings see the API's Reference.

JSON Response

{
 "kind": "groupsSettings#groups",
 "id": "salesgroup@example.com",
 "email": "salesgroup@example.com",
 "name": "Sales Group",
 "description": "This is the sales group",
 "whoCanViewMembership": "ALL_IN_DOMAIN_CAN_VIEW",
 "whoCanInvite": "ALL_MANAGERS_CAN_INVITE",
 "allowExternalMembers": "false",
 "whoCanPostMessage": "ALL_IN_DOMAIN_CAN_POST",
 "allowWebPosting": "true",
 "primaryLanguage": "en",
 "maxMessageBytes": 10240,
 "isArchived": "true",
 "archiveOnly": "false",
 "messageModerationLevel": "MODERATE_NONE",
 "spamModerationLevel": "ALLOW",
 "replyTo": "REPLY_TO_IGNORE",
 "customReplyTo": "sales@example.com",
 "sendMessageDenyNotification": "true",
 "defaultMessageDenyNotificationText": "Your Message has been denied.",
 "showInGroupDirectory": "false",
 "allowGoogleCommunication": "false",
 "membersCanPostAsTheGroup": "false",
 "messageDisplayFont": "DEFAULT_FONT",
 "includeInGlobalAddressList": "false"
}

Authentication required

You need to be signed in with Google+ to do that.

Signing you in...

Google Developers needs your permission to do that.