set_identity_feedback_forwarding_enabled ( $identity, $forwarding_enabled, $opt )

Given an identity (email address or domain), enables or disables whether Amazon SES forwards feedback notifications as email. Feedback forwarding may only be disabled when both complaint and bounce topics are set. For more information about feedback notification, see the Amazon SES Developer Guide.

Access

public

Parameters

Parameter

Type

Required

Description

$identity

string

Required

The identity for which to set feedback notification forwarding. Examples: user@example.com, example.com.

$forwarding_enabled

boolean

Required

Sets whether Amazon SES will forward feedback notifications as email. true specifies that Amazon SES will forward feedback notifications as email, in addition to any Amazon SNS topic publishing otherwise specified. false specifies that Amazon SES will publish feedback notifications only through Amazon SNS. This value can only be set to false when topics are specified for both Bounce and Complaint topic types.

$opt

array

Optional

An associative array of parameters that can have the following keys:

  • curlopts - array - Optional - A set of values to pass directly into curl_setopt(), where the key is a pre-defined CURLOPT_* constant.
  • returnCurlHandle - boolean - Optional - A private toggle specifying that the cURL handle be returned rather than actually completing the request. This toggle is useful for manually managed batch requests.

Returns

Type

Description

CFResponse

A CFResponse object containing a parsed HTTP response.

Examples

Testing Feedback Notification feature of SES

// Instantiate the class
$email = new AmazonSES();

$response = $email->set_identity_feedback_forwarding_enabled('you@example.com', true);

var_dump($response->isOK());

$response = $email->set_identity_notification_topic('you@example.com', 'Bounce');

var_dump($response->isOK());

$response = $email->get_identity_notification_attributes('you@example.com');

var_dump($response->isOK());
Result:
bool(true)
bool(true)
bool(true)

Source

Method defined in services/ses.class.php | Toggle source view (8 lines) | View on GitHub

public function set_identity_feedback_forwarding_enabled($identity, $forwarding_enabled, $opt = null)
{
    if (!$opt) $opt = array();
    $opt['Identity'] = $identity;
    $opt['ForwardingEnabled'] = $forwarding_enabled;
    
    return $this->authenticate('SetIdentityFeedbackForwardingEnabled', $opt);
}

Copyright © 2010–2013 Amazon Web Services, LLC


Feedback