Class: AWS.S3
- Inherits:
-
AWS.Service
- Object
- AWS.Service
- AWS.S3
- Identifier:
- s3
- API Version:
- 2006-03-01
- Defined in:
- (unknown)
Overview
Constructs a service interface object. Each API operation is exposed as a function on service.
Service Description
Sending a Request Using S3
var s3 = new AWS.S3();
s3.abortMultipartUpload(params, function (err, data) {
if (err) console.log(err, err.stack); // an error occurred
else console.log(data); // successful response
});
Locking the API Version
In order to ensure that the S3 object uses this specific API, you can
construct the object by passing the apiVersion
option to the constructor:
var s3 = new AWS.S3({apiVersion: '2006-03-01'});
You can also set the API version globally in AWS.config.apiVersions
using
the s3 service identifier:
AWS.config.apiVersions = {
s3: '2006-03-01',
// other service API versions
};
var s3 = new AWS.S3();
Defined Under Namespace
Classes: ManagedUpload
Waiter Resource States
This service supports a list of resource states that can be polled using the waitFor() method. The resource states are:
bucketExists, bucketNotExists, objectExists, objectNotExists
Constructor Summary collapse
-
new AWS.S3(options = {}) ⇒ Object
constructor
Constructs a service object.
Property Summary collapse
-
endpoint ⇒ AWS.Endpoint
readwrite
An Endpoint object representing the endpoint URL for service requests.
Properties inherited from AWS.Service
Method Summary collapse
-
abortMultipartUpload(params = {}, callback) ⇒ AWS.Request
This operation aborts a multipart upload.
-
completeMultipartUpload(params = {}, callback) ⇒ AWS.Request
Completes a multipart upload by assembling previously uploaded parts.
You first initiate the multipart upload and then upload all parts using the UploadPart operation or the UploadPartCopy operation.
-
copyObject(params = {}, callback) ⇒ AWS.Request
Creates a copy of an object that is already stored in Amazon S3.
Note: You can store individual objects of up to 5 TB in Amazon S3.- createBucket(params, callback) ⇒ AWS.Request
Note: This action creates an Amazon S3 bucket.- createMultipartUpload(params = {}, callback) ⇒ AWS.Request
This action initiates a multipart upload and returns an upload ID.
- createPresignedPost(params, callback) ⇒ map?
Get a pre-signed POST policy to support uploading to S3 directly from an HTML form.
- createSession(params = {}, callback) ⇒ AWS.Request
Creates a session that establishes temporary security credentials to support fast authentication and authorization for the Zonal endpoint API operations on directory buckets.
- deleteBucket(params = {}, callback) ⇒ AWS.Request
Deletes the S3 bucket.
- deleteBucketAnalyticsConfiguration(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- deleteBucketCors(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- deleteBucketEncryption(params = {}, callback) ⇒ AWS.Request
This implementation of the DELETE action resets the default encryption for the bucket as server-side encryption with Amazon S3 managed keys (SSE-S3).
Note:- General purpose buckets - For information about the bucket default encryption feature, see Amazon S3 Bucket Default Encryption in the Amazon S3 User Guide.
- deleteBucketIntelligentTieringConfiguration(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- deleteBucketInventoryConfiguration(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- deleteBucketLifecycle(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- deleteBucketMetricsConfiguration(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- deleteBucketOwnershipControls(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- deleteBucketPolicy(params = {}, callback) ⇒ AWS.Request
Deletes the policy of a specified bucket.
Note: Directory buckets - For directory buckets, you must make requests for this API operation to the Regional endpoint.- deleteBucketReplication(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- deleteBucketTagging(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- deleteBucketWebsite(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- deleteObject(params = {}, callback) ⇒ AWS.Request
Removes an object from a bucket.
- deleteObjects(params = {}, callback) ⇒ AWS.Request
This operation enables you to delete multiple objects from a bucket using a single HTTP request.
- deleteObjectTagging(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- deletePublicAccessBlock(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- getBucketAccelerateConfiguration(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- getBucketAcl(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- getBucketAnalyticsConfiguration(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- getBucketCors(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- getBucketEncryption(params = {}, callback) ⇒ AWS.Request
Returns the default encryption configuration for an Amazon S3 bucket.
- getBucketIntelligentTieringConfiguration(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- getBucketInventoryConfiguration(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- getBucketLifecycle(params = {}, callback) ⇒ AWS.Request
For an updated version of this API, see GetBucketLifecycleConfiguration.
- getBucketLifecycleConfiguration(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- getBucketLocation(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- getBucketLogging(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- getBucketMetricsConfiguration(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- getBucketNotification(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- getBucketNotificationConfiguration(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- getBucketOwnershipControls(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- getBucketPolicy(params = {}, callback) ⇒ AWS.Request
Returns the policy of a specified bucket.
Note: Directory buckets - For directory buckets, you must make requests for this API operation to the Regional endpoint.- getBucketPolicyStatus(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- getBucketReplication(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- getBucketRequestPayment(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- getBucketTagging(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- getBucketVersioning(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- getBucketWebsite(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- getObject(params = {}, callback) ⇒ AWS.Request
Retrieves an object from Amazon S3.
In the
GetObject
request, specify the full key name for the object.General purpose buckets - Both the virtual-hosted-style requests and the path-style requests are supported.
- getObjectAcl(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- getObjectAttributes(params = {}, callback) ⇒ AWS.Request
Retrieves all the metadata from an object without returning the object itself.
- getObjectLegalHold(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- getObjectLockConfiguration(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- getObjectRetention(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- getObjectTagging(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- getObjectTorrent(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- getPublicAccessBlock(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- getSignedUrl(operation, params, callback) ⇒ String?
Get a pre-signed URL for a given operation name.
- getSignedUrlPromise() ⇒ Promise
Returns a 'thenable' promise that will be resolved with a pre-signed URL for a given operation name.
- headBucket(params = {}, callback) ⇒ AWS.Request
You can use this operation to determine if a bucket exists and if you have permission to access it.
- headObject(params = {}, callback) ⇒ AWS.Request
The
HEAD
operation retrieves metadata from an object without returning the object itself.- listBucketAnalyticsConfigurations(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- listBucketIntelligentTieringConfigurations(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- listBucketInventoryConfigurations(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- listBucketMetricsConfigurations(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- listBuckets(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- listDirectoryBuckets(params = {}, callback) ⇒ AWS.Request
Returns a list of all Amazon S3 directory buckets owned by the authenticated sender of the request.
- listMultipartUploads(params = {}, callback) ⇒ AWS.Request
This operation lists in-progress multipart uploads in a bucket.
- listObjects(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- listObjectsV2(params = {}, callback) ⇒ AWS.Request
Returns some or all (up to 1,000) of the objects in a bucket with each request.
- listObjectVersions(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- listParts(params = {}, callback) ⇒ AWS.Request
Lists the parts that have been uploaded for a specific multipart upload.
To use this operation, you must provide the
upload ID
in the request.- populateUriFromAccessPointArn(req) ⇒ void
When user supply an access point ARN in the Bucket parameter, we need to populate the URI according to the ARN.
- putBucketAccelerateConfiguration(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- putBucketAcl(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- putBucketAnalyticsConfiguration(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- putBucketCors(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- putBucketEncryption(params = {}, callback) ⇒ AWS.Request
This operation configures default encryption and Amazon S3 Bucket Keys for an existing bucket.
Note: Directory buckets - For directory buckets, you must make requests for this API operation to the Regional endpoint.- putBucketIntelligentTieringConfiguration(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- putBucketInventoryConfiguration(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- putBucketLifecycle(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- putBucketLifecycleConfiguration(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- putBucketLogging(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- putBucketMetricsConfiguration(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- putBucketNotification(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- putBucketNotificationConfiguration(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- putBucketOwnershipControls(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- putBucketPolicy(params = {}, callback) ⇒ AWS.Request
Applies an Amazon S3 bucket policy to an Amazon S3 bucket.
Note: Directory buckets - For directory buckets, you must make requests for this API operation to the Regional endpoint.- putBucketReplication(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- putBucketRequestPayment(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- putBucketTagging(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- putBucketVersioning(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- putBucketWebsite(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- putObject(params = {}, callback) ⇒ AWS.Request
Adds an object to a bucket.
Note:- Amazon S3 never adds partial objects; if you receive a success response, Amazon S3 added the entire object to the bucket.
- putObjectAcl(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- putObjectLegalHold(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- putObjectLockConfiguration(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- putObjectRetention(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- putObjectTagging(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- putPublicAccessBlock(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- restoreObject(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- selectObjectContent(params = {}, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.- upload(params = {}, [options], [callback]) ⇒ AWS.S3.ManagedUpload
Uploads an arbitrarily sized buffer, blob, or stream, using intelligent concurrent handling of parts if the payload is large enough.
- uploadPart(params = {}, callback) ⇒ AWS.Request
Uploads a part in a multipart upload.
Note: In this operation, you provide new data as a part of an object in your request.- uploadPartCopy(params = {}, callback) ⇒ AWS.Request
Uploads a part by copying data from an existing object as data source.
- validateArnResourceType(req) ⇒ void
Validate resource-type supplied in S3 ARN.
- waitFor(state, params = {}, callback) ⇒ AWS.Request
Waits for a given S3 resource.
- writeGetObjectResponse(params, callback) ⇒ AWS.Request
Note: This operation is not supported by directory buckets.Methods inherited from AWS.Service
makeRequest, makeUnauthenticatedRequest, defineService
Constructor Details
new AWS.S3(options = {}) ⇒ Object
Constructs a service object. This object has one method for each API operation.
Property Details
Method Details
abortMultipartUpload(params = {}, callback) ⇒ AWS.Request
This operation aborts a multipart upload. After a multipart upload is aborted, no additional parts can be uploaded using that upload ID. The storage consumed by any previously uploaded parts will be freed. However, if any part uploads are currently in progress, those part uploads might or might not succeed. As a result, it might be necessary to abort a given multipart upload multiple times in order to completely free all storage consumed by all parts.
To verify that all parts have been removed and prevent getting charged for the part storage, you should call the ListParts API operation and ensure that the parts list is empty.
Note:- Directory buckets - If multipart uploads in a directory bucket are in progress, you can't delete the bucket until all the in-progress multipart uploads are aborted or completed. To delete these in-progress multipart uploads, use the
ListMultipartUploads
operation to list the in-progress multipart uploads in the bucket and use theAbortMultupartUpload
operation to abort all the in-progress multipart uploads. - Directory buckets - For directory buckets, you must make requests for this API operation to the Zonal endpoint. These endpoints support virtual-hosted-style requests in the format
https://bucket_name.s3express-az_id.region.amazonaws.com/key-name
. Path-style requests are not supported. For more information, see Regional and Zonal endpoints in the Amazon S3 User Guide.
- Permissions
-
-
- createBucket(params, callback) ⇒ AWS.Request