Amazon CloudFront
API Reference (API Version 2010-11-01)
Print this pageEmail this pageGo to the ForumsView the PDFShare this page on TwitterShare this page on FacebookBookmark this page on DeliciousSubmit this page to RedditSubmit this page to DiggDid this page help you?  Yes  No   Tell us about it...

DELETE Origin Access Identity

Description

This action deletes a CloudFront origin access identity. You must first disassociate the identity from all distributions (by updating each distribution's configuration to omit the OriginAccessIdentity element). Make sure to wait until each distribution's state is Deployed before deleting the origin access identity.

To delete an identity, you do a DELETE on the 2010-11-01/origin-access-identity/CloudFront/<identity ID> resource.

Requests

Syntax

DELETE /2010-11-01/origin-access-identity/cloudfront/<identity ID> HTTP/1.1
Host: cloudfront.amazonaws.com
If-Match: [value from ETag header in previous GET or PUT response]
Authorization: [AWS authentication string]
Date: [time stamp]
[Other required headers]	

Headers

The following table lists the special request header the action uses in addition to the common request headers all actions use (for more information, see Common REST Headers).

NameDescriptionRequired

If-Match

The value of the ETag header you received from a previous GET or PUT request. For example: E2QWRUHAPOMQZL

Type: String

Yes

Responses

Syntax

204 No Content
x-amz-request-id: [Request ID]

Special Errors

The following table lists the special errors returned in addition to the common errors all actions return (for more information, see Errors).

ErrorDescriptionHTTP Status Code

CloudFrontOriginAccessIdentityInUse

The CloudFront origin access identity is still being used by one or more distributions.

409

InvalidIfMatchVersion

The If-Match version is missing or not valid.

400

NoSuchCloudFrontOriginAccessIdentity

The specified origin access identity does not exist.

404

PreconditionFailed

The precondition given in one or more of the request-header fields evaluated to false.

412

Examples

The following example request deletes the CloudFront origin access identity with ID E74FTE3AJFJ256A.

Sample Request

DELETE /2010-11-01/origin-access-identity/cloudfront/E74FTE3AJFJ256A HTTP 1.1
Host: cloudfront.amazonaws.com
If-Match: E2QWRUHAPOMQZL
Authorization: AWS O39F6A430S6FJNPPGDR2:frJIUN8DYpKDtOLEXAMPLE=
[Other required headers]

Sample Response

204 No Content
x-amz-request-id: request_id