AWS SDK Version 3 for .NET
API Reference

AWS services or capabilities described in AWS Documentation may vary by region/location. Click Getting Started with Amazon AWS to see specific differences applicable to the China (Beijing) Region.

Container for redirect information. You can redirect requests to another host, to another page, or with another protocol. In the event of an error, you can can specify a different error code to return.

Inheritance Hierarchy


Namespace: Amazon.S3.Model
Assembly: AWSSDK.S3.dll
Version: 3.x.y.z


public class RoutingRuleRedirect

The RoutingRuleRedirect type exposes the following members


Public Method RoutingRuleRedirect()


Public Property HostName System.String

Name of the host where requests will be redirected.

Public Property HttpRedirectCode System.String

The HTTP redirect code to use on the response. Not required if one of the siblings is present.

Public Property Protocol System.String

Protocol to use (http, https) when redirecting requests. The default is the protocol that is used in the original request.

Public Property ReplaceKeyPrefixWith System.String

The object key prefix to use in the redirect request. For example, to redirect requests for all pages with prefix docs/ (objects in the docs/ folder) to documents/, you can set a condition block with KeyPrefixEquals set to docs/ and in the Redirect set ReplaceKeyPrefixWith to /documents. Not required if one of the siblings is present. Can be present only if ReplaceKeyWith is not provided.

Public Property ReplaceKeyWith System.String

The specific object key to use in the redirect request. For example, redirect request to error.html. Not required if one of the sibling is present. Can be present only if ReplaceKeyPrefixWith is not provided.

Version Information

.NET Standard:
Supported in: 1.3

.NET Framework:
Supported in: 4.5, 4.0, 3.5

Portable Class Library:
Supported in: Windows Store Apps
Supported in: Windows Phone 8.1
Supported in: Xamarin Android
Supported in: Xamarin iOS (Unified)
Supported in: Xamarin.Forms

Supported Versions: 4.6 and above
Supported Platforms: Android, iOS, Standalone