30029: Invalid ContentRetention
MESSAGING
ERROR
Twilio returns this error when the ContentRetention value in a Message create request is not valid for the request, or when the request depends on Message Privacy settings that are not enabled and configured for your account. The Messages resource documents retain and discard as supported ContentRetention values.
- The request includes an unsupported or misspelled
ContentRetentionvalue.retainanddiscardas supported values for the Messages resource. - The request uses Message Privacy behavior on an account that is not enabled or configured for Message Redaction. Twilio requires you to configure Message Privacy features on the account before using those controls.
- The request tries to override account-level privacy behavior without the required Message Redaction setup being enabled in Console.
- Update the request so
ContentRetentionuses a supported value. Useretainordiscardbased on the behavior you want for that message. - If Message Redaction is enabled on your account and you need to keep message content for a specific message, set
ContentRetentiontoretain. - If Message Redaction is disabled on your account and you need to redact content for a specific message, set
ContentRetentiontodiscard. - If your use case depends on Message Privacy features, request access to Message Redaction, configure the account for Message Privacy, and enable the appropriate redaction settings in Console before sending the request again.