Skip to main content

account.setGlobalPrivacySettings

Set global privacy settings

func (c *Client) AccountSetGlobalPrivacySettings(ctx context.Context, settings GlobalPrivacySettings) (*GlobalPrivacySettings, error)

Calling this method

client.Run(ctx, func(ctx context.Context) error {
api := client.API()

res, err := api.AccountSetGlobalPrivacySettings(ctx, settings)
if err != nil {
return err
}
_ = res // *GlobalPrivacySettings
return nil
})

Parameters

NameTypeRequiredDescription
SettingsGlobalPrivacySettingsyesGlobal privacy settings

Returns

*GlobalPrivacySettings

Possible errors

CodeTypeDescription
400AUTOARCHIVE_NOT_AVAILABLEThe autoarchive setting is not available at this time: please check the value of the autoarchive_setting_available field in client config » before calling this method.
403BOT_ACCESS_FORBIDDENThe specified method can be used over a business connection for some operations, but the specified query attempted an operation that is not allowed over a business connection.
400BUSINESS_CONNECTION_INVALIDThe connection_id passed to the wrapping invokeWithBusinessConnection call is invalid.
403PREMIUM_ACCOUNT_REQUIREDA premium account is required to execute this action.

References