1// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT. 2 3package glacier 4 5import ( 6 "fmt" 7 "io" 8 9 "github.com/aws/aws-sdk-go/aws" 10 "github.com/aws/aws-sdk-go/aws/awsutil" 11 "github.com/aws/aws-sdk-go/aws/request" 12 "github.com/aws/aws-sdk-go/private/protocol" 13 "github.com/aws/aws-sdk-go/private/protocol/restjson" 14) 15 16const opAbortMultipartUpload = "AbortMultipartUpload" 17 18// AbortMultipartUploadRequest generates a "aws/request.Request" representing the 19// client's request for the AbortMultipartUpload operation. The "output" return 20// value will be populated with the request's response once the request completes 21// successfully. 22// 23// Use "Send" method on the returned Request to send the API call to the service. 24// the "output" return value is not valid until after Send returns without error. 25// 26// See AbortMultipartUpload for more information on using the AbortMultipartUpload 27// API call, and error handling. 28// 29// This method is useful when you want to inject custom logic or configuration 30// into the SDK's request lifecycle. Such as custom headers, or retry logic. 31// 32// 33// // Example sending a request using the AbortMultipartUploadRequest method. 34// req, resp := client.AbortMultipartUploadRequest(params) 35// 36// err := req.Send() 37// if err == nil { // resp is now filled 38// fmt.Println(resp) 39// } 40func (c *Glacier) AbortMultipartUploadRequest(input *AbortMultipartUploadInput) (req *request.Request, output *AbortMultipartUploadOutput) { 41 op := &request.Operation{ 42 Name: opAbortMultipartUpload, 43 HTTPMethod: "DELETE", 44 HTTPPath: "/{accountId}/vaults/{vaultName}/multipart-uploads/{uploadId}", 45 } 46 47 if input == nil { 48 input = &AbortMultipartUploadInput{} 49 } 50 51 output = &AbortMultipartUploadOutput{} 52 req = c.newRequest(op, input, output) 53 req.Handlers.Unmarshal.Swap(restjson.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 54 return 55} 56 57// AbortMultipartUpload API operation for Amazon Glacier. 58// 59// This operation aborts a multipart upload identified by the upload ID. 60// 61// After the Abort Multipart Upload request succeeds, you cannot upload any 62// more parts to the multipart upload or complete the multipart upload. Aborting 63// a completed upload fails. However, aborting an already-aborted upload will 64// succeed, for a short time. For more information about uploading a part and 65// completing a multipart upload, see UploadMultipartPart and CompleteMultipartUpload. 66// 67// This operation is idempotent. 68// 69// An AWS account has full permission to perform all operations (actions). However, 70// AWS Identity and Access Management (IAM) users don't have any permissions 71// by default. You must grant them explicit permission to perform specific actions. 72// For more information, see Access Control Using AWS Identity and Access Management 73// (IAM) (https://docs.aws.amazon.com/amazonglacier/latest/dev/using-iam-with-amazon-glacier.html). 74// 75// For conceptual information and underlying REST API, see Working with Archives 76// in Amazon S3 Glacier (https://docs.aws.amazon.com/amazonglacier/latest/dev/working-with-archives.html) 77// and Abort Multipart Upload (https://docs.aws.amazon.com/amazonglacier/latest/dev/api-multipart-abort-upload.html) 78// in the Amazon Glacier Developer Guide. 79// 80// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 81// with awserr.Error's Code and Message methods to get detailed information about 82// the error. 83// 84// See the AWS API reference guide for Amazon Glacier's 85// API operation AbortMultipartUpload for usage and error information. 86// 87// Returned Error Types: 88// * ResourceNotFoundException 89// Returned if the specified resource (such as a vault, upload ID, or job ID) 90// doesn't exist. 91// 92// * InvalidParameterValueException 93// Returned if a parameter of the request is incorrectly specified. 94// 95// * MissingParameterValueException 96// Returned if a required header or parameter is missing from the request. 97// 98// * ServiceUnavailableException 99// Returned if the service cannot complete the request. 100// 101func (c *Glacier) AbortMultipartUpload(input *AbortMultipartUploadInput) (*AbortMultipartUploadOutput, error) { 102 req, out := c.AbortMultipartUploadRequest(input) 103 return out, req.Send() 104} 105 106// AbortMultipartUploadWithContext is the same as AbortMultipartUpload with the addition of 107// the ability to pass a context and additional request options. 108// 109// See AbortMultipartUpload for details on how to use this API operation. 110// 111// The context must be non-nil and will be used for request cancellation. If 112// the context is nil a panic will occur. In the future the SDK may create 113// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 114// for more information on using Contexts. 115func (c *Glacier) AbortMultipartUploadWithContext(ctx aws.Context, input *AbortMultipartUploadInput, opts ...request.Option) (*AbortMultipartUploadOutput, error) { 116 req, out := c.AbortMultipartUploadRequest(input) 117 req.SetContext(ctx) 118 req.ApplyOptions(opts...) 119 return out, req.Send() 120} 121 122const opAbortVaultLock = "AbortVaultLock" 123 124// AbortVaultLockRequest generates a "aws/request.Request" representing the 125// client's request for the AbortVaultLock operation. The "output" return 126// value will be populated with the request's response once the request completes 127// successfully. 128// 129// Use "Send" method on the returned Request to send the API call to the service. 130// the "output" return value is not valid until after Send returns without error. 131// 132// See AbortVaultLock for more information on using the AbortVaultLock 133// API call, and error handling. 134// 135// This method is useful when you want to inject custom logic or configuration 136// into the SDK's request lifecycle. Such as custom headers, or retry logic. 137// 138// 139// // Example sending a request using the AbortVaultLockRequest method. 140// req, resp := client.AbortVaultLockRequest(params) 141// 142// err := req.Send() 143// if err == nil { // resp is now filled 144// fmt.Println(resp) 145// } 146func (c *Glacier) AbortVaultLockRequest(input *AbortVaultLockInput) (req *request.Request, output *AbortVaultLockOutput) { 147 op := &request.Operation{ 148 Name: opAbortVaultLock, 149 HTTPMethod: "DELETE", 150 HTTPPath: "/{accountId}/vaults/{vaultName}/lock-policy", 151 } 152 153 if input == nil { 154 input = &AbortVaultLockInput{} 155 } 156 157 output = &AbortVaultLockOutput{} 158 req = c.newRequest(op, input, output) 159 req.Handlers.Unmarshal.Swap(restjson.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 160 return 161} 162 163// AbortVaultLock API operation for Amazon Glacier. 164// 165// This operation aborts the vault locking process if the vault lock is not 166// in the Locked state. If the vault lock is in the Locked state when this operation 167// is requested, the operation returns an AccessDeniedException error. Aborting 168// the vault locking process removes the vault lock policy from the specified 169// vault. 170// 171// A vault lock is put into the InProgress state by calling InitiateVaultLock. 172// A vault lock is put into the Locked state by calling CompleteVaultLock. You 173// can get the state of a vault lock by calling GetVaultLock. For more information 174// about the vault locking process, see Amazon Glacier Vault Lock (https://docs.aws.amazon.com/amazonglacier/latest/dev/vault-lock.html). 175// For more information about vault lock policies, see Amazon Glacier Access 176// Control with Vault Lock Policies (https://docs.aws.amazon.com/amazonglacier/latest/dev/vault-lock-policy.html). 177// 178// This operation is idempotent. You can successfully invoke this operation 179// multiple times, if the vault lock is in the InProgress state or if there 180// is no policy associated with the vault. 181// 182// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 183// with awserr.Error's Code and Message methods to get detailed information about 184// the error. 185// 186// See the AWS API reference guide for Amazon Glacier's 187// API operation AbortVaultLock for usage and error information. 188// 189// Returned Error Types: 190// * ResourceNotFoundException 191// Returned if the specified resource (such as a vault, upload ID, or job ID) 192// doesn't exist. 193// 194// * InvalidParameterValueException 195// Returned if a parameter of the request is incorrectly specified. 196// 197// * MissingParameterValueException 198// Returned if a required header or parameter is missing from the request. 199// 200// * ServiceUnavailableException 201// Returned if the service cannot complete the request. 202// 203func (c *Glacier) AbortVaultLock(input *AbortVaultLockInput) (*AbortVaultLockOutput, error) { 204 req, out := c.AbortVaultLockRequest(input) 205 return out, req.Send() 206} 207 208// AbortVaultLockWithContext is the same as AbortVaultLock with the addition of 209// the ability to pass a context and additional request options. 210// 211// See AbortVaultLock for details on how to use this API operation. 212// 213// The context must be non-nil and will be used for request cancellation. If 214// the context is nil a panic will occur. In the future the SDK may create 215// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 216// for more information on using Contexts. 217func (c *Glacier) AbortVaultLockWithContext(ctx aws.Context, input *AbortVaultLockInput, opts ...request.Option) (*AbortVaultLockOutput, error) { 218 req, out := c.AbortVaultLockRequest(input) 219 req.SetContext(ctx) 220 req.ApplyOptions(opts...) 221 return out, req.Send() 222} 223 224const opAddTagsToVault = "AddTagsToVault" 225 226// AddTagsToVaultRequest generates a "aws/request.Request" representing the 227// client's request for the AddTagsToVault operation. The "output" return 228// value will be populated with the request's response once the request completes 229// successfully. 230// 231// Use "Send" method on the returned Request to send the API call to the service. 232// the "output" return value is not valid until after Send returns without error. 233// 234// See AddTagsToVault for more information on using the AddTagsToVault 235// API call, and error handling. 236// 237// This method is useful when you want to inject custom logic or configuration 238// into the SDK's request lifecycle. Such as custom headers, or retry logic. 239// 240// 241// // Example sending a request using the AddTagsToVaultRequest method. 242// req, resp := client.AddTagsToVaultRequest(params) 243// 244// err := req.Send() 245// if err == nil { // resp is now filled 246// fmt.Println(resp) 247// } 248func (c *Glacier) AddTagsToVaultRequest(input *AddTagsToVaultInput) (req *request.Request, output *AddTagsToVaultOutput) { 249 op := &request.Operation{ 250 Name: opAddTagsToVault, 251 HTTPMethod: "POST", 252 HTTPPath: "/{accountId}/vaults/{vaultName}/tags?operation=add", 253 } 254 255 if input == nil { 256 input = &AddTagsToVaultInput{} 257 } 258 259 output = &AddTagsToVaultOutput{} 260 req = c.newRequest(op, input, output) 261 req.Handlers.Unmarshal.Swap(restjson.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 262 return 263} 264 265// AddTagsToVault API operation for Amazon Glacier. 266// 267// This operation adds the specified tags to a vault. Each tag is composed of 268// a key and a value. Each vault can have up to 10 tags. If your request would 269// cause the tag limit for the vault to be exceeded, the operation throws the 270// LimitExceededException error. If a tag already exists on the vault under 271// a specified key, the existing key value will be overwritten. For more information 272// about tags, see Tagging Amazon S3 Glacier Resources (https://docs.aws.amazon.com/amazonglacier/latest/dev/tagging.html). 273// 274// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 275// with awserr.Error's Code and Message methods to get detailed information about 276// the error. 277// 278// See the AWS API reference guide for Amazon Glacier's 279// API operation AddTagsToVault for usage and error information. 280// 281// Returned Error Types: 282// * InvalidParameterValueException 283// Returned if a parameter of the request is incorrectly specified. 284// 285// * MissingParameterValueException 286// Returned if a required header or parameter is missing from the request. 287// 288// * ResourceNotFoundException 289// Returned if the specified resource (such as a vault, upload ID, or job ID) 290// doesn't exist. 291// 292// * LimitExceededException 293// Returned if the request results in a vault or account limit being exceeded. 294// 295// * ServiceUnavailableException 296// Returned if the service cannot complete the request. 297// 298func (c *Glacier) AddTagsToVault(input *AddTagsToVaultInput) (*AddTagsToVaultOutput, error) { 299 req, out := c.AddTagsToVaultRequest(input) 300 return out, req.Send() 301} 302 303// AddTagsToVaultWithContext is the same as AddTagsToVault with the addition of 304// the ability to pass a context and additional request options. 305// 306// See AddTagsToVault for details on how to use this API operation. 307// 308// The context must be non-nil and will be used for request cancellation. If 309// the context is nil a panic will occur. In the future the SDK may create 310// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 311// for more information on using Contexts. 312func (c *Glacier) AddTagsToVaultWithContext(ctx aws.Context, input *AddTagsToVaultInput, opts ...request.Option) (*AddTagsToVaultOutput, error) { 313 req, out := c.AddTagsToVaultRequest(input) 314 req.SetContext(ctx) 315 req.ApplyOptions(opts...) 316 return out, req.Send() 317} 318 319const opCompleteMultipartUpload = "CompleteMultipartUpload" 320 321// CompleteMultipartUploadRequest generates a "aws/request.Request" representing the 322// client's request for the CompleteMultipartUpload operation. The "output" return 323// value will be populated with the request's response once the request completes 324// successfully. 325// 326// Use "Send" method on the returned Request to send the API call to the service. 327// the "output" return value is not valid until after Send returns without error. 328// 329// See CompleteMultipartUpload for more information on using the CompleteMultipartUpload 330// API call, and error handling. 331// 332// This method is useful when you want to inject custom logic or configuration 333// into the SDK's request lifecycle. Such as custom headers, or retry logic. 334// 335// 336// // Example sending a request using the CompleteMultipartUploadRequest method. 337// req, resp := client.CompleteMultipartUploadRequest(params) 338// 339// err := req.Send() 340// if err == nil { // resp is now filled 341// fmt.Println(resp) 342// } 343func (c *Glacier) CompleteMultipartUploadRequest(input *CompleteMultipartUploadInput) (req *request.Request, output *ArchiveCreationOutput) { 344 op := &request.Operation{ 345 Name: opCompleteMultipartUpload, 346 HTTPMethod: "POST", 347 HTTPPath: "/{accountId}/vaults/{vaultName}/multipart-uploads/{uploadId}", 348 } 349 350 if input == nil { 351 input = &CompleteMultipartUploadInput{} 352 } 353 354 output = &ArchiveCreationOutput{} 355 req = c.newRequest(op, input, output) 356 return 357} 358 359// CompleteMultipartUpload API operation for Amazon Glacier. 360// 361// You call this operation to inform Amazon S3 Glacier (Glacier) that all the 362// archive parts have been uploaded and that Glacier can now assemble the archive 363// from the uploaded parts. After assembling and saving the archive to the vault, 364// Glacier returns the URI path of the newly created archive resource. Using 365// the URI path, you can then access the archive. After you upload an archive, 366// you should save the archive ID returned to retrieve the archive at a later 367// point. You can also get the vault inventory to obtain a list of archive IDs 368// in a vault. For more information, see InitiateJob. 369// 370// In the request, you must include the computed SHA256 tree hash of the entire 371// archive you have uploaded. For information about computing a SHA256 tree 372// hash, see Computing Checksums (https://docs.aws.amazon.com/amazonglacier/latest/dev/checksum-calculations.html). 373// On the server side, Glacier also constructs the SHA256 tree hash of the assembled 374// archive. If the values match, Glacier saves the archive to the vault; otherwise, 375// it returns an error, and the operation fails. The ListParts operation returns 376// a list of parts uploaded for a specific multipart upload. It includes checksum 377// information for each uploaded part that can be used to debug a bad checksum 378// issue. 379// 380// Additionally, Glacier also checks for any missing content ranges when assembling 381// the archive, if missing content ranges are found, Glacier returns an error 382// and the operation fails. 383// 384// Complete Multipart Upload is an idempotent operation. After your first successful 385// complete multipart upload, if you call the operation again within a short 386// period, the operation will succeed and return the same archive ID. This is 387// useful in the event you experience a network issue that causes an aborted 388// connection or receive a 500 server error, in which case you can repeat your 389// Complete Multipart Upload request and get the same archive ID without creating 390// duplicate archives. Note, however, that after the multipart upload completes, 391// you cannot call the List Parts operation and the multipart upload will not 392// appear in List Multipart Uploads response, even if idempotent complete is 393// possible. 394// 395// An AWS account has full permission to perform all operations (actions). However, 396// AWS Identity and Access Management (IAM) users don't have any permissions 397// by default. You must grant them explicit permission to perform specific actions. 398// For more information, see Access Control Using AWS Identity and Access Management 399// (IAM) (https://docs.aws.amazon.com/amazonglacier/latest/dev/using-iam-with-amazon-glacier.html). 400// 401// For conceptual information and underlying REST API, see Uploading Large Archives 402// in Parts (Multipart Upload) (https://docs.aws.amazon.com/amazonglacier/latest/dev/uploading-archive-mpu.html) 403// and Complete Multipart Upload (https://docs.aws.amazon.com/amazonglacier/latest/dev/api-multipart-complete-upload.html) 404// in the Amazon Glacier Developer Guide. 405// 406// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 407// with awserr.Error's Code and Message methods to get detailed information about 408// the error. 409// 410// See the AWS API reference guide for Amazon Glacier's 411// API operation CompleteMultipartUpload for usage and error information. 412// 413// Returned Error Types: 414// * ResourceNotFoundException 415// Returned if the specified resource (such as a vault, upload ID, or job ID) 416// doesn't exist. 417// 418// * InvalidParameterValueException 419// Returned if a parameter of the request is incorrectly specified. 420// 421// * MissingParameterValueException 422// Returned if a required header or parameter is missing from the request. 423// 424// * ServiceUnavailableException 425// Returned if the service cannot complete the request. 426// 427func (c *Glacier) CompleteMultipartUpload(input *CompleteMultipartUploadInput) (*ArchiveCreationOutput, error) { 428 req, out := c.CompleteMultipartUploadRequest(input) 429 return out, req.Send() 430} 431 432// CompleteMultipartUploadWithContext is the same as CompleteMultipartUpload with the addition of 433// the ability to pass a context and additional request options. 434// 435// See CompleteMultipartUpload for details on how to use this API operation. 436// 437// The context must be non-nil and will be used for request cancellation. If 438// the context is nil a panic will occur. In the future the SDK may create 439// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 440// for more information on using Contexts. 441func (c *Glacier) CompleteMultipartUploadWithContext(ctx aws.Context, input *CompleteMultipartUploadInput, opts ...request.Option) (*ArchiveCreationOutput, error) { 442 req, out := c.CompleteMultipartUploadRequest(input) 443 req.SetContext(ctx) 444 req.ApplyOptions(opts...) 445 return out, req.Send() 446} 447 448const opCompleteVaultLock = "CompleteVaultLock" 449 450// CompleteVaultLockRequest generates a "aws/request.Request" representing the 451// client's request for the CompleteVaultLock operation. The "output" return 452// value will be populated with the request's response once the request completes 453// successfully. 454// 455// Use "Send" method on the returned Request to send the API call to the service. 456// the "output" return value is not valid until after Send returns without error. 457// 458// See CompleteVaultLock for more information on using the CompleteVaultLock 459// API call, and error handling. 460// 461// This method is useful when you want to inject custom logic or configuration 462// into the SDK's request lifecycle. Such as custom headers, or retry logic. 463// 464// 465// // Example sending a request using the CompleteVaultLockRequest method. 466// req, resp := client.CompleteVaultLockRequest(params) 467// 468// err := req.Send() 469// if err == nil { // resp is now filled 470// fmt.Println(resp) 471// } 472func (c *Glacier) CompleteVaultLockRequest(input *CompleteVaultLockInput) (req *request.Request, output *CompleteVaultLockOutput) { 473 op := &request.Operation{ 474 Name: opCompleteVaultLock, 475 HTTPMethod: "POST", 476 HTTPPath: "/{accountId}/vaults/{vaultName}/lock-policy/{lockId}", 477 } 478 479 if input == nil { 480 input = &CompleteVaultLockInput{} 481 } 482 483 output = &CompleteVaultLockOutput{} 484 req = c.newRequest(op, input, output) 485 req.Handlers.Unmarshal.Swap(restjson.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 486 return 487} 488 489// CompleteVaultLock API operation for Amazon Glacier. 490// 491// This operation completes the vault locking process by transitioning the vault 492// lock from the InProgress state to the Locked state, which causes the vault 493// lock policy to become unchangeable. A vault lock is put into the InProgress 494// state by calling InitiateVaultLock. You can obtain the state of the vault 495// lock by calling GetVaultLock. For more information about the vault locking 496// process, Amazon Glacier Vault Lock (https://docs.aws.amazon.com/amazonglacier/latest/dev/vault-lock.html). 497// 498// This operation is idempotent. This request is always successful if the vault 499// lock is in the Locked state and the provided lock ID matches the lock ID 500// originally used to lock the vault. 501// 502// If an invalid lock ID is passed in the request when the vault lock is in 503// the Locked state, the operation returns an AccessDeniedException error. If 504// an invalid lock ID is passed in the request when the vault lock is in the 505// InProgress state, the operation throws an InvalidParameter error. 506// 507// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 508// with awserr.Error's Code and Message methods to get detailed information about 509// the error. 510// 511// See the AWS API reference guide for Amazon Glacier's 512// API operation CompleteVaultLock for usage and error information. 513// 514// Returned Error Types: 515// * ResourceNotFoundException 516// Returned if the specified resource (such as a vault, upload ID, or job ID) 517// doesn't exist. 518// 519// * InvalidParameterValueException 520// Returned if a parameter of the request is incorrectly specified. 521// 522// * MissingParameterValueException 523// Returned if a required header or parameter is missing from the request. 524// 525// * ServiceUnavailableException 526// Returned if the service cannot complete the request. 527// 528func (c *Glacier) CompleteVaultLock(input *CompleteVaultLockInput) (*CompleteVaultLockOutput, error) { 529 req, out := c.CompleteVaultLockRequest(input) 530 return out, req.Send() 531} 532 533// CompleteVaultLockWithContext is the same as CompleteVaultLock with the addition of 534// the ability to pass a context and additional request options. 535// 536// See CompleteVaultLock for details on how to use this API operation. 537// 538// The context must be non-nil and will be used for request cancellation. If 539// the context is nil a panic will occur. In the future the SDK may create 540// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 541// for more information on using Contexts. 542func (c *Glacier) CompleteVaultLockWithContext(ctx aws.Context, input *CompleteVaultLockInput, opts ...request.Option) (*CompleteVaultLockOutput, error) { 543 req, out := c.CompleteVaultLockRequest(input) 544 req.SetContext(ctx) 545 req.ApplyOptions(opts...) 546 return out, req.Send() 547} 548 549const opCreateVault = "CreateVault" 550 551// CreateVaultRequest generates a "aws/request.Request" representing the 552// client's request for the CreateVault operation. The "output" return 553// value will be populated with the request's response once the request completes 554// successfully. 555// 556// Use "Send" method on the returned Request to send the API call to the service. 557// the "output" return value is not valid until after Send returns without error. 558// 559// See CreateVault for more information on using the CreateVault 560// API call, and error handling. 561// 562// This method is useful when you want to inject custom logic or configuration 563// into the SDK's request lifecycle. Such as custom headers, or retry logic. 564// 565// 566// // Example sending a request using the CreateVaultRequest method. 567// req, resp := client.CreateVaultRequest(params) 568// 569// err := req.Send() 570// if err == nil { // resp is now filled 571// fmt.Println(resp) 572// } 573func (c *Glacier) CreateVaultRequest(input *CreateVaultInput) (req *request.Request, output *CreateVaultOutput) { 574 op := &request.Operation{ 575 Name: opCreateVault, 576 HTTPMethod: "PUT", 577 HTTPPath: "/{accountId}/vaults/{vaultName}", 578 } 579 580 if input == nil { 581 input = &CreateVaultInput{} 582 } 583 584 output = &CreateVaultOutput{} 585 req = c.newRequest(op, input, output) 586 return 587} 588 589// CreateVault API operation for Amazon Glacier. 590// 591// This operation creates a new vault with the specified name. The name of the 592// vault must be unique within a region for an AWS account. You can create up 593// to 1,000 vaults per account. If you need to create more vaults, contact Amazon 594// S3 Glacier. 595// 596// You must use the following guidelines when naming a vault. 597// 598// * Names can be between 1 and 255 characters long. 599// 600// * Allowed characters are a-z, A-Z, 0-9, '_' (underscore), '-' (hyphen), 601// and '.' (period). 602// 603// This operation is idempotent. 604// 605// An AWS account has full permission to perform all operations (actions). However, 606// AWS Identity and Access Management (IAM) users don't have any permissions 607// by default. You must grant them explicit permission to perform specific actions. 608// For more information, see Access Control Using AWS Identity and Access Management 609// (IAM) (https://docs.aws.amazon.com/amazonglacier/latest/dev/using-iam-with-amazon-glacier.html). 610// 611// For conceptual information and underlying REST API, see Creating a Vault 612// in Amazon Glacier (https://docs.aws.amazon.com/amazonglacier/latest/dev/creating-vaults.html) 613// and Create Vault (https://docs.aws.amazon.com/amazonglacier/latest/dev/api-vault-put.html) 614// in the Amazon Glacier Developer Guide. 615// 616// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 617// with awserr.Error's Code and Message methods to get detailed information about 618// the error. 619// 620// See the AWS API reference guide for Amazon Glacier's 621// API operation CreateVault for usage and error information. 622// 623// Returned Error Types: 624// * InvalidParameterValueException 625// Returned if a parameter of the request is incorrectly specified. 626// 627// * MissingParameterValueException 628// Returned if a required header or parameter is missing from the request. 629// 630// * ServiceUnavailableException 631// Returned if the service cannot complete the request. 632// 633// * LimitExceededException 634// Returned if the request results in a vault or account limit being exceeded. 635// 636func (c *Glacier) CreateVault(input *CreateVaultInput) (*CreateVaultOutput, error) { 637 req, out := c.CreateVaultRequest(input) 638 return out, req.Send() 639} 640 641// CreateVaultWithContext is the same as CreateVault with the addition of 642// the ability to pass a context and additional request options. 643// 644// See CreateVault for details on how to use this API operation. 645// 646// The context must be non-nil and will be used for request cancellation. If 647// the context is nil a panic will occur. In the future the SDK may create 648// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 649// for more information on using Contexts. 650func (c *Glacier) CreateVaultWithContext(ctx aws.Context, input *CreateVaultInput, opts ...request.Option) (*CreateVaultOutput, error) { 651 req, out := c.CreateVaultRequest(input) 652 req.SetContext(ctx) 653 req.ApplyOptions(opts...) 654 return out, req.Send() 655} 656 657const opDeleteArchive = "DeleteArchive" 658 659// DeleteArchiveRequest generates a "aws/request.Request" representing the 660// client's request for the DeleteArchive operation. The "output" return 661// value will be populated with the request's response once the request completes 662// successfully. 663// 664// Use "Send" method on the returned Request to send the API call to the service. 665// the "output" return value is not valid until after Send returns without error. 666// 667// See DeleteArchive for more information on using the DeleteArchive 668// API call, and error handling. 669// 670// This method is useful when you want to inject custom logic or configuration 671// into the SDK's request lifecycle. Such as custom headers, or retry logic. 672// 673// 674// // Example sending a request using the DeleteArchiveRequest method. 675// req, resp := client.DeleteArchiveRequest(params) 676// 677// err := req.Send() 678// if err == nil { // resp is now filled 679// fmt.Println(resp) 680// } 681func (c *Glacier) DeleteArchiveRequest(input *DeleteArchiveInput) (req *request.Request, output *DeleteArchiveOutput) { 682 op := &request.Operation{ 683 Name: opDeleteArchive, 684 HTTPMethod: "DELETE", 685 HTTPPath: "/{accountId}/vaults/{vaultName}/archives/{archiveId}", 686 } 687 688 if input == nil { 689 input = &DeleteArchiveInput{} 690 } 691 692 output = &DeleteArchiveOutput{} 693 req = c.newRequest(op, input, output) 694 req.Handlers.Unmarshal.Swap(restjson.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 695 return 696} 697 698// DeleteArchive API operation for Amazon Glacier. 699// 700// This operation deletes an archive from a vault. Subsequent requests to initiate 701// a retrieval of this archive will fail. Archive retrievals that are in progress 702// for this archive ID may or may not succeed according to the following scenarios: 703// 704// * If the archive retrieval job is actively preparing the data for download 705// when Amazon S3 Glacier receives the delete archive request, the archival 706// retrieval operation might fail. 707// 708// * If the archive retrieval job has successfully prepared the archive for 709// download when Amazon S3 Glacier receives the delete archive request, you 710// will be able to download the output. 711// 712// This operation is idempotent. Attempting to delete an already-deleted archive 713// does not result in an error. 714// 715// An AWS account has full permission to perform all operations (actions). However, 716// AWS Identity and Access Management (IAM) users don't have any permissions 717// by default. You must grant them explicit permission to perform specific actions. 718// For more information, see Access Control Using AWS Identity and Access Management 719// (IAM) (https://docs.aws.amazon.com/amazonglacier/latest/dev/using-iam-with-amazon-glacier.html). 720// 721// For conceptual information and underlying REST API, see Deleting an Archive 722// in Amazon Glacier (https://docs.aws.amazon.com/amazonglacier/latest/dev/deleting-an-archive.html) 723// and Delete Archive (https://docs.aws.amazon.com/amazonglacier/latest/dev/api-archive-delete.html) 724// in the Amazon Glacier Developer Guide. 725// 726// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 727// with awserr.Error's Code and Message methods to get detailed information about 728// the error. 729// 730// See the AWS API reference guide for Amazon Glacier's 731// API operation DeleteArchive for usage and error information. 732// 733// Returned Error Types: 734// * ResourceNotFoundException 735// Returned if the specified resource (such as a vault, upload ID, or job ID) 736// doesn't exist. 737// 738// * InvalidParameterValueException 739// Returned if a parameter of the request is incorrectly specified. 740// 741// * MissingParameterValueException 742// Returned if a required header or parameter is missing from the request. 743// 744// * ServiceUnavailableException 745// Returned if the service cannot complete the request. 746// 747func (c *Glacier) DeleteArchive(input *DeleteArchiveInput) (*DeleteArchiveOutput, error) { 748 req, out := c.DeleteArchiveRequest(input) 749 return out, req.Send() 750} 751 752// DeleteArchiveWithContext is the same as DeleteArchive with the addition of 753// the ability to pass a context and additional request options. 754// 755// See DeleteArchive for details on how to use this API operation. 756// 757// The context must be non-nil and will be used for request cancellation. If 758// the context is nil a panic will occur. In the future the SDK may create 759// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 760// for more information on using Contexts. 761func (c *Glacier) DeleteArchiveWithContext(ctx aws.Context, input *DeleteArchiveInput, opts ...request.Option) (*DeleteArchiveOutput, error) { 762 req, out := c.DeleteArchiveRequest(input) 763 req.SetContext(ctx) 764 req.ApplyOptions(opts...) 765 return out, req.Send() 766} 767 768const opDeleteVault = "DeleteVault" 769 770// DeleteVaultRequest generates a "aws/request.Request" representing the 771// client's request for the DeleteVault operation. The "output" return 772// value will be populated with the request's response once the request completes 773// successfully. 774// 775// Use "Send" method on the returned Request to send the API call to the service. 776// the "output" return value is not valid until after Send returns without error. 777// 778// See DeleteVault for more information on using the DeleteVault 779// API call, and error handling. 780// 781// This method is useful when you want to inject custom logic or configuration 782// into the SDK's request lifecycle. Such as custom headers, or retry logic. 783// 784// 785// // Example sending a request using the DeleteVaultRequest method. 786// req, resp := client.DeleteVaultRequest(params) 787// 788// err := req.Send() 789// if err == nil { // resp is now filled 790// fmt.Println(resp) 791// } 792func (c *Glacier) DeleteVaultRequest(input *DeleteVaultInput) (req *request.Request, output *DeleteVaultOutput) { 793 op := &request.Operation{ 794 Name: opDeleteVault, 795 HTTPMethod: "DELETE", 796 HTTPPath: "/{accountId}/vaults/{vaultName}", 797 } 798 799 if input == nil { 800 input = &DeleteVaultInput{} 801 } 802 803 output = &DeleteVaultOutput{} 804 req = c.newRequest(op, input, output) 805 req.Handlers.Unmarshal.Swap(restjson.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 806 return 807} 808 809// DeleteVault API operation for Amazon Glacier. 810// 811// This operation deletes a vault. Amazon S3 Glacier will delete a vault only 812// if there are no archives in the vault as of the last inventory and there 813// have been no writes to the vault since the last inventory. If either of these 814// conditions is not satisfied, the vault deletion fails (that is, the vault 815// is not removed) and Amazon S3 Glacier returns an error. You can use DescribeVault 816// to return the number of archives in a vault, and you can use Initiate a Job 817// (POST jobs) (https://docs.aws.amazon.com/amazonglacier/latest/dev/api-initiate-job-post.html) 818// to initiate a new inventory retrieval for a vault. The inventory contains 819// the archive IDs you use to delete archives using Delete Archive (DELETE archive) 820// (https://docs.aws.amazon.com/amazonglacier/latest/dev/api-archive-delete.html). 821// 822// This operation is idempotent. 823// 824// An AWS account has full permission to perform all operations (actions). However, 825// AWS Identity and Access Management (IAM) users don't have any permissions 826// by default. You must grant them explicit permission to perform specific actions. 827// For more information, see Access Control Using AWS Identity and Access Management 828// (IAM) (https://docs.aws.amazon.com/amazonglacier/latest/dev/using-iam-with-amazon-glacier.html). 829// 830// For conceptual information and underlying REST API, see Deleting a Vault 831// in Amazon Glacier (https://docs.aws.amazon.com/amazonglacier/latest/dev/deleting-vaults.html) 832// and Delete Vault (https://docs.aws.amazon.com/amazonglacier/latest/dev/api-vault-delete.html) 833// in the Amazon S3 Glacier Developer Guide. 834// 835// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 836// with awserr.Error's Code and Message methods to get detailed information about 837// the error. 838// 839// See the AWS API reference guide for Amazon Glacier's 840// API operation DeleteVault for usage and error information. 841// 842// Returned Error Types: 843// * ResourceNotFoundException 844// Returned if the specified resource (such as a vault, upload ID, or job ID) 845// doesn't exist. 846// 847// * InvalidParameterValueException 848// Returned if a parameter of the request is incorrectly specified. 849// 850// * MissingParameterValueException 851// Returned if a required header or parameter is missing from the request. 852// 853// * ServiceUnavailableException 854// Returned if the service cannot complete the request. 855// 856func (c *Glacier) DeleteVault(input *DeleteVaultInput) (*DeleteVaultOutput, error) { 857 req, out := c.DeleteVaultRequest(input) 858 return out, req.Send() 859} 860 861// DeleteVaultWithContext is the same as DeleteVault with the addition of 862// the ability to pass a context and additional request options. 863// 864// See DeleteVault for details on how to use this API operation. 865// 866// The context must be non-nil and will be used for request cancellation. If 867// the context is nil a panic will occur. In the future the SDK may create 868// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 869// for more information on using Contexts. 870func (c *Glacier) DeleteVaultWithContext(ctx aws.Context, input *DeleteVaultInput, opts ...request.Option) (*DeleteVaultOutput, error) { 871 req, out := c.DeleteVaultRequest(input) 872 req.SetContext(ctx) 873 req.ApplyOptions(opts...) 874 return out, req.Send() 875} 876 877const opDeleteVaultAccessPolicy = "DeleteVaultAccessPolicy" 878 879// DeleteVaultAccessPolicyRequest generates a "aws/request.Request" representing the 880// client's request for the DeleteVaultAccessPolicy operation. The "output" return 881// value will be populated with the request's response once the request completes 882// successfully. 883// 884// Use "Send" method on the returned Request to send the API call to the service. 885// the "output" return value is not valid until after Send returns without error. 886// 887// See DeleteVaultAccessPolicy for more information on using the DeleteVaultAccessPolicy 888// API call, and error handling. 889// 890// This method is useful when you want to inject custom logic or configuration 891// into the SDK's request lifecycle. Such as custom headers, or retry logic. 892// 893// 894// // Example sending a request using the DeleteVaultAccessPolicyRequest method. 895// req, resp := client.DeleteVaultAccessPolicyRequest(params) 896// 897// err := req.Send() 898// if err == nil { // resp is now filled 899// fmt.Println(resp) 900// } 901func (c *Glacier) DeleteVaultAccessPolicyRequest(input *DeleteVaultAccessPolicyInput) (req *request.Request, output *DeleteVaultAccessPolicyOutput) { 902 op := &request.Operation{ 903 Name: opDeleteVaultAccessPolicy, 904 HTTPMethod: "DELETE", 905 HTTPPath: "/{accountId}/vaults/{vaultName}/access-policy", 906 } 907 908 if input == nil { 909 input = &DeleteVaultAccessPolicyInput{} 910 } 911 912 output = &DeleteVaultAccessPolicyOutput{} 913 req = c.newRequest(op, input, output) 914 req.Handlers.Unmarshal.Swap(restjson.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 915 return 916} 917 918// DeleteVaultAccessPolicy API operation for Amazon Glacier. 919// 920// This operation deletes the access policy associated with the specified vault. 921// The operation is eventually consistent; that is, it might take some time 922// for Amazon S3 Glacier to completely remove the access policy, and you might 923// still see the effect of the policy for a short time after you send the delete 924// request. 925// 926// This operation is idempotent. You can invoke delete multiple times, even 927// if there is no policy associated with the vault. For more information about 928// vault access policies, see Amazon Glacier Access Control with Vault Access 929// Policies (https://docs.aws.amazon.com/amazonglacier/latest/dev/vault-access-policy.html). 930// 931// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 932// with awserr.Error's Code and Message methods to get detailed information about 933// the error. 934// 935// See the AWS API reference guide for Amazon Glacier's 936// API operation DeleteVaultAccessPolicy for usage and error information. 937// 938// Returned Error Types: 939// * ResourceNotFoundException 940// Returned if the specified resource (such as a vault, upload ID, or job ID) 941// doesn't exist. 942// 943// * InvalidParameterValueException 944// Returned if a parameter of the request is incorrectly specified. 945// 946// * MissingParameterValueException 947// Returned if a required header or parameter is missing from the request. 948// 949// * ServiceUnavailableException 950// Returned if the service cannot complete the request. 951// 952func (c *Glacier) DeleteVaultAccessPolicy(input *DeleteVaultAccessPolicyInput) (*DeleteVaultAccessPolicyOutput, error) { 953 req, out := c.DeleteVaultAccessPolicyRequest(input) 954 return out, req.Send() 955} 956 957// DeleteVaultAccessPolicyWithContext is the same as DeleteVaultAccessPolicy with the addition of 958// the ability to pass a context and additional request options. 959// 960// See DeleteVaultAccessPolicy for details on how to use this API operation. 961// 962// The context must be non-nil and will be used for request cancellation. If 963// the context is nil a panic will occur. In the future the SDK may create 964// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 965// for more information on using Contexts. 966func (c *Glacier) DeleteVaultAccessPolicyWithContext(ctx aws.Context, input *DeleteVaultAccessPolicyInput, opts ...request.Option) (*DeleteVaultAccessPolicyOutput, error) { 967 req, out := c.DeleteVaultAccessPolicyRequest(input) 968 req.SetContext(ctx) 969 req.ApplyOptions(opts...) 970 return out, req.Send() 971} 972 973const opDeleteVaultNotifications = "DeleteVaultNotifications" 974 975// DeleteVaultNotificationsRequest generates a "aws/request.Request" representing the 976// client's request for the DeleteVaultNotifications operation. The "output" return 977// value will be populated with the request's response once the request completes 978// successfully. 979// 980// Use "Send" method on the returned Request to send the API call to the service. 981// the "output" return value is not valid until after Send returns without error. 982// 983// See DeleteVaultNotifications for more information on using the DeleteVaultNotifications 984// API call, and error handling. 985// 986// This method is useful when you want to inject custom logic or configuration 987// into the SDK's request lifecycle. Such as custom headers, or retry logic. 988// 989// 990// // Example sending a request using the DeleteVaultNotificationsRequest method. 991// req, resp := client.DeleteVaultNotificationsRequest(params) 992// 993// err := req.Send() 994// if err == nil { // resp is now filled 995// fmt.Println(resp) 996// } 997func (c *Glacier) DeleteVaultNotificationsRequest(input *DeleteVaultNotificationsInput) (req *request.Request, output *DeleteVaultNotificationsOutput) { 998 op := &request.Operation{ 999 Name: opDeleteVaultNotifications, 1000 HTTPMethod: "DELETE", 1001 HTTPPath: "/{accountId}/vaults/{vaultName}/notification-configuration", 1002 } 1003 1004 if input == nil { 1005 input = &DeleteVaultNotificationsInput{} 1006 } 1007 1008 output = &DeleteVaultNotificationsOutput{} 1009 req = c.newRequest(op, input, output) 1010 req.Handlers.Unmarshal.Swap(restjson.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 1011 return 1012} 1013 1014// DeleteVaultNotifications API operation for Amazon Glacier. 1015// 1016// This operation deletes the notification configuration set for a vault. The 1017// operation is eventually consistent; that is, it might take some time for 1018// Amazon S3 Glacier to completely disable the notifications and you might still 1019// receive some notifications for a short time after you send the delete request. 1020// 1021// An AWS account has full permission to perform all operations (actions). However, 1022// AWS Identity and Access Management (IAM) users don't have any permissions 1023// by default. You must grant them explicit permission to perform specific actions. 1024// For more information, see Access Control Using AWS Identity and Access Management 1025// (IAM) (https://docs.aws.amazon.com/amazonglacier/latest/dev/using-iam-with-amazon-glacier.html). 1026// 1027// For conceptual information and underlying REST API, see Configuring Vault 1028// Notifications in Amazon S3 Glacier (https://docs.aws.amazon.com/amazonglacier/latest/dev/configuring-notifications.html) 1029// and Delete Vault Notification Configuration (https://docs.aws.amazon.com/amazonglacier/latest/dev/api-vault-notifications-delete.html) 1030// in the Amazon S3 Glacier Developer Guide. 1031// 1032// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1033// with awserr.Error's Code and Message methods to get detailed information about 1034// the error. 1035// 1036// See the AWS API reference guide for Amazon Glacier's 1037// API operation DeleteVaultNotifications for usage and error information. 1038// 1039// Returned Error Types: 1040// * ResourceNotFoundException 1041// Returned if the specified resource (such as a vault, upload ID, or job ID) 1042// doesn't exist. 1043// 1044// * InvalidParameterValueException 1045// Returned if a parameter of the request is incorrectly specified. 1046// 1047// * MissingParameterValueException 1048// Returned if a required header or parameter is missing from the request. 1049// 1050// * ServiceUnavailableException 1051// Returned if the service cannot complete the request. 1052// 1053func (c *Glacier) DeleteVaultNotifications(input *DeleteVaultNotificationsInput) (*DeleteVaultNotificationsOutput, error) { 1054 req, out := c.DeleteVaultNotificationsRequest(input) 1055 return out, req.Send() 1056} 1057 1058// DeleteVaultNotificationsWithContext is the same as DeleteVaultNotifications with the addition of 1059// the ability to pass a context and additional request options. 1060// 1061// See DeleteVaultNotifications for details on how to use this API operation. 1062// 1063// The context must be non-nil and will be used for request cancellation. If 1064// the context is nil a panic will occur. In the future the SDK may create 1065// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1066// for more information on using Contexts. 1067func (c *Glacier) DeleteVaultNotificationsWithContext(ctx aws.Context, input *DeleteVaultNotificationsInput, opts ...request.Option) (*DeleteVaultNotificationsOutput, error) { 1068 req, out := c.DeleteVaultNotificationsRequest(input) 1069 req.SetContext(ctx) 1070 req.ApplyOptions(opts...) 1071 return out, req.Send() 1072} 1073 1074const opDescribeJob = "DescribeJob" 1075 1076// DescribeJobRequest generates a "aws/request.Request" representing the 1077// client's request for the DescribeJob operation. The "output" return 1078// value will be populated with the request's response once the request completes 1079// successfully. 1080// 1081// Use "Send" method on the returned Request to send the API call to the service. 1082// the "output" return value is not valid until after Send returns without error. 1083// 1084// See DescribeJob for more information on using the DescribeJob 1085// API call, and error handling. 1086// 1087// This method is useful when you want to inject custom logic or configuration 1088// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1089// 1090// 1091// // Example sending a request using the DescribeJobRequest method. 1092// req, resp := client.DescribeJobRequest(params) 1093// 1094// err := req.Send() 1095// if err == nil { // resp is now filled 1096// fmt.Println(resp) 1097// } 1098func (c *Glacier) DescribeJobRequest(input *DescribeJobInput) (req *request.Request, output *JobDescription) { 1099 op := &request.Operation{ 1100 Name: opDescribeJob, 1101 HTTPMethod: "GET", 1102 HTTPPath: "/{accountId}/vaults/{vaultName}/jobs/{jobId}", 1103 } 1104 1105 if input == nil { 1106 input = &DescribeJobInput{} 1107 } 1108 1109 output = &JobDescription{} 1110 req = c.newRequest(op, input, output) 1111 return 1112} 1113 1114// DescribeJob API operation for Amazon Glacier. 1115// 1116// This operation returns information about a job you previously initiated, 1117// including the job initiation date, the user who initiated the job, the job 1118// status code/message and the Amazon SNS topic to notify after Amazon S3 Glacier 1119// (Glacier) completes the job. For more information about initiating a job, 1120// see InitiateJob. 1121// 1122// This operation enables you to check the status of your job. However, it is 1123// strongly recommended that you set up an Amazon SNS topic and specify it in 1124// your initiate job request so that Glacier can notify the topic after it completes 1125// the job. 1126// 1127// A job ID will not expire for at least 24 hours after Glacier completes the 1128// job. 1129// 1130// An AWS account has full permission to perform all operations (actions). However, 1131// AWS Identity and Access Management (IAM) users don't have any permissions 1132// by default. You must grant them explicit permission to perform specific actions. 1133// For more information, see Access Control Using AWS Identity and Access Management 1134// (IAM) (https://docs.aws.amazon.com/amazonglacier/latest/dev/using-iam-with-amazon-glacier.html). 1135// 1136// For more information about using this operation, see the documentation for 1137// the underlying REST API Describe Job (https://docs.aws.amazon.com/amazonglacier/latest/dev/api-describe-job-get.html) 1138// in the Amazon Glacier Developer Guide. 1139// 1140// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1141// with awserr.Error's Code and Message methods to get detailed information about 1142// the error. 1143// 1144// See the AWS API reference guide for Amazon Glacier's 1145// API operation DescribeJob for usage and error information. 1146// 1147// Returned Error Types: 1148// * ResourceNotFoundException 1149// Returned if the specified resource (such as a vault, upload ID, or job ID) 1150// doesn't exist. 1151// 1152// * InvalidParameterValueException 1153// Returned if a parameter of the request is incorrectly specified. 1154// 1155// * MissingParameterValueException 1156// Returned if a required header or parameter is missing from the request. 1157// 1158// * ServiceUnavailableException 1159// Returned if the service cannot complete the request. 1160// 1161func (c *Glacier) DescribeJob(input *DescribeJobInput) (*JobDescription, error) { 1162 req, out := c.DescribeJobRequest(input) 1163 return out, req.Send() 1164} 1165 1166// DescribeJobWithContext is the same as DescribeJob with the addition of 1167// the ability to pass a context and additional request options. 1168// 1169// See DescribeJob for details on how to use this API operation. 1170// 1171// The context must be non-nil and will be used for request cancellation. If 1172// the context is nil a panic will occur. In the future the SDK may create 1173// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1174// for more information on using Contexts. 1175func (c *Glacier) DescribeJobWithContext(ctx aws.Context, input *DescribeJobInput, opts ...request.Option) (*JobDescription, error) { 1176 req, out := c.DescribeJobRequest(input) 1177 req.SetContext(ctx) 1178 req.ApplyOptions(opts...) 1179 return out, req.Send() 1180} 1181 1182const opDescribeVault = "DescribeVault" 1183 1184// DescribeVaultRequest generates a "aws/request.Request" representing the 1185// client's request for the DescribeVault operation. The "output" return 1186// value will be populated with the request's response once the request completes 1187// successfully. 1188// 1189// Use "Send" method on the returned Request to send the API call to the service. 1190// the "output" return value is not valid until after Send returns without error. 1191// 1192// See DescribeVault for more information on using the DescribeVault 1193// API call, and error handling. 1194// 1195// This method is useful when you want to inject custom logic or configuration 1196// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1197// 1198// 1199// // Example sending a request using the DescribeVaultRequest method. 1200// req, resp := client.DescribeVaultRequest(params) 1201// 1202// err := req.Send() 1203// if err == nil { // resp is now filled 1204// fmt.Println(resp) 1205// } 1206func (c *Glacier) DescribeVaultRequest(input *DescribeVaultInput) (req *request.Request, output *DescribeVaultOutput) { 1207 op := &request.Operation{ 1208 Name: opDescribeVault, 1209 HTTPMethod: "GET", 1210 HTTPPath: "/{accountId}/vaults/{vaultName}", 1211 } 1212 1213 if input == nil { 1214 input = &DescribeVaultInput{} 1215 } 1216 1217 output = &DescribeVaultOutput{} 1218 req = c.newRequest(op, input, output) 1219 return 1220} 1221 1222// DescribeVault API operation for Amazon Glacier. 1223// 1224// This operation returns information about a vault, including the vault's Amazon 1225// Resource Name (ARN), the date the vault was created, the number of archives 1226// it contains, and the total size of all the archives in the vault. The number 1227// of archives and their total size are as of the last inventory generation. 1228// This means that if you add or remove an archive from a vault, and then immediately 1229// use Describe Vault, the change in contents will not be immediately reflected. 1230// If you want to retrieve the latest inventory of the vault, use InitiateJob. 1231// Amazon S3 Glacier generates vault inventories approximately daily. For more 1232// information, see Downloading a Vault Inventory in Amazon S3 Glacier (https://docs.aws.amazon.com/amazonglacier/latest/dev/vault-inventory.html). 1233// 1234// An AWS account has full permission to perform all operations (actions). However, 1235// AWS Identity and Access Management (IAM) users don't have any permissions 1236// by default. You must grant them explicit permission to perform specific actions. 1237// For more information, see Access Control Using AWS Identity and Access Management 1238// (IAM) (https://docs.aws.amazon.com/amazonglacier/latest/dev/using-iam-with-amazon-glacier.html). 1239// 1240// For conceptual information and underlying REST API, see Retrieving Vault 1241// Metadata in Amazon S3 Glacier (https://docs.aws.amazon.com/amazonglacier/latest/dev/retrieving-vault-info.html) 1242// and Describe Vault (https://docs.aws.amazon.com/amazonglacier/latest/dev/api-vault-get.html) 1243// in the Amazon Glacier Developer Guide. 1244// 1245// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1246// with awserr.Error's Code and Message methods to get detailed information about 1247// the error. 1248// 1249// See the AWS API reference guide for Amazon Glacier's 1250// API operation DescribeVault for usage and error information. 1251// 1252// Returned Error Types: 1253// * ResourceNotFoundException 1254// Returned if the specified resource (such as a vault, upload ID, or job ID) 1255// doesn't exist. 1256// 1257// * InvalidParameterValueException 1258// Returned if a parameter of the request is incorrectly specified. 1259// 1260// * MissingParameterValueException 1261// Returned if a required header or parameter is missing from the request. 1262// 1263// * ServiceUnavailableException 1264// Returned if the service cannot complete the request. 1265// 1266func (c *Glacier) DescribeVault(input *DescribeVaultInput) (*DescribeVaultOutput, error) { 1267 req, out := c.DescribeVaultRequest(input) 1268 return out, req.Send() 1269} 1270 1271// DescribeVaultWithContext is the same as DescribeVault with the addition of 1272// the ability to pass a context and additional request options. 1273// 1274// See DescribeVault for details on how to use this API operation. 1275// 1276// The context must be non-nil and will be used for request cancellation. If 1277// the context is nil a panic will occur. In the future the SDK may create 1278// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1279// for more information on using Contexts. 1280func (c *Glacier) DescribeVaultWithContext(ctx aws.Context, input *DescribeVaultInput, opts ...request.Option) (*DescribeVaultOutput, error) { 1281 req, out := c.DescribeVaultRequest(input) 1282 req.SetContext(ctx) 1283 req.ApplyOptions(opts...) 1284 return out, req.Send() 1285} 1286 1287const opGetDataRetrievalPolicy = "GetDataRetrievalPolicy" 1288 1289// GetDataRetrievalPolicyRequest generates a "aws/request.Request" representing the 1290// client's request for the GetDataRetrievalPolicy operation. The "output" return 1291// value will be populated with the request's response once the request completes 1292// successfully. 1293// 1294// Use "Send" method on the returned Request to send the API call to the service. 1295// the "output" return value is not valid until after Send returns without error. 1296// 1297// See GetDataRetrievalPolicy for more information on using the GetDataRetrievalPolicy 1298// API call, and error handling. 1299// 1300// This method is useful when you want to inject custom logic or configuration 1301// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1302// 1303// 1304// // Example sending a request using the GetDataRetrievalPolicyRequest method. 1305// req, resp := client.GetDataRetrievalPolicyRequest(params) 1306// 1307// err := req.Send() 1308// if err == nil { // resp is now filled 1309// fmt.Println(resp) 1310// } 1311func (c *Glacier) GetDataRetrievalPolicyRequest(input *GetDataRetrievalPolicyInput) (req *request.Request, output *GetDataRetrievalPolicyOutput) { 1312 op := &request.Operation{ 1313 Name: opGetDataRetrievalPolicy, 1314 HTTPMethod: "GET", 1315 HTTPPath: "/{accountId}/policies/data-retrieval", 1316 } 1317 1318 if input == nil { 1319 input = &GetDataRetrievalPolicyInput{} 1320 } 1321 1322 output = &GetDataRetrievalPolicyOutput{} 1323 req = c.newRequest(op, input, output) 1324 return 1325} 1326 1327// GetDataRetrievalPolicy API operation for Amazon Glacier. 1328// 1329// This operation returns the current data retrieval policy for the account 1330// and region specified in the GET request. For more information about data 1331// retrieval policies, see Amazon Glacier Data Retrieval Policies (https://docs.aws.amazon.com/amazonglacier/latest/dev/data-retrieval-policy.html). 1332// 1333// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1334// with awserr.Error's Code and Message methods to get detailed information about 1335// the error. 1336// 1337// See the AWS API reference guide for Amazon Glacier's 1338// API operation GetDataRetrievalPolicy for usage and error information. 1339// 1340// Returned Error Types: 1341// * InvalidParameterValueException 1342// Returned if a parameter of the request is incorrectly specified. 1343// 1344// * MissingParameterValueException 1345// Returned if a required header or parameter is missing from the request. 1346// 1347// * ServiceUnavailableException 1348// Returned if the service cannot complete the request. 1349// 1350func (c *Glacier) GetDataRetrievalPolicy(input *GetDataRetrievalPolicyInput) (*GetDataRetrievalPolicyOutput, error) { 1351 req, out := c.GetDataRetrievalPolicyRequest(input) 1352 return out, req.Send() 1353} 1354 1355// GetDataRetrievalPolicyWithContext is the same as GetDataRetrievalPolicy with the addition of 1356// the ability to pass a context and additional request options. 1357// 1358// See GetDataRetrievalPolicy for details on how to use this API operation. 1359// 1360// The context must be non-nil and will be used for request cancellation. If 1361// the context is nil a panic will occur. In the future the SDK may create 1362// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1363// for more information on using Contexts. 1364func (c *Glacier) GetDataRetrievalPolicyWithContext(ctx aws.Context, input *GetDataRetrievalPolicyInput, opts ...request.Option) (*GetDataRetrievalPolicyOutput, error) { 1365 req, out := c.GetDataRetrievalPolicyRequest(input) 1366 req.SetContext(ctx) 1367 req.ApplyOptions(opts...) 1368 return out, req.Send() 1369} 1370 1371const opGetJobOutput = "GetJobOutput" 1372 1373// GetJobOutputRequest generates a "aws/request.Request" representing the 1374// client's request for the GetJobOutput operation. The "output" return 1375// value will be populated with the request's response once the request completes 1376// successfully. 1377// 1378// Use "Send" method on the returned Request to send the API call to the service. 1379// the "output" return value is not valid until after Send returns without error. 1380// 1381// See GetJobOutput for more information on using the GetJobOutput 1382// API call, and error handling. 1383// 1384// This method is useful when you want to inject custom logic or configuration 1385// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1386// 1387// 1388// // Example sending a request using the GetJobOutputRequest method. 1389// req, resp := client.GetJobOutputRequest(params) 1390// 1391// err := req.Send() 1392// if err == nil { // resp is now filled 1393// fmt.Println(resp) 1394// } 1395func (c *Glacier) GetJobOutputRequest(input *GetJobOutputInput) (req *request.Request, output *GetJobOutputOutput) { 1396 op := &request.Operation{ 1397 Name: opGetJobOutput, 1398 HTTPMethod: "GET", 1399 HTTPPath: "/{accountId}/vaults/{vaultName}/jobs/{jobId}/output", 1400 } 1401 1402 if input == nil { 1403 input = &GetJobOutputInput{} 1404 } 1405 1406 output = &GetJobOutputOutput{} 1407 req = c.newRequest(op, input, output) 1408 return 1409} 1410 1411// GetJobOutput API operation for Amazon Glacier. 1412// 1413// This operation downloads the output of the job you initiated using InitiateJob. 1414// Depending on the job type you specified when you initiated the job, the output 1415// will be either the content of an archive or a vault inventory. 1416// 1417// You can download all the job output or download a portion of the output by 1418// specifying a byte range. In the case of an archive retrieval job, depending 1419// on the byte range you specify, Amazon S3 Glacier (Glacier) returns the checksum 1420// for the portion of the data. You can compute the checksum on the client and 1421// verify that the values match to ensure the portion you downloaded is the 1422// correct data. 1423// 1424// A job ID will not expire for at least 24 hours after Glacier completes the 1425// job. That a byte range. For both archive and inventory retrieval jobs, you 1426// should verify the downloaded size against the size returned in the headers 1427// from the Get Job Output response. 1428// 1429// For archive retrieval jobs, you should also verify that the size is what 1430// you expected. If you download a portion of the output, the expected size 1431// is based on the range of bytes you specified. For example, if you specify 1432// a range of bytes=0-1048575, you should verify your download size is 1,048,576 1433// bytes. If you download an entire archive, the expected size is the size of 1434// the archive when you uploaded it to Amazon S3 Glacier The expected size is 1435// also returned in the headers from the Get Job Output response. 1436// 1437// In the case of an archive retrieval job, depending on the byte range you 1438// specify, Glacier returns the checksum for the portion of the data. To ensure 1439// the portion you downloaded is the correct data, compute the checksum on the 1440// client, verify that the values match, and verify that the size is what you 1441// expected. 1442// 1443// A job ID does not expire for at least 24 hours after Glacier completes the 1444// job. That is, you can download the job output within the 24 hours period 1445// after Amazon Glacier completes the job. 1446// 1447// An AWS account has full permission to perform all operations (actions). However, 1448// AWS Identity and Access Management (IAM) users don't have any permissions 1449// by default. You must grant them explicit permission to perform specific actions. 1450// For more information, see Access Control Using AWS Identity and Access Management 1451// (IAM) (https://docs.aws.amazon.com/amazonglacier/latest/dev/using-iam-with-amazon-glacier.html). 1452// 1453// For conceptual information and the underlying REST API, see Downloading a 1454// Vault Inventory (https://docs.aws.amazon.com/amazonglacier/latest/dev/vault-inventory.html), 1455// Downloading an Archive (https://docs.aws.amazon.com/amazonglacier/latest/dev/downloading-an-archive.html), 1456// and Get Job Output (https://docs.aws.amazon.com/amazonglacier/latest/dev/api-job-output-get.html) 1457// 1458// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1459// with awserr.Error's Code and Message methods to get detailed information about 1460// the error. 1461// 1462// See the AWS API reference guide for Amazon Glacier's 1463// API operation GetJobOutput for usage and error information. 1464// 1465// Returned Error Types: 1466// * ResourceNotFoundException 1467// Returned if the specified resource (such as a vault, upload ID, or job ID) 1468// doesn't exist. 1469// 1470// * InvalidParameterValueException 1471// Returned if a parameter of the request is incorrectly specified. 1472// 1473// * MissingParameterValueException 1474// Returned if a required header or parameter is missing from the request. 1475// 1476// * ServiceUnavailableException 1477// Returned if the service cannot complete the request. 1478// 1479func (c *Glacier) GetJobOutput(input *GetJobOutputInput) (*GetJobOutputOutput, error) { 1480 req, out := c.GetJobOutputRequest(input) 1481 return out, req.Send() 1482} 1483 1484// GetJobOutputWithContext is the same as GetJobOutput with the addition of 1485// the ability to pass a context and additional request options. 1486// 1487// See GetJobOutput for details on how to use this API operation. 1488// 1489// The context must be non-nil and will be used for request cancellation. If 1490// the context is nil a panic will occur. In the future the SDK may create 1491// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1492// for more information on using Contexts. 1493func (c *Glacier) GetJobOutputWithContext(ctx aws.Context, input *GetJobOutputInput, opts ...request.Option) (*GetJobOutputOutput, error) { 1494 req, out := c.GetJobOutputRequest(input) 1495 req.SetContext(ctx) 1496 req.ApplyOptions(opts...) 1497 return out, req.Send() 1498} 1499 1500const opGetVaultAccessPolicy = "GetVaultAccessPolicy" 1501 1502// GetVaultAccessPolicyRequest generates a "aws/request.Request" representing the 1503// client's request for the GetVaultAccessPolicy operation. The "output" return 1504// value will be populated with the request's response once the request completes 1505// successfully. 1506// 1507// Use "Send" method on the returned Request to send the API call to the service. 1508// the "output" return value is not valid until after Send returns without error. 1509// 1510// See GetVaultAccessPolicy for more information on using the GetVaultAccessPolicy 1511// API call, and error handling. 1512// 1513// This method is useful when you want to inject custom logic or configuration 1514// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1515// 1516// 1517// // Example sending a request using the GetVaultAccessPolicyRequest method. 1518// req, resp := client.GetVaultAccessPolicyRequest(params) 1519// 1520// err := req.Send() 1521// if err == nil { // resp is now filled 1522// fmt.Println(resp) 1523// } 1524func (c *Glacier) GetVaultAccessPolicyRequest(input *GetVaultAccessPolicyInput) (req *request.Request, output *GetVaultAccessPolicyOutput) { 1525 op := &request.Operation{ 1526 Name: opGetVaultAccessPolicy, 1527 HTTPMethod: "GET", 1528 HTTPPath: "/{accountId}/vaults/{vaultName}/access-policy", 1529 } 1530 1531 if input == nil { 1532 input = &GetVaultAccessPolicyInput{} 1533 } 1534 1535 output = &GetVaultAccessPolicyOutput{} 1536 req = c.newRequest(op, input, output) 1537 return 1538} 1539 1540// GetVaultAccessPolicy API operation for Amazon Glacier. 1541// 1542// This operation retrieves the access-policy subresource set on the vault; 1543// for more information on setting this subresource, see Set Vault Access Policy 1544// (PUT access-policy) (https://docs.aws.amazon.com/amazonglacier/latest/dev/api-SetVaultAccessPolicy.html). 1545// If there is no access policy set on the vault, the operation returns a 404 1546// Not found error. For more information about vault access policies, see Amazon 1547// Glacier Access Control with Vault Access Policies (https://docs.aws.amazon.com/amazonglacier/latest/dev/vault-access-policy.html). 1548// 1549// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1550// with awserr.Error's Code and Message methods to get detailed information about 1551// the error. 1552// 1553// See the AWS API reference guide for Amazon Glacier's 1554// API operation GetVaultAccessPolicy for usage and error information. 1555// 1556// Returned Error Types: 1557// * ResourceNotFoundException 1558// Returned if the specified resource (such as a vault, upload ID, or job ID) 1559// doesn't exist. 1560// 1561// * InvalidParameterValueException 1562// Returned if a parameter of the request is incorrectly specified. 1563// 1564// * MissingParameterValueException 1565// Returned if a required header or parameter is missing from the request. 1566// 1567// * ServiceUnavailableException 1568// Returned if the service cannot complete the request. 1569// 1570func (c *Glacier) GetVaultAccessPolicy(input *GetVaultAccessPolicyInput) (*GetVaultAccessPolicyOutput, error) { 1571 req, out := c.GetVaultAccessPolicyRequest(input) 1572 return out, req.Send() 1573} 1574 1575// GetVaultAccessPolicyWithContext is the same as GetVaultAccessPolicy with the addition of 1576// the ability to pass a context and additional request options. 1577// 1578// See GetVaultAccessPolicy for details on how to use this API operation. 1579// 1580// The context must be non-nil and will be used for request cancellation. If 1581// the context is nil a panic will occur. In the future the SDK may create 1582// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1583// for more information on using Contexts. 1584func (c *Glacier) GetVaultAccessPolicyWithContext(ctx aws.Context, input *GetVaultAccessPolicyInput, opts ...request.Option) (*GetVaultAccessPolicyOutput, error) { 1585 req, out := c.GetVaultAccessPolicyRequest(input) 1586 req.SetContext(ctx) 1587 req.ApplyOptions(opts...) 1588 return out, req.Send() 1589} 1590 1591const opGetVaultLock = "GetVaultLock" 1592 1593// GetVaultLockRequest generates a "aws/request.Request" representing the 1594// client's request for the GetVaultLock operation. The "output" return 1595// value will be populated with the request's response once the request completes 1596// successfully. 1597// 1598// Use "Send" method on the returned Request to send the API call to the service. 1599// the "output" return value is not valid until after Send returns without error. 1600// 1601// See GetVaultLock for more information on using the GetVaultLock 1602// API call, and error handling. 1603// 1604// This method is useful when you want to inject custom logic or configuration 1605// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1606// 1607// 1608// // Example sending a request using the GetVaultLockRequest method. 1609// req, resp := client.GetVaultLockRequest(params) 1610// 1611// err := req.Send() 1612// if err == nil { // resp is now filled 1613// fmt.Println(resp) 1614// } 1615func (c *Glacier) GetVaultLockRequest(input *GetVaultLockInput) (req *request.Request, output *GetVaultLockOutput) { 1616 op := &request.Operation{ 1617 Name: opGetVaultLock, 1618 HTTPMethod: "GET", 1619 HTTPPath: "/{accountId}/vaults/{vaultName}/lock-policy", 1620 } 1621 1622 if input == nil { 1623 input = &GetVaultLockInput{} 1624 } 1625 1626 output = &GetVaultLockOutput{} 1627 req = c.newRequest(op, input, output) 1628 return 1629} 1630 1631// GetVaultLock API operation for Amazon Glacier. 1632// 1633// This operation retrieves the following attributes from the lock-policy subresource 1634// set on the specified vault: 1635// 1636// * The vault lock policy set on the vault. 1637// 1638// * The state of the vault lock, which is either InProgess or Locked. 1639// 1640// * When the lock ID expires. The lock ID is used to complete the vault 1641// locking process. 1642// 1643// * When the vault lock was initiated and put into the InProgress state. 1644// 1645// A vault lock is put into the InProgress state by calling InitiateVaultLock. 1646// A vault lock is put into the Locked state by calling CompleteVaultLock. You 1647// can abort the vault locking process by calling AbortVaultLock. For more information 1648// about the vault locking process, Amazon Glacier Vault Lock (https://docs.aws.amazon.com/amazonglacier/latest/dev/vault-lock.html). 1649// 1650// If there is no vault lock policy set on the vault, the operation returns 1651// a 404 Not found error. For more information about vault lock policies, Amazon 1652// Glacier Access Control with Vault Lock Policies (https://docs.aws.amazon.com/amazonglacier/latest/dev/vault-lock-policy.html). 1653// 1654// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1655// with awserr.Error's Code and Message methods to get detailed information about 1656// the error. 1657// 1658// See the AWS API reference guide for Amazon Glacier's 1659// API operation GetVaultLock for usage and error information. 1660// 1661// Returned Error Types: 1662// * ResourceNotFoundException 1663// Returned if the specified resource (such as a vault, upload ID, or job ID) 1664// doesn't exist. 1665// 1666// * InvalidParameterValueException 1667// Returned if a parameter of the request is incorrectly specified. 1668// 1669// * MissingParameterValueException 1670// Returned if a required header or parameter is missing from the request. 1671// 1672// * ServiceUnavailableException 1673// Returned if the service cannot complete the request. 1674// 1675func (c *Glacier) GetVaultLock(input *GetVaultLockInput) (*GetVaultLockOutput, error) { 1676 req, out := c.GetVaultLockRequest(input) 1677 return out, req.Send() 1678} 1679 1680// GetVaultLockWithContext is the same as GetVaultLock with the addition of 1681// the ability to pass a context and additional request options. 1682// 1683// See GetVaultLock for details on how to use this API operation. 1684// 1685// The context must be non-nil and will be used for request cancellation. If 1686// the context is nil a panic will occur. In the future the SDK may create 1687// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1688// for more information on using Contexts. 1689func (c *Glacier) GetVaultLockWithContext(ctx aws.Context, input *GetVaultLockInput, opts ...request.Option) (*GetVaultLockOutput, error) { 1690 req, out := c.GetVaultLockRequest(input) 1691 req.SetContext(ctx) 1692 req.ApplyOptions(opts...) 1693 return out, req.Send() 1694} 1695 1696const opGetVaultNotifications = "GetVaultNotifications" 1697 1698// GetVaultNotificationsRequest generates a "aws/request.Request" representing the 1699// client's request for the GetVaultNotifications operation. The "output" return 1700// value will be populated with the request's response once the request completes 1701// successfully. 1702// 1703// Use "Send" method on the returned Request to send the API call to the service. 1704// the "output" return value is not valid until after Send returns without error. 1705// 1706// See GetVaultNotifications for more information on using the GetVaultNotifications 1707// API call, and error handling. 1708// 1709// This method is useful when you want to inject custom logic or configuration 1710// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1711// 1712// 1713// // Example sending a request using the GetVaultNotificationsRequest method. 1714// req, resp := client.GetVaultNotificationsRequest(params) 1715// 1716// err := req.Send() 1717// if err == nil { // resp is now filled 1718// fmt.Println(resp) 1719// } 1720func (c *Glacier) GetVaultNotificationsRequest(input *GetVaultNotificationsInput) (req *request.Request, output *GetVaultNotificationsOutput) { 1721 op := &request.Operation{ 1722 Name: opGetVaultNotifications, 1723 HTTPMethod: "GET", 1724 HTTPPath: "/{accountId}/vaults/{vaultName}/notification-configuration", 1725 } 1726 1727 if input == nil { 1728 input = &GetVaultNotificationsInput{} 1729 } 1730 1731 output = &GetVaultNotificationsOutput{} 1732 req = c.newRequest(op, input, output) 1733 return 1734} 1735 1736// GetVaultNotifications API operation for Amazon Glacier. 1737// 1738// This operation retrieves the notification-configuration subresource of the 1739// specified vault. 1740// 1741// For information about setting a notification configuration on a vault, see 1742// SetVaultNotifications. If a notification configuration for a vault is not 1743// set, the operation returns a 404 Not Found error. For more information about 1744// vault notifications, see Configuring Vault Notifications in Amazon S3 Glacier 1745// (https://docs.aws.amazon.com/amazonglacier/latest/dev/configuring-notifications.html). 1746// 1747// An AWS account has full permission to perform all operations (actions). However, 1748// AWS Identity and Access Management (IAM) users don't have any permissions 1749// by default. You must grant them explicit permission to perform specific actions. 1750// For more information, see Access Control Using AWS Identity and Access Management 1751// (IAM) (https://docs.aws.amazon.com/amazonglacier/latest/dev/using-iam-with-amazon-glacier.html). 1752// 1753// For conceptual information and underlying REST API, see Configuring Vault 1754// Notifications in Amazon S3 Glacier (https://docs.aws.amazon.com/amazonglacier/latest/dev/configuring-notifications.html) 1755// and Get Vault Notification Configuration (https://docs.aws.amazon.com/amazonglacier/latest/dev/api-vault-notifications-get.html) 1756// in the Amazon Glacier Developer Guide. 1757// 1758// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1759// with awserr.Error's Code and Message methods to get detailed information about 1760// the error. 1761// 1762// See the AWS API reference guide for Amazon Glacier's 1763// API operation GetVaultNotifications for usage and error information. 1764// 1765// Returned Error Types: 1766// * ResourceNotFoundException 1767// Returned if the specified resource (such as a vault, upload ID, or job ID) 1768// doesn't exist. 1769// 1770// * InvalidParameterValueException 1771// Returned if a parameter of the request is incorrectly specified. 1772// 1773// * MissingParameterValueException 1774// Returned if a required header or parameter is missing from the request. 1775// 1776// * ServiceUnavailableException 1777// Returned if the service cannot complete the request. 1778// 1779func (c *Glacier) GetVaultNotifications(input *GetVaultNotificationsInput) (*GetVaultNotificationsOutput, error) { 1780 req, out := c.GetVaultNotificationsRequest(input) 1781 return out, req.Send() 1782} 1783 1784// GetVaultNotificationsWithContext is the same as GetVaultNotifications with the addition of 1785// the ability to pass a context and additional request options. 1786// 1787// See GetVaultNotifications for details on how to use this API operation. 1788// 1789// The context must be non-nil and will be used for request cancellation. If 1790// the context is nil a panic will occur. In the future the SDK may create 1791// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1792// for more information on using Contexts. 1793func (c *Glacier) GetVaultNotificationsWithContext(ctx aws.Context, input *GetVaultNotificationsInput, opts ...request.Option) (*GetVaultNotificationsOutput, error) { 1794 req, out := c.GetVaultNotificationsRequest(input) 1795 req.SetContext(ctx) 1796 req.ApplyOptions(opts...) 1797 return out, req.Send() 1798} 1799 1800const opInitiateJob = "InitiateJob" 1801 1802// InitiateJobRequest generates a "aws/request.Request" representing the 1803// client's request for the InitiateJob operation. The "output" return 1804// value will be populated with the request's response once the request completes 1805// successfully. 1806// 1807// Use "Send" method on the returned Request to send the API call to the service. 1808// the "output" return value is not valid until after Send returns without error. 1809// 1810// See InitiateJob for more information on using the InitiateJob 1811// API call, and error handling. 1812// 1813// This method is useful when you want to inject custom logic or configuration 1814// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1815// 1816// 1817// // Example sending a request using the InitiateJobRequest method. 1818// req, resp := client.InitiateJobRequest(params) 1819// 1820// err := req.Send() 1821// if err == nil { // resp is now filled 1822// fmt.Println(resp) 1823// } 1824func (c *Glacier) InitiateJobRequest(input *InitiateJobInput) (req *request.Request, output *InitiateJobOutput) { 1825 op := &request.Operation{ 1826 Name: opInitiateJob, 1827 HTTPMethod: "POST", 1828 HTTPPath: "/{accountId}/vaults/{vaultName}/jobs", 1829 } 1830 1831 if input == nil { 1832 input = &InitiateJobInput{} 1833 } 1834 1835 output = &InitiateJobOutput{} 1836 req = c.newRequest(op, input, output) 1837 return 1838} 1839 1840// InitiateJob API operation for Amazon Glacier. 1841// 1842// This operation initiates a job of the specified type, which can be a select, 1843// an archival retrieval, or a vault retrieval. For more information about using 1844// this operation, see the documentation for the underlying REST API Initiate 1845// a Job (https://docs.aws.amazon.com/amazonglacier/latest/dev/api-initiate-job-post.html). 1846// 1847// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1848// with awserr.Error's Code and Message methods to get detailed information about 1849// the error. 1850// 1851// See the AWS API reference guide for Amazon Glacier's 1852// API operation InitiateJob for usage and error information. 1853// 1854// Returned Error Types: 1855// * ResourceNotFoundException 1856// Returned if the specified resource (such as a vault, upload ID, or job ID) 1857// doesn't exist. 1858// 1859// * PolicyEnforcedException 1860// Returned if a retrieval job would exceed the current data policy's retrieval 1861// rate limit. For more information about data retrieval policies, 1862// 1863// * InvalidParameterValueException 1864// Returned if a parameter of the request is incorrectly specified. 1865// 1866// * MissingParameterValueException 1867// Returned if a required header or parameter is missing from the request. 1868// 1869// * InsufficientCapacityException 1870// Returned if there is insufficient capacity to process this expedited request. 1871// This error only applies to expedited retrievals and not to standard or bulk 1872// retrievals. 1873// 1874// * ServiceUnavailableException 1875// Returned if the service cannot complete the request. 1876// 1877func (c *Glacier) InitiateJob(input *InitiateJobInput) (*InitiateJobOutput, error) { 1878 req, out := c.InitiateJobRequest(input) 1879 return out, req.Send() 1880} 1881 1882// InitiateJobWithContext is the same as InitiateJob with the addition of 1883// the ability to pass a context and additional request options. 1884// 1885// See InitiateJob for details on how to use this API operation. 1886// 1887// The context must be non-nil and will be used for request cancellation. If 1888// the context is nil a panic will occur. In the future the SDK may create 1889// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1890// for more information on using Contexts. 1891func (c *Glacier) InitiateJobWithContext(ctx aws.Context, input *InitiateJobInput, opts ...request.Option) (*InitiateJobOutput, error) { 1892 req, out := c.InitiateJobRequest(input) 1893 req.SetContext(ctx) 1894 req.ApplyOptions(opts...) 1895 return out, req.Send() 1896} 1897 1898const opInitiateMultipartUpload = "InitiateMultipartUpload" 1899 1900// InitiateMultipartUploadRequest generates a "aws/request.Request" representing the 1901// client's request for the InitiateMultipartUpload operation. The "output" return 1902// value will be populated with the request's response once the request completes 1903// successfully. 1904// 1905// Use "Send" method on the returned Request to send the API call to the service. 1906// the "output" return value is not valid until after Send returns without error. 1907// 1908// See InitiateMultipartUpload for more information on using the InitiateMultipartUpload 1909// API call, and error handling. 1910// 1911// This method is useful when you want to inject custom logic or configuration 1912// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1913// 1914// 1915// // Example sending a request using the InitiateMultipartUploadRequest method. 1916// req, resp := client.InitiateMultipartUploadRequest(params) 1917// 1918// err := req.Send() 1919// if err == nil { // resp is now filled 1920// fmt.Println(resp) 1921// } 1922func (c *Glacier) InitiateMultipartUploadRequest(input *InitiateMultipartUploadInput) (req *request.Request, output *InitiateMultipartUploadOutput) { 1923 op := &request.Operation{ 1924 Name: opInitiateMultipartUpload, 1925 HTTPMethod: "POST", 1926 HTTPPath: "/{accountId}/vaults/{vaultName}/multipart-uploads", 1927 } 1928 1929 if input == nil { 1930 input = &InitiateMultipartUploadInput{} 1931 } 1932 1933 output = &InitiateMultipartUploadOutput{} 1934 req = c.newRequest(op, input, output) 1935 return 1936} 1937 1938// InitiateMultipartUpload API operation for Amazon Glacier. 1939// 1940// This operation initiates a multipart upload. Amazon S3 Glacier creates a 1941// multipart upload resource and returns its ID in the response. The multipart 1942// upload ID is used in subsequent requests to upload parts of an archive (see 1943// UploadMultipartPart). 1944// 1945// When you initiate a multipart upload, you specify the part size in number 1946// of bytes. The part size must be a megabyte (1024 KB) multiplied by a power 1947// of 2-for example, 1048576 (1 MB), 2097152 (2 MB), 4194304 (4 MB), 8388608 1948// (8 MB), and so on. The minimum allowable part size is 1 MB, and the maximum 1949// is 4 GB. 1950// 1951// Every part you upload to this resource (see UploadMultipartPart), except 1952// the last one, must have the same size. The last one can be the same size 1953// or smaller. For example, suppose you want to upload a 16.2 MB file. If you 1954// initiate the multipart upload with a part size of 4 MB, you will upload four 1955// parts of 4 MB each and one part of 0.2 MB. 1956// 1957// You don't need to know the size of the archive when you start a multipart 1958// upload because Amazon S3 Glacier does not require you to specify the overall 1959// archive size. 1960// 1961// After you complete the multipart upload, Amazon S3 Glacier (Glacier) removes 1962// the multipart upload resource referenced by the ID. Glacier also removes 1963// the multipart upload resource if you cancel the multipart upload or it may 1964// be removed if there is no activity for a period of 24 hours. 1965// 1966// An AWS account has full permission to perform all operations (actions). However, 1967// AWS Identity and Access Management (IAM) users don't have any permissions 1968// by default. You must grant them explicit permission to perform specific actions. 1969// For more information, see Access Control Using AWS Identity and Access Management 1970// (IAM) (https://docs.aws.amazon.com/amazonglacier/latest/dev/using-iam-with-amazon-glacier.html). 1971// 1972// For conceptual information and underlying REST API, see Uploading Large Archives 1973// in Parts (Multipart Upload) (https://docs.aws.amazon.com/amazonglacier/latest/dev/uploading-archive-mpu.html) 1974// and Initiate Multipart Upload (https://docs.aws.amazon.com/amazonglacier/latest/dev/api-multipart-initiate-upload.html) 1975// in the Amazon Glacier Developer Guide. 1976// 1977// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1978// with awserr.Error's Code and Message methods to get detailed information about 1979// the error. 1980// 1981// See the AWS API reference guide for Amazon Glacier's 1982// API operation InitiateMultipartUpload for usage and error information. 1983// 1984// Returned Error Types: 1985// * ResourceNotFoundException 1986// Returned if the specified resource (such as a vault, upload ID, or job ID) 1987// doesn't exist. 1988// 1989// * InvalidParameterValueException 1990// Returned if a parameter of the request is incorrectly specified. 1991// 1992// * MissingParameterValueException 1993// Returned if a required header or parameter is missing from the request. 1994// 1995// * ServiceUnavailableException 1996// Returned if the service cannot complete the request. 1997// 1998func (c *Glacier) InitiateMultipartUpload(input *InitiateMultipartUploadInput) (*InitiateMultipartUploadOutput, error) { 1999 req, out := c.InitiateMultipartUploadRequest(input) 2000 return out, req.Send() 2001} 2002 2003// InitiateMultipartUploadWithContext is the same as InitiateMultipartUpload with the addition of 2004// the ability to pass a context and additional request options. 2005// 2006// See InitiateMultipartUpload for details on how to use this API operation. 2007// 2008// The context must be non-nil and will be used for request cancellation. If 2009// the context is nil a panic will occur. In the future the SDK may create 2010// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2011// for more information on using Contexts. 2012func (c *Glacier) InitiateMultipartUploadWithContext(ctx aws.Context, input *InitiateMultipartUploadInput, opts ...request.Option) (*InitiateMultipartUploadOutput, error) { 2013 req, out := c.InitiateMultipartUploadRequest(input) 2014 req.SetContext(ctx) 2015 req.ApplyOptions(opts...) 2016 return out, req.Send() 2017} 2018 2019const opInitiateVaultLock = "InitiateVaultLock" 2020 2021// InitiateVaultLockRequest generates a "aws/request.Request" representing the 2022// client's request for the InitiateVaultLock operation. The "output" return 2023// value will be populated with the request's response once the request completes 2024// successfully. 2025// 2026// Use "Send" method on the returned Request to send the API call to the service. 2027// the "output" return value is not valid until after Send returns without error. 2028// 2029// See InitiateVaultLock for more information on using the InitiateVaultLock 2030// API call, and error handling. 2031// 2032// This method is useful when you want to inject custom logic or configuration 2033// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2034// 2035// 2036// // Example sending a request using the InitiateVaultLockRequest method. 2037// req, resp := client.InitiateVaultLockRequest(params) 2038// 2039// err := req.Send() 2040// if err == nil { // resp is now filled 2041// fmt.Println(resp) 2042// } 2043func (c *Glacier) InitiateVaultLockRequest(input *InitiateVaultLockInput) (req *request.Request, output *InitiateVaultLockOutput) { 2044 op := &request.Operation{ 2045 Name: opInitiateVaultLock, 2046 HTTPMethod: "POST", 2047 HTTPPath: "/{accountId}/vaults/{vaultName}/lock-policy", 2048 } 2049 2050 if input == nil { 2051 input = &InitiateVaultLockInput{} 2052 } 2053 2054 output = &InitiateVaultLockOutput{} 2055 req = c.newRequest(op, input, output) 2056 return 2057} 2058 2059// InitiateVaultLock API operation for Amazon Glacier. 2060// 2061// This operation initiates the vault locking process by doing the following: 2062// 2063// * Installing a vault lock policy on the specified vault. 2064// 2065// * Setting the lock state of vault lock to InProgress. 2066// 2067// * Returning a lock ID, which is used to complete the vault locking process. 2068// 2069// You can set one vault lock policy for each vault and this policy can be up 2070// to 20 KB in size. For more information about vault lock policies, see Amazon 2071// Glacier Access Control with Vault Lock Policies (https://docs.aws.amazon.com/amazonglacier/latest/dev/vault-lock-policy.html). 2072// 2073// You must complete the vault locking process within 24 hours after the vault 2074// lock enters the InProgress state. After the 24 hour window ends, the lock 2075// ID expires, the vault automatically exits the InProgress state, and the vault 2076// lock policy is removed from the vault. You call CompleteVaultLock to complete 2077// the vault locking process by setting the state of the vault lock to Locked. 2078// 2079// After a vault lock is in the Locked state, you cannot initiate a new vault 2080// lock for the vault. 2081// 2082// You can abort the vault locking process by calling AbortVaultLock. You can 2083// get the state of the vault lock by calling GetVaultLock. For more information 2084// about the vault locking process, Amazon Glacier Vault Lock (https://docs.aws.amazon.com/amazonglacier/latest/dev/vault-lock.html). 2085// 2086// If this operation is called when the vault lock is in the InProgress state, 2087// the operation returns an AccessDeniedException error. When the vault lock 2088// is in the InProgress state you must call AbortVaultLock before you can initiate 2089// a new vault lock policy. 2090// 2091// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2092// with awserr.Error's Code and Message methods to get detailed information about 2093// the error. 2094// 2095// See the AWS API reference guide for Amazon Glacier's 2096// API operation InitiateVaultLock for usage and error information. 2097// 2098// Returned Error Types: 2099// * ResourceNotFoundException 2100// Returned if the specified resource (such as a vault, upload ID, or job ID) 2101// doesn't exist. 2102// 2103// * InvalidParameterValueException 2104// Returned if a parameter of the request is incorrectly specified. 2105// 2106// * MissingParameterValueException 2107// Returned if a required header or parameter is missing from the request. 2108// 2109// * ServiceUnavailableException 2110// Returned if the service cannot complete the request. 2111// 2112func (c *Glacier) InitiateVaultLock(input *InitiateVaultLockInput) (*InitiateVaultLockOutput, error) { 2113 req, out := c.InitiateVaultLockRequest(input) 2114 return out, req.Send() 2115} 2116 2117// InitiateVaultLockWithContext is the same as InitiateVaultLock with the addition of 2118// the ability to pass a context and additional request options. 2119// 2120// See InitiateVaultLock for details on how to use this API operation. 2121// 2122// The context must be non-nil and will be used for request cancellation. If 2123// the context is nil a panic will occur. In the future the SDK may create 2124// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2125// for more information on using Contexts. 2126func (c *Glacier) InitiateVaultLockWithContext(ctx aws.Context, input *InitiateVaultLockInput, opts ...request.Option) (*InitiateVaultLockOutput, error) { 2127 req, out := c.InitiateVaultLockRequest(input) 2128 req.SetContext(ctx) 2129 req.ApplyOptions(opts...) 2130 return out, req.Send() 2131} 2132 2133const opListJobs = "ListJobs" 2134 2135// ListJobsRequest generates a "aws/request.Request" representing the 2136// client's request for the ListJobs operation. The "output" return 2137// value will be populated with the request's response once the request completes 2138// successfully. 2139// 2140// Use "Send" method on the returned Request to send the API call to the service. 2141// the "output" return value is not valid until after Send returns without error. 2142// 2143// See ListJobs for more information on using the ListJobs 2144// API call, and error handling. 2145// 2146// This method is useful when you want to inject custom logic or configuration 2147// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2148// 2149// 2150// // Example sending a request using the ListJobsRequest method. 2151// req, resp := client.ListJobsRequest(params) 2152// 2153// err := req.Send() 2154// if err == nil { // resp is now filled 2155// fmt.Println(resp) 2156// } 2157func (c *Glacier) ListJobsRequest(input *ListJobsInput) (req *request.Request, output *ListJobsOutput) { 2158 op := &request.Operation{ 2159 Name: opListJobs, 2160 HTTPMethod: "GET", 2161 HTTPPath: "/{accountId}/vaults/{vaultName}/jobs", 2162 Paginator: &request.Paginator{ 2163 InputTokens: []string{"marker"}, 2164 OutputTokens: []string{"Marker"}, 2165 LimitToken: "limit", 2166 TruncationToken: "", 2167 }, 2168 } 2169 2170 if input == nil { 2171 input = &ListJobsInput{} 2172 } 2173 2174 output = &ListJobsOutput{} 2175 req = c.newRequest(op, input, output) 2176 return 2177} 2178 2179// ListJobs API operation for Amazon Glacier. 2180// 2181// This operation lists jobs for a vault, including jobs that are in-progress 2182// and jobs that have recently finished. The List Job operation returns a list 2183// of these jobs sorted by job initiation time. 2184// 2185// Amazon Glacier retains recently completed jobs for a period before deleting 2186// them; however, it eventually removes completed jobs. The output of completed 2187// jobs can be retrieved. Retaining completed jobs for a period of time after 2188// they have completed enables you to get a job output in the event you miss 2189// the job completion notification or your first attempt to download it fails. 2190// For example, suppose you start an archive retrieval job to download an archive. 2191// After the job completes, you start to download the archive but encounter 2192// a network error. In this scenario, you can retry and download the archive 2193// while the job exists. 2194// 2195// The List Jobs operation supports pagination. You should always check the 2196// response Marker field. If there are no more jobs to list, the Marker field 2197// is set to null. If there are more jobs to list, the Marker field is set to 2198// a non-null value, which you can use to continue the pagination of the list. 2199// To return a list of jobs that begins at a specific job, set the marker request 2200// parameter to the Marker value for that job that you obtained from a previous 2201// List Jobs request. 2202// 2203// You can set a maximum limit for the number of jobs returned in the response 2204// by specifying the limit parameter in the request. The default limit is 50. 2205// The number of jobs returned might be fewer than the limit, but the number 2206// of returned jobs never exceeds the limit. 2207// 2208// Additionally, you can filter the jobs list returned by specifying the optional 2209// statuscode parameter or completed parameter, or both. Using the statuscode 2210// parameter, you can specify to return only jobs that match either the InProgress, 2211// Succeeded, or Failed status. Using the completed parameter, you can specify 2212// to return only jobs that were completed (true) or jobs that were not completed 2213// (false). 2214// 2215// For more information about using this operation, see the documentation for 2216// the underlying REST API List Jobs (https://docs.aws.amazon.com/amazonglacier/latest/dev/api-jobs-get.html). 2217// 2218// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2219// with awserr.Error's Code and Message methods to get detailed information about 2220// the error. 2221// 2222// See the AWS API reference guide for Amazon Glacier's 2223// API operation ListJobs for usage and error information. 2224// 2225// Returned Error Types: 2226// * ResourceNotFoundException 2227// Returned if the specified resource (such as a vault, upload ID, or job ID) 2228// doesn't exist. 2229// 2230// * InvalidParameterValueException 2231// Returned if a parameter of the request is incorrectly specified. 2232// 2233// * MissingParameterValueException 2234// Returned if a required header or parameter is missing from the request. 2235// 2236// * ServiceUnavailableException 2237// Returned if the service cannot complete the request. 2238// 2239func (c *Glacier) ListJobs(input *ListJobsInput) (*ListJobsOutput, error) { 2240 req, out := c.ListJobsRequest(input) 2241 return out, req.Send() 2242} 2243 2244// ListJobsWithContext is the same as ListJobs with the addition of 2245// the ability to pass a context and additional request options. 2246// 2247// See ListJobs for details on how to use this API operation. 2248// 2249// The context must be non-nil and will be used for request cancellation. If 2250// the context is nil a panic will occur. In the future the SDK may create 2251// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2252// for more information on using Contexts. 2253func (c *Glacier) ListJobsWithContext(ctx aws.Context, input *ListJobsInput, opts ...request.Option) (*ListJobsOutput, error) { 2254 req, out := c.ListJobsRequest(input) 2255 req.SetContext(ctx) 2256 req.ApplyOptions(opts...) 2257 return out, req.Send() 2258} 2259 2260// ListJobsPages iterates over the pages of a ListJobs operation, 2261// calling the "fn" function with the response data for each page. To stop 2262// iterating, return false from the fn function. 2263// 2264// See ListJobs method for more information on how to use this operation. 2265// 2266// Note: This operation can generate multiple requests to a service. 2267// 2268// // Example iterating over at most 3 pages of a ListJobs operation. 2269// pageNum := 0 2270// err := client.ListJobsPages(params, 2271// func(page *glacier.ListJobsOutput, lastPage bool) bool { 2272// pageNum++ 2273// fmt.Println(page) 2274// return pageNum <= 3 2275// }) 2276// 2277func (c *Glacier) ListJobsPages(input *ListJobsInput, fn func(*ListJobsOutput, bool) bool) error { 2278 return c.ListJobsPagesWithContext(aws.BackgroundContext(), input, fn) 2279} 2280 2281// ListJobsPagesWithContext same as ListJobsPages except 2282// it takes a Context and allows setting request options on the pages. 2283// 2284// The context must be non-nil and will be used for request cancellation. If 2285// the context is nil a panic will occur. In the future the SDK may create 2286// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2287// for more information on using Contexts. 2288func (c *Glacier) ListJobsPagesWithContext(ctx aws.Context, input *ListJobsInput, fn func(*ListJobsOutput, bool) bool, opts ...request.Option) error { 2289 p := request.Pagination{ 2290 NewRequest: func() (*request.Request, error) { 2291 var inCpy *ListJobsInput 2292 if input != nil { 2293 tmp := *input 2294 inCpy = &tmp 2295 } 2296 req, _ := c.ListJobsRequest(inCpy) 2297 req.SetContext(ctx) 2298 req.ApplyOptions(opts...) 2299 return req, nil 2300 }, 2301 } 2302 2303 for p.Next() { 2304 if !fn(p.Page().(*ListJobsOutput), !p.HasNextPage()) { 2305 break 2306 } 2307 } 2308 2309 return p.Err() 2310} 2311 2312const opListMultipartUploads = "ListMultipartUploads" 2313 2314// ListMultipartUploadsRequest generates a "aws/request.Request" representing the 2315// client's request for the ListMultipartUploads operation. The "output" return 2316// value will be populated with the request's response once the request completes 2317// successfully. 2318// 2319// Use "Send" method on the returned Request to send the API call to the service. 2320// the "output" return value is not valid until after Send returns without error. 2321// 2322// See ListMultipartUploads for more information on using the ListMultipartUploads 2323// API call, and error handling. 2324// 2325// This method is useful when you want to inject custom logic or configuration 2326// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2327// 2328// 2329// // Example sending a request using the ListMultipartUploadsRequest method. 2330// req, resp := client.ListMultipartUploadsRequest(params) 2331// 2332// err := req.Send() 2333// if err == nil { // resp is now filled 2334// fmt.Println(resp) 2335// } 2336func (c *Glacier) ListMultipartUploadsRequest(input *ListMultipartUploadsInput) (req *request.Request, output *ListMultipartUploadsOutput) { 2337 op := &request.Operation{ 2338 Name: opListMultipartUploads, 2339 HTTPMethod: "GET", 2340 HTTPPath: "/{accountId}/vaults/{vaultName}/multipart-uploads", 2341 Paginator: &request.Paginator{ 2342 InputTokens: []string{"marker"}, 2343 OutputTokens: []string{"Marker"}, 2344 LimitToken: "limit", 2345 TruncationToken: "", 2346 }, 2347 } 2348 2349 if input == nil { 2350 input = &ListMultipartUploadsInput{} 2351 } 2352 2353 output = &ListMultipartUploadsOutput{} 2354 req = c.newRequest(op, input, output) 2355 return 2356} 2357 2358// ListMultipartUploads API operation for Amazon Glacier. 2359// 2360// This operation lists in-progress multipart uploads for the specified vault. 2361// An in-progress multipart upload is a multipart upload that has been initiated 2362// by an InitiateMultipartUpload request, but has not yet been completed or 2363// aborted. The list returned in the List Multipart Upload response has no guaranteed 2364// order. 2365// 2366// The List Multipart Uploads operation supports pagination. By default, this 2367// operation returns up to 50 multipart uploads in the response. You should 2368// always check the response for a marker at which to continue the list; if 2369// there are no more items the marker is null. To return a list of multipart 2370// uploads that begins at a specific upload, set the marker request parameter 2371// to the value you obtained from a previous List Multipart Upload request. 2372// You can also limit the number of uploads returned in the response by specifying 2373// the limit parameter in the request. 2374// 2375// Note the difference between this operation and listing parts (ListParts). 2376// The List Multipart Uploads operation lists all multipart uploads for a vault 2377// and does not require a multipart upload ID. The List Parts operation requires 2378// a multipart upload ID since parts are associated with a single upload. 2379// 2380// An AWS account has full permission to perform all operations (actions). However, 2381// AWS Identity and Access Management (IAM) users don't have any permissions 2382// by default. You must grant them explicit permission to perform specific actions. 2383// For more information, see Access Control Using AWS Identity and Access Management 2384// (IAM) (https://docs.aws.amazon.com/amazonglacier/latest/dev/using-iam-with-amazon-glacier.html). 2385// 2386// For conceptual information and the underlying REST API, see Working with 2387// Archives in Amazon S3 Glacier (https://docs.aws.amazon.com/amazonglacier/latest/dev/working-with-archives.html) 2388// and List Multipart Uploads (https://docs.aws.amazon.com/amazonglacier/latest/dev/api-multipart-list-uploads.html) 2389// in the Amazon Glacier Developer Guide. 2390// 2391// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2392// with awserr.Error's Code and Message methods to get detailed information about 2393// the error. 2394// 2395// See the AWS API reference guide for Amazon Glacier's 2396// API operation ListMultipartUploads for usage and error information. 2397// 2398// Returned Error Types: 2399// * ResourceNotFoundException 2400// Returned if the specified resource (such as a vault, upload ID, or job ID) 2401// doesn't exist. 2402// 2403// * InvalidParameterValueException 2404// Returned if a parameter of the request is incorrectly specified. 2405// 2406// * MissingParameterValueException 2407// Returned if a required header or parameter is missing from the request. 2408// 2409// * ServiceUnavailableException 2410// Returned if the service cannot complete the request. 2411// 2412func (c *Glacier) ListMultipartUploads(input *ListMultipartUploadsInput) (*ListMultipartUploadsOutput, error) { 2413 req, out := c.ListMultipartUploadsRequest(input) 2414 return out, req.Send() 2415} 2416 2417// ListMultipartUploadsWithContext is the same as ListMultipartUploads with the addition of 2418// the ability to pass a context and additional request options. 2419// 2420// See ListMultipartUploads for details on how to use this API operation. 2421// 2422// The context must be non-nil and will be used for request cancellation. If 2423// the context is nil a panic will occur. In the future the SDK may create 2424// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2425// for more information on using Contexts. 2426func (c *Glacier) ListMultipartUploadsWithContext(ctx aws.Context, input *ListMultipartUploadsInput, opts ...request.Option) (*ListMultipartUploadsOutput, error) { 2427 req, out := c.ListMultipartUploadsRequest(input) 2428 req.SetContext(ctx) 2429 req.ApplyOptions(opts...) 2430 return out, req.Send() 2431} 2432 2433// ListMultipartUploadsPages iterates over the pages of a ListMultipartUploads operation, 2434// calling the "fn" function with the response data for each page. To stop 2435// iterating, return false from the fn function. 2436// 2437// See ListMultipartUploads method for more information on how to use this operation. 2438// 2439// Note: This operation can generate multiple requests to a service. 2440// 2441// // Example iterating over at most 3 pages of a ListMultipartUploads operation. 2442// pageNum := 0 2443// err := client.ListMultipartUploadsPages(params, 2444// func(page *glacier.ListMultipartUploadsOutput, lastPage bool) bool { 2445// pageNum++ 2446// fmt.Println(page) 2447// return pageNum <= 3 2448// }) 2449// 2450func (c *Glacier) ListMultipartUploadsPages(input *ListMultipartUploadsInput, fn func(*ListMultipartUploadsOutput, bool) bool) error { 2451 return c.ListMultipartUploadsPagesWithContext(aws.BackgroundContext(), input, fn) 2452} 2453 2454// ListMultipartUploadsPagesWithContext same as ListMultipartUploadsPages except 2455// it takes a Context and allows setting request options on the pages. 2456// 2457// The context must be non-nil and will be used for request cancellation. If 2458// the context is nil a panic will occur. In the future the SDK may create 2459// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2460// for more information on using Contexts. 2461func (c *Glacier) ListMultipartUploadsPagesWithContext(ctx aws.Context, input *ListMultipartUploadsInput, fn func(*ListMultipartUploadsOutput, bool) bool, opts ...request.Option) error { 2462 p := request.Pagination{ 2463 NewRequest: func() (*request.Request, error) { 2464 var inCpy *ListMultipartUploadsInput 2465 if input != nil { 2466 tmp := *input 2467 inCpy = &tmp 2468 } 2469 req, _ := c.ListMultipartUploadsRequest(inCpy) 2470 req.SetContext(ctx) 2471 req.ApplyOptions(opts...) 2472 return req, nil 2473 }, 2474 } 2475 2476 for p.Next() { 2477 if !fn(p.Page().(*ListMultipartUploadsOutput), !p.HasNextPage()) { 2478 break 2479 } 2480 } 2481 2482 return p.Err() 2483} 2484 2485const opListParts = "ListParts" 2486 2487// ListPartsRequest generates a "aws/request.Request" representing the 2488// client's request for the ListParts operation. The "output" return 2489// value will be populated with the request's response once the request completes 2490// successfully. 2491// 2492// Use "Send" method on the returned Request to send the API call to the service. 2493// the "output" return value is not valid until after Send returns without error. 2494// 2495// See ListParts for more information on using the ListParts 2496// API call, and error handling. 2497// 2498// This method is useful when you want to inject custom logic or configuration 2499// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2500// 2501// 2502// // Example sending a request using the ListPartsRequest method. 2503// req, resp := client.ListPartsRequest(params) 2504// 2505// err := req.Send() 2506// if err == nil { // resp is now filled 2507// fmt.Println(resp) 2508// } 2509func (c *Glacier) ListPartsRequest(input *ListPartsInput) (req *request.Request, output *ListPartsOutput) { 2510 op := &request.Operation{ 2511 Name: opListParts, 2512 HTTPMethod: "GET", 2513 HTTPPath: "/{accountId}/vaults/{vaultName}/multipart-uploads/{uploadId}", 2514 Paginator: &request.Paginator{ 2515 InputTokens: []string{"marker"}, 2516 OutputTokens: []string{"Marker"}, 2517 LimitToken: "limit", 2518 TruncationToken: "", 2519 }, 2520 } 2521 2522 if input == nil { 2523 input = &ListPartsInput{} 2524 } 2525 2526 output = &ListPartsOutput{} 2527 req = c.newRequest(op, input, output) 2528 return 2529} 2530 2531// ListParts API operation for Amazon Glacier. 2532// 2533// This operation lists the parts of an archive that have been uploaded in a 2534// specific multipart upload. You can make this request at any time during an 2535// in-progress multipart upload before you complete the upload (see CompleteMultipartUpload. 2536// List Parts returns an error for completed uploads. The list returned in the 2537// List Parts response is sorted by part range. 2538// 2539// The List Parts operation supports pagination. By default, this operation 2540// returns up to 50 uploaded parts in the response. You should always check 2541// the response for a marker at which to continue the list; if there are no 2542// more items the marker is null. To return a list of parts that begins at a 2543// specific part, set the marker request parameter to the value you obtained 2544// from a previous List Parts request. You can also limit the number of parts 2545// returned in the response by specifying the limit parameter in the request. 2546// 2547// An AWS account has full permission to perform all operations (actions). However, 2548// AWS Identity and Access Management (IAM) users don't have any permissions 2549// by default. You must grant them explicit permission to perform specific actions. 2550// For more information, see Access Control Using AWS Identity and Access Management 2551// (IAM) (https://docs.aws.amazon.com/amazonglacier/latest/dev/using-iam-with-amazon-glacier.html). 2552// 2553// For conceptual information and the underlying REST API, see Working with 2554// Archives in Amazon S3 Glacier (https://docs.aws.amazon.com/amazonglacier/latest/dev/working-with-archives.html) 2555// and List Parts (https://docs.aws.amazon.com/amazonglacier/latest/dev/api-multipart-list-parts.html) 2556// in the Amazon Glacier Developer Guide. 2557// 2558// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2559// with awserr.Error's Code and Message methods to get detailed information about 2560// the error. 2561// 2562// See the AWS API reference guide for Amazon Glacier's 2563// API operation ListParts for usage and error information. 2564// 2565// Returned Error Types: 2566// * ResourceNotFoundException 2567// Returned if the specified resource (such as a vault, upload ID, or job ID) 2568// doesn't exist. 2569// 2570// * InvalidParameterValueException 2571// Returned if a parameter of the request is incorrectly specified. 2572// 2573// * MissingParameterValueException 2574// Returned if a required header or parameter is missing from the request. 2575// 2576// * ServiceUnavailableException 2577// Returned if the service cannot complete the request. 2578// 2579func (c *Glacier) ListParts(input *ListPartsInput) (*ListPartsOutput, error) { 2580 req, out := c.ListPartsRequest(input) 2581 return out, req.Send() 2582} 2583 2584// ListPartsWithContext is the same as ListParts with the addition of 2585// the ability to pass a context and additional request options. 2586// 2587// See ListParts for details on how to use this API operation. 2588// 2589// The context must be non-nil and will be used for request cancellation. If 2590// the context is nil a panic will occur. In the future the SDK may create 2591// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2592// for more information on using Contexts. 2593func (c *Glacier) ListPartsWithContext(ctx aws.Context, input *ListPartsInput, opts ...request.Option) (*ListPartsOutput, error) { 2594 req, out := c.ListPartsRequest(input) 2595 req.SetContext(ctx) 2596 req.ApplyOptions(opts...) 2597 return out, req.Send() 2598} 2599 2600// ListPartsPages iterates over the pages of a ListParts operation, 2601// calling the "fn" function with the response data for each page. To stop 2602// iterating, return false from the fn function. 2603// 2604// See ListParts method for more information on how to use this operation. 2605// 2606// Note: This operation can generate multiple requests to a service. 2607// 2608// // Example iterating over at most 3 pages of a ListParts operation. 2609// pageNum := 0 2610// err := client.ListPartsPages(params, 2611// func(page *glacier.ListPartsOutput, lastPage bool) bool { 2612// pageNum++ 2613// fmt.Println(page) 2614// return pageNum <= 3 2615// }) 2616// 2617func (c *Glacier) ListPartsPages(input *ListPartsInput, fn func(*ListPartsOutput, bool) bool) error { 2618 return c.ListPartsPagesWithContext(aws.BackgroundContext(), input, fn) 2619} 2620 2621// ListPartsPagesWithContext same as ListPartsPages except 2622// it takes a Context and allows setting request options on the pages. 2623// 2624// The context must be non-nil and will be used for request cancellation. If 2625// the context is nil a panic will occur. In the future the SDK may create 2626// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2627// for more information on using Contexts. 2628func (c *Glacier) ListPartsPagesWithContext(ctx aws.Context, input *ListPartsInput, fn func(*ListPartsOutput, bool) bool, opts ...request.Option) error { 2629 p := request.Pagination{ 2630 NewRequest: func() (*request.Request, error) { 2631 var inCpy *ListPartsInput 2632 if input != nil { 2633 tmp := *input 2634 inCpy = &tmp 2635 } 2636 req, _ := c.ListPartsRequest(inCpy) 2637 req.SetContext(ctx) 2638 req.ApplyOptions(opts...) 2639 return req, nil 2640 }, 2641 } 2642 2643 for p.Next() { 2644 if !fn(p.Page().(*ListPartsOutput), !p.HasNextPage()) { 2645 break 2646 } 2647 } 2648 2649 return p.Err() 2650} 2651 2652const opListProvisionedCapacity = "ListProvisionedCapacity" 2653 2654// ListProvisionedCapacityRequest generates a "aws/request.Request" representing the 2655// client's request for the ListProvisionedCapacity operation. The "output" return 2656// value will be populated with the request's response once the request completes 2657// successfully. 2658// 2659// Use "Send" method on the returned Request to send the API call to the service. 2660// the "output" return value is not valid until after Send returns without error. 2661// 2662// See ListProvisionedCapacity for more information on using the ListProvisionedCapacity 2663// API call, and error handling. 2664// 2665// This method is useful when you want to inject custom logic or configuration 2666// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2667// 2668// 2669// // Example sending a request using the ListProvisionedCapacityRequest method. 2670// req, resp := client.ListProvisionedCapacityRequest(params) 2671// 2672// err := req.Send() 2673// if err == nil { // resp is now filled 2674// fmt.Println(resp) 2675// } 2676func (c *Glacier) ListProvisionedCapacityRequest(input *ListProvisionedCapacityInput) (req *request.Request, output *ListProvisionedCapacityOutput) { 2677 op := &request.Operation{ 2678 Name: opListProvisionedCapacity, 2679 HTTPMethod: "GET", 2680 HTTPPath: "/{accountId}/provisioned-capacity", 2681 } 2682 2683 if input == nil { 2684 input = &ListProvisionedCapacityInput{} 2685 } 2686 2687 output = &ListProvisionedCapacityOutput{} 2688 req = c.newRequest(op, input, output) 2689 return 2690} 2691 2692// ListProvisionedCapacity API operation for Amazon Glacier. 2693// 2694// This operation lists the provisioned capacity units for the specified AWS 2695// account. 2696// 2697// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2698// with awserr.Error's Code and Message methods to get detailed information about 2699// the error. 2700// 2701// See the AWS API reference guide for Amazon Glacier's 2702// API operation ListProvisionedCapacity for usage and error information. 2703// 2704// Returned Error Types: 2705// * InvalidParameterValueException 2706// Returned if a parameter of the request is incorrectly specified. 2707// 2708// * MissingParameterValueException 2709// Returned if a required header or parameter is missing from the request. 2710// 2711// * ServiceUnavailableException 2712// Returned if the service cannot complete the request. 2713// 2714func (c *Glacier) ListProvisionedCapacity(input *ListProvisionedCapacityInput) (*ListProvisionedCapacityOutput, error) { 2715 req, out := c.ListProvisionedCapacityRequest(input) 2716 return out, req.Send() 2717} 2718 2719// ListProvisionedCapacityWithContext is the same as ListProvisionedCapacity with the addition of 2720// the ability to pass a context and additional request options. 2721// 2722// See ListProvisionedCapacity for details on how to use this API operation. 2723// 2724// The context must be non-nil and will be used for request cancellation. If 2725// the context is nil a panic will occur. In the future the SDK may create 2726// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2727// for more information on using Contexts. 2728func (c *Glacier) ListProvisionedCapacityWithContext(ctx aws.Context, input *ListProvisionedCapacityInput, opts ...request.Option) (*ListProvisionedCapacityOutput, error) { 2729 req, out := c.ListProvisionedCapacityRequest(input) 2730 req.SetContext(ctx) 2731 req.ApplyOptions(opts...) 2732 return out, req.Send() 2733} 2734 2735const opListTagsForVault = "ListTagsForVault" 2736 2737// ListTagsForVaultRequest generates a "aws/request.Request" representing the 2738// client's request for the ListTagsForVault operation. The "output" return 2739// value will be populated with the request's response once the request completes 2740// successfully. 2741// 2742// Use "Send" method on the returned Request to send the API call to the service. 2743// the "output" return value is not valid until after Send returns without error. 2744// 2745// See ListTagsForVault for more information on using the ListTagsForVault 2746// API call, and error handling. 2747// 2748// This method is useful when you want to inject custom logic or configuration 2749// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2750// 2751// 2752// // Example sending a request using the ListTagsForVaultRequest method. 2753// req, resp := client.ListTagsForVaultRequest(params) 2754// 2755// err := req.Send() 2756// if err == nil { // resp is now filled 2757// fmt.Println(resp) 2758// } 2759func (c *Glacier) ListTagsForVaultRequest(input *ListTagsForVaultInput) (req *request.Request, output *ListTagsForVaultOutput) { 2760 op := &request.Operation{ 2761 Name: opListTagsForVault, 2762 HTTPMethod: "GET", 2763 HTTPPath: "/{accountId}/vaults/{vaultName}/tags", 2764 } 2765 2766 if input == nil { 2767 input = &ListTagsForVaultInput{} 2768 } 2769 2770 output = &ListTagsForVaultOutput{} 2771 req = c.newRequest(op, input, output) 2772 return 2773} 2774 2775// ListTagsForVault API operation for Amazon Glacier. 2776// 2777// This operation lists all the tags attached to a vault. The operation returns 2778// an empty map if there are no tags. For more information about tags, see Tagging 2779// Amazon S3 Glacier Resources (https://docs.aws.amazon.com/amazonglacier/latest/dev/tagging.html). 2780// 2781// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2782// with awserr.Error's Code and Message methods to get detailed information about 2783// the error. 2784// 2785// See the AWS API reference guide for Amazon Glacier's 2786// API operation ListTagsForVault for usage and error information. 2787// 2788// Returned Error Types: 2789// * InvalidParameterValueException 2790// Returned if a parameter of the request is incorrectly specified. 2791// 2792// * MissingParameterValueException 2793// Returned if a required header or parameter is missing from the request. 2794// 2795// * ResourceNotFoundException 2796// Returned if the specified resource (such as a vault, upload ID, or job ID) 2797// doesn't exist. 2798// 2799// * ServiceUnavailableException 2800// Returned if the service cannot complete the request. 2801// 2802func (c *Glacier) ListTagsForVault(input *ListTagsForVaultInput) (*ListTagsForVaultOutput, error) { 2803 req, out := c.ListTagsForVaultRequest(input) 2804 return out, req.Send() 2805} 2806 2807// ListTagsForVaultWithContext is the same as ListTagsForVault with the addition of 2808// the ability to pass a context and additional request options. 2809// 2810// See ListTagsForVault for details on how to use this API operation. 2811// 2812// The context must be non-nil and will be used for request cancellation. If 2813// the context is nil a panic will occur. In the future the SDK may create 2814// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2815// for more information on using Contexts. 2816func (c *Glacier) ListTagsForVaultWithContext(ctx aws.Context, input *ListTagsForVaultInput, opts ...request.Option) (*ListTagsForVaultOutput, error) { 2817 req, out := c.ListTagsForVaultRequest(input) 2818 req.SetContext(ctx) 2819 req.ApplyOptions(opts...) 2820 return out, req.Send() 2821} 2822 2823const opListVaults = "ListVaults" 2824 2825// ListVaultsRequest generates a "aws/request.Request" representing the 2826// client's request for the ListVaults operation. The "output" return 2827// value will be populated with the request's response once the request completes 2828// successfully. 2829// 2830// Use "Send" method on the returned Request to send the API call to the service. 2831// the "output" return value is not valid until after Send returns without error. 2832// 2833// See ListVaults for more information on using the ListVaults 2834// API call, and error handling. 2835// 2836// This method is useful when you want to inject custom logic or configuration 2837// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2838// 2839// 2840// // Example sending a request using the ListVaultsRequest method. 2841// req, resp := client.ListVaultsRequest(params) 2842// 2843// err := req.Send() 2844// if err == nil { // resp is now filled 2845// fmt.Println(resp) 2846// } 2847func (c *Glacier) ListVaultsRequest(input *ListVaultsInput) (req *request.Request, output *ListVaultsOutput) { 2848 op := &request.Operation{ 2849 Name: opListVaults, 2850 HTTPMethod: "GET", 2851 HTTPPath: "/{accountId}/vaults", 2852 Paginator: &request.Paginator{ 2853 InputTokens: []string{"marker"}, 2854 OutputTokens: []string{"Marker"}, 2855 LimitToken: "limit", 2856 TruncationToken: "", 2857 }, 2858 } 2859 2860 if input == nil { 2861 input = &ListVaultsInput{} 2862 } 2863 2864 output = &ListVaultsOutput{} 2865 req = c.newRequest(op, input, output) 2866 return 2867} 2868 2869// ListVaults API operation for Amazon Glacier. 2870// 2871// This operation lists all vaults owned by the calling user's account. The 2872// list returned in the response is ASCII-sorted by vault name. 2873// 2874// By default, this operation returns up to 10 items. If there are more vaults 2875// to list, the response marker field contains the vault Amazon Resource Name 2876// (ARN) at which to continue the list with a new List Vaults request; otherwise, 2877// the marker field is null. To return a list of vaults that begins at a specific 2878// vault, set the marker request parameter to the vault ARN you obtained from 2879// a previous List Vaults request. You can also limit the number of vaults returned 2880// in the response by specifying the limit parameter in the request. 2881// 2882// An AWS account has full permission to perform all operations (actions). However, 2883// AWS Identity and Access Management (IAM) users don't have any permissions 2884// by default. You must grant them explicit permission to perform specific actions. 2885// For more information, see Access Control Using AWS Identity and Access Management 2886// (IAM) (https://docs.aws.amazon.com/amazonglacier/latest/dev/using-iam-with-amazon-glacier.html). 2887// 2888// For conceptual information and underlying REST API, see Retrieving Vault 2889// Metadata in Amazon S3 Glacier (https://docs.aws.amazon.com/amazonglacier/latest/dev/retrieving-vault-info.html) 2890// and List Vaults (https://docs.aws.amazon.com/amazonglacier/latest/dev/api-vaults-get.html) 2891// in the Amazon Glacier Developer Guide. 2892// 2893// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2894// with awserr.Error's Code and Message methods to get detailed information about 2895// the error. 2896// 2897// See the AWS API reference guide for Amazon Glacier's 2898// API operation ListVaults for usage and error information. 2899// 2900// Returned Error Types: 2901// * ResourceNotFoundException 2902// Returned if the specified resource (such as a vault, upload ID, or job ID) 2903// doesn't exist. 2904// 2905// * InvalidParameterValueException 2906// Returned if a parameter of the request is incorrectly specified. 2907// 2908// * MissingParameterValueException 2909// Returned if a required header or parameter is missing from the request. 2910// 2911// * ServiceUnavailableException 2912// Returned if the service cannot complete the request. 2913// 2914func (c *Glacier) ListVaults(input *ListVaultsInput) (*ListVaultsOutput, error) { 2915 req, out := c.ListVaultsRequest(input) 2916 return out, req.Send() 2917} 2918 2919// ListVaultsWithContext is the same as ListVaults with the addition of 2920// the ability to pass a context and additional request options. 2921// 2922// See ListVaults for details on how to use this API operation. 2923// 2924// The context must be non-nil and will be used for request cancellation. If 2925// the context is nil a panic will occur. In the future the SDK may create 2926// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2927// for more information on using Contexts. 2928func (c *Glacier) ListVaultsWithContext(ctx aws.Context, input *ListVaultsInput, opts ...request.Option) (*ListVaultsOutput, error) { 2929 req, out := c.ListVaultsRequest(input) 2930 req.SetContext(ctx) 2931 req.ApplyOptions(opts...) 2932 return out, req.Send() 2933} 2934 2935// ListVaultsPages iterates over the pages of a ListVaults operation, 2936// calling the "fn" function with the response data for each page. To stop 2937// iterating, return false from the fn function. 2938// 2939// See ListVaults method for more information on how to use this operation. 2940// 2941// Note: This operation can generate multiple requests to a service. 2942// 2943// // Example iterating over at most 3 pages of a ListVaults operation. 2944// pageNum := 0 2945// err := client.ListVaultsPages(params, 2946// func(page *glacier.ListVaultsOutput, lastPage bool) bool { 2947// pageNum++ 2948// fmt.Println(page) 2949// return pageNum <= 3 2950// }) 2951// 2952func (c *Glacier) ListVaultsPages(input *ListVaultsInput, fn func(*ListVaultsOutput, bool) bool) error { 2953 return c.ListVaultsPagesWithContext(aws.BackgroundContext(), input, fn) 2954} 2955 2956// ListVaultsPagesWithContext same as ListVaultsPages except 2957// it takes a Context and allows setting request options on the pages. 2958// 2959// The context must be non-nil and will be used for request cancellation. If 2960// the context is nil a panic will occur. In the future the SDK may create 2961// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2962// for more information on using Contexts. 2963func (c *Glacier) ListVaultsPagesWithContext(ctx aws.Context, input *ListVaultsInput, fn func(*ListVaultsOutput, bool) bool, opts ...request.Option) error { 2964 p := request.Pagination{ 2965 NewRequest: func() (*request.Request, error) { 2966 var inCpy *ListVaultsInput 2967 if input != nil { 2968 tmp := *input 2969 inCpy = &tmp 2970 } 2971 req, _ := c.ListVaultsRequest(inCpy) 2972 req.SetContext(ctx) 2973 req.ApplyOptions(opts...) 2974 return req, nil 2975 }, 2976 } 2977 2978 for p.Next() { 2979 if !fn(p.Page().(*ListVaultsOutput), !p.HasNextPage()) { 2980 break 2981 } 2982 } 2983 2984 return p.Err() 2985} 2986 2987const opPurchaseProvisionedCapacity = "PurchaseProvisionedCapacity" 2988 2989// PurchaseProvisionedCapacityRequest generates a "aws/request.Request" representing the 2990// client's request for the PurchaseProvisionedCapacity operation. The "output" return 2991// value will be populated with the request's response once the request completes 2992// successfully. 2993// 2994// Use "Send" method on the returned Request to send the API call to the service. 2995// the "output" return value is not valid until after Send returns without error. 2996// 2997// See PurchaseProvisionedCapacity for more information on using the PurchaseProvisionedCapacity 2998// API call, and error handling. 2999// 3000// This method is useful when you want to inject custom logic or configuration 3001// into the SDK's request lifecycle. Such as custom headers, or retry logic. 3002// 3003// 3004// // Example sending a request using the PurchaseProvisionedCapacityRequest method. 3005// req, resp := client.PurchaseProvisionedCapacityRequest(params) 3006// 3007// err := req.Send() 3008// if err == nil { // resp is now filled 3009// fmt.Println(resp) 3010// } 3011func (c *Glacier) PurchaseProvisionedCapacityRequest(input *PurchaseProvisionedCapacityInput) (req *request.Request, output *PurchaseProvisionedCapacityOutput) { 3012 op := &request.Operation{ 3013 Name: opPurchaseProvisionedCapacity, 3014 HTTPMethod: "POST", 3015 HTTPPath: "/{accountId}/provisioned-capacity", 3016 } 3017 3018 if input == nil { 3019 input = &PurchaseProvisionedCapacityInput{} 3020 } 3021 3022 output = &PurchaseProvisionedCapacityOutput{} 3023 req = c.newRequest(op, input, output) 3024 return 3025} 3026 3027// PurchaseProvisionedCapacity API operation for Amazon Glacier. 3028// 3029// This operation purchases a provisioned capacity unit for an AWS account. 3030// 3031// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 3032// with awserr.Error's Code and Message methods to get detailed information about 3033// the error. 3034// 3035// See the AWS API reference guide for Amazon Glacier's 3036// API operation PurchaseProvisionedCapacity for usage and error information. 3037// 3038// Returned Error Types: 3039// * InvalidParameterValueException 3040// Returned if a parameter of the request is incorrectly specified. 3041// 3042// * MissingParameterValueException 3043// Returned if a required header or parameter is missing from the request. 3044// 3045// * LimitExceededException 3046// Returned if the request results in a vault or account limit being exceeded. 3047// 3048// * ServiceUnavailableException 3049// Returned if the service cannot complete the request. 3050// 3051func (c *Glacier) PurchaseProvisionedCapacity(input *PurchaseProvisionedCapacityInput) (*PurchaseProvisionedCapacityOutput, error) { 3052 req, out := c.PurchaseProvisionedCapacityRequest(input) 3053 return out, req.Send() 3054} 3055 3056// PurchaseProvisionedCapacityWithContext is the same as PurchaseProvisionedCapacity with the addition of 3057// the ability to pass a context and additional request options. 3058// 3059// See PurchaseProvisionedCapacity for details on how to use this API operation. 3060// 3061// The context must be non-nil and will be used for request cancellation. If 3062// the context is nil a panic will occur. In the future the SDK may create 3063// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 3064// for more information on using Contexts. 3065func (c *Glacier) PurchaseProvisionedCapacityWithContext(ctx aws.Context, input *PurchaseProvisionedCapacityInput, opts ...request.Option) (*PurchaseProvisionedCapacityOutput, error) { 3066 req, out := c.PurchaseProvisionedCapacityRequest(input) 3067 req.SetContext(ctx) 3068 req.ApplyOptions(opts...) 3069 return out, req.Send() 3070} 3071 3072const opRemoveTagsFromVault = "RemoveTagsFromVault" 3073 3074// RemoveTagsFromVaultRequest generates a "aws/request.Request" representing the 3075// client's request for the RemoveTagsFromVault operation. The "output" return 3076// value will be populated with the request's response once the request completes 3077// successfully. 3078// 3079// Use "Send" method on the returned Request to send the API call to the service. 3080// the "output" return value is not valid until after Send returns without error. 3081// 3082// See RemoveTagsFromVault for more information on using the RemoveTagsFromVault 3083// API call, and error handling. 3084// 3085// This method is useful when you want to inject custom logic or configuration 3086// into the SDK's request lifecycle. Such as custom headers, or retry logic. 3087// 3088// 3089// // Example sending a request using the RemoveTagsFromVaultRequest method. 3090// req, resp := client.RemoveTagsFromVaultRequest(params) 3091// 3092// err := req.Send() 3093// if err == nil { // resp is now filled 3094// fmt.Println(resp) 3095// } 3096func (c *Glacier) RemoveTagsFromVaultRequest(input *RemoveTagsFromVaultInput) (req *request.Request, output *RemoveTagsFromVaultOutput) { 3097 op := &request.Operation{ 3098 Name: opRemoveTagsFromVault, 3099 HTTPMethod: "POST", 3100 HTTPPath: "/{accountId}/vaults/{vaultName}/tags?operation=remove", 3101 } 3102 3103 if input == nil { 3104 input = &RemoveTagsFromVaultInput{} 3105 } 3106 3107 output = &RemoveTagsFromVaultOutput{} 3108 req = c.newRequest(op, input, output) 3109 req.Handlers.Unmarshal.Swap(restjson.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 3110 return 3111} 3112 3113// RemoveTagsFromVault API operation for Amazon Glacier. 3114// 3115// This operation removes one or more tags from the set of tags attached to 3116// a vault. For more information about tags, see Tagging Amazon S3 Glacier Resources 3117// (https://docs.aws.amazon.com/amazonglacier/latest/dev/tagging.html). This 3118// operation is idempotent. The operation will be successful, even if there 3119// are no tags attached to the vault. 3120// 3121// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 3122// with awserr.Error's Code and Message methods to get detailed information about 3123// the error. 3124// 3125// See the AWS API reference guide for Amazon Glacier's 3126// API operation RemoveTagsFromVault for usage and error information. 3127// 3128// Returned Error Types: 3129// * InvalidParameterValueException 3130// Returned if a parameter of the request is incorrectly specified. 3131// 3132// * MissingParameterValueException 3133// Returned if a required header or parameter is missing from the request. 3134// 3135// * ResourceNotFoundException 3136// Returned if the specified resource (such as a vault, upload ID, or job ID) 3137// doesn't exist. 3138// 3139// * ServiceUnavailableException 3140// Returned if the service cannot complete the request. 3141// 3142func (c *Glacier) RemoveTagsFromVault(input *RemoveTagsFromVaultInput) (*RemoveTagsFromVaultOutput, error) { 3143 req, out := c.RemoveTagsFromVaultRequest(input) 3144 return out, req.Send() 3145} 3146 3147// RemoveTagsFromVaultWithContext is the same as RemoveTagsFromVault with the addition of 3148// the ability to pass a context and additional request options. 3149// 3150// See RemoveTagsFromVault for details on how to use this API operation. 3151// 3152// The context must be non-nil and will be used for request cancellation. If 3153// the context is nil a panic will occur. In the future the SDK may create 3154// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 3155// for more information on using Contexts. 3156func (c *Glacier) RemoveTagsFromVaultWithContext(ctx aws.Context, input *RemoveTagsFromVaultInput, opts ...request.Option) (*RemoveTagsFromVaultOutput, error) { 3157 req, out := c.RemoveTagsFromVaultRequest(input) 3158 req.SetContext(ctx) 3159 req.ApplyOptions(opts...) 3160 return out, req.Send() 3161} 3162 3163const opSetDataRetrievalPolicy = "SetDataRetrievalPolicy" 3164 3165// SetDataRetrievalPolicyRequest generates a "aws/request.Request" representing the 3166// client's request for the SetDataRetrievalPolicy operation. The "output" return 3167// value will be populated with the request's response once the request completes 3168// successfully. 3169// 3170// Use "Send" method on the returned Request to send the API call to the service. 3171// the "output" return value is not valid until after Send returns without error. 3172// 3173// See SetDataRetrievalPolicy for more information on using the SetDataRetrievalPolicy 3174// API call, and error handling. 3175// 3176// This method is useful when you want to inject custom logic or configuration 3177// into the SDK's request lifecycle. Such as custom headers, or retry logic. 3178// 3179// 3180// // Example sending a request using the SetDataRetrievalPolicyRequest method. 3181// req, resp := client.SetDataRetrievalPolicyRequest(params) 3182// 3183// err := req.Send() 3184// if err == nil { // resp is now filled 3185// fmt.Println(resp) 3186// } 3187func (c *Glacier) SetDataRetrievalPolicyRequest(input *SetDataRetrievalPolicyInput) (req *request.Request, output *SetDataRetrievalPolicyOutput) { 3188 op := &request.Operation{ 3189 Name: opSetDataRetrievalPolicy, 3190 HTTPMethod: "PUT", 3191 HTTPPath: "/{accountId}/policies/data-retrieval", 3192 } 3193 3194 if input == nil { 3195 input = &SetDataRetrievalPolicyInput{} 3196 } 3197 3198 output = &SetDataRetrievalPolicyOutput{} 3199 req = c.newRequest(op, input, output) 3200 req.Handlers.Unmarshal.Swap(restjson.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 3201 return 3202} 3203 3204// SetDataRetrievalPolicy API operation for Amazon Glacier. 3205// 3206// This operation sets and then enacts a data retrieval policy in the region 3207// specified in the PUT request. You can set one policy per region for an AWS 3208// account. The policy is enacted within a few minutes of a successful PUT operation. 3209// 3210// The set policy operation does not affect retrieval jobs that were in progress 3211// before the policy was enacted. For more information about data retrieval 3212// policies, see Amazon Glacier Data Retrieval Policies (https://docs.aws.amazon.com/amazonglacier/latest/dev/data-retrieval-policy.html). 3213// 3214// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 3215// with awserr.Error's Code and Message methods to get detailed information about 3216// the error. 3217// 3218// See the AWS API reference guide for Amazon Glacier's 3219// API operation SetDataRetrievalPolicy for usage and error information. 3220// 3221// Returned Error Types: 3222// * InvalidParameterValueException 3223// Returned if a parameter of the request is incorrectly specified. 3224// 3225// * MissingParameterValueException 3226// Returned if a required header or parameter is missing from the request. 3227// 3228// * ServiceUnavailableException 3229// Returned if the service cannot complete the request. 3230// 3231func (c *Glacier) SetDataRetrievalPolicy(input *SetDataRetrievalPolicyInput) (*SetDataRetrievalPolicyOutput, error) { 3232 req, out := c.SetDataRetrievalPolicyRequest(input) 3233 return out, req.Send() 3234} 3235 3236// SetDataRetrievalPolicyWithContext is the same as SetDataRetrievalPolicy with the addition of 3237// the ability to pass a context and additional request options. 3238// 3239// See SetDataRetrievalPolicy for details on how to use this API operation. 3240// 3241// The context must be non-nil and will be used for request cancellation. If 3242// the context is nil a panic will occur. In the future the SDK may create 3243// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 3244// for more information on using Contexts. 3245func (c *Glacier) SetDataRetrievalPolicyWithContext(ctx aws.Context, input *SetDataRetrievalPolicyInput, opts ...request.Option) (*SetDataRetrievalPolicyOutput, error) { 3246 req, out := c.SetDataRetrievalPolicyRequest(input) 3247 req.SetContext(ctx) 3248 req.ApplyOptions(opts...) 3249 return out, req.Send() 3250} 3251 3252const opSetVaultAccessPolicy = "SetVaultAccessPolicy" 3253 3254// SetVaultAccessPolicyRequest generates a "aws/request.Request" representing the 3255// client's request for the SetVaultAccessPolicy operation. The "output" return 3256// value will be populated with the request's response once the request completes 3257// successfully. 3258// 3259// Use "Send" method on the returned Request to send the API call to the service. 3260// the "output" return value is not valid until after Send returns without error. 3261// 3262// See SetVaultAccessPolicy for more information on using the SetVaultAccessPolicy 3263// API call, and error handling. 3264// 3265// This method is useful when you want to inject custom logic or configuration 3266// into the SDK's request lifecycle. Such as custom headers, or retry logic. 3267// 3268// 3269// // Example sending a request using the SetVaultAccessPolicyRequest method. 3270// req, resp := client.SetVaultAccessPolicyRequest(params) 3271// 3272// err := req.Send() 3273// if err == nil { // resp is now filled 3274// fmt.Println(resp) 3275// } 3276func (c *Glacier) SetVaultAccessPolicyRequest(input *SetVaultAccessPolicyInput) (req *request.Request, output *SetVaultAccessPolicyOutput) { 3277 op := &request.Operation{ 3278 Name: opSetVaultAccessPolicy, 3279 HTTPMethod: "PUT", 3280 HTTPPath: "/{accountId}/vaults/{vaultName}/access-policy", 3281 } 3282 3283 if input == nil { 3284 input = &SetVaultAccessPolicyInput{} 3285 } 3286 3287 output = &SetVaultAccessPolicyOutput{} 3288 req = c.newRequest(op, input, output) 3289 req.Handlers.Unmarshal.Swap(restjson.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 3290 return 3291} 3292 3293// SetVaultAccessPolicy API operation for Amazon Glacier. 3294// 3295// This operation configures an access policy for a vault and will overwrite 3296// an existing policy. To configure a vault access policy, send a PUT request 3297// to the access-policy subresource of the vault. An access policy is specific 3298// to a vault and is also called a vault subresource. You can set one access 3299// policy per vault and the policy can be up to 20 KB in size. For more information 3300// about vault access policies, see Amazon Glacier Access Control with Vault 3301// Access Policies (https://docs.aws.amazon.com/amazonglacier/latest/dev/vault-access-policy.html). 3302// 3303// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 3304// with awserr.Error's Code and Message methods to get detailed information about 3305// the error. 3306// 3307// See the AWS API reference guide for Amazon Glacier's 3308// API operation SetVaultAccessPolicy for usage and error information. 3309// 3310// Returned Error Types: 3311// * ResourceNotFoundException 3312// Returned if the specified resource (such as a vault, upload ID, or job ID) 3313// doesn't exist. 3314// 3315// * InvalidParameterValueException 3316// Returned if a parameter of the request is incorrectly specified. 3317// 3318// * MissingParameterValueException 3319// Returned if a required header or parameter is missing from the request. 3320// 3321// * ServiceUnavailableException 3322// Returned if the service cannot complete the request. 3323// 3324func (c *Glacier) SetVaultAccessPolicy(input *SetVaultAccessPolicyInput) (*SetVaultAccessPolicyOutput, error) { 3325 req, out := c.SetVaultAccessPolicyRequest(input) 3326 return out, req.Send() 3327} 3328 3329// SetVaultAccessPolicyWithContext is the same as SetVaultAccessPolicy with the addition of 3330// the ability to pass a context and additional request options. 3331// 3332// See SetVaultAccessPolicy for details on how to use this API operation. 3333// 3334// The context must be non-nil and will be used for request cancellation. If 3335// the context is nil a panic will occur. In the future the SDK may create 3336// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 3337// for more information on using Contexts. 3338func (c *Glacier) SetVaultAccessPolicyWithContext(ctx aws.Context, input *SetVaultAccessPolicyInput, opts ...request.Option) (*SetVaultAccessPolicyOutput, error) { 3339 req, out := c.SetVaultAccessPolicyRequest(input) 3340 req.SetContext(ctx) 3341 req.ApplyOptions(opts...) 3342 return out, req.Send() 3343} 3344 3345const opSetVaultNotifications = "SetVaultNotifications" 3346 3347// SetVaultNotificationsRequest generates a "aws/request.Request" representing the 3348// client's request for the SetVaultNotifications operation. The "output" return 3349// value will be populated with the request's response once the request completes 3350// successfully. 3351// 3352// Use "Send" method on the returned Request to send the API call to the service. 3353// the "output" return value is not valid until after Send returns without error. 3354// 3355// See SetVaultNotifications for more information on using the SetVaultNotifications 3356// API call, and error handling. 3357// 3358// This method is useful when you want to inject custom logic or configuration 3359// into the SDK's request lifecycle. Such as custom headers, or retry logic. 3360// 3361// 3362// // Example sending a request using the SetVaultNotificationsRequest method. 3363// req, resp := client.SetVaultNotificationsRequest(params) 3364// 3365// err := req.Send() 3366// if err == nil { // resp is now filled 3367// fmt.Println(resp) 3368// } 3369func (c *Glacier) SetVaultNotificationsRequest(input *SetVaultNotificationsInput) (req *request.Request, output *SetVaultNotificationsOutput) { 3370 op := &request.Operation{ 3371 Name: opSetVaultNotifications, 3372 HTTPMethod: "PUT", 3373 HTTPPath: "/{accountId}/vaults/{vaultName}/notification-configuration", 3374 } 3375 3376 if input == nil { 3377 input = &SetVaultNotificationsInput{} 3378 } 3379 3380 output = &SetVaultNotificationsOutput{} 3381 req = c.newRequest(op, input, output) 3382 req.Handlers.Unmarshal.Swap(restjson.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 3383 return 3384} 3385 3386// SetVaultNotifications API operation for Amazon Glacier. 3387// 3388// This operation configures notifications that will be sent when specific events 3389// happen to a vault. By default, you don't get any notifications. 3390// 3391// To configure vault notifications, send a PUT request to the notification-configuration 3392// subresource of the vault. The request should include a JSON document that 3393// provides an Amazon SNS topic and specific events for which you want Amazon 3394// S3 Glacier to send notifications to the topic. 3395// 3396// Amazon SNS topics must grant permission to the vault to be allowed to publish 3397// notifications to the topic. You can configure a vault to publish a notification 3398// for the following vault events: 3399// 3400// * ArchiveRetrievalCompleted This event occurs when a job that was initiated 3401// for an archive retrieval is completed (InitiateJob). The status of the 3402// completed job can be "Succeeded" or "Failed". The notification sent to 3403// the SNS topic is the same output as returned from DescribeJob. 3404// 3405// * InventoryRetrievalCompleted This event occurs when a job that was initiated 3406// for an inventory retrieval is completed (InitiateJob). The status of the 3407// completed job can be "Succeeded" or "Failed". The notification sent to 3408// the SNS topic is the same output as returned from DescribeJob. 3409// 3410// An AWS account has full permission to perform all operations (actions). However, 3411// AWS Identity and Access Management (IAM) users don't have any permissions 3412// by default. You must grant them explicit permission to perform specific actions. 3413// For more information, see Access Control Using AWS Identity and Access Management 3414// (IAM) (https://docs.aws.amazon.com/amazonglacier/latest/dev/using-iam-with-amazon-glacier.html). 3415// 3416// For conceptual information and underlying REST API, see Configuring Vault 3417// Notifications in Amazon S3 Glacier (https://docs.aws.amazon.com/amazonglacier/latest/dev/configuring-notifications.html) 3418// and Set Vault Notification Configuration (https://docs.aws.amazon.com/amazonglacier/latest/dev/api-vault-notifications-put.html) 3419// in the Amazon Glacier Developer Guide. 3420// 3421// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 3422// with awserr.Error's Code and Message methods to get detailed information about 3423// the error. 3424// 3425// See the AWS API reference guide for Amazon Glacier's 3426// API operation SetVaultNotifications for usage and error information. 3427// 3428// Returned Error Types: 3429// * ResourceNotFoundException 3430// Returned if the specified resource (such as a vault, upload ID, or job ID) 3431// doesn't exist. 3432// 3433// * InvalidParameterValueException 3434// Returned if a parameter of the request is incorrectly specified. 3435// 3436// * MissingParameterValueException 3437// Returned if a required header or parameter is missing from the request. 3438// 3439// * ServiceUnavailableException 3440// Returned if the service cannot complete the request. 3441// 3442func (c *Glacier) SetVaultNotifications(input *SetVaultNotificationsInput) (*SetVaultNotificationsOutput, error) { 3443 req, out := c.SetVaultNotificationsRequest(input) 3444 return out, req.Send() 3445} 3446 3447// SetVaultNotificationsWithContext is the same as SetVaultNotifications with the addition of 3448// the ability to pass a context and additional request options. 3449// 3450// See SetVaultNotifications for details on how to use this API operation. 3451// 3452// The context must be non-nil and will be used for request cancellation. If 3453// the context is nil a panic will occur. In the future the SDK may create 3454// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 3455// for more information on using Contexts. 3456func (c *Glacier) SetVaultNotificationsWithContext(ctx aws.Context, input *SetVaultNotificationsInput, opts ...request.Option) (*SetVaultNotificationsOutput, error) { 3457 req, out := c.SetVaultNotificationsRequest(input) 3458 req.SetContext(ctx) 3459 req.ApplyOptions(opts...) 3460 return out, req.Send() 3461} 3462 3463const opUploadArchive = "UploadArchive" 3464 3465// UploadArchiveRequest generates a "aws/request.Request" representing the 3466// client's request for the UploadArchive operation. The "output" return 3467// value will be populated with the request's response once the request completes 3468// successfully. 3469// 3470// Use "Send" method on the returned Request to send the API call to the service. 3471// the "output" return value is not valid until after Send returns without error. 3472// 3473// See UploadArchive for more information on using the UploadArchive 3474// API call, and error handling. 3475// 3476// This method is useful when you want to inject custom logic or configuration 3477// into the SDK's request lifecycle. Such as custom headers, or retry logic. 3478// 3479// 3480// // Example sending a request using the UploadArchiveRequest method. 3481// req, resp := client.UploadArchiveRequest(params) 3482// 3483// err := req.Send() 3484// if err == nil { // resp is now filled 3485// fmt.Println(resp) 3486// } 3487func (c *Glacier) UploadArchiveRequest(input *UploadArchiveInput) (req *request.Request, output *ArchiveCreationOutput) { 3488 op := &request.Operation{ 3489 Name: opUploadArchive, 3490 HTTPMethod: "POST", 3491 HTTPPath: "/{accountId}/vaults/{vaultName}/archives", 3492 } 3493 3494 if input == nil { 3495 input = &UploadArchiveInput{} 3496 } 3497 3498 output = &ArchiveCreationOutput{} 3499 req = c.newRequest(op, input, output) 3500 return 3501} 3502 3503// UploadArchive API operation for Amazon Glacier. 3504// 3505// This operation adds an archive to a vault. This is a synchronous operation, 3506// and for a successful upload, your data is durably persisted. Amazon S3 Glacier 3507// returns the archive ID in the x-amz-archive-id header of the response. 3508// 3509// You must use the archive ID to access your data in Amazon S3 Glacier. After 3510// you upload an archive, you should save the archive ID returned so that you 3511// can retrieve or delete the archive later. Besides saving the archive ID, 3512// you can also index it and give it a friendly name to allow for better searching. 3513// You can also use the optional archive description field to specify how the 3514// archive is referred to in an external index of archives, such as you might 3515// create in Amazon DynamoDB. You can also get the vault inventory to obtain 3516// a list of archive IDs in a vault. For more information, see InitiateJob. 3517// 3518// You must provide a SHA256 tree hash of the data you are uploading. For information 3519// about computing a SHA256 tree hash, see Computing Checksums (https://docs.aws.amazon.com/amazonglacier/latest/dev/checksum-calculations.html). 3520// 3521// You can optionally specify an archive description of up to 1,024 printable 3522// ASCII characters. You can get the archive description when you either retrieve 3523// the archive or get the vault inventory. For more information, see InitiateJob. 3524// Amazon Glacier does not interpret the description in any way. An archive 3525// description does not need to be unique. You cannot use the description to 3526// retrieve or sort the archive list. 3527// 3528// Archives are immutable. After you upload an archive, you cannot edit the 3529// archive or its description. 3530// 3531// An AWS account has full permission to perform all operations (actions). However, 3532// AWS Identity and Access Management (IAM) users don't have any permissions 3533// by default. You must grant them explicit permission to perform specific actions. 3534// For more information, see Access Control Using AWS Identity and Access Management 3535// (IAM) (https://docs.aws.amazon.com/amazonglacier/latest/dev/using-iam-with-amazon-glacier.html). 3536// 3537// For conceptual information and underlying REST API, see Uploading an Archive 3538// in Amazon Glacier (https://docs.aws.amazon.com/amazonglacier/latest/dev/uploading-an-archive.html) 3539// and Upload Archive (https://docs.aws.amazon.com/amazonglacier/latest/dev/api-archive-post.html) 3540// in the Amazon Glacier Developer Guide. 3541// 3542// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 3543// with awserr.Error's Code and Message methods to get detailed information about 3544// the error. 3545// 3546// See the AWS API reference guide for Amazon Glacier's 3547// API operation UploadArchive for usage and error information. 3548// 3549// Returned Error Types: 3550// * ResourceNotFoundException 3551// Returned if the specified resource (such as a vault, upload ID, or job ID) 3552// doesn't exist. 3553// 3554// * InvalidParameterValueException 3555// Returned if a parameter of the request is incorrectly specified. 3556// 3557// * MissingParameterValueException 3558// Returned if a required header or parameter is missing from the request. 3559// 3560// * RequestTimeoutException 3561// Returned if, when uploading an archive, Amazon S3 Glacier times out while 3562// receiving the upload. 3563// 3564// * ServiceUnavailableException 3565// Returned if the service cannot complete the request. 3566// 3567func (c *Glacier) UploadArchive(input *UploadArchiveInput) (*ArchiveCreationOutput, error) { 3568 req, out := c.UploadArchiveRequest(input) 3569 return out, req.Send() 3570} 3571 3572// UploadArchiveWithContext is the same as UploadArchive with the addition of 3573// the ability to pass a context and additional request options. 3574// 3575// See UploadArchive for details on how to use this API operation. 3576// 3577// The context must be non-nil and will be used for request cancellation. If 3578// the context is nil a panic will occur. In the future the SDK may create 3579// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 3580// for more information on using Contexts. 3581func (c *Glacier) UploadArchiveWithContext(ctx aws.Context, input *UploadArchiveInput, opts ...request.Option) (*ArchiveCreationOutput, error) { 3582 req, out := c.UploadArchiveRequest(input) 3583 req.SetContext(ctx) 3584 req.ApplyOptions(opts...) 3585 return out, req.Send() 3586} 3587 3588const opUploadMultipartPart = "UploadMultipartPart" 3589 3590// UploadMultipartPartRequest generates a "aws/request.Request" representing the 3591// client's request for the UploadMultipartPart operation. The "output" return 3592// value will be populated with the request's response once the request completes 3593// successfully. 3594// 3595// Use "Send" method on the returned Request to send the API call to the service. 3596// the "output" return value is not valid until after Send returns without error. 3597// 3598// See UploadMultipartPart for more information on using the UploadMultipartPart 3599// API call, and error handling. 3600// 3601// This method is useful when you want to inject custom logic or configuration 3602// into the SDK's request lifecycle. Such as custom headers, or retry logic. 3603// 3604// 3605// // Example sending a request using the UploadMultipartPartRequest method. 3606// req, resp := client.UploadMultipartPartRequest(params) 3607// 3608// err := req.Send() 3609// if err == nil { // resp is now filled 3610// fmt.Println(resp) 3611// } 3612func (c *Glacier) UploadMultipartPartRequest(input *UploadMultipartPartInput) (req *request.Request, output *UploadMultipartPartOutput) { 3613 op := &request.Operation{ 3614 Name: opUploadMultipartPart, 3615 HTTPMethod: "PUT", 3616 HTTPPath: "/{accountId}/vaults/{vaultName}/multipart-uploads/{uploadId}", 3617 } 3618 3619 if input == nil { 3620 input = &UploadMultipartPartInput{} 3621 } 3622 3623 output = &UploadMultipartPartOutput{} 3624 req = c.newRequest(op, input, output) 3625 return 3626} 3627 3628// UploadMultipartPart API operation for Amazon Glacier. 3629// 3630// This operation uploads a part of an archive. You can upload archive parts 3631// in any order. You can also upload them in parallel. You can upload up to 3632// 10,000 parts for a multipart upload. 3633// 3634// Amazon Glacier rejects your upload part request if any of the following conditions 3635// is true: 3636// 3637// * SHA256 tree hash does not matchTo ensure that part data is not corrupted 3638// in transmission, you compute a SHA256 tree hash of the part and include 3639// it in your request. Upon receiving the part data, Amazon S3 Glacier also 3640// computes a SHA256 tree hash. If these hash values don't match, the operation 3641// fails. For information about computing a SHA256 tree hash, see Computing 3642// Checksums (https://docs.aws.amazon.com/amazonglacier/latest/dev/checksum-calculations.html). 3643// 3644// * Part size does not matchThe size of each part except the last must match 3645// the size specified in the corresponding InitiateMultipartUpload request. 3646// The size of the last part must be the same size as, or smaller than, the 3647// specified size. If you upload a part whose size is smaller than the part 3648// size you specified in your initiate multipart upload request and that 3649// part is not the last part, then the upload part request will succeed. 3650// However, the subsequent Complete Multipart Upload request will fail. 3651// 3652// * Range does not alignThe byte range value in the request does not align 3653// with the part size specified in the corresponding initiate request. For 3654// example, if you specify a part size of 4194304 bytes (4 MB), then 0 to 3655// 4194303 bytes (4 MB - 1) and 4194304 (4 MB) to 8388607 (8 MB - 1) are 3656// valid part ranges. However, if you set a range value of 2 MB to 6 MB, 3657// the range does not align with the part size and the upload will fail. 3658// 3659// This operation is idempotent. If you upload the same part multiple times, 3660// the data included in the most recent request overwrites the previously uploaded 3661// data. 3662// 3663// An AWS account has full permission to perform all operations (actions). However, 3664// AWS Identity and Access Management (IAM) users don't have any permissions 3665// by default. You must grant them explicit permission to perform specific actions. 3666// For more information, see Access Control Using AWS Identity and Access Management 3667// (IAM) (https://docs.aws.amazon.com/amazonglacier/latest/dev/using-iam-with-amazon-glacier.html). 3668// 3669// For conceptual information and underlying REST API, see Uploading Large Archives 3670// in Parts (Multipart Upload) (https://docs.aws.amazon.com/amazonglacier/latest/dev/uploading-archive-mpu.html) 3671// and Upload Part (https://docs.aws.amazon.com/amazonglacier/latest/dev/api-upload-part.html) 3672// in the Amazon Glacier Developer Guide. 3673// 3674// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 3675// with awserr.Error's Code and Message methods to get detailed information about 3676// the error. 3677// 3678// See the AWS API reference guide for Amazon Glacier's 3679// API operation UploadMultipartPart for usage and error information. 3680// 3681// Returned Error Types: 3682// * ResourceNotFoundException 3683// Returned if the specified resource (such as a vault, upload ID, or job ID) 3684// doesn't exist. 3685// 3686// * InvalidParameterValueException 3687// Returned if a parameter of the request is incorrectly specified. 3688// 3689// * MissingParameterValueException 3690// Returned if a required header or parameter is missing from the request. 3691// 3692// * RequestTimeoutException 3693// Returned if, when uploading an archive, Amazon S3 Glacier times out while 3694// receiving the upload. 3695// 3696// * ServiceUnavailableException 3697// Returned if the service cannot complete the request. 3698// 3699func (c *Glacier) UploadMultipartPart(input *UploadMultipartPartInput) (*UploadMultipartPartOutput, error) { 3700 req, out := c.UploadMultipartPartRequest(input) 3701 return out, req.Send() 3702} 3703 3704// UploadMultipartPartWithContext is the same as UploadMultipartPart with the addition of 3705// the ability to pass a context and additional request options. 3706// 3707// See UploadMultipartPart for details on how to use this API operation. 3708// 3709// The context must be non-nil and will be used for request cancellation. If 3710// the context is nil a panic will occur. In the future the SDK may create 3711// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 3712// for more information on using Contexts. 3713func (c *Glacier) UploadMultipartPartWithContext(ctx aws.Context, input *UploadMultipartPartInput, opts ...request.Option) (*UploadMultipartPartOutput, error) { 3714 req, out := c.UploadMultipartPartRequest(input) 3715 req.SetContext(ctx) 3716 req.ApplyOptions(opts...) 3717 return out, req.Send() 3718} 3719 3720// Provides options to abort a multipart upload identified by the upload ID. 3721// 3722// For information about the underlying REST API, see Abort Multipart Upload 3723// (https://docs.aws.amazon.com/amazonglacier/latest/dev/api-multipart-abort-upload.html). 3724// For conceptual information, see Working with Archives in Amazon S3 Glacier 3725// (https://docs.aws.amazon.com/amazonglacier/latest/dev/working-with-archives.html). 3726type AbortMultipartUploadInput struct { 3727 _ struct{} `type:"structure" nopayload:"true"` 3728 3729 // The AccountId value is the AWS account ID of the account that owns the vault. 3730 // You can either specify an AWS account ID or optionally a single '-' (hyphen), 3731 // in which case Amazon S3 Glacier uses the AWS account ID associated with the 3732 // credentials used to sign the request. If you use an account ID, do not include 3733 // any hyphens ('-') in the ID. 3734 // 3735 // AccountId is a required field 3736 AccountId *string `location:"uri" locationName:"accountId" type:"string" required:"true"` 3737 3738 // The upload ID of the multipart upload to delete. 3739 // 3740 // UploadId is a required field 3741 UploadId *string `location:"uri" locationName:"uploadId" type:"string" required:"true"` 3742 3743 // The name of the vault. 3744 // 3745 // VaultName is a required field 3746 VaultName *string `location:"uri" locationName:"vaultName" type:"string" required:"true"` 3747} 3748 3749// String returns the string representation. 3750// 3751// API parameter values that are decorated as "sensitive" in the API will not 3752// be included in the string output. The member name will be present, but the 3753// value will be replaced with "sensitive". 3754func (s AbortMultipartUploadInput) String() string { 3755 return awsutil.Prettify(s) 3756} 3757 3758// GoString returns the string representation. 3759// 3760// API parameter values that are decorated as "sensitive" in the API will not 3761// be included in the string output. The member name will be present, but the 3762// value will be replaced with "sensitive". 3763func (s AbortMultipartUploadInput) GoString() string { 3764 return s.String() 3765} 3766 3767// Validate inspects the fields of the type to determine if they are valid. 3768func (s *AbortMultipartUploadInput) Validate() error { 3769 invalidParams := request.ErrInvalidParams{Context: "AbortMultipartUploadInput"} 3770 if s.AccountId == nil { 3771 invalidParams.Add(request.NewErrParamRequired("AccountId")) 3772 } 3773 if s.AccountId != nil && len(*s.AccountId) < 1 { 3774 invalidParams.Add(request.NewErrParamMinLen("AccountId", 1)) 3775 } 3776 if s.UploadId == nil { 3777 invalidParams.Add(request.NewErrParamRequired("UploadId")) 3778 } 3779 if s.UploadId != nil && len(*s.UploadId) < 1 { 3780 invalidParams.Add(request.NewErrParamMinLen("UploadId", 1)) 3781 } 3782 if s.VaultName == nil { 3783 invalidParams.Add(request.NewErrParamRequired("VaultName")) 3784 } 3785 if s.VaultName != nil && len(*s.VaultName) < 1 { 3786 invalidParams.Add(request.NewErrParamMinLen("VaultName", 1)) 3787 } 3788 3789 if invalidParams.Len() > 0 { 3790 return invalidParams 3791 } 3792 return nil 3793} 3794 3795// SetAccountId sets the AccountId field's value. 3796func (s *AbortMultipartUploadInput) SetAccountId(v string) *AbortMultipartUploadInput { 3797 s.AccountId = &v 3798 return s 3799} 3800 3801// SetUploadId sets the UploadId field's value. 3802func (s *AbortMultipartUploadInput) SetUploadId(v string) *AbortMultipartUploadInput { 3803 s.UploadId = &v 3804 return s 3805} 3806 3807// SetVaultName sets the VaultName field's value. 3808func (s *AbortMultipartUploadInput) SetVaultName(v string) *AbortMultipartUploadInput { 3809 s.VaultName = &v 3810 return s 3811} 3812 3813type AbortMultipartUploadOutput struct { 3814 _ struct{} `type:"structure"` 3815} 3816 3817// String returns the string representation. 3818// 3819// API parameter values that are decorated as "sensitive" in the API will not 3820// be included in the string output. The member name will be present, but the 3821// value will be replaced with "sensitive". 3822func (s AbortMultipartUploadOutput) String() string { 3823 return awsutil.Prettify(s) 3824} 3825 3826// GoString returns the string representation. 3827// 3828// API parameter values that are decorated as "sensitive" in the API will not 3829// be included in the string output. The member name will be present, but the 3830// value will be replaced with "sensitive". 3831func (s AbortMultipartUploadOutput) GoString() string { 3832 return s.String() 3833} 3834 3835// The input values for AbortVaultLock. 3836type AbortVaultLockInput struct { 3837 _ struct{} `type:"structure" nopayload:"true"` 3838 3839 // The AccountId value is the AWS account ID. This value must match the AWS 3840 // account ID associated with the credentials used to sign the request. You 3841 // can either specify an AWS account ID or optionally a single '-' (hyphen), 3842 // in which case Amazon Glacier uses the AWS account ID associated with the 3843 // credentials used to sign the request. If you specify your account ID, do 3844 // not include any hyphens ('-') in the ID. 3845 // 3846 // AccountId is a required field 3847 AccountId *string `location:"uri" locationName:"accountId" type:"string" required:"true"` 3848 3849 // The name of the vault. 3850 // 3851 // VaultName is a required field 3852 VaultName *string `location:"uri" locationName:"vaultName" type:"string" required:"true"` 3853} 3854 3855// String returns the string representation. 3856// 3857// API parameter values that are decorated as "sensitive" in the API will not 3858// be included in the string output. The member name will be present, but the 3859// value will be replaced with "sensitive". 3860func (s AbortVaultLockInput) String() string { 3861 return awsutil.Prettify(s) 3862} 3863 3864// GoString returns the string representation. 3865// 3866// API parameter values that are decorated as "sensitive" in the API will not 3867// be included in the string output. The member name will be present, but the 3868// value will be replaced with "sensitive". 3869func (s AbortVaultLockInput) GoString() string { 3870 return s.String() 3871} 3872 3873// Validate inspects the fields of the type to determine if they are valid. 3874func (s *AbortVaultLockInput) Validate() error { 3875 invalidParams := request.ErrInvalidParams{Context: "AbortVaultLockInput"} 3876 if s.AccountId == nil { 3877 invalidParams.Add(request.NewErrParamRequired("AccountId")) 3878 } 3879 if s.AccountId != nil && len(*s.AccountId) < 1 { 3880 invalidParams.Add(request.NewErrParamMinLen("AccountId", 1)) 3881 } 3882 if s.VaultName == nil { 3883 invalidParams.Add(request.NewErrParamRequired("VaultName")) 3884 } 3885 if s.VaultName != nil && len(*s.VaultName) < 1 { 3886 invalidParams.Add(request.NewErrParamMinLen("VaultName", 1)) 3887 } 3888 3889 if invalidParams.Len() > 0 { 3890 return invalidParams 3891 } 3892 return nil 3893} 3894 3895// SetAccountId sets the AccountId field's value. 3896func (s *AbortVaultLockInput) SetAccountId(v string) *AbortVaultLockInput { 3897 s.AccountId = &v 3898 return s 3899} 3900 3901// SetVaultName sets the VaultName field's value. 3902func (s *AbortVaultLockInput) SetVaultName(v string) *AbortVaultLockInput { 3903 s.VaultName = &v 3904 return s 3905} 3906 3907type AbortVaultLockOutput struct { 3908 _ struct{} `type:"structure"` 3909} 3910 3911// String returns the string representation. 3912// 3913// API parameter values that are decorated as "sensitive" in the API will not 3914// be included in the string output. The member name will be present, but the 3915// value will be replaced with "sensitive". 3916func (s AbortVaultLockOutput) String() string { 3917 return awsutil.Prettify(s) 3918} 3919 3920// GoString returns the string representation. 3921// 3922// API parameter values that are decorated as "sensitive" in the API will not 3923// be included in the string output. The member name will be present, but the 3924// value will be replaced with "sensitive". 3925func (s AbortVaultLockOutput) GoString() string { 3926 return s.String() 3927} 3928 3929// The input values for AddTagsToVault. 3930type AddTagsToVaultInput struct { 3931 _ struct{} `type:"structure"` 3932 3933 // The AccountId value is the AWS account ID of the account that owns the vault. 3934 // You can either specify an AWS account ID or optionally a single '-' (hyphen), 3935 // in which case Amazon S3 Glacier uses the AWS account ID associated with the 3936 // credentials used to sign the request. If you use an account ID, do not include 3937 // any hyphens ('-') in the ID. 3938 // 3939 // AccountId is a required field 3940 AccountId *string `location:"uri" locationName:"accountId" type:"string" required:"true"` 3941 3942 // The tags to add to the vault. Each tag is composed of a key and a value. 3943 // The value can be an empty string. 3944 Tags map[string]*string `type:"map"` 3945 3946 // The name of the vault. 3947 // 3948 // VaultName is a required field 3949 VaultName *string `location:"uri" locationName:"vaultName" type:"string" required:"true"` 3950} 3951 3952// String returns the string representation. 3953// 3954// API parameter values that are decorated as "sensitive" in the API will not 3955// be included in the string output. The member name will be present, but the 3956// value will be replaced with "sensitive". 3957func (s AddTagsToVaultInput) String() string { 3958 return awsutil.Prettify(s) 3959} 3960 3961// GoString returns the string representation. 3962// 3963// API parameter values that are decorated as "sensitive" in the API will not 3964// be included in the string output. The member name will be present, but the 3965// value will be replaced with "sensitive". 3966func (s AddTagsToVaultInput) GoString() string { 3967 return s.String() 3968} 3969 3970// Validate inspects the fields of the type to determine if they are valid. 3971func (s *AddTagsToVaultInput) Validate() error { 3972 invalidParams := request.ErrInvalidParams{Context: "AddTagsToVaultInput"} 3973 if s.AccountId == nil { 3974 invalidParams.Add(request.NewErrParamRequired("AccountId")) 3975 } 3976 if s.AccountId != nil && len(*s.AccountId) < 1 { 3977 invalidParams.Add(request.NewErrParamMinLen("AccountId", 1)) 3978 } 3979 if s.VaultName == nil { 3980 invalidParams.Add(request.NewErrParamRequired("VaultName")) 3981 } 3982 if s.VaultName != nil && len(*s.VaultName) < 1 { 3983 invalidParams.Add(request.NewErrParamMinLen("VaultName", 1)) 3984 } 3985 3986 if invalidParams.Len() > 0 { 3987 return invalidParams 3988 } 3989 return nil 3990} 3991 3992// SetAccountId sets the AccountId field's value. 3993func (s *AddTagsToVaultInput) SetAccountId(v string) *AddTagsToVaultInput { 3994 s.AccountId = &v 3995 return s 3996} 3997 3998// SetTags sets the Tags field's value. 3999func (s *AddTagsToVaultInput) SetTags(v map[string]*string) *AddTagsToVaultInput { 4000 s.Tags = v 4001 return s 4002} 4003 4004// SetVaultName sets the VaultName field's value. 4005func (s *AddTagsToVaultInput) SetVaultName(v string) *AddTagsToVaultInput { 4006 s.VaultName = &v 4007 return s 4008} 4009 4010type AddTagsToVaultOutput struct { 4011 _ struct{} `type:"structure"` 4012} 4013 4014// String returns the string representation. 4015// 4016// API parameter values that are decorated as "sensitive" in the API will not 4017// be included in the string output. The member name will be present, but the 4018// value will be replaced with "sensitive". 4019func (s AddTagsToVaultOutput) String() string { 4020 return awsutil.Prettify(s) 4021} 4022 4023// GoString returns the string representation. 4024// 4025// API parameter values that are decorated as "sensitive" in the API will not 4026// be included in the string output. The member name will be present, but the 4027// value will be replaced with "sensitive". 4028func (s AddTagsToVaultOutput) GoString() string { 4029 return s.String() 4030} 4031 4032// Contains the Amazon S3 Glacier response to your request. 4033// 4034// For information about the underlying REST API, see Upload Archive (https://docs.aws.amazon.com/amazonglacier/latest/dev/api-archive-post.html). 4035// For conceptual information, see Working with Archives in Amazon S3 Glacier 4036// (https://docs.aws.amazon.com/amazonglacier/latest/dev/working-with-archives.html). 4037type ArchiveCreationOutput struct { 4038 _ struct{} `type:"structure"` 4039 4040 // The ID of the archive. This value is also included as part of the location. 4041 ArchiveId *string `location:"header" locationName:"x-amz-archive-id" type:"string"` 4042 4043 // The checksum of the archive computed by Amazon S3 Glacier. 4044 Checksum *string `location:"header" locationName:"x-amz-sha256-tree-hash" type:"string"` 4045 4046 // The relative URI path of the newly added archive resource. 4047 Location *string `location:"header" locationName:"Location" type:"string"` 4048} 4049 4050// String returns the string representation. 4051// 4052// API parameter values that are decorated as "sensitive" in the API will not 4053// be included in the string output. The member name will be present, but the 4054// value will be replaced with "sensitive". 4055func (s ArchiveCreationOutput) String() string { 4056 return awsutil.Prettify(s) 4057} 4058 4059// GoString returns the string representation. 4060// 4061// API parameter values that are decorated as "sensitive" in the API will not 4062// be included in the string output. The member name will be present, but the 4063// value will be replaced with "sensitive". 4064func (s ArchiveCreationOutput) GoString() string { 4065 return s.String() 4066} 4067 4068// SetArchiveId sets the ArchiveId field's value. 4069func (s *ArchiveCreationOutput) SetArchiveId(v string) *ArchiveCreationOutput { 4070 s.ArchiveId = &v 4071 return s 4072} 4073 4074// SetChecksum sets the Checksum field's value. 4075func (s *ArchiveCreationOutput) SetChecksum(v string) *ArchiveCreationOutput { 4076 s.Checksum = &v 4077 return s 4078} 4079 4080// SetLocation sets the Location field's value. 4081func (s *ArchiveCreationOutput) SetLocation(v string) *ArchiveCreationOutput { 4082 s.Location = &v 4083 return s 4084} 4085 4086// Contains information about the comma-separated value (CSV) file to select 4087// from. 4088type CSVInput struct { 4089 _ struct{} `type:"structure"` 4090 4091 // A single character used to indicate that a row should be ignored when the 4092 // character is present at the start of that row. 4093 Comments *string `type:"string"` 4094 4095 // A value used to separate individual fields from each other within a record. 4096 FieldDelimiter *string `type:"string"` 4097 4098 // Describes the first line of input. Valid values are None, Ignore, and Use. 4099 FileHeaderInfo *string `type:"string" enum:"FileHeaderInfo"` 4100 4101 // A value used as an escape character where the field delimiter is part of 4102 // the value. 4103 QuoteCharacter *string `type:"string"` 4104 4105 // A single character used for escaping the quotation-mark character inside 4106 // an already escaped value. 4107 QuoteEscapeCharacter *string `type:"string"` 4108 4109 // A value used to separate individual records from each other. 4110 RecordDelimiter *string `type:"string"` 4111} 4112 4113// String returns the string representation. 4114// 4115// API parameter values that are decorated as "sensitive" in the API will not 4116// be included in the string output. The member name will be present, but the 4117// value will be replaced with "sensitive". 4118func (s CSVInput) String() string { 4119 return awsutil.Prettify(s) 4120} 4121 4122// GoString returns the string representation. 4123// 4124// API parameter values that are decorated as "sensitive" in the API will not 4125// be included in the string output. The member name will be present, but the 4126// value will be replaced with "sensitive". 4127func (s CSVInput) GoString() string { 4128 return s.String() 4129} 4130 4131// SetComments sets the Comments field's value. 4132func (s *CSVInput) SetComments(v string) *CSVInput { 4133 s.Comments = &v 4134 return s 4135} 4136 4137// SetFieldDelimiter sets the FieldDelimiter field's value. 4138func (s *CSVInput) SetFieldDelimiter(v string) *CSVInput { 4139 s.FieldDelimiter = &v 4140 return s 4141} 4142 4143// SetFileHeaderInfo sets the FileHeaderInfo field's value. 4144func (s *CSVInput) SetFileHeaderInfo(v string) *CSVInput { 4145 s.FileHeaderInfo = &v 4146 return s 4147} 4148 4149// SetQuoteCharacter sets the QuoteCharacter field's value. 4150func (s *CSVInput) SetQuoteCharacter(v string) *CSVInput { 4151 s.QuoteCharacter = &v 4152 return s 4153} 4154 4155// SetQuoteEscapeCharacter sets the QuoteEscapeCharacter field's value. 4156func (s *CSVInput) SetQuoteEscapeCharacter(v string) *CSVInput { 4157 s.QuoteEscapeCharacter = &v 4158 return s 4159} 4160 4161// SetRecordDelimiter sets the RecordDelimiter field's value. 4162func (s *CSVInput) SetRecordDelimiter(v string) *CSVInput { 4163 s.RecordDelimiter = &v 4164 return s 4165} 4166 4167// Contains information about the comma-separated value (CSV) file that the 4168// job results are stored in. 4169type CSVOutput struct { 4170 _ struct{} `type:"structure"` 4171 4172 // A value used to separate individual fields from each other within a record. 4173 FieldDelimiter *string `type:"string"` 4174 4175 // A value used as an escape character where the field delimiter is part of 4176 // the value. 4177 QuoteCharacter *string `type:"string"` 4178 4179 // A single character used for escaping the quotation-mark character inside 4180 // an already escaped value. 4181 QuoteEscapeCharacter *string `type:"string"` 4182 4183 // A value that indicates whether all output fields should be contained within 4184 // quotation marks. 4185 QuoteFields *string `type:"string" enum:"QuoteFields"` 4186 4187 // A value used to separate individual records from each other. 4188 RecordDelimiter *string `type:"string"` 4189} 4190 4191// String returns the string representation. 4192// 4193// API parameter values that are decorated as "sensitive" in the API will not 4194// be included in the string output. The member name will be present, but the 4195// value will be replaced with "sensitive". 4196func (s CSVOutput) String() string { 4197 return awsutil.Prettify(s) 4198} 4199 4200// GoString returns the string representation. 4201// 4202// API parameter values that are decorated as "sensitive" in the API will not 4203// be included in the string output. The member name will be present, but the 4204// value will be replaced with "sensitive". 4205func (s CSVOutput) GoString() string { 4206 return s.String() 4207} 4208 4209// SetFieldDelimiter sets the FieldDelimiter field's value. 4210func (s *CSVOutput) SetFieldDelimiter(v string) *CSVOutput { 4211 s.FieldDelimiter = &v 4212 return s 4213} 4214 4215// SetQuoteCharacter sets the QuoteCharacter field's value. 4216func (s *CSVOutput) SetQuoteCharacter(v string) *CSVOutput { 4217 s.QuoteCharacter = &v 4218 return s 4219} 4220 4221// SetQuoteEscapeCharacter sets the QuoteEscapeCharacter field's value. 4222func (s *CSVOutput) SetQuoteEscapeCharacter(v string) *CSVOutput { 4223 s.QuoteEscapeCharacter = &v 4224 return s 4225} 4226 4227// SetQuoteFields sets the QuoteFields field's value. 4228func (s *CSVOutput) SetQuoteFields(v string) *CSVOutput { 4229 s.QuoteFields = &v 4230 return s 4231} 4232 4233// SetRecordDelimiter sets the RecordDelimiter field's value. 4234func (s *CSVOutput) SetRecordDelimiter(v string) *CSVOutput { 4235 s.RecordDelimiter = &v 4236 return s 4237} 4238 4239// Provides options to complete a multipart upload operation. This informs Amazon 4240// Glacier that all the archive parts have been uploaded and Amazon S3 Glacier 4241// (Glacier) can now assemble the archive from the uploaded parts. After assembling 4242// and saving the archive to the vault, Glacier returns the URI path of the 4243// newly created archive resource. 4244type CompleteMultipartUploadInput struct { 4245 _ struct{} `type:"structure" nopayload:"true"` 4246 4247 // The AccountId value is the AWS account ID of the account that owns the vault. 4248 // You can either specify an AWS account ID or optionally a single '-' (hyphen), 4249 // in which case Amazon S3 Glacier uses the AWS account ID associated with the 4250 // credentials used to sign the request. If you use an account ID, do not include 4251 // any hyphens ('-') in the ID. 4252 // 4253 // AccountId is a required field 4254 AccountId *string `location:"uri" locationName:"accountId" type:"string" required:"true"` 4255 4256 // The total size, in bytes, of the entire archive. This value should be the 4257 // sum of all the sizes of the individual parts that you uploaded. 4258 ArchiveSize *string `location:"header" locationName:"x-amz-archive-size" type:"string"` 4259 4260 // The SHA256 tree hash of the entire archive. It is the tree hash of SHA256 4261 // tree hash of the individual parts. If the value you specify in the request 4262 // does not match the SHA256 tree hash of the final assembled archive as computed 4263 // by Amazon S3 Glacier (Glacier), Glacier returns an error and the request 4264 // fails. 4265 Checksum *string `location:"header" locationName:"x-amz-sha256-tree-hash" type:"string"` 4266 4267 // The upload ID of the multipart upload. 4268 // 4269 // UploadId is a required field 4270 UploadId *string `location:"uri" locationName:"uploadId" type:"string" required:"true"` 4271 4272 // The name of the vault. 4273 // 4274 // VaultName is a required field 4275 VaultName *string `location:"uri" locationName:"vaultName" type:"string" required:"true"` 4276} 4277 4278// String returns the string representation. 4279// 4280// API parameter values that are decorated as "sensitive" in the API will not 4281// be included in the string output. The member name will be present, but the 4282// value will be replaced with "sensitive". 4283func (s CompleteMultipartUploadInput) String() string { 4284 return awsutil.Prettify(s) 4285} 4286 4287// GoString returns the string representation. 4288// 4289// API parameter values that are decorated as "sensitive" in the API will not 4290// be included in the string output. The member name will be present, but the 4291// value will be replaced with "sensitive". 4292func (s CompleteMultipartUploadInput) GoString() string { 4293 return s.String() 4294} 4295 4296// Validate inspects the fields of the type to determine if they are valid. 4297func (s *CompleteMultipartUploadInput) Validate() error { 4298 invalidParams := request.ErrInvalidParams{Context: "CompleteMultipartUploadInput"} 4299 if s.AccountId == nil { 4300 invalidParams.Add(request.NewErrParamRequired("AccountId")) 4301 } 4302 if s.AccountId != nil && len(*s.AccountId) < 1 { 4303 invalidParams.Add(request.NewErrParamMinLen("AccountId", 1)) 4304 } 4305 if s.UploadId == nil { 4306 invalidParams.Add(request.NewErrParamRequired("UploadId")) 4307 } 4308 if s.UploadId != nil && len(*s.UploadId) < 1 { 4309 invalidParams.Add(request.NewErrParamMinLen("UploadId", 1)) 4310 } 4311 if s.VaultName == nil { 4312 invalidParams.Add(request.NewErrParamRequired("VaultName")) 4313 } 4314 if s.VaultName != nil && len(*s.VaultName) < 1 { 4315 invalidParams.Add(request.NewErrParamMinLen("VaultName", 1)) 4316 } 4317 4318 if invalidParams.Len() > 0 { 4319 return invalidParams 4320 } 4321 return nil 4322} 4323 4324// SetAccountId sets the AccountId field's value. 4325func (s *CompleteMultipartUploadInput) SetAccountId(v string) *CompleteMultipartUploadInput { 4326 s.AccountId = &v 4327 return s 4328} 4329 4330// SetArchiveSize sets the ArchiveSize field's value. 4331func (s *CompleteMultipartUploadInput) SetArchiveSize(v string) *CompleteMultipartUploadInput { 4332 s.ArchiveSize = &v 4333 return s 4334} 4335 4336// SetChecksum sets the Checksum field's value. 4337func (s *CompleteMultipartUploadInput) SetChecksum(v string) *CompleteMultipartUploadInput { 4338 s.Checksum = &v 4339 return s 4340} 4341 4342// SetUploadId sets the UploadId field's value. 4343func (s *CompleteMultipartUploadInput) SetUploadId(v string) *CompleteMultipartUploadInput { 4344 s.UploadId = &v 4345 return s 4346} 4347 4348// SetVaultName sets the VaultName field's value. 4349func (s *CompleteMultipartUploadInput) SetVaultName(v string) *CompleteMultipartUploadInput { 4350 s.VaultName = &v 4351 return s 4352} 4353 4354// The input values for CompleteVaultLock. 4355type CompleteVaultLockInput struct { 4356 _ struct{} `type:"structure" nopayload:"true"` 4357 4358 // The AccountId value is the AWS account ID. This value must match the AWS 4359 // account ID associated with the credentials used to sign the request. You 4360 // can either specify an AWS account ID or optionally a single '-' (hyphen), 4361 // in which case Amazon Glacier uses the AWS account ID associated with the 4362 // credentials used to sign the request. If you specify your account ID, do 4363 // not include any hyphens ('-') in the ID. 4364 // 4365 // AccountId is a required field 4366 AccountId *string `location:"uri" locationName:"accountId" type:"string" required:"true"` 4367 4368 // The lockId value is the lock ID obtained from a InitiateVaultLock request. 4369 // 4370 // LockId is a required field 4371 LockId *string `location:"uri" locationName:"lockId" type:"string" required:"true"` 4372 4373 // The name of the vault. 4374 // 4375 // VaultName is a required field 4376 VaultName *string `location:"uri" locationName:"vaultName" type:"string" required:"true"` 4377} 4378 4379// String returns the string representation. 4380// 4381// API parameter values that are decorated as "sensitive" in the API will not 4382// be included in the string output. The member name will be present, but the 4383// value will be replaced with "sensitive". 4384func (s CompleteVaultLockInput) String() string { 4385 return awsutil.Prettify(s) 4386} 4387 4388// GoString returns the string representation. 4389// 4390// API parameter values that are decorated as "sensitive" in the API will not 4391// be included in the string output. The member name will be present, but the 4392// value will be replaced with "sensitive". 4393func (s CompleteVaultLockInput) GoString() string { 4394 return s.String() 4395} 4396 4397// Validate inspects the fields of the type to determine if they are valid. 4398func (s *CompleteVaultLockInput) Validate() error { 4399 invalidParams := request.ErrInvalidParams{Context: "CompleteVaultLockInput"} 4400 if s.AccountId == nil { 4401 invalidParams.Add(request.NewErrParamRequired("AccountId")) 4402 } 4403 if s.AccountId != nil && len(*s.AccountId) < 1 { 4404 invalidParams.Add(request.NewErrParamMinLen("AccountId", 1)) 4405 } 4406 if s.LockId == nil { 4407 invalidParams.Add(request.NewErrParamRequired("LockId")) 4408 } 4409 if s.LockId != nil && len(*s.LockId) < 1 { 4410 invalidParams.Add(request.NewErrParamMinLen("LockId", 1)) 4411 } 4412 if s.VaultName == nil { 4413 invalidParams.Add(request.NewErrParamRequired("VaultName")) 4414 } 4415 if s.VaultName != nil && len(*s.VaultName) < 1 { 4416 invalidParams.Add(request.NewErrParamMinLen("VaultName", 1)) 4417 } 4418 4419 if invalidParams.Len() > 0 { 4420 return invalidParams 4421 } 4422 return nil 4423} 4424 4425// SetAccountId sets the AccountId field's value. 4426func (s *CompleteVaultLockInput) SetAccountId(v string) *CompleteVaultLockInput { 4427 s.AccountId = &v 4428 return s 4429} 4430 4431// SetLockId sets the LockId field's value. 4432func (s *CompleteVaultLockInput) SetLockId(v string) *CompleteVaultLockInput { 4433 s.LockId = &v 4434 return s 4435} 4436 4437// SetVaultName sets the VaultName field's value. 4438func (s *CompleteVaultLockInput) SetVaultName(v string) *CompleteVaultLockInput { 4439 s.VaultName = &v 4440 return s 4441} 4442 4443type CompleteVaultLockOutput struct { 4444 _ struct{} `type:"structure"` 4445} 4446 4447// String returns the string representation. 4448// 4449// API parameter values that are decorated as "sensitive" in the API will not 4450// be included in the string output. The member name will be present, but the 4451// value will be replaced with "sensitive". 4452func (s CompleteVaultLockOutput) String() string { 4453 return awsutil.Prettify(s) 4454} 4455 4456// GoString returns the string representation. 4457// 4458// API parameter values that are decorated as "sensitive" in the API will not 4459// be included in the string output. The member name will be present, but the 4460// value will be replaced with "sensitive". 4461func (s CompleteVaultLockOutput) GoString() string { 4462 return s.String() 4463} 4464 4465// Provides options to create a vault. 4466type CreateVaultInput struct { 4467 _ struct{} `type:"structure" nopayload:"true"` 4468 4469 // The AccountId value is the AWS account ID. This value must match the AWS 4470 // account ID associated with the credentials used to sign the request. You 4471 // can either specify an AWS account ID or optionally a single '-' (hyphen), 4472 // in which case Amazon S3 Glacier uses the AWS account ID associated with the 4473 // credentials used to sign the request. If you specify your account ID, do 4474 // not include any hyphens ('-') in the ID. 4475 // 4476 // AccountId is a required field 4477 AccountId *string `location:"uri" locationName:"accountId" type:"string" required:"true"` 4478 4479 // The name of the vault. 4480 // 4481 // VaultName is a required field 4482 VaultName *string `location:"uri" locationName:"vaultName" type:"string" required:"true"` 4483} 4484 4485// String returns the string representation. 4486// 4487// API parameter values that are decorated as "sensitive" in the API will not 4488// be included in the string output. The member name will be present, but the 4489// value will be replaced with "sensitive". 4490func (s CreateVaultInput) String() string { 4491 return awsutil.Prettify(s) 4492} 4493 4494// GoString returns the string representation. 4495// 4496// API parameter values that are decorated as "sensitive" in the API will not 4497// be included in the string output. The member name will be present, but the 4498// value will be replaced with "sensitive". 4499func (s CreateVaultInput) GoString() string { 4500 return s.String() 4501} 4502 4503// Validate inspects the fields of the type to determine if they are valid. 4504func (s *CreateVaultInput) Validate() error { 4505 invalidParams := request.ErrInvalidParams{Context: "CreateVaultInput"} 4506 if s.AccountId == nil { 4507 invalidParams.Add(request.NewErrParamRequired("AccountId")) 4508 } 4509 if s.AccountId != nil && len(*s.AccountId) < 1 { 4510 invalidParams.Add(request.NewErrParamMinLen("AccountId", 1)) 4511 } 4512 if s.VaultName == nil { 4513 invalidParams.Add(request.NewErrParamRequired("VaultName")) 4514 } 4515 if s.VaultName != nil && len(*s.VaultName) < 1 { 4516 invalidParams.Add(request.NewErrParamMinLen("VaultName", 1)) 4517 } 4518 4519 if invalidParams.Len() > 0 { 4520 return invalidParams 4521 } 4522 return nil 4523} 4524 4525// SetAccountId sets the AccountId field's value. 4526func (s *CreateVaultInput) SetAccountId(v string) *CreateVaultInput { 4527 s.AccountId = &v 4528 return s 4529} 4530 4531// SetVaultName sets the VaultName field's value. 4532func (s *CreateVaultInput) SetVaultName(v string) *CreateVaultInput { 4533 s.VaultName = &v 4534 return s 4535} 4536 4537// Contains the Amazon S3 Glacier response to your request. 4538type CreateVaultOutput struct { 4539 _ struct{} `type:"structure"` 4540 4541 // The URI of the vault that was created. 4542 Location *string `location:"header" locationName:"Location" type:"string"` 4543} 4544 4545// String returns the string representation. 4546// 4547// API parameter values that are decorated as "sensitive" in the API will not 4548// be included in the string output. The member name will be present, but the 4549// value will be replaced with "sensitive". 4550func (s CreateVaultOutput) String() string { 4551 return awsutil.Prettify(s) 4552} 4553 4554// GoString returns the string representation. 4555// 4556// API parameter values that are decorated as "sensitive" in the API will not 4557// be included in the string output. The member name will be present, but the 4558// value will be replaced with "sensitive". 4559func (s CreateVaultOutput) GoString() string { 4560 return s.String() 4561} 4562 4563// SetLocation sets the Location field's value. 4564func (s *CreateVaultOutput) SetLocation(v string) *CreateVaultOutput { 4565 s.Location = &v 4566 return s 4567} 4568 4569// Data retrieval policy. 4570type DataRetrievalPolicy struct { 4571 _ struct{} `type:"structure"` 4572 4573 // The policy rule. Although this is a list type, currently there must be only 4574 // one rule, which contains a Strategy field and optionally a BytesPerHour field. 4575 Rules []*DataRetrievalRule `type:"list"` 4576} 4577 4578// String returns the string representation. 4579// 4580// API parameter values that are decorated as "sensitive" in the API will not 4581// be included in the string output. The member name will be present, but the 4582// value will be replaced with "sensitive". 4583func (s DataRetrievalPolicy) String() string { 4584 return awsutil.Prettify(s) 4585} 4586 4587// GoString returns the string representation. 4588// 4589// API parameter values that are decorated as "sensitive" in the API will not 4590// be included in the string output. The member name will be present, but the 4591// value will be replaced with "sensitive". 4592func (s DataRetrievalPolicy) GoString() string { 4593 return s.String() 4594} 4595 4596// SetRules sets the Rules field's value. 4597func (s *DataRetrievalPolicy) SetRules(v []*DataRetrievalRule) *DataRetrievalPolicy { 4598 s.Rules = v 4599 return s 4600} 4601 4602// Data retrieval policy rule. 4603type DataRetrievalRule struct { 4604 _ struct{} `type:"structure"` 4605 4606 // The maximum number of bytes that can be retrieved in an hour. 4607 // 4608 // This field is required only if the value of the Strategy field is BytesPerHour. 4609 // Your PUT operation will be rejected if the Strategy field is not set to BytesPerHour 4610 // and you set this field. 4611 BytesPerHour *int64 `type:"long"` 4612 4613 // The type of data retrieval policy to set. 4614 // 4615 // Valid values: BytesPerHour|FreeTier|None 4616 Strategy *string `type:"string"` 4617} 4618 4619// String returns the string representation. 4620// 4621// API parameter values that are decorated as "sensitive" in the API will not 4622// be included in the string output. The member name will be present, but the 4623// value will be replaced with "sensitive". 4624func (s DataRetrievalRule) String() string { 4625 return awsutil.Prettify(s) 4626} 4627 4628// GoString returns the string representation. 4629// 4630// API parameter values that are decorated as "sensitive" in the API will not 4631// be included in the string output. The member name will be present, but the 4632// value will be replaced with "sensitive". 4633func (s DataRetrievalRule) GoString() string { 4634 return s.String() 4635} 4636 4637// SetBytesPerHour sets the BytesPerHour field's value. 4638func (s *DataRetrievalRule) SetBytesPerHour(v int64) *DataRetrievalRule { 4639 s.BytesPerHour = &v 4640 return s 4641} 4642 4643// SetStrategy sets the Strategy field's value. 4644func (s *DataRetrievalRule) SetStrategy(v string) *DataRetrievalRule { 4645 s.Strategy = &v 4646 return s 4647} 4648 4649// Provides options for deleting an archive from an Amazon S3 Glacier vault. 4650type DeleteArchiveInput struct { 4651 _ struct{} `type:"structure" nopayload:"true"` 4652 4653 // The AccountId value is the AWS account ID of the account that owns the vault. 4654 // You can either specify an AWS account ID or optionally a single '-' (hyphen), 4655 // in which case Amazon S3 Glacier uses the AWS account ID associated with the 4656 // credentials used to sign the request. If you use an account ID, do not include 4657 // any hyphens ('-') in the ID. 4658 // 4659 // AccountId is a required field 4660 AccountId *string `location:"uri" locationName:"accountId" type:"string" required:"true"` 4661 4662 // The ID of the archive to delete. 4663 // 4664 // ArchiveId is a required field 4665 ArchiveId *string `location:"uri" locationName:"archiveId" type:"string" required:"true"` 4666 4667 // The name of the vault. 4668 // 4669 // VaultName is a required field 4670 VaultName *string `location:"uri" locationName:"vaultName" type:"string" required:"true"` 4671} 4672 4673// String returns the string representation. 4674// 4675// API parameter values that are decorated as "sensitive" in the API will not 4676// be included in the string output. The member name will be present, but the 4677// value will be replaced with "sensitive". 4678func (s DeleteArchiveInput) String() string { 4679 return awsutil.Prettify(s) 4680} 4681 4682// GoString returns the string representation. 4683// 4684// API parameter values that are decorated as "sensitive" in the API will not 4685// be included in the string output. The member name will be present, but the 4686// value will be replaced with "sensitive". 4687func (s DeleteArchiveInput) GoString() string { 4688 return s.String() 4689} 4690 4691// Validate inspects the fields of the type to determine if they are valid. 4692func (s *DeleteArchiveInput) Validate() error { 4693 invalidParams := request.ErrInvalidParams{Context: "DeleteArchiveInput"} 4694 if s.AccountId == nil { 4695 invalidParams.Add(request.NewErrParamRequired("AccountId")) 4696 } 4697 if s.AccountId != nil && len(*s.AccountId) < 1 { 4698 invalidParams.Add(request.NewErrParamMinLen("AccountId", 1)) 4699 } 4700 if s.ArchiveId == nil { 4701 invalidParams.Add(request.NewErrParamRequired("ArchiveId")) 4702 } 4703 if s.ArchiveId != nil && len(*s.ArchiveId) < 1 { 4704 invalidParams.Add(request.NewErrParamMinLen("ArchiveId", 1)) 4705 } 4706 if s.VaultName == nil { 4707 invalidParams.Add(request.NewErrParamRequired("VaultName")) 4708 } 4709 if s.VaultName != nil && len(*s.VaultName) < 1 { 4710 invalidParams.Add(request.NewErrParamMinLen("VaultName", 1)) 4711 } 4712 4713 if invalidParams.Len() > 0 { 4714 return invalidParams 4715 } 4716 return nil 4717} 4718 4719// SetAccountId sets the AccountId field's value. 4720func (s *DeleteArchiveInput) SetAccountId(v string) *DeleteArchiveInput { 4721 s.AccountId = &v 4722 return s 4723} 4724 4725// SetArchiveId sets the ArchiveId field's value. 4726func (s *DeleteArchiveInput) SetArchiveId(v string) *DeleteArchiveInput { 4727 s.ArchiveId = &v 4728 return s 4729} 4730 4731// SetVaultName sets the VaultName field's value. 4732func (s *DeleteArchiveInput) SetVaultName(v string) *DeleteArchiveInput { 4733 s.VaultName = &v 4734 return s 4735} 4736 4737type DeleteArchiveOutput struct { 4738 _ struct{} `type:"structure"` 4739} 4740 4741// String returns the string representation. 4742// 4743// API parameter values that are decorated as "sensitive" in the API will not 4744// be included in the string output. The member name will be present, but the 4745// value will be replaced with "sensitive". 4746func (s DeleteArchiveOutput) String() string { 4747 return awsutil.Prettify(s) 4748} 4749 4750// GoString returns the string representation. 4751// 4752// API parameter values that are decorated as "sensitive" in the API will not 4753// be included in the string output. The member name will be present, but the 4754// value will be replaced with "sensitive". 4755func (s DeleteArchiveOutput) GoString() string { 4756 return s.String() 4757} 4758 4759// DeleteVaultAccessPolicy input. 4760type DeleteVaultAccessPolicyInput struct { 4761 _ struct{} `type:"structure" nopayload:"true"` 4762 4763 // The AccountId value is the AWS account ID of the account that owns the vault. 4764 // You can either specify an AWS account ID or optionally a single '-' (hyphen), 4765 // in which case Amazon S3 Glacier uses the AWS account ID associated with the 4766 // credentials used to sign the request. If you use an account ID, do not include 4767 // any hyphens ('-') in the ID. 4768 // 4769 // AccountId is a required field 4770 AccountId *string `location:"uri" locationName:"accountId" type:"string" required:"true"` 4771 4772 // The name of the vault. 4773 // 4774 // VaultName is a required field 4775 VaultName *string `location:"uri" locationName:"vaultName" type:"string" required:"true"` 4776} 4777 4778// String returns the string representation. 4779// 4780// API parameter values that are decorated as "sensitive" in the API will not 4781// be included in the string output. The member name will be present, but the 4782// value will be replaced with "sensitive". 4783func (s DeleteVaultAccessPolicyInput) String() string { 4784 return awsutil.Prettify(s) 4785} 4786 4787// GoString returns the string representation. 4788// 4789// API parameter values that are decorated as "sensitive" in the API will not 4790// be included in the string output. The member name will be present, but the 4791// value will be replaced with "sensitive". 4792func (s DeleteVaultAccessPolicyInput) GoString() string { 4793 return s.String() 4794} 4795 4796// Validate inspects the fields of the type to determine if they are valid. 4797func (s *DeleteVaultAccessPolicyInput) Validate() error { 4798 invalidParams := request.ErrInvalidParams{Context: "DeleteVaultAccessPolicyInput"} 4799 if s.AccountId == nil { 4800 invalidParams.Add(request.NewErrParamRequired("AccountId")) 4801 } 4802 if s.AccountId != nil && len(*s.AccountId) < 1 { 4803 invalidParams.Add(request.NewErrParamMinLen("AccountId", 1)) 4804 } 4805 if s.VaultName == nil { 4806 invalidParams.Add(request.NewErrParamRequired("VaultName")) 4807 } 4808 if s.VaultName != nil && len(*s.VaultName) < 1 { 4809 invalidParams.Add(request.NewErrParamMinLen("VaultName", 1)) 4810 } 4811 4812 if invalidParams.Len() > 0 { 4813 return invalidParams 4814 } 4815 return nil 4816} 4817 4818// SetAccountId sets the AccountId field's value. 4819func (s *DeleteVaultAccessPolicyInput) SetAccountId(v string) *DeleteVaultAccessPolicyInput { 4820 s.AccountId = &v 4821 return s 4822} 4823 4824// SetVaultName sets the VaultName field's value. 4825func (s *DeleteVaultAccessPolicyInput) SetVaultName(v string) *DeleteVaultAccessPolicyInput { 4826 s.VaultName = &v 4827 return s 4828} 4829 4830type DeleteVaultAccessPolicyOutput struct { 4831 _ struct{} `type:"structure"` 4832} 4833 4834// String returns the string representation. 4835// 4836// API parameter values that are decorated as "sensitive" in the API will not 4837// be included in the string output. The member name will be present, but the 4838// value will be replaced with "sensitive". 4839func (s DeleteVaultAccessPolicyOutput) String() string { 4840 return awsutil.Prettify(s) 4841} 4842 4843// GoString returns the string representation. 4844// 4845// API parameter values that are decorated as "sensitive" in the API will not 4846// be included in the string output. The member name will be present, but the 4847// value will be replaced with "sensitive". 4848func (s DeleteVaultAccessPolicyOutput) GoString() string { 4849 return s.String() 4850} 4851 4852// Provides options for deleting a vault from Amazon S3 Glacier. 4853type DeleteVaultInput struct { 4854 _ struct{} `type:"structure" nopayload:"true"` 4855 4856 // The AccountId value is the AWS account ID of the account that owns the vault. 4857 // You can either specify an AWS account ID or optionally a single '-' (hyphen), 4858 // in which case Amazon S3 Glacier uses the AWS account ID associated with the 4859 // credentials used to sign the request. If you use an account ID, do not include 4860 // any hyphens ('-') in the ID. 4861 // 4862 // AccountId is a required field 4863 AccountId *string `location:"uri" locationName:"accountId" type:"string" required:"true"` 4864 4865 // The name of the vault. 4866 // 4867 // VaultName is a required field 4868 VaultName *string `location:"uri" locationName:"vaultName" type:"string" required:"true"` 4869} 4870 4871// String returns the string representation. 4872// 4873// API parameter values that are decorated as "sensitive" in the API will not 4874// be included in the string output. The member name will be present, but the 4875// value will be replaced with "sensitive". 4876func (s DeleteVaultInput) String() string { 4877 return awsutil.Prettify(s) 4878} 4879 4880// GoString returns the string representation. 4881// 4882// API parameter values that are decorated as "sensitive" in the API will not 4883// be included in the string output. The member name will be present, but the 4884// value will be replaced with "sensitive". 4885func (s DeleteVaultInput) GoString() string { 4886 return s.String() 4887} 4888 4889// Validate inspects the fields of the type to determine if they are valid. 4890func (s *DeleteVaultInput) Validate() error { 4891 invalidParams := request.ErrInvalidParams{Context: "DeleteVaultInput"} 4892 if s.AccountId == nil { 4893 invalidParams.Add(request.NewErrParamRequired("AccountId")) 4894 } 4895 if s.AccountId != nil && len(*s.AccountId) < 1 { 4896 invalidParams.Add(request.NewErrParamMinLen("AccountId", 1)) 4897 } 4898 if s.VaultName == nil { 4899 invalidParams.Add(request.NewErrParamRequired("VaultName")) 4900 } 4901 if s.VaultName != nil && len(*s.VaultName) < 1 { 4902 invalidParams.Add(request.NewErrParamMinLen("VaultName", 1)) 4903 } 4904 4905 if invalidParams.Len() > 0 { 4906 return invalidParams 4907 } 4908 return nil 4909} 4910 4911// SetAccountId sets the AccountId field's value. 4912func (s *DeleteVaultInput) SetAccountId(v string) *DeleteVaultInput { 4913 s.AccountId = &v 4914 return s 4915} 4916 4917// SetVaultName sets the VaultName field's value. 4918func (s *DeleteVaultInput) SetVaultName(v string) *DeleteVaultInput { 4919 s.VaultName = &v 4920 return s 4921} 4922 4923// Provides options for deleting a vault notification configuration from an 4924// Amazon Glacier vault. 4925type DeleteVaultNotificationsInput struct { 4926 _ struct{} `type:"structure" nopayload:"true"` 4927 4928 // The AccountId value is the AWS account ID of the account that owns the vault. 4929 // You can either specify an AWS account ID or optionally a single '-' (hyphen), 4930 // in which case Amazon S3 Glacier uses the AWS account ID associated with the 4931 // credentials used to sign the request. If you use an account ID, do not include 4932 // any hyphens ('-') in the ID. 4933 // 4934 // AccountId is a required field 4935 AccountId *string `location:"uri" locationName:"accountId" type:"string" required:"true"` 4936 4937 // The name of the vault. 4938 // 4939 // VaultName is a required field 4940 VaultName *string `location:"uri" locationName:"vaultName" type:"string" required:"true"` 4941} 4942 4943// String returns the string representation. 4944// 4945// API parameter values that are decorated as "sensitive" in the API will not 4946// be included in the string output. The member name will be present, but the 4947// value will be replaced with "sensitive". 4948func (s DeleteVaultNotificationsInput) String() string { 4949 return awsutil.Prettify(s) 4950} 4951 4952// GoString returns the string representation. 4953// 4954// API parameter values that are decorated as "sensitive" in the API will not 4955// be included in the string output. The member name will be present, but the 4956// value will be replaced with "sensitive". 4957func (s DeleteVaultNotificationsInput) GoString() string { 4958 return s.String() 4959} 4960 4961// Validate inspects the fields of the type to determine if they are valid. 4962func (s *DeleteVaultNotificationsInput) Validate() error { 4963 invalidParams := request.ErrInvalidParams{Context: "DeleteVaultNotificationsInput"} 4964 if s.AccountId == nil { 4965 invalidParams.Add(request.NewErrParamRequired("AccountId")) 4966 } 4967 if s.AccountId != nil && len(*s.AccountId) < 1 { 4968 invalidParams.Add(request.NewErrParamMinLen("AccountId", 1)) 4969 } 4970 if s.VaultName == nil { 4971 invalidParams.Add(request.NewErrParamRequired("VaultName")) 4972 } 4973 if s.VaultName != nil && len(*s.VaultName) < 1 { 4974 invalidParams.Add(request.NewErrParamMinLen("VaultName", 1)) 4975 } 4976 4977 if invalidParams.Len() > 0 { 4978 return invalidParams 4979 } 4980 return nil 4981} 4982 4983// SetAccountId sets the AccountId field's value. 4984func (s *DeleteVaultNotificationsInput) SetAccountId(v string) *DeleteVaultNotificationsInput { 4985 s.AccountId = &v 4986 return s 4987} 4988 4989// SetVaultName sets the VaultName field's value. 4990func (s *DeleteVaultNotificationsInput) SetVaultName(v string) *DeleteVaultNotificationsInput { 4991 s.VaultName = &v 4992 return s 4993} 4994 4995type DeleteVaultNotificationsOutput struct { 4996 _ struct{} `type:"structure"` 4997} 4998 4999// String returns the string representation. 5000// 5001// API parameter values that are decorated as "sensitive" in the API will not 5002// be included in the string output. The member name will be present, but the 5003// value will be replaced with "sensitive". 5004func (s DeleteVaultNotificationsOutput) String() string { 5005 return awsutil.Prettify(s) 5006} 5007 5008// GoString returns the string representation. 5009// 5010// API parameter values that are decorated as "sensitive" in the API will not 5011// be included in the string output. The member name will be present, but the 5012// value will be replaced with "sensitive". 5013func (s DeleteVaultNotificationsOutput) GoString() string { 5014 return s.String() 5015} 5016 5017type DeleteVaultOutput struct { 5018 _ struct{} `type:"structure"` 5019} 5020 5021// String returns the string representation. 5022// 5023// API parameter values that are decorated as "sensitive" in the API will not 5024// be included in the string output. The member name will be present, but the 5025// value will be replaced with "sensitive". 5026func (s DeleteVaultOutput) String() string { 5027 return awsutil.Prettify(s) 5028} 5029 5030// GoString returns the string representation. 5031// 5032// API parameter values that are decorated as "sensitive" in the API will not 5033// be included in the string output. The member name will be present, but the 5034// value will be replaced with "sensitive". 5035func (s DeleteVaultOutput) GoString() string { 5036 return s.String() 5037} 5038 5039// Provides options for retrieving a job description. 5040type DescribeJobInput struct { 5041 _ struct{} `type:"structure" nopayload:"true"` 5042 5043 // The AccountId value is the AWS account ID of the account that owns the vault. 5044 // You can either specify an AWS account ID or optionally a single '-' (hyphen), 5045 // in which case Amazon S3 Glacier uses the AWS account ID associated with the 5046 // credentials used to sign the request. If you use an account ID, do not include 5047 // any hyphens ('-') in the ID. 5048 // 5049 // AccountId is a required field 5050 AccountId *string `location:"uri" locationName:"accountId" type:"string" required:"true"` 5051 5052 // The ID of the job to describe. 5053 // 5054 // JobId is a required field 5055 JobId *string `location:"uri" locationName:"jobId" type:"string" required:"true"` 5056 5057 // The name of the vault. 5058 // 5059 // VaultName is a required field 5060 VaultName *string `location:"uri" locationName:"vaultName" type:"string" required:"true"` 5061} 5062 5063// String returns the string representation. 5064// 5065// API parameter values that are decorated as "sensitive" in the API will not 5066// be included in the string output. The member name will be present, but the 5067// value will be replaced with "sensitive". 5068func (s DescribeJobInput) String() string { 5069 return awsutil.Prettify(s) 5070} 5071 5072// GoString returns the string representation. 5073// 5074// API parameter values that are decorated as "sensitive" in the API will not 5075// be included in the string output. The member name will be present, but the 5076// value will be replaced with "sensitive". 5077func (s DescribeJobInput) GoString() string { 5078 return s.String() 5079} 5080 5081// Validate inspects the fields of the type to determine if they are valid. 5082func (s *DescribeJobInput) Validate() error { 5083 invalidParams := request.ErrInvalidParams{Context: "DescribeJobInput"} 5084 if s.AccountId == nil { 5085 invalidParams.Add(request.NewErrParamRequired("AccountId")) 5086 } 5087 if s.AccountId != nil && len(*s.AccountId) < 1 { 5088 invalidParams.Add(request.NewErrParamMinLen("AccountId", 1)) 5089 } 5090 if s.JobId == nil { 5091 invalidParams.Add(request.NewErrParamRequired("JobId")) 5092 } 5093 if s.JobId != nil && len(*s.JobId) < 1 { 5094 invalidParams.Add(request.NewErrParamMinLen("JobId", 1)) 5095 } 5096 if s.VaultName == nil { 5097 invalidParams.Add(request.NewErrParamRequired("VaultName")) 5098 } 5099 if s.VaultName != nil && len(*s.VaultName) < 1 { 5100 invalidParams.Add(request.NewErrParamMinLen("VaultName", 1)) 5101 } 5102 5103 if invalidParams.Len() > 0 { 5104 return invalidParams 5105 } 5106 return nil 5107} 5108 5109// SetAccountId sets the AccountId field's value. 5110func (s *DescribeJobInput) SetAccountId(v string) *DescribeJobInput { 5111 s.AccountId = &v 5112 return s 5113} 5114 5115// SetJobId sets the JobId field's value. 5116func (s *DescribeJobInput) SetJobId(v string) *DescribeJobInput { 5117 s.JobId = &v 5118 return s 5119} 5120 5121// SetVaultName sets the VaultName field's value. 5122func (s *DescribeJobInput) SetVaultName(v string) *DescribeJobInput { 5123 s.VaultName = &v 5124 return s 5125} 5126 5127// Provides options for retrieving metadata for a specific vault in Amazon Glacier. 5128type DescribeVaultInput struct { 5129 _ struct{} `type:"structure" nopayload:"true"` 5130 5131 // The AccountId value is the AWS account ID of the account that owns the vault. 5132 // You can either specify an AWS account ID or optionally a single '-' (hyphen), 5133 // in which case Amazon S3 Glacier uses the AWS account ID associated with the 5134 // credentials used to sign the request. If you use an account ID, do not include 5135 // any hyphens ('-') in the ID. 5136 // 5137 // AccountId is a required field 5138 AccountId *string `location:"uri" locationName:"accountId" type:"string" required:"true"` 5139 5140 // The name of the vault. 5141 // 5142 // VaultName is a required field 5143 VaultName *string `location:"uri" locationName:"vaultName" type:"string" required:"true"` 5144} 5145 5146// String returns the string representation. 5147// 5148// API parameter values that are decorated as "sensitive" in the API will not 5149// be included in the string output. The member name will be present, but the 5150// value will be replaced with "sensitive". 5151func (s DescribeVaultInput) String() string { 5152 return awsutil.Prettify(s) 5153} 5154 5155// GoString returns the string representation. 5156// 5157// API parameter values that are decorated as "sensitive" in the API will not 5158// be included in the string output. The member name will be present, but the 5159// value will be replaced with "sensitive". 5160func (s DescribeVaultInput) GoString() string { 5161 return s.String() 5162} 5163 5164// Validate inspects the fields of the type to determine if they are valid. 5165func (s *DescribeVaultInput) Validate() error { 5166 invalidParams := request.ErrInvalidParams{Context: "DescribeVaultInput"} 5167 if s.AccountId == nil { 5168 invalidParams.Add(request.NewErrParamRequired("AccountId")) 5169 } 5170 if s.AccountId != nil && len(*s.AccountId) < 1 { 5171 invalidParams.Add(request.NewErrParamMinLen("AccountId", 1)) 5172 } 5173 if s.VaultName == nil { 5174 invalidParams.Add(request.NewErrParamRequired("VaultName")) 5175 } 5176 if s.VaultName != nil && len(*s.VaultName) < 1 { 5177 invalidParams.Add(request.NewErrParamMinLen("VaultName", 1)) 5178 } 5179 5180 if invalidParams.Len() > 0 { 5181 return invalidParams 5182 } 5183 return nil 5184} 5185 5186// SetAccountId sets the AccountId field's value. 5187func (s *DescribeVaultInput) SetAccountId(v string) *DescribeVaultInput { 5188 s.AccountId = &v 5189 return s 5190} 5191 5192// SetVaultName sets the VaultName field's value. 5193func (s *DescribeVaultInput) SetVaultName(v string) *DescribeVaultInput { 5194 s.VaultName = &v 5195 return s 5196} 5197 5198// Contains the Amazon S3 Glacier response to your request. 5199type DescribeVaultOutput struct { 5200 _ struct{} `type:"structure"` 5201 5202 // The Universal Coordinated Time (UTC) date when the vault was created. This 5203 // value should be a string in the ISO 8601 date format, for example 2012-03-20T17:03:43.221Z. 5204 CreationDate *string `type:"string"` 5205 5206 // The Universal Coordinated Time (UTC) date when Amazon S3 Glacier completed 5207 // the last vault inventory. This value should be a string in the ISO 8601 date 5208 // format, for example 2012-03-20T17:03:43.221Z. 5209 LastInventoryDate *string `type:"string"` 5210 5211 // The number of archives in the vault as of the last inventory date. This field 5212 // will return null if an inventory has not yet run on the vault, for example 5213 // if you just created the vault. 5214 NumberOfArchives *int64 `type:"long"` 5215 5216 // Total size, in bytes, of the archives in the vault as of the last inventory 5217 // date. This field will return null if an inventory has not yet run on the 5218 // vault, for example if you just created the vault. 5219 SizeInBytes *int64 `type:"long"` 5220 5221 // The Amazon Resource Name (ARN) of the vault. 5222 VaultARN *string `type:"string"` 5223 5224 // The name of the vault. 5225 VaultName *string `type:"string"` 5226} 5227 5228// String returns the string representation. 5229// 5230// API parameter values that are decorated as "sensitive" in the API will not 5231// be included in the string output. The member name will be present, but the 5232// value will be replaced with "sensitive". 5233func (s DescribeVaultOutput) String() string { 5234 return awsutil.Prettify(s) 5235} 5236 5237// GoString returns the string representation. 5238// 5239// API parameter values that are decorated as "sensitive" in the API will not 5240// be included in the string output. The member name will be present, but the 5241// value will be replaced with "sensitive". 5242func (s DescribeVaultOutput) GoString() string { 5243 return s.String() 5244} 5245 5246// SetCreationDate sets the CreationDate field's value. 5247func (s *DescribeVaultOutput) SetCreationDate(v string) *DescribeVaultOutput { 5248 s.CreationDate = &v 5249 return s 5250} 5251 5252// SetLastInventoryDate sets the LastInventoryDate field's value. 5253func (s *DescribeVaultOutput) SetLastInventoryDate(v string) *DescribeVaultOutput { 5254 s.LastInventoryDate = &v 5255 return s 5256} 5257 5258// SetNumberOfArchives sets the NumberOfArchives field's value. 5259func (s *DescribeVaultOutput) SetNumberOfArchives(v int64) *DescribeVaultOutput { 5260 s.NumberOfArchives = &v 5261 return s 5262} 5263 5264// SetSizeInBytes sets the SizeInBytes field's value. 5265func (s *DescribeVaultOutput) SetSizeInBytes(v int64) *DescribeVaultOutput { 5266 s.SizeInBytes = &v 5267 return s 5268} 5269 5270// SetVaultARN sets the VaultARN field's value. 5271func (s *DescribeVaultOutput) SetVaultARN(v string) *DescribeVaultOutput { 5272 s.VaultARN = &v 5273 return s 5274} 5275 5276// SetVaultName sets the VaultName field's value. 5277func (s *DescribeVaultOutput) SetVaultName(v string) *DescribeVaultOutput { 5278 s.VaultName = &v 5279 return s 5280} 5281 5282// Contains information about the encryption used to store the job results in 5283// Amazon S3. 5284type Encryption struct { 5285 _ struct{} `type:"structure"` 5286 5287 // The server-side encryption algorithm used when storing job results in Amazon 5288 // S3, for example AES256 or aws:kms. 5289 EncryptionType *string `type:"string" enum:"EncryptionType"` 5290 5291 // Optional. If the encryption type is aws:kms, you can use this value to specify 5292 // the encryption context for the job results. 5293 KMSContext *string `type:"string"` 5294 5295 // The AWS KMS key ID to use for object encryption. All GET and PUT requests 5296 // for an object protected by AWS KMS fail if not made by using Secure Sockets 5297 // Layer (SSL) or Signature Version 4. 5298 KMSKeyId *string `type:"string"` 5299} 5300 5301// String returns the string representation. 5302// 5303// API parameter values that are decorated as "sensitive" in the API will not 5304// be included in the string output. The member name will be present, but the 5305// value will be replaced with "sensitive". 5306func (s Encryption) String() string { 5307 return awsutil.Prettify(s) 5308} 5309 5310// GoString returns the string representation. 5311// 5312// API parameter values that are decorated as "sensitive" in the API will not 5313// be included in the string output. The member name will be present, but the 5314// value will be replaced with "sensitive". 5315func (s Encryption) GoString() string { 5316 return s.String() 5317} 5318 5319// SetEncryptionType sets the EncryptionType field's value. 5320func (s *Encryption) SetEncryptionType(v string) *Encryption { 5321 s.EncryptionType = &v 5322 return s 5323} 5324 5325// SetKMSContext sets the KMSContext field's value. 5326func (s *Encryption) SetKMSContext(v string) *Encryption { 5327 s.KMSContext = &v 5328 return s 5329} 5330 5331// SetKMSKeyId sets the KMSKeyId field's value. 5332func (s *Encryption) SetKMSKeyId(v string) *Encryption { 5333 s.KMSKeyId = &v 5334 return s 5335} 5336 5337// Input for GetDataRetrievalPolicy. 5338type GetDataRetrievalPolicyInput struct { 5339 _ struct{} `type:"structure" nopayload:"true"` 5340 5341 // The AccountId value is the AWS account ID. This value must match the AWS 5342 // account ID associated with the credentials used to sign the request. You 5343 // can either specify an AWS account ID or optionally a single '-' (hyphen), 5344 // in which case Amazon Glacier uses the AWS account ID associated with the 5345 // credentials used to sign the request. If you specify your account ID, do 5346 // not include any hyphens ('-') in the ID. 5347 // 5348 // AccountId is a required field 5349 AccountId *string `location:"uri" locationName:"accountId" type:"string" required:"true"` 5350} 5351 5352// String returns the string representation. 5353// 5354// API parameter values that are decorated as "sensitive" in the API will not 5355// be included in the string output. The member name will be present, but the 5356// value will be replaced with "sensitive". 5357func (s GetDataRetrievalPolicyInput) String() string { 5358 return awsutil.Prettify(s) 5359} 5360 5361// GoString returns the string representation. 5362// 5363// API parameter values that are decorated as "sensitive" in the API will not 5364// be included in the string output. The member name will be present, but the 5365// value will be replaced with "sensitive". 5366func (s GetDataRetrievalPolicyInput) GoString() string { 5367 return s.String() 5368} 5369 5370// Validate inspects the fields of the type to determine if they are valid. 5371func (s *GetDataRetrievalPolicyInput) Validate() error { 5372 invalidParams := request.ErrInvalidParams{Context: "GetDataRetrievalPolicyInput"} 5373 if s.AccountId == nil { 5374 invalidParams.Add(request.NewErrParamRequired("AccountId")) 5375 } 5376 if s.AccountId != nil && len(*s.AccountId) < 1 { 5377 invalidParams.Add(request.NewErrParamMinLen("AccountId", 1)) 5378 } 5379 5380 if invalidParams.Len() > 0 { 5381 return invalidParams 5382 } 5383 return nil 5384} 5385 5386// SetAccountId sets the AccountId field's value. 5387func (s *GetDataRetrievalPolicyInput) SetAccountId(v string) *GetDataRetrievalPolicyInput { 5388 s.AccountId = &v 5389 return s 5390} 5391 5392// Contains the Amazon S3 Glacier response to the GetDataRetrievalPolicy request. 5393type GetDataRetrievalPolicyOutput struct { 5394 _ struct{} `type:"structure"` 5395 5396 // Contains the returned data retrieval policy in JSON format. 5397 Policy *DataRetrievalPolicy `type:"structure"` 5398} 5399 5400// String returns the string representation. 5401// 5402// API parameter values that are decorated as "sensitive" in the API will not 5403// be included in the string output. The member name will be present, but the 5404// value will be replaced with "sensitive". 5405func (s GetDataRetrievalPolicyOutput) String() string { 5406 return awsutil.Prettify(s) 5407} 5408 5409// GoString returns the string representation. 5410// 5411// API parameter values that are decorated as "sensitive" in the API will not 5412// be included in the string output. The member name will be present, but the 5413// value will be replaced with "sensitive". 5414func (s GetDataRetrievalPolicyOutput) GoString() string { 5415 return s.String() 5416} 5417 5418// SetPolicy sets the Policy field's value. 5419func (s *GetDataRetrievalPolicyOutput) SetPolicy(v *DataRetrievalPolicy) *GetDataRetrievalPolicyOutput { 5420 s.Policy = v 5421 return s 5422} 5423 5424// Provides options for downloading output of an Amazon S3 Glacier job. 5425type GetJobOutputInput struct { 5426 _ struct{} `type:"structure" nopayload:"true"` 5427 5428 // The AccountId value is the AWS account ID of the account that owns the vault. 5429 // You can either specify an AWS account ID or optionally a single '-' (hyphen), 5430 // in which case Amazon S3 Glacier uses the AWS account ID associated with the 5431 // credentials used to sign the request. If you use an account ID, do not include 5432 // any hyphens ('-') in the ID. 5433 // 5434 // AccountId is a required field 5435 AccountId *string `location:"uri" locationName:"accountId" type:"string" required:"true"` 5436 5437 // The job ID whose data is downloaded. 5438 // 5439 // JobId is a required field 5440 JobId *string `location:"uri" locationName:"jobId" type:"string" required:"true"` 5441 5442 // The range of bytes to retrieve from the output. For example, if you want 5443 // to download the first 1,048,576 bytes, specify the range as bytes=0-1048575. 5444 // By default, this operation downloads the entire output. 5445 // 5446 // If the job output is large, then you can use a range to retrieve a portion 5447 // of the output. This allows you to download the entire output in smaller chunks 5448 // of bytes. For example, suppose you have 1 GB of job output you want to download 5449 // and you decide to download 128 MB chunks of data at a time, which is a total 5450 // of eight Get Job Output requests. You use the following process to download 5451 // the job output: 5452 // 5453 // Download a 128 MB chunk of output by specifying the appropriate byte range. 5454 // Verify that all 128 MB of data was received. 5455 // 5456 // Along with the data, the response includes a SHA256 tree hash of the payload. 5457 // You compute the checksum of the payload on the client and compare it with 5458 // the checksum you received in the response to ensure you received all the 5459 // expected data. 5460 // 5461 // Repeat steps 1 and 2 for all the eight 128 MB chunks of output data, each 5462 // time specifying the appropriate byte range. 5463 // 5464 // After downloading all the parts of the job output, you have a list of eight 5465 // checksum values. Compute the tree hash of these values to find the checksum 5466 // of the entire output. Using the DescribeJob API, obtain job information of 5467 // the job that provided you the output. The response includes the checksum 5468 // of the entire archive stored in Amazon S3 Glacier. You compare this value 5469 // with the checksum you computed to ensure you have downloaded the entire archive 5470 // content with no errors. 5471 Range *string `location:"header" locationName:"Range" type:"string"` 5472 5473 // The name of the vault. 5474 // 5475 // VaultName is a required field 5476 VaultName *string `location:"uri" locationName:"vaultName" type:"string" required:"true"` 5477} 5478 5479// String returns the string representation. 5480// 5481// API parameter values that are decorated as "sensitive" in the API will not 5482// be included in the string output. The member name will be present, but the 5483// value will be replaced with "sensitive". 5484func (s GetJobOutputInput) String() string { 5485 return awsutil.Prettify(s) 5486} 5487 5488// GoString returns the string representation. 5489// 5490// API parameter values that are decorated as "sensitive" in the API will not 5491// be included in the string output. The member name will be present, but the 5492// value will be replaced with "sensitive". 5493func (s GetJobOutputInput) GoString() string { 5494 return s.String() 5495} 5496 5497// Validate inspects the fields of the type to determine if they are valid. 5498func (s *GetJobOutputInput) Validate() error { 5499 invalidParams := request.ErrInvalidParams{Context: "GetJobOutputInput"} 5500 if s.AccountId == nil { 5501 invalidParams.Add(request.NewErrParamRequired("AccountId")) 5502 } 5503 if s.AccountId != nil && len(*s.AccountId) < 1 { 5504 invalidParams.Add(request.NewErrParamMinLen("AccountId", 1)) 5505 } 5506 if s.JobId == nil { 5507 invalidParams.Add(request.NewErrParamRequired("JobId")) 5508 } 5509 if s.JobId != nil && len(*s.JobId) < 1 { 5510 invalidParams.Add(request.NewErrParamMinLen("JobId", 1)) 5511 } 5512 if s.VaultName == nil { 5513 invalidParams.Add(request.NewErrParamRequired("VaultName")) 5514 } 5515 if s.VaultName != nil && len(*s.VaultName) < 1 { 5516 invalidParams.Add(request.NewErrParamMinLen("VaultName", 1)) 5517 } 5518 5519 if invalidParams.Len() > 0 { 5520 return invalidParams 5521 } 5522 return nil 5523} 5524 5525// SetAccountId sets the AccountId field's value. 5526func (s *GetJobOutputInput) SetAccountId(v string) *GetJobOutputInput { 5527 s.AccountId = &v 5528 return s 5529} 5530 5531// SetJobId sets the JobId field's value. 5532func (s *GetJobOutputInput) SetJobId(v string) *GetJobOutputInput { 5533 s.JobId = &v 5534 return s 5535} 5536 5537// SetRange sets the Range field's value. 5538func (s *GetJobOutputInput) SetRange(v string) *GetJobOutputInput { 5539 s.Range = &v 5540 return s 5541} 5542 5543// SetVaultName sets the VaultName field's value. 5544func (s *GetJobOutputInput) SetVaultName(v string) *GetJobOutputInput { 5545 s.VaultName = &v 5546 return s 5547} 5548 5549// Contains the Amazon S3 Glacier response to your request. 5550type GetJobOutputOutput struct { 5551 _ struct{} `type:"structure" payload:"Body"` 5552 5553 // Indicates the range units accepted. For more information, see RFC2616 (http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html). 5554 AcceptRanges *string `location:"header" locationName:"Accept-Ranges" type:"string"` 5555 5556 // The description of an archive. 5557 ArchiveDescription *string `location:"header" locationName:"x-amz-archive-description" type:"string"` 5558 5559 // The job data, either archive data or inventory data. 5560 Body io.ReadCloser `locationName:"body" type:"blob"` 5561 5562 // The checksum of the data in the response. This header is returned only when 5563 // retrieving the output for an archive retrieval job. Furthermore, this header 5564 // appears only under the following conditions: 5565 // 5566 // * You get the entire range of the archive. 5567 // 5568 // * You request a range to return of the archive that starts and ends on 5569 // a multiple of 1 MB. For example, if you have an 3.1 MB archive and you 5570 // specify a range to return that starts at 1 MB and ends at 2 MB, then the 5571 // x-amz-sha256-tree-hash is returned as a response header. 5572 // 5573 // * You request a range of the archive to return that starts on a multiple 5574 // of 1 MB and goes to the end of the archive. For example, if you have a 5575 // 3.1 MB archive and you specify a range that starts at 2 MB and ends at 5576 // 3.1 MB (the end of the archive), then the x-amz-sha256-tree-hash is returned 5577 // as a response header. 5578 Checksum *string `location:"header" locationName:"x-amz-sha256-tree-hash" type:"string"` 5579 5580 // The range of bytes returned by Amazon S3 Glacier. If only partial output 5581 // is downloaded, the response provides the range of bytes Amazon S3 Glacier 5582 // returned. For example, bytes 0-1048575/8388608 returns the first 1 MB from 5583 // 8 MB. 5584 ContentRange *string `location:"header" locationName:"Content-Range" type:"string"` 5585 5586 // The Content-Type depends on whether the job output is an archive or a vault 5587 // inventory. For archive data, the Content-Type is application/octet-stream. 5588 // For vault inventory, if you requested CSV format when you initiated the job, 5589 // the Content-Type is text/csv. Otherwise, by default, vault inventory is returned 5590 // as JSON, and the Content-Type is application/json. 5591 ContentType *string `location:"header" locationName:"Content-Type" type:"string"` 5592 5593 // The HTTP response code for a job output request. The value depends on whether 5594 // a range was specified in the request. 5595 Status *int64 `location:"statusCode" locationName:"status" type:"integer"` 5596} 5597 5598// String returns the string representation. 5599// 5600// API parameter values that are decorated as "sensitive" in the API will not 5601// be included in the string output. The member name will be present, but the 5602// value will be replaced with "sensitive". 5603func (s GetJobOutputOutput) String() string { 5604 return awsutil.Prettify(s) 5605} 5606 5607// GoString returns the string representation. 5608// 5609// API parameter values that are decorated as "sensitive" in the API will not 5610// be included in the string output. The member name will be present, but the 5611// value will be replaced with "sensitive". 5612func (s GetJobOutputOutput) GoString() string { 5613 return s.String() 5614} 5615 5616// SetAcceptRanges sets the AcceptRanges field's value. 5617func (s *GetJobOutputOutput) SetAcceptRanges(v string) *GetJobOutputOutput { 5618 s.AcceptRanges = &v 5619 return s 5620} 5621 5622// SetArchiveDescription sets the ArchiveDescription field's value. 5623func (s *GetJobOutputOutput) SetArchiveDescription(v string) *GetJobOutputOutput { 5624 s.ArchiveDescription = &v 5625 return s 5626} 5627 5628// SetBody sets the Body field's value. 5629func (s *GetJobOutputOutput) SetBody(v io.ReadCloser) *GetJobOutputOutput { 5630 s.Body = v 5631 return s 5632} 5633 5634// SetChecksum sets the Checksum field's value. 5635func (s *GetJobOutputOutput) SetChecksum(v string) *GetJobOutputOutput { 5636 s.Checksum = &v 5637 return s 5638} 5639 5640// SetContentRange sets the ContentRange field's value. 5641func (s *GetJobOutputOutput) SetContentRange(v string) *GetJobOutputOutput { 5642 s.ContentRange = &v 5643 return s 5644} 5645 5646// SetContentType sets the ContentType field's value. 5647func (s *GetJobOutputOutput) SetContentType(v string) *GetJobOutputOutput { 5648 s.ContentType = &v 5649 return s 5650} 5651 5652// SetStatus sets the Status field's value. 5653func (s *GetJobOutputOutput) SetStatus(v int64) *GetJobOutputOutput { 5654 s.Status = &v 5655 return s 5656} 5657 5658// Input for GetVaultAccessPolicy. 5659type GetVaultAccessPolicyInput struct { 5660 _ struct{} `type:"structure" nopayload:"true"` 5661 5662 // The AccountId value is the AWS account ID of the account that owns the vault. 5663 // You can either specify an AWS account ID or optionally a single '-' (hyphen), 5664 // in which case Amazon S3 Glacier uses the AWS account ID associated with the 5665 // credentials used to sign the request. If you use an account ID, do not include 5666 // any hyphens ('-') in the ID. 5667 // 5668 // AccountId is a required field 5669 AccountId *string `location:"uri" locationName:"accountId" type:"string" required:"true"` 5670 5671 // The name of the vault. 5672 // 5673 // VaultName is a required field 5674 VaultName *string `location:"uri" locationName:"vaultName" type:"string" required:"true"` 5675} 5676 5677// String returns the string representation. 5678// 5679// API parameter values that are decorated as "sensitive" in the API will not 5680// be included in the string output. The member name will be present, but the 5681// value will be replaced with "sensitive". 5682func (s GetVaultAccessPolicyInput) String() string { 5683 return awsutil.Prettify(s) 5684} 5685 5686// GoString returns the string representation. 5687// 5688// API parameter values that are decorated as "sensitive" in the API will not 5689// be included in the string output. The member name will be present, but the 5690// value will be replaced with "sensitive". 5691func (s GetVaultAccessPolicyInput) GoString() string { 5692 return s.String() 5693} 5694 5695// Validate inspects the fields of the type to determine if they are valid. 5696func (s *GetVaultAccessPolicyInput) Validate() error { 5697 invalidParams := request.ErrInvalidParams{Context: "GetVaultAccessPolicyInput"} 5698 if s.AccountId == nil { 5699 invalidParams.Add(request.NewErrParamRequired("AccountId")) 5700 } 5701 if s.AccountId != nil && len(*s.AccountId) < 1 { 5702 invalidParams.Add(request.NewErrParamMinLen("AccountId", 1)) 5703 } 5704 if s.VaultName == nil { 5705 invalidParams.Add(request.NewErrParamRequired("VaultName")) 5706 } 5707 if s.VaultName != nil && len(*s.VaultName) < 1 { 5708 invalidParams.Add(request.NewErrParamMinLen("VaultName", 1)) 5709 } 5710 5711 if invalidParams.Len() > 0 { 5712 return invalidParams 5713 } 5714 return nil 5715} 5716 5717// SetAccountId sets the AccountId field's value. 5718func (s *GetVaultAccessPolicyInput) SetAccountId(v string) *GetVaultAccessPolicyInput { 5719 s.AccountId = &v 5720 return s 5721} 5722 5723// SetVaultName sets the VaultName field's value. 5724func (s *GetVaultAccessPolicyInput) SetVaultName(v string) *GetVaultAccessPolicyInput { 5725 s.VaultName = &v 5726 return s 5727} 5728 5729// Output for GetVaultAccessPolicy. 5730type GetVaultAccessPolicyOutput struct { 5731 _ struct{} `type:"structure" payload:"Policy"` 5732 5733 // Contains the returned vault access policy as a JSON string. 5734 Policy *VaultAccessPolicy `locationName:"policy" type:"structure"` 5735} 5736 5737// String returns the string representation. 5738// 5739// API parameter values that are decorated as "sensitive" in the API will not 5740// be included in the string output. The member name will be present, but the 5741// value will be replaced with "sensitive". 5742func (s GetVaultAccessPolicyOutput) String() string { 5743 return awsutil.Prettify(s) 5744} 5745 5746// GoString returns the string representation. 5747// 5748// API parameter values that are decorated as "sensitive" in the API will not 5749// be included in the string output. The member name will be present, but the 5750// value will be replaced with "sensitive". 5751func (s GetVaultAccessPolicyOutput) GoString() string { 5752 return s.String() 5753} 5754 5755// SetPolicy sets the Policy field's value. 5756func (s *GetVaultAccessPolicyOutput) SetPolicy(v *VaultAccessPolicy) *GetVaultAccessPolicyOutput { 5757 s.Policy = v 5758 return s 5759} 5760 5761// The input values for GetVaultLock. 5762type GetVaultLockInput struct { 5763 _ struct{} `type:"structure" nopayload:"true"` 5764 5765 // The AccountId value is the AWS account ID of the account that owns the vault. 5766 // You can either specify an AWS account ID or optionally a single '-' (hyphen), 5767 // in which case Amazon S3 Glacier uses the AWS account ID associated with the 5768 // credentials used to sign the request. If you use an account ID, do not include 5769 // any hyphens ('-') in the ID. 5770 // 5771 // AccountId is a required field 5772 AccountId *string `location:"uri" locationName:"accountId" type:"string" required:"true"` 5773 5774 // The name of the vault. 5775 // 5776 // VaultName is a required field 5777 VaultName *string `location:"uri" locationName:"vaultName" type:"string" required:"true"` 5778} 5779 5780// String returns the string representation. 5781// 5782// API parameter values that are decorated as "sensitive" in the API will not 5783// be included in the string output. The member name will be present, but the 5784// value will be replaced with "sensitive". 5785func (s GetVaultLockInput) String() string { 5786 return awsutil.Prettify(s) 5787} 5788 5789// GoString returns the string representation. 5790// 5791// API parameter values that are decorated as "sensitive" in the API will not 5792// be included in the string output. The member name will be present, but the 5793// value will be replaced with "sensitive". 5794func (s GetVaultLockInput) GoString() string { 5795 return s.String() 5796} 5797 5798// Validate inspects the fields of the type to determine if they are valid. 5799func (s *GetVaultLockInput) Validate() error { 5800 invalidParams := request.ErrInvalidParams{Context: "GetVaultLockInput"} 5801 if s.AccountId == nil { 5802 invalidParams.Add(request.NewErrParamRequired("AccountId")) 5803 } 5804 if s.AccountId != nil && len(*s.AccountId) < 1 { 5805 invalidParams.Add(request.NewErrParamMinLen("AccountId", 1)) 5806 } 5807 if s.VaultName == nil { 5808 invalidParams.Add(request.NewErrParamRequired("VaultName")) 5809 } 5810 if s.VaultName != nil && len(*s.VaultName) < 1 { 5811 invalidParams.Add(request.NewErrParamMinLen("VaultName", 1)) 5812 } 5813 5814 if invalidParams.Len() > 0 { 5815 return invalidParams 5816 } 5817 return nil 5818} 5819 5820// SetAccountId sets the AccountId field's value. 5821func (s *GetVaultLockInput) SetAccountId(v string) *GetVaultLockInput { 5822 s.AccountId = &v 5823 return s 5824} 5825 5826// SetVaultName sets the VaultName field's value. 5827func (s *GetVaultLockInput) SetVaultName(v string) *GetVaultLockInput { 5828 s.VaultName = &v 5829 return s 5830} 5831 5832// Contains the Amazon S3 Glacier response to your request. 5833type GetVaultLockOutput struct { 5834 _ struct{} `type:"structure"` 5835 5836 // The UTC date and time at which the vault lock was put into the InProgress 5837 // state. 5838 CreationDate *string `type:"string"` 5839 5840 // The UTC date and time at which the lock ID expires. This value can be null 5841 // if the vault lock is in a Locked state. 5842 ExpirationDate *string `type:"string"` 5843 5844 // The vault lock policy as a JSON string, which uses "\" as an escape character. 5845 Policy *string `type:"string"` 5846 5847 // The state of the vault lock. InProgress or Locked. 5848 State *string `type:"string"` 5849} 5850 5851// String returns the string representation. 5852// 5853// API parameter values that are decorated as "sensitive" in the API will not 5854// be included in the string output. The member name will be present, but the 5855// value will be replaced with "sensitive". 5856func (s GetVaultLockOutput) String() string { 5857 return awsutil.Prettify(s) 5858} 5859 5860// GoString returns the string representation. 5861// 5862// API parameter values that are decorated as "sensitive" in the API will not 5863// be included in the string output. The member name will be present, but the 5864// value will be replaced with "sensitive". 5865func (s GetVaultLockOutput) GoString() string { 5866 return s.String() 5867} 5868 5869// SetCreationDate sets the CreationDate field's value. 5870func (s *GetVaultLockOutput) SetCreationDate(v string) *GetVaultLockOutput { 5871 s.CreationDate = &v 5872 return s 5873} 5874 5875// SetExpirationDate sets the ExpirationDate field's value. 5876func (s *GetVaultLockOutput) SetExpirationDate(v string) *GetVaultLockOutput { 5877 s.ExpirationDate = &v 5878 return s 5879} 5880 5881// SetPolicy sets the Policy field's value. 5882func (s *GetVaultLockOutput) SetPolicy(v string) *GetVaultLockOutput { 5883 s.Policy = &v 5884 return s 5885} 5886 5887// SetState sets the State field's value. 5888func (s *GetVaultLockOutput) SetState(v string) *GetVaultLockOutput { 5889 s.State = &v 5890 return s 5891} 5892 5893// Provides options for retrieving the notification configuration set on an 5894// Amazon Glacier vault. 5895type GetVaultNotificationsInput struct { 5896 _ struct{} `type:"structure" nopayload:"true"` 5897 5898 // The AccountId value is the AWS account ID of the account that owns the vault. 5899 // You can either specify an AWS account ID or optionally a single '-' (hyphen), 5900 // in which case Amazon S3 Glacier uses the AWS account ID associated with the 5901 // credentials used to sign the request. If you use an account ID, do not include 5902 // any hyphens ('-') in the ID. 5903 // 5904 // AccountId is a required field 5905 AccountId *string `location:"uri" locationName:"accountId" type:"string" required:"true"` 5906 5907 // The name of the vault. 5908 // 5909 // VaultName is a required field 5910 VaultName *string `location:"uri" locationName:"vaultName" type:"string" required:"true"` 5911} 5912 5913// String returns the string representation. 5914// 5915// API parameter values that are decorated as "sensitive" in the API will not 5916// be included in the string output. The member name will be present, but the 5917// value will be replaced with "sensitive". 5918func (s GetVaultNotificationsInput) String() string { 5919 return awsutil.Prettify(s) 5920} 5921 5922// GoString returns the string representation. 5923// 5924// API parameter values that are decorated as "sensitive" in the API will not 5925// be included in the string output. The member name will be present, but the 5926// value will be replaced with "sensitive". 5927func (s GetVaultNotificationsInput) GoString() string { 5928 return s.String() 5929} 5930 5931// Validate inspects the fields of the type to determine if they are valid. 5932func (s *GetVaultNotificationsInput) Validate() error { 5933 invalidParams := request.ErrInvalidParams{Context: "GetVaultNotificationsInput"} 5934 if s.AccountId == nil { 5935 invalidParams.Add(request.NewErrParamRequired("AccountId")) 5936 } 5937 if s.AccountId != nil && len(*s.AccountId) < 1 { 5938 invalidParams.Add(request.NewErrParamMinLen("AccountId", 1)) 5939 } 5940 if s.VaultName == nil { 5941 invalidParams.Add(request.NewErrParamRequired("VaultName")) 5942 } 5943 if s.VaultName != nil && len(*s.VaultName) < 1 { 5944 invalidParams.Add(request.NewErrParamMinLen("VaultName", 1)) 5945 } 5946 5947 if invalidParams.Len() > 0 { 5948 return invalidParams 5949 } 5950 return nil 5951} 5952 5953// SetAccountId sets the AccountId field's value. 5954func (s *GetVaultNotificationsInput) SetAccountId(v string) *GetVaultNotificationsInput { 5955 s.AccountId = &v 5956 return s 5957} 5958 5959// SetVaultName sets the VaultName field's value. 5960func (s *GetVaultNotificationsInput) SetVaultName(v string) *GetVaultNotificationsInput { 5961 s.VaultName = &v 5962 return s 5963} 5964 5965// Contains the Amazon S3 Glacier response to your request. 5966type GetVaultNotificationsOutput struct { 5967 _ struct{} `type:"structure" payload:"VaultNotificationConfig"` 5968 5969 // Returns the notification configuration set on the vault. 5970 VaultNotificationConfig *VaultNotificationConfig `locationName:"vaultNotificationConfig" type:"structure"` 5971} 5972 5973// String returns the string representation. 5974// 5975// API parameter values that are decorated as "sensitive" in the API will not 5976// be included in the string output. The member name will be present, but the 5977// value will be replaced with "sensitive". 5978func (s GetVaultNotificationsOutput) String() string { 5979 return awsutil.Prettify(s) 5980} 5981 5982// GoString returns the string representation. 5983// 5984// API parameter values that are decorated as "sensitive" in the API will not 5985// be included in the string output. The member name will be present, but the 5986// value will be replaced with "sensitive". 5987func (s GetVaultNotificationsOutput) GoString() string { 5988 return s.String() 5989} 5990 5991// SetVaultNotificationConfig sets the VaultNotificationConfig field's value. 5992func (s *GetVaultNotificationsOutput) SetVaultNotificationConfig(v *VaultNotificationConfig) *GetVaultNotificationsOutput { 5993 s.VaultNotificationConfig = v 5994 return s 5995} 5996 5997// Contains information about a grant. 5998type Grant struct { 5999 _ struct{} `type:"structure"` 6000 6001 // The grantee. 6002 Grantee *Grantee `type:"structure"` 6003 6004 // Specifies the permission given to the grantee. 6005 Permission *string `type:"string" enum:"Permission"` 6006} 6007 6008// String returns the string representation. 6009// 6010// API parameter values that are decorated as "sensitive" in the API will not 6011// be included in the string output. The member name will be present, but the 6012// value will be replaced with "sensitive". 6013func (s Grant) String() string { 6014 return awsutil.Prettify(s) 6015} 6016 6017// GoString returns the string representation. 6018// 6019// API parameter values that are decorated as "sensitive" in the API will not 6020// be included in the string output. The member name will be present, but the 6021// value will be replaced with "sensitive". 6022func (s Grant) GoString() string { 6023 return s.String() 6024} 6025 6026// Validate inspects the fields of the type to determine if they are valid. 6027func (s *Grant) Validate() error { 6028 invalidParams := request.ErrInvalidParams{Context: "Grant"} 6029 if s.Grantee != nil { 6030 if err := s.Grantee.Validate(); err != nil { 6031 invalidParams.AddNested("Grantee", err.(request.ErrInvalidParams)) 6032 } 6033 } 6034 6035 if invalidParams.Len() > 0 { 6036 return invalidParams 6037 } 6038 return nil 6039} 6040 6041// SetGrantee sets the Grantee field's value. 6042func (s *Grant) SetGrantee(v *Grantee) *Grant { 6043 s.Grantee = v 6044 return s 6045} 6046 6047// SetPermission sets the Permission field's value. 6048func (s *Grant) SetPermission(v string) *Grant { 6049 s.Permission = &v 6050 return s 6051} 6052 6053// Contains information about the grantee. 6054type Grantee struct { 6055 _ struct{} `type:"structure"` 6056 6057 // Screen name of the grantee. 6058 DisplayName *string `type:"string"` 6059 6060 // Email address of the grantee. 6061 EmailAddress *string `type:"string"` 6062 6063 // The canonical user ID of the grantee. 6064 ID *string `type:"string"` 6065 6066 // Type of grantee 6067 // 6068 // Type is a required field 6069 Type *string `type:"string" required:"true" enum:"Type"` 6070 6071 // URI of the grantee group. 6072 URI *string `type:"string"` 6073} 6074 6075// String returns the string representation. 6076// 6077// API parameter values that are decorated as "sensitive" in the API will not 6078// be included in the string output. The member name will be present, but the 6079// value will be replaced with "sensitive". 6080func (s Grantee) String() string { 6081 return awsutil.Prettify(s) 6082} 6083 6084// GoString returns the string representation. 6085// 6086// API parameter values that are decorated as "sensitive" in the API will not 6087// be included in the string output. The member name will be present, but the 6088// value will be replaced with "sensitive". 6089func (s Grantee) GoString() string { 6090 return s.String() 6091} 6092 6093// Validate inspects the fields of the type to determine if they are valid. 6094func (s *Grantee) Validate() error { 6095 invalidParams := request.ErrInvalidParams{Context: "Grantee"} 6096 if s.Type == nil { 6097 invalidParams.Add(request.NewErrParamRequired("Type")) 6098 } 6099 6100 if invalidParams.Len() > 0 { 6101 return invalidParams 6102 } 6103 return nil 6104} 6105 6106// SetDisplayName sets the DisplayName field's value. 6107func (s *Grantee) SetDisplayName(v string) *Grantee { 6108 s.DisplayName = &v 6109 return s 6110} 6111 6112// SetEmailAddress sets the EmailAddress field's value. 6113func (s *Grantee) SetEmailAddress(v string) *Grantee { 6114 s.EmailAddress = &v 6115 return s 6116} 6117 6118// SetID sets the ID field's value. 6119func (s *Grantee) SetID(v string) *Grantee { 6120 s.ID = &v 6121 return s 6122} 6123 6124// SetType sets the Type field's value. 6125func (s *Grantee) SetType(v string) *Grantee { 6126 s.Type = &v 6127 return s 6128} 6129 6130// SetURI sets the URI field's value. 6131func (s *Grantee) SetURI(v string) *Grantee { 6132 s.URI = &v 6133 return s 6134} 6135 6136// Provides options for initiating an Amazon S3 Glacier job. 6137type InitiateJobInput struct { 6138 _ struct{} `type:"structure" payload:"JobParameters"` 6139 6140 // The AccountId value is the AWS account ID of the account that owns the vault. 6141 // You can either specify an AWS account ID or optionally a single '-' (hyphen), 6142 // in which case Amazon S3 Glacier uses the AWS account ID associated with the 6143 // credentials used to sign the request. If you use an account ID, do not include 6144 // any hyphens ('-') in the ID. 6145 // 6146 // AccountId is a required field 6147 AccountId *string `location:"uri" locationName:"accountId" type:"string" required:"true"` 6148 6149 // Provides options for specifying job information. 6150 JobParameters *JobParameters `locationName:"jobParameters" type:"structure"` 6151 6152 // The name of the vault. 6153 // 6154 // VaultName is a required field 6155 VaultName *string `location:"uri" locationName:"vaultName" type:"string" required:"true"` 6156} 6157 6158// String returns the string representation. 6159// 6160// API parameter values that are decorated as "sensitive" in the API will not 6161// be included in the string output. The member name will be present, but the 6162// value will be replaced with "sensitive". 6163func (s InitiateJobInput) String() string { 6164 return awsutil.Prettify(s) 6165} 6166 6167// GoString returns the string representation. 6168// 6169// API parameter values that are decorated as "sensitive" in the API will not 6170// be included in the string output. The member name will be present, but the 6171// value will be replaced with "sensitive". 6172func (s InitiateJobInput) GoString() string { 6173 return s.String() 6174} 6175 6176// Validate inspects the fields of the type to determine if they are valid. 6177func (s *InitiateJobInput) Validate() error { 6178 invalidParams := request.ErrInvalidParams{Context: "InitiateJobInput"} 6179 if s.AccountId == nil { 6180 invalidParams.Add(request.NewErrParamRequired("AccountId")) 6181 } 6182 if s.AccountId != nil && len(*s.AccountId) < 1 { 6183 invalidParams.Add(request.NewErrParamMinLen("AccountId", 1)) 6184 } 6185 if s.VaultName == nil { 6186 invalidParams.Add(request.NewErrParamRequired("VaultName")) 6187 } 6188 if s.VaultName != nil && len(*s.VaultName) < 1 { 6189 invalidParams.Add(request.NewErrParamMinLen("VaultName", 1)) 6190 } 6191 if s.JobParameters != nil { 6192 if err := s.JobParameters.Validate(); err != nil { 6193 invalidParams.AddNested("JobParameters", err.(request.ErrInvalidParams)) 6194 } 6195 } 6196 6197 if invalidParams.Len() > 0 { 6198 return invalidParams 6199 } 6200 return nil 6201} 6202 6203// SetAccountId sets the AccountId field's value. 6204func (s *InitiateJobInput) SetAccountId(v string) *InitiateJobInput { 6205 s.AccountId = &v 6206 return s 6207} 6208 6209// SetJobParameters sets the JobParameters field's value. 6210func (s *InitiateJobInput) SetJobParameters(v *JobParameters) *InitiateJobInput { 6211 s.JobParameters = v 6212 return s 6213} 6214 6215// SetVaultName sets the VaultName field's value. 6216func (s *InitiateJobInput) SetVaultName(v string) *InitiateJobInput { 6217 s.VaultName = &v 6218 return s 6219} 6220 6221// Contains the Amazon S3 Glacier response to your request. 6222type InitiateJobOutput struct { 6223 _ struct{} `type:"structure"` 6224 6225 // The ID of the job. 6226 JobId *string `location:"header" locationName:"x-amz-job-id" type:"string"` 6227 6228 // The path to the location of where the select results are stored. 6229 JobOutputPath *string `location:"header" locationName:"x-amz-job-output-path" type:"string"` 6230 6231 // The relative URI path of the job. 6232 Location *string `location:"header" locationName:"Location" type:"string"` 6233} 6234 6235// String returns the string representation. 6236// 6237// API parameter values that are decorated as "sensitive" in the API will not 6238// be included in the string output. The member name will be present, but the 6239// value will be replaced with "sensitive". 6240func (s InitiateJobOutput) String() string { 6241 return awsutil.Prettify(s) 6242} 6243 6244// GoString returns the string representation. 6245// 6246// API parameter values that are decorated as "sensitive" in the API will not 6247// be included in the string output. The member name will be present, but the 6248// value will be replaced with "sensitive". 6249func (s InitiateJobOutput) GoString() string { 6250 return s.String() 6251} 6252 6253// SetJobId sets the JobId field's value. 6254func (s *InitiateJobOutput) SetJobId(v string) *InitiateJobOutput { 6255 s.JobId = &v 6256 return s 6257} 6258 6259// SetJobOutputPath sets the JobOutputPath field's value. 6260func (s *InitiateJobOutput) SetJobOutputPath(v string) *InitiateJobOutput { 6261 s.JobOutputPath = &v 6262 return s 6263} 6264 6265// SetLocation sets the Location field's value. 6266func (s *InitiateJobOutput) SetLocation(v string) *InitiateJobOutput { 6267 s.Location = &v 6268 return s 6269} 6270 6271// Provides options for initiating a multipart upload to an Amazon S3 Glacier 6272// vault. 6273type InitiateMultipartUploadInput struct { 6274 _ struct{} `type:"structure" nopayload:"true"` 6275 6276 // The AccountId value is the AWS account ID of the account that owns the vault. 6277 // You can either specify an AWS account ID or optionally a single '-' (hyphen), 6278 // in which case Amazon S3 Glacier uses the AWS account ID associated with the 6279 // credentials used to sign the request. If you use an account ID, do not include 6280 // any hyphens ('-') in the ID. 6281 // 6282 // AccountId is a required field 6283 AccountId *string `location:"uri" locationName:"accountId" type:"string" required:"true"` 6284 6285 // The archive description that you are uploading in parts. 6286 // 6287 // The part size must be a megabyte (1024 KB) multiplied by a power of 2, for 6288 // example 1048576 (1 MB), 2097152 (2 MB), 4194304 (4 MB), 8388608 (8 MB), and 6289 // so on. The minimum allowable part size is 1 MB, and the maximum is 4 GB (4096 6290 // MB). 6291 ArchiveDescription *string `location:"header" locationName:"x-amz-archive-description" type:"string"` 6292 6293 // The size of each part except the last, in bytes. The last part can be smaller 6294 // than this part size. 6295 PartSize *string `location:"header" locationName:"x-amz-part-size" type:"string"` 6296 6297 // The name of the vault. 6298 // 6299 // VaultName is a required field 6300 VaultName *string `location:"uri" locationName:"vaultName" type:"string" required:"true"` 6301} 6302 6303// String returns the string representation. 6304// 6305// API parameter values that are decorated as "sensitive" in the API will not 6306// be included in the string output. The member name will be present, but the 6307// value will be replaced with "sensitive". 6308func (s InitiateMultipartUploadInput) String() string { 6309 return awsutil.Prettify(s) 6310} 6311 6312// GoString returns the string representation. 6313// 6314// API parameter values that are decorated as "sensitive" in the API will not 6315// be included in the string output. The member name will be present, but the 6316// value will be replaced with "sensitive". 6317func (s InitiateMultipartUploadInput) GoString() string { 6318 return s.String() 6319} 6320 6321// Validate inspects the fields of the type to determine if they are valid. 6322func (s *InitiateMultipartUploadInput) Validate() error { 6323 invalidParams := request.ErrInvalidParams{Context: "InitiateMultipartUploadInput"} 6324 if s.AccountId == nil { 6325 invalidParams.Add(request.NewErrParamRequired("AccountId")) 6326 } 6327 if s.AccountId != nil && len(*s.AccountId) < 1 { 6328 invalidParams.Add(request.NewErrParamMinLen("AccountId", 1)) 6329 } 6330 if s.VaultName == nil { 6331 invalidParams.Add(request.NewErrParamRequired("VaultName")) 6332 } 6333 if s.VaultName != nil && len(*s.VaultName) < 1 { 6334 invalidParams.Add(request.NewErrParamMinLen("VaultName", 1)) 6335 } 6336 6337 if invalidParams.Len() > 0 { 6338 return invalidParams 6339 } 6340 return nil 6341} 6342 6343// SetAccountId sets the AccountId field's value. 6344func (s *InitiateMultipartUploadInput) SetAccountId(v string) *InitiateMultipartUploadInput { 6345 s.AccountId = &v 6346 return s 6347} 6348 6349// SetArchiveDescription sets the ArchiveDescription field's value. 6350func (s *InitiateMultipartUploadInput) SetArchiveDescription(v string) *InitiateMultipartUploadInput { 6351 s.ArchiveDescription = &v 6352 return s 6353} 6354 6355// SetPartSize sets the PartSize field's value. 6356func (s *InitiateMultipartUploadInput) SetPartSize(v string) *InitiateMultipartUploadInput { 6357 s.PartSize = &v 6358 return s 6359} 6360 6361// SetVaultName sets the VaultName field's value. 6362func (s *InitiateMultipartUploadInput) SetVaultName(v string) *InitiateMultipartUploadInput { 6363 s.VaultName = &v 6364 return s 6365} 6366 6367// The Amazon S3 Glacier response to your request. 6368type InitiateMultipartUploadOutput struct { 6369 _ struct{} `type:"structure"` 6370 6371 // The relative URI path of the multipart upload ID Amazon S3 Glacier created. 6372 Location *string `location:"header" locationName:"Location" type:"string"` 6373 6374 // The ID of the multipart upload. This value is also included as part of the 6375 // location. 6376 UploadId *string `location:"header" locationName:"x-amz-multipart-upload-id" type:"string"` 6377} 6378 6379// String returns the string representation. 6380// 6381// API parameter values that are decorated as "sensitive" in the API will not 6382// be included in the string output. The member name will be present, but the 6383// value will be replaced with "sensitive". 6384func (s InitiateMultipartUploadOutput) String() string { 6385 return awsutil.Prettify(s) 6386} 6387 6388// GoString returns the string representation. 6389// 6390// API parameter values that are decorated as "sensitive" in the API will not 6391// be included in the string output. The member name will be present, but the 6392// value will be replaced with "sensitive". 6393func (s InitiateMultipartUploadOutput) GoString() string { 6394 return s.String() 6395} 6396 6397// SetLocation sets the Location field's value. 6398func (s *InitiateMultipartUploadOutput) SetLocation(v string) *InitiateMultipartUploadOutput { 6399 s.Location = &v 6400 return s 6401} 6402 6403// SetUploadId sets the UploadId field's value. 6404func (s *InitiateMultipartUploadOutput) SetUploadId(v string) *InitiateMultipartUploadOutput { 6405 s.UploadId = &v 6406 return s 6407} 6408 6409// The input values for InitiateVaultLock. 6410type InitiateVaultLockInput struct { 6411 _ struct{} `type:"structure" payload:"Policy"` 6412 6413 // The AccountId value is the AWS account ID. This value must match the AWS 6414 // account ID associated with the credentials used to sign the request. You 6415 // can either specify an AWS account ID or optionally a single '-' (hyphen), 6416 // in which case Amazon Glacier uses the AWS account ID associated with the 6417 // credentials used to sign the request. If you specify your account ID, do 6418 // not include any hyphens ('-') in the ID. 6419 // 6420 // AccountId is a required field 6421 AccountId *string `location:"uri" locationName:"accountId" type:"string" required:"true"` 6422 6423 // The vault lock policy as a JSON string, which uses "\" as an escape character. 6424 Policy *VaultLockPolicy `locationName:"policy" type:"structure"` 6425 6426 // The name of the vault. 6427 // 6428 // VaultName is a required field 6429 VaultName *string `location:"uri" locationName:"vaultName" type:"string" required:"true"` 6430} 6431 6432// String returns the string representation. 6433// 6434// API parameter values that are decorated as "sensitive" in the API will not 6435// be included in the string output. The member name will be present, but the 6436// value will be replaced with "sensitive". 6437func (s InitiateVaultLockInput) String() string { 6438 return awsutil.Prettify(s) 6439} 6440 6441// GoString returns the string representation. 6442// 6443// API parameter values that are decorated as "sensitive" in the API will not 6444// be included in the string output. The member name will be present, but the 6445// value will be replaced with "sensitive". 6446func (s InitiateVaultLockInput) GoString() string { 6447 return s.String() 6448} 6449 6450// Validate inspects the fields of the type to determine if they are valid. 6451func (s *InitiateVaultLockInput) Validate() error { 6452 invalidParams := request.ErrInvalidParams{Context: "InitiateVaultLockInput"} 6453 if s.AccountId == nil { 6454 invalidParams.Add(request.NewErrParamRequired("AccountId")) 6455 } 6456 if s.AccountId != nil && len(*s.AccountId) < 1 { 6457 invalidParams.Add(request.NewErrParamMinLen("AccountId", 1)) 6458 } 6459 if s.VaultName == nil { 6460 invalidParams.Add(request.NewErrParamRequired("VaultName")) 6461 } 6462 if s.VaultName != nil && len(*s.VaultName) < 1 { 6463 invalidParams.Add(request.NewErrParamMinLen("VaultName", 1)) 6464 } 6465 6466 if invalidParams.Len() > 0 { 6467 return invalidParams 6468 } 6469 return nil 6470} 6471 6472// SetAccountId sets the AccountId field's value. 6473func (s *InitiateVaultLockInput) SetAccountId(v string) *InitiateVaultLockInput { 6474 s.AccountId = &v 6475 return s 6476} 6477 6478// SetPolicy sets the Policy field's value. 6479func (s *InitiateVaultLockInput) SetPolicy(v *VaultLockPolicy) *InitiateVaultLockInput { 6480 s.Policy = v 6481 return s 6482} 6483 6484// SetVaultName sets the VaultName field's value. 6485func (s *InitiateVaultLockInput) SetVaultName(v string) *InitiateVaultLockInput { 6486 s.VaultName = &v 6487 return s 6488} 6489 6490// Contains the Amazon S3 Glacier response to your request. 6491type InitiateVaultLockOutput struct { 6492 _ struct{} `type:"structure"` 6493 6494 // The lock ID, which is used to complete the vault locking process. 6495 LockId *string `location:"header" locationName:"x-amz-lock-id" type:"string"` 6496} 6497 6498// String returns the string representation. 6499// 6500// API parameter values that are decorated as "sensitive" in the API will not 6501// be included in the string output. The member name will be present, but the 6502// value will be replaced with "sensitive". 6503func (s InitiateVaultLockOutput) String() string { 6504 return awsutil.Prettify(s) 6505} 6506 6507// GoString returns the string representation. 6508// 6509// API parameter values that are decorated as "sensitive" in the API will not 6510// be included in the string output. The member name will be present, but the 6511// value will be replaced with "sensitive". 6512func (s InitiateVaultLockOutput) GoString() string { 6513 return s.String() 6514} 6515 6516// SetLockId sets the LockId field's value. 6517func (s *InitiateVaultLockOutput) SetLockId(v string) *InitiateVaultLockOutput { 6518 s.LockId = &v 6519 return s 6520} 6521 6522// Describes how the archive is serialized. 6523type InputSerialization struct { 6524 _ struct{} `type:"structure"` 6525 6526 // Describes the serialization of a CSV-encoded object. 6527 Csv *CSVInput `locationName:"csv" type:"structure"` 6528} 6529 6530// String returns the string representation. 6531// 6532// API parameter values that are decorated as "sensitive" in the API will not 6533// be included in the string output. The member name will be present, but the 6534// value will be replaced with "sensitive". 6535func (s InputSerialization) String() string { 6536 return awsutil.Prettify(s) 6537} 6538 6539// GoString returns the string representation. 6540// 6541// API parameter values that are decorated as "sensitive" in the API will not 6542// be included in the string output. The member name will be present, but the 6543// value will be replaced with "sensitive". 6544func (s InputSerialization) GoString() string { 6545 return s.String() 6546} 6547 6548// SetCsv sets the Csv field's value. 6549func (s *InputSerialization) SetCsv(v *CSVInput) *InputSerialization { 6550 s.Csv = v 6551 return s 6552} 6553 6554// Returned if there is insufficient capacity to process this expedited request. 6555// This error only applies to expedited retrievals and not to standard or bulk 6556// retrievals. 6557type InsufficientCapacityException struct { 6558 _ struct{} `type:"structure"` 6559 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 6560 6561 Code_ *string `locationName:"code" type:"string"` 6562 6563 Message_ *string `locationName:"message" type:"string"` 6564 6565 Type *string `locationName:"type" type:"string"` 6566} 6567 6568// String returns the string representation. 6569// 6570// API parameter values that are decorated as "sensitive" in the API will not 6571// be included in the string output. The member name will be present, but the 6572// value will be replaced with "sensitive". 6573func (s InsufficientCapacityException) String() string { 6574 return awsutil.Prettify(s) 6575} 6576 6577// GoString returns the string representation. 6578// 6579// API parameter values that are decorated as "sensitive" in the API will not 6580// be included in the string output. The member name will be present, but the 6581// value will be replaced with "sensitive". 6582func (s InsufficientCapacityException) GoString() string { 6583 return s.String() 6584} 6585 6586func newErrorInsufficientCapacityException(v protocol.ResponseMetadata) error { 6587 return &InsufficientCapacityException{ 6588 RespMetadata: v, 6589 } 6590} 6591 6592// Code returns the exception type name. 6593func (s *InsufficientCapacityException) Code() string { 6594 return "InsufficientCapacityException" 6595} 6596 6597// Message returns the exception's message. 6598func (s *InsufficientCapacityException) Message() string { 6599 if s.Message_ != nil { 6600 return *s.Message_ 6601 } 6602 return "" 6603} 6604 6605// OrigErr always returns nil, satisfies awserr.Error interface. 6606func (s *InsufficientCapacityException) OrigErr() error { 6607 return nil 6608} 6609 6610func (s *InsufficientCapacityException) Error() string { 6611 return fmt.Sprintf("%s: %s\n%s", s.Code(), s.Message(), s.String()) 6612} 6613 6614// Status code returns the HTTP status code for the request's response error. 6615func (s *InsufficientCapacityException) StatusCode() int { 6616 return s.RespMetadata.StatusCode 6617} 6618 6619// RequestID returns the service's response RequestID for request. 6620func (s *InsufficientCapacityException) RequestID() string { 6621 return s.RespMetadata.RequestID 6622} 6623 6624// Returned if a parameter of the request is incorrectly specified. 6625type InvalidParameterValueException struct { 6626 _ struct{} `type:"structure"` 6627 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 6628 6629 // 400 Bad Request 6630 Code_ *string `locationName:"code" type:"string"` 6631 6632 // Returned if a parameter of the request is incorrectly specified. 6633 Message_ *string `locationName:"message" type:"string"` 6634 6635 // Client 6636 Type *string `locationName:"type" type:"string"` 6637} 6638 6639// String returns the string representation. 6640// 6641// API parameter values that are decorated as "sensitive" in the API will not 6642// be included in the string output. The member name will be present, but the 6643// value will be replaced with "sensitive". 6644func (s InvalidParameterValueException) String() string { 6645 return awsutil.Prettify(s) 6646} 6647 6648// GoString returns the string representation. 6649// 6650// API parameter values that are decorated as "sensitive" in the API will not 6651// be included in the string output. The member name will be present, but the 6652// value will be replaced with "sensitive". 6653func (s InvalidParameterValueException) GoString() string { 6654 return s.String() 6655} 6656 6657func newErrorInvalidParameterValueException(v protocol.ResponseMetadata) error { 6658 return &InvalidParameterValueException{ 6659 RespMetadata: v, 6660 } 6661} 6662 6663// Code returns the exception type name. 6664func (s *InvalidParameterValueException) Code() string { 6665 return "InvalidParameterValueException" 6666} 6667 6668// Message returns the exception's message. 6669func (s *InvalidParameterValueException) Message() string { 6670 if s.Message_ != nil { 6671 return *s.Message_ 6672 } 6673 return "" 6674} 6675 6676// OrigErr always returns nil, satisfies awserr.Error interface. 6677func (s *InvalidParameterValueException) OrigErr() error { 6678 return nil 6679} 6680 6681func (s *InvalidParameterValueException) Error() string { 6682 return fmt.Sprintf("%s: %s\n%s", s.Code(), s.Message(), s.String()) 6683} 6684 6685// Status code returns the HTTP status code for the request's response error. 6686func (s *InvalidParameterValueException) StatusCode() int { 6687 return s.RespMetadata.StatusCode 6688} 6689 6690// RequestID returns the service's response RequestID for request. 6691func (s *InvalidParameterValueException) RequestID() string { 6692 return s.RespMetadata.RequestID 6693} 6694 6695// Describes the options for a range inventory retrieval job. 6696type InventoryRetrievalJobDescription struct { 6697 _ struct{} `type:"structure"` 6698 6699 // The end of the date range in UTC for vault inventory retrieval that includes 6700 // archives created before this date. This value should be a string in the ISO 6701 // 8601 date format, for example 2013-03-20T17:03:43Z. 6702 EndDate *string `type:"string"` 6703 6704 // The output format for the vault inventory list, which is set by the InitiateJob 6705 // request when initiating a job to retrieve a vault inventory. Valid values 6706 // are CSV and JSON. 6707 Format *string `type:"string"` 6708 6709 // The maximum number of inventory items returned per vault inventory retrieval 6710 // request. This limit is set when initiating the job with the a InitiateJob 6711 // request. 6712 Limit *string `type:"string"` 6713 6714 // An opaque string that represents where to continue pagination of the vault 6715 // inventory retrieval results. You use the marker in a new InitiateJob request 6716 // to obtain additional inventory items. If there are no more inventory items, 6717 // this value is null. For more information, see Range Inventory Retrieval (https://docs.aws.amazon.com/amazonglacier/latest/dev/api-initiate-job-post.html#api-initiate-job-post-vault-inventory-list-filtering). 6718 Marker *string `type:"string"` 6719 6720 // The start of the date range in Universal Coordinated Time (UTC) for vault 6721 // inventory retrieval that includes archives created on or after this date. 6722 // This value should be a string in the ISO 8601 date format, for example 2013-03-20T17:03:43Z. 6723 StartDate *string `type:"string"` 6724} 6725 6726// String returns the string representation. 6727// 6728// API parameter values that are decorated as "sensitive" in the API will not 6729// be included in the string output. The member name will be present, but the 6730// value will be replaced with "sensitive". 6731func (s InventoryRetrievalJobDescription) String() string { 6732 return awsutil.Prettify(s) 6733} 6734 6735// GoString returns the string representation. 6736// 6737// API parameter values that are decorated as "sensitive" in the API will not 6738// be included in the string output. The member name will be present, but the 6739// value will be replaced with "sensitive". 6740func (s InventoryRetrievalJobDescription) GoString() string { 6741 return s.String() 6742} 6743 6744// SetEndDate sets the EndDate field's value. 6745func (s *InventoryRetrievalJobDescription) SetEndDate(v string) *InventoryRetrievalJobDescription { 6746 s.EndDate = &v 6747 return s 6748} 6749 6750// SetFormat sets the Format field's value. 6751func (s *InventoryRetrievalJobDescription) SetFormat(v string) *InventoryRetrievalJobDescription { 6752 s.Format = &v 6753 return s 6754} 6755 6756// SetLimit sets the Limit field's value. 6757func (s *InventoryRetrievalJobDescription) SetLimit(v string) *InventoryRetrievalJobDescription { 6758 s.Limit = &v 6759 return s 6760} 6761 6762// SetMarker sets the Marker field's value. 6763func (s *InventoryRetrievalJobDescription) SetMarker(v string) *InventoryRetrievalJobDescription { 6764 s.Marker = &v 6765 return s 6766} 6767 6768// SetStartDate sets the StartDate field's value. 6769func (s *InventoryRetrievalJobDescription) SetStartDate(v string) *InventoryRetrievalJobDescription { 6770 s.StartDate = &v 6771 return s 6772} 6773 6774// Provides options for specifying a range inventory retrieval job. 6775type InventoryRetrievalJobInput struct { 6776 _ struct{} `type:"structure"` 6777 6778 // The end of the date range in UTC for vault inventory retrieval that includes 6779 // archives created before this date. This value should be a string in the ISO 6780 // 8601 date format, for example 2013-03-20T17:03:43Z. 6781 EndDate *string `type:"string"` 6782 6783 // Specifies the maximum number of inventory items returned per vault inventory 6784 // retrieval request. Valid values are greater than or equal to 1. 6785 Limit *string `type:"string"` 6786 6787 // An opaque string that represents where to continue pagination of the vault 6788 // inventory retrieval results. You use the marker in a new InitiateJob request 6789 // to obtain additional inventory items. If there are no more inventory items, 6790 // this value is null. 6791 Marker *string `type:"string"` 6792 6793 // The start of the date range in UTC for vault inventory retrieval that includes 6794 // archives created on or after this date. This value should be a string in 6795 // the ISO 8601 date format, for example 2013-03-20T17:03:43Z. 6796 StartDate *string `type:"string"` 6797} 6798 6799// String returns the string representation. 6800// 6801// API parameter values that are decorated as "sensitive" in the API will not 6802// be included in the string output. The member name will be present, but the 6803// value will be replaced with "sensitive". 6804func (s InventoryRetrievalJobInput) String() string { 6805 return awsutil.Prettify(s) 6806} 6807 6808// GoString returns the string representation. 6809// 6810// API parameter values that are decorated as "sensitive" in the API will not 6811// be included in the string output. The member name will be present, but the 6812// value will be replaced with "sensitive". 6813func (s InventoryRetrievalJobInput) GoString() string { 6814 return s.String() 6815} 6816 6817// SetEndDate sets the EndDate field's value. 6818func (s *InventoryRetrievalJobInput) SetEndDate(v string) *InventoryRetrievalJobInput { 6819 s.EndDate = &v 6820 return s 6821} 6822 6823// SetLimit sets the Limit field's value. 6824func (s *InventoryRetrievalJobInput) SetLimit(v string) *InventoryRetrievalJobInput { 6825 s.Limit = &v 6826 return s 6827} 6828 6829// SetMarker sets the Marker field's value. 6830func (s *InventoryRetrievalJobInput) SetMarker(v string) *InventoryRetrievalJobInput { 6831 s.Marker = &v 6832 return s 6833} 6834 6835// SetStartDate sets the StartDate field's value. 6836func (s *InventoryRetrievalJobInput) SetStartDate(v string) *InventoryRetrievalJobInput { 6837 s.StartDate = &v 6838 return s 6839} 6840 6841// Contains the description of an Amazon S3 Glacier job. 6842type JobDescription struct { 6843 _ struct{} `type:"structure"` 6844 6845 // The job type. This value is either ArchiveRetrieval, InventoryRetrieval, 6846 // or Select. 6847 Action *string `type:"string" enum:"ActionCode"` 6848 6849 // The archive ID requested for a select job or archive retrieval. Otherwise, 6850 // this field is null. 6851 ArchiveId *string `type:"string"` 6852 6853 // The SHA256 tree hash of the entire archive for an archive retrieval. For 6854 // inventory retrieval or select jobs, this field is null. 6855 ArchiveSHA256TreeHash *string `type:"string"` 6856 6857 // For an archive retrieval job, this value is the size in bytes of the archive 6858 // being requested for download. For an inventory retrieval or select job, this 6859 // value is null. 6860 ArchiveSizeInBytes *int64 `type:"long"` 6861 6862 // The job status. When a job is completed, you get the job's output using Get 6863 // Job Output (GET output). 6864 Completed *bool `type:"boolean"` 6865 6866 // The UTC time that the job request completed. While the job is in progress, 6867 // the value is null. 6868 CompletionDate *string `type:"string"` 6869 6870 // The UTC date when the job was created. This value is a string representation 6871 // of ISO 8601 date format, for example "2012-03-20T17:03:43.221Z". 6872 CreationDate *string `type:"string"` 6873 6874 // Parameters used for range inventory retrieval. 6875 InventoryRetrievalParameters *InventoryRetrievalJobDescription `type:"structure"` 6876 6877 // For an inventory retrieval job, this value is the size in bytes of the inventory 6878 // requested for download. For an archive retrieval or select job, this value 6879 // is null. 6880 InventorySizeInBytes *int64 `type:"long"` 6881 6882 // The job description provided when initiating the job. 6883 JobDescription *string `type:"string"` 6884 6885 // An opaque string that identifies an Amazon S3 Glacier job. 6886 JobId *string `type:"string"` 6887 6888 // Contains the job output location. 6889 JobOutputPath *string `type:"string"` 6890 6891 // Contains the location where the data from the select job is stored. 6892 OutputLocation *OutputLocation `type:"structure"` 6893 6894 // The retrieved byte range for archive retrieval jobs in the form StartByteValue-EndByteValue. 6895 // If no range was specified in the archive retrieval, then the whole archive 6896 // is retrieved. In this case, StartByteValue equals 0 and EndByteValue equals 6897 // the size of the archive minus 1. For inventory retrieval or select jobs, 6898 // this field is null. 6899 RetrievalByteRange *string `type:"string"` 6900 6901 // For an archive retrieval job, this value is the checksum of the archive. 6902 // Otherwise, this value is null. 6903 // 6904 // The SHA256 tree hash value for the requested range of an archive. If the 6905 // InitiateJob request for an archive specified a tree-hash aligned range, then 6906 // this field returns a value. 6907 // 6908 // If the whole archive is retrieved, this value is the same as the ArchiveSHA256TreeHash 6909 // value. 6910 // 6911 // This field is null for the following: 6912 // 6913 // * Archive retrieval jobs that specify a range that is not tree-hash aligned 6914 // 6915 // * Archival jobs that specify a range that is equal to the whole archive, 6916 // when the job status is InProgress 6917 // 6918 // * Inventory jobs 6919 // 6920 // * Select jobs 6921 SHA256TreeHash *string `type:"string"` 6922 6923 // An Amazon SNS topic that receives notification. 6924 SNSTopic *string `type:"string"` 6925 6926 // Contains the parameters used for a select. 6927 SelectParameters *SelectParameters `type:"structure"` 6928 6929 // The status code can be InProgress, Succeeded, or Failed, and indicates the 6930 // status of the job. 6931 StatusCode *string `type:"string" enum:"StatusCode"` 6932 6933 // A friendly message that describes the job status. 6934 StatusMessage *string `type:"string"` 6935 6936 // The tier to use for a select or an archive retrieval. Valid values are Expedited, 6937 // Standard, or Bulk. Standard is the default. 6938 Tier *string `type:"string"` 6939 6940 // The Amazon Resource Name (ARN) of the vault from which an archive retrieval 6941 // was requested. 6942 VaultARN *string `type:"string"` 6943} 6944 6945// String returns the string representation. 6946// 6947// API parameter values that are decorated as "sensitive" in the API will not 6948// be included in the string output. The member name will be present, but the 6949// value will be replaced with "sensitive". 6950func (s JobDescription) String() string { 6951 return awsutil.Prettify(s) 6952} 6953 6954// GoString returns the string representation. 6955// 6956// API parameter values that are decorated as "sensitive" in the API will not 6957// be included in the string output. The member name will be present, but the 6958// value will be replaced with "sensitive". 6959func (s JobDescription) GoString() string { 6960 return s.String() 6961} 6962 6963// SetAction sets the Action field's value. 6964func (s *JobDescription) SetAction(v string) *JobDescription { 6965 s.Action = &v 6966 return s 6967} 6968 6969// SetArchiveId sets the ArchiveId field's value. 6970func (s *JobDescription) SetArchiveId(v string) *JobDescription { 6971 s.ArchiveId = &v 6972 return s 6973} 6974 6975// SetArchiveSHA256TreeHash sets the ArchiveSHA256TreeHash field's value. 6976func (s *JobDescription) SetArchiveSHA256TreeHash(v string) *JobDescription { 6977 s.ArchiveSHA256TreeHash = &v 6978 return s 6979} 6980 6981// SetArchiveSizeInBytes sets the ArchiveSizeInBytes field's value. 6982func (s *JobDescription) SetArchiveSizeInBytes(v int64) *JobDescription { 6983 s.ArchiveSizeInBytes = &v 6984 return s 6985} 6986 6987// SetCompleted sets the Completed field's value. 6988func (s *JobDescription) SetCompleted(v bool) *JobDescription { 6989 s.Completed = &v 6990 return s 6991} 6992 6993// SetCompletionDate sets the CompletionDate field's value. 6994func (s *JobDescription) SetCompletionDate(v string) *JobDescription { 6995 s.CompletionDate = &v 6996 return s 6997} 6998 6999// SetCreationDate sets the CreationDate field's value. 7000func (s *JobDescription) SetCreationDate(v string) *JobDescription { 7001 s.CreationDate = &v 7002 return s 7003} 7004 7005// SetInventoryRetrievalParameters sets the InventoryRetrievalParameters field's value. 7006func (s *JobDescription) SetInventoryRetrievalParameters(v *InventoryRetrievalJobDescription) *JobDescription { 7007 s.InventoryRetrievalParameters = v 7008 return s 7009} 7010 7011// SetInventorySizeInBytes sets the InventorySizeInBytes field's value. 7012func (s *JobDescription) SetInventorySizeInBytes(v int64) *JobDescription { 7013 s.InventorySizeInBytes = &v 7014 return s 7015} 7016 7017// SetJobDescription sets the JobDescription field's value. 7018func (s *JobDescription) SetJobDescription(v string) *JobDescription { 7019 s.JobDescription = &v 7020 return s 7021} 7022 7023// SetJobId sets the JobId field's value. 7024func (s *JobDescription) SetJobId(v string) *JobDescription { 7025 s.JobId = &v 7026 return s 7027} 7028 7029// SetJobOutputPath sets the JobOutputPath field's value. 7030func (s *JobDescription) SetJobOutputPath(v string) *JobDescription { 7031 s.JobOutputPath = &v 7032 return s 7033} 7034 7035// SetOutputLocation sets the OutputLocation field's value. 7036func (s *JobDescription) SetOutputLocation(v *OutputLocation) *JobDescription { 7037 s.OutputLocation = v 7038 return s 7039} 7040 7041// SetRetrievalByteRange sets the RetrievalByteRange field's value. 7042func (s *JobDescription) SetRetrievalByteRange(v string) *JobDescription { 7043 s.RetrievalByteRange = &v 7044 return s 7045} 7046 7047// SetSHA256TreeHash sets the SHA256TreeHash field's value. 7048func (s *JobDescription) SetSHA256TreeHash(v string) *JobDescription { 7049 s.SHA256TreeHash = &v 7050 return s 7051} 7052 7053// SetSNSTopic sets the SNSTopic field's value. 7054func (s *JobDescription) SetSNSTopic(v string) *JobDescription { 7055 s.SNSTopic = &v 7056 return s 7057} 7058 7059// SetSelectParameters sets the SelectParameters field's value. 7060func (s *JobDescription) SetSelectParameters(v *SelectParameters) *JobDescription { 7061 s.SelectParameters = v 7062 return s 7063} 7064 7065// SetStatusCode sets the StatusCode field's value. 7066func (s *JobDescription) SetStatusCode(v string) *JobDescription { 7067 s.StatusCode = &v 7068 return s 7069} 7070 7071// SetStatusMessage sets the StatusMessage field's value. 7072func (s *JobDescription) SetStatusMessage(v string) *JobDescription { 7073 s.StatusMessage = &v 7074 return s 7075} 7076 7077// SetTier sets the Tier field's value. 7078func (s *JobDescription) SetTier(v string) *JobDescription { 7079 s.Tier = &v 7080 return s 7081} 7082 7083// SetVaultARN sets the VaultARN field's value. 7084func (s *JobDescription) SetVaultARN(v string) *JobDescription { 7085 s.VaultARN = &v 7086 return s 7087} 7088 7089// Provides options for defining a job. 7090type JobParameters struct { 7091 _ struct{} `type:"structure"` 7092 7093 // The ID of the archive that you want to retrieve. This field is required only 7094 // if Type is set to select or archive-retrievalcode>. An error occurs if you 7095 // specify this request parameter for an inventory retrieval job request. 7096 ArchiveId *string `type:"string"` 7097 7098 // The optional description for the job. The description must be less than or 7099 // equal to 1,024 bytes. The allowable characters are 7-bit ASCII without control 7100 // codes-specifically, ASCII values 32-126 decimal or 0x20-0x7E hexadecimal. 7101 Description *string `type:"string"` 7102 7103 // When initiating a job to retrieve a vault inventory, you can optionally add 7104 // this parameter to your request to specify the output format. If you are initiating 7105 // an inventory job and do not specify a Format field, JSON is the default format. 7106 // Valid values are "CSV" and "JSON". 7107 Format *string `type:"string"` 7108 7109 // Input parameters used for range inventory retrieval. 7110 InventoryRetrievalParameters *InventoryRetrievalJobInput `type:"structure"` 7111 7112 // Contains information about the location where the select job results are 7113 // stored. 7114 OutputLocation *OutputLocation `type:"structure"` 7115 7116 // The byte range to retrieve for an archive retrieval. in the form "StartByteValue-EndByteValue" 7117 // If not specified, the whole archive is retrieved. If specified, the byte 7118 // range must be megabyte (1024*1024) aligned which means that StartByteValue 7119 // must be divisible by 1 MB and EndByteValue plus 1 must be divisible by 1 7120 // MB or be the end of the archive specified as the archive byte size value 7121 // minus 1. If RetrievalByteRange is not megabyte aligned, this operation returns 7122 // a 400 response. 7123 // 7124 // An error occurs if you specify this field for an inventory retrieval job 7125 // request. 7126 RetrievalByteRange *string `type:"string"` 7127 7128 // The Amazon SNS topic ARN to which Amazon S3 Glacier sends a notification 7129 // when the job is completed and the output is ready for you to download. The 7130 // specified topic publishes the notification to its subscribers. The SNS topic 7131 // must exist. 7132 SNSTopic *string `type:"string"` 7133 7134 // Contains the parameters that define a job. 7135 SelectParameters *SelectParameters `type:"structure"` 7136 7137 // The tier to use for a select or an archive retrieval job. Valid values are 7138 // Expedited, Standard, or Bulk. Standard is the default. 7139 Tier *string `type:"string"` 7140 7141 // The job type. You can initiate a job to perform a select query on an archive, 7142 // retrieve an archive, or get an inventory of a vault. Valid values are "select", 7143 // "archive-retrieval" and "inventory-retrieval". 7144 Type *string `type:"string"` 7145} 7146 7147// String returns the string representation. 7148// 7149// API parameter values that are decorated as "sensitive" in the API will not 7150// be included in the string output. The member name will be present, but the 7151// value will be replaced with "sensitive". 7152func (s JobParameters) String() string { 7153 return awsutil.Prettify(s) 7154} 7155 7156// GoString returns the string representation. 7157// 7158// API parameter values that are decorated as "sensitive" in the API will not 7159// be included in the string output. The member name will be present, but the 7160// value will be replaced with "sensitive". 7161func (s JobParameters) GoString() string { 7162 return s.String() 7163} 7164 7165// Validate inspects the fields of the type to determine if they are valid. 7166func (s *JobParameters) Validate() error { 7167 invalidParams := request.ErrInvalidParams{Context: "JobParameters"} 7168 if s.OutputLocation != nil { 7169 if err := s.OutputLocation.Validate(); err != nil { 7170 invalidParams.AddNested("OutputLocation", err.(request.ErrInvalidParams)) 7171 } 7172 } 7173 7174 if invalidParams.Len() > 0 { 7175 return invalidParams 7176 } 7177 return nil 7178} 7179 7180// SetArchiveId sets the ArchiveId field's value. 7181func (s *JobParameters) SetArchiveId(v string) *JobParameters { 7182 s.ArchiveId = &v 7183 return s 7184} 7185 7186// SetDescription sets the Description field's value. 7187func (s *JobParameters) SetDescription(v string) *JobParameters { 7188 s.Description = &v 7189 return s 7190} 7191 7192// SetFormat sets the Format field's value. 7193func (s *JobParameters) SetFormat(v string) *JobParameters { 7194 s.Format = &v 7195 return s 7196} 7197 7198// SetInventoryRetrievalParameters sets the InventoryRetrievalParameters field's value. 7199func (s *JobParameters) SetInventoryRetrievalParameters(v *InventoryRetrievalJobInput) *JobParameters { 7200 s.InventoryRetrievalParameters = v 7201 return s 7202} 7203 7204// SetOutputLocation sets the OutputLocation field's value. 7205func (s *JobParameters) SetOutputLocation(v *OutputLocation) *JobParameters { 7206 s.OutputLocation = v 7207 return s 7208} 7209 7210// SetRetrievalByteRange sets the RetrievalByteRange field's value. 7211func (s *JobParameters) SetRetrievalByteRange(v string) *JobParameters { 7212 s.RetrievalByteRange = &v 7213 return s 7214} 7215 7216// SetSNSTopic sets the SNSTopic field's value. 7217func (s *JobParameters) SetSNSTopic(v string) *JobParameters { 7218 s.SNSTopic = &v 7219 return s 7220} 7221 7222// SetSelectParameters sets the SelectParameters field's value. 7223func (s *JobParameters) SetSelectParameters(v *SelectParameters) *JobParameters { 7224 s.SelectParameters = v 7225 return s 7226} 7227 7228// SetTier sets the Tier field's value. 7229func (s *JobParameters) SetTier(v string) *JobParameters { 7230 s.Tier = &v 7231 return s 7232} 7233 7234// SetType sets the Type field's value. 7235func (s *JobParameters) SetType(v string) *JobParameters { 7236 s.Type = &v 7237 return s 7238} 7239 7240// Returned if the request results in a vault or account limit being exceeded. 7241type LimitExceededException struct { 7242 _ struct{} `type:"structure"` 7243 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 7244 7245 // 400 Bad Request 7246 Code_ *string `locationName:"code" type:"string"` 7247 7248 // Returned if the request results in a vault limit or tags limit being exceeded. 7249 Message_ *string `locationName:"message" type:"string"` 7250 7251 // Client 7252 Type *string `locationName:"type" type:"string"` 7253} 7254 7255// String returns the string representation. 7256// 7257// API parameter values that are decorated as "sensitive" in the API will not 7258// be included in the string output. The member name will be present, but the 7259// value will be replaced with "sensitive". 7260func (s LimitExceededException) String() string { 7261 return awsutil.Prettify(s) 7262} 7263 7264// GoString returns the string representation. 7265// 7266// API parameter values that are decorated as "sensitive" in the API will not 7267// be included in the string output. The member name will be present, but the 7268// value will be replaced with "sensitive". 7269func (s LimitExceededException) GoString() string { 7270 return s.String() 7271} 7272 7273func newErrorLimitExceededException(v protocol.ResponseMetadata) error { 7274 return &LimitExceededException{ 7275 RespMetadata: v, 7276 } 7277} 7278 7279// Code returns the exception type name. 7280func (s *LimitExceededException) Code() string { 7281 return "LimitExceededException" 7282} 7283 7284// Message returns the exception's message. 7285func (s *LimitExceededException) Message() string { 7286 if s.Message_ != nil { 7287 return *s.Message_ 7288 } 7289 return "" 7290} 7291 7292// OrigErr always returns nil, satisfies awserr.Error interface. 7293func (s *LimitExceededException) OrigErr() error { 7294 return nil 7295} 7296 7297func (s *LimitExceededException) Error() string { 7298 return fmt.Sprintf("%s: %s\n%s", s.Code(), s.Message(), s.String()) 7299} 7300 7301// Status code returns the HTTP status code for the request's response error. 7302func (s *LimitExceededException) StatusCode() int { 7303 return s.RespMetadata.StatusCode 7304} 7305 7306// RequestID returns the service's response RequestID for request. 7307func (s *LimitExceededException) RequestID() string { 7308 return s.RespMetadata.RequestID 7309} 7310 7311// Provides options for retrieving a job list for an Amazon S3 Glacier vault. 7312type ListJobsInput struct { 7313 _ struct{} `type:"structure" nopayload:"true"` 7314 7315 // The AccountId value is the AWS account ID of the account that owns the vault. 7316 // You can either specify an AWS account ID or optionally a single '-' (hyphen), 7317 // in which case Amazon S3 Glacier uses the AWS account ID associated with the 7318 // credentials used to sign the request. If you use an account ID, do not include 7319 // any hyphens ('-') in the ID. 7320 // 7321 // AccountId is a required field 7322 AccountId *string `location:"uri" locationName:"accountId" type:"string" required:"true"` 7323 7324 // The state of the jobs to return. You can specify true or false. 7325 Completed *string `location:"querystring" locationName:"completed" type:"string"` 7326 7327 // The maximum number of jobs to be returned. The default limit is 50. The number 7328 // of jobs returned might be fewer than the specified limit, but the number 7329 // of returned jobs never exceeds the limit. 7330 Limit *string `location:"querystring" locationName:"limit" type:"string"` 7331 7332 // An opaque string used for pagination. This value specifies the job at which 7333 // the listing of jobs should begin. Get the marker value from a previous List 7334 // Jobs response. You only need to include the marker if you are continuing 7335 // the pagination of results started in a previous List Jobs request. 7336 Marker *string `location:"querystring" locationName:"marker" type:"string"` 7337 7338 // The type of job status to return. You can specify the following values: InProgress, 7339 // Succeeded, or Failed. 7340 Statuscode *string `location:"querystring" locationName:"statuscode" type:"string"` 7341 7342 // The name of the vault. 7343 // 7344 // VaultName is a required field 7345 VaultName *string `location:"uri" locationName:"vaultName" type:"string" required:"true"` 7346} 7347 7348// String returns the string representation. 7349// 7350// API parameter values that are decorated as "sensitive" in the API will not 7351// be included in the string output. The member name will be present, but the 7352// value will be replaced with "sensitive". 7353func (s ListJobsInput) String() string { 7354 return awsutil.Prettify(s) 7355} 7356 7357// GoString returns the string representation. 7358// 7359// API parameter values that are decorated as "sensitive" in the API will not 7360// be included in the string output. The member name will be present, but the 7361// value will be replaced with "sensitive". 7362func (s ListJobsInput) GoString() string { 7363 return s.String() 7364} 7365 7366// Validate inspects the fields of the type to determine if they are valid. 7367func (s *ListJobsInput) Validate() error { 7368 invalidParams := request.ErrInvalidParams{Context: "ListJobsInput"} 7369 if s.AccountId == nil { 7370 invalidParams.Add(request.NewErrParamRequired("AccountId")) 7371 } 7372 if s.AccountId != nil && len(*s.AccountId) < 1 { 7373 invalidParams.Add(request.NewErrParamMinLen("AccountId", 1)) 7374 } 7375 if s.VaultName == nil { 7376 invalidParams.Add(request.NewErrParamRequired("VaultName")) 7377 } 7378 if s.VaultName != nil && len(*s.VaultName) < 1 { 7379 invalidParams.Add(request.NewErrParamMinLen("VaultName", 1)) 7380 } 7381 7382 if invalidParams.Len() > 0 { 7383 return invalidParams 7384 } 7385 return nil 7386} 7387 7388// SetAccountId sets the AccountId field's value. 7389func (s *ListJobsInput) SetAccountId(v string) *ListJobsInput { 7390 s.AccountId = &v 7391 return s 7392} 7393 7394// SetCompleted sets the Completed field's value. 7395func (s *ListJobsInput) SetCompleted(v string) *ListJobsInput { 7396 s.Completed = &v 7397 return s 7398} 7399 7400// SetLimit sets the Limit field's value. 7401func (s *ListJobsInput) SetLimit(v string) *ListJobsInput { 7402 s.Limit = &v 7403 return s 7404} 7405 7406// SetMarker sets the Marker field's value. 7407func (s *ListJobsInput) SetMarker(v string) *ListJobsInput { 7408 s.Marker = &v 7409 return s 7410} 7411 7412// SetStatuscode sets the Statuscode field's value. 7413func (s *ListJobsInput) SetStatuscode(v string) *ListJobsInput { 7414 s.Statuscode = &v 7415 return s 7416} 7417 7418// SetVaultName sets the VaultName field's value. 7419func (s *ListJobsInput) SetVaultName(v string) *ListJobsInput { 7420 s.VaultName = &v 7421 return s 7422} 7423 7424// Contains the Amazon S3 Glacier response to your request. 7425type ListJobsOutput struct { 7426 _ struct{} `type:"structure"` 7427 7428 // A list of job objects. Each job object contains metadata describing the job. 7429 JobList []*JobDescription `type:"list"` 7430 7431 // An opaque string used for pagination that specifies the job at which the 7432 // listing of jobs should begin. You get the marker value from a previous List 7433 // Jobs response. You only need to include the marker if you are continuing 7434 // the pagination of the results started in a previous List Jobs request. 7435 Marker *string `type:"string"` 7436} 7437 7438// String returns the string representation. 7439// 7440// API parameter values that are decorated as "sensitive" in the API will not 7441// be included in the string output. The member name will be present, but the 7442// value will be replaced with "sensitive". 7443func (s ListJobsOutput) String() string { 7444 return awsutil.Prettify(s) 7445} 7446 7447// GoString returns the string representation. 7448// 7449// API parameter values that are decorated as "sensitive" in the API will not 7450// be included in the string output. The member name will be present, but the 7451// value will be replaced with "sensitive". 7452func (s ListJobsOutput) GoString() string { 7453 return s.String() 7454} 7455 7456// SetJobList sets the JobList field's value. 7457func (s *ListJobsOutput) SetJobList(v []*JobDescription) *ListJobsOutput { 7458 s.JobList = v 7459 return s 7460} 7461 7462// SetMarker sets the Marker field's value. 7463func (s *ListJobsOutput) SetMarker(v string) *ListJobsOutput { 7464 s.Marker = &v 7465 return s 7466} 7467 7468// Provides options for retrieving list of in-progress multipart uploads for 7469// an Amazon Glacier vault. 7470type ListMultipartUploadsInput struct { 7471 _ struct{} `type:"structure" nopayload:"true"` 7472 7473 // The AccountId value is the AWS account ID of the account that owns the vault. 7474 // You can either specify an AWS account ID or optionally a single '-' (hyphen), 7475 // in which case Amazon S3 Glacier uses the AWS account ID associated with the 7476 // credentials used to sign the request. If you use an account ID, do not include 7477 // any hyphens ('-') in the ID. 7478 // 7479 // AccountId is a required field 7480 AccountId *string `location:"uri" locationName:"accountId" type:"string" required:"true"` 7481 7482 // Specifies the maximum number of uploads returned in the response body. If 7483 // this value is not specified, the List Uploads operation returns up to 50 7484 // uploads. 7485 Limit *string `location:"querystring" locationName:"limit" type:"string"` 7486 7487 // An opaque string used for pagination. This value specifies the upload at 7488 // which the listing of uploads should begin. Get the marker value from a previous 7489 // List Uploads response. You need only include the marker if you are continuing 7490 // the pagination of results started in a previous List Uploads request. 7491 Marker *string `location:"querystring" locationName:"marker" type:"string"` 7492 7493 // The name of the vault. 7494 // 7495 // VaultName is a required field 7496 VaultName *string `location:"uri" locationName:"vaultName" type:"string" required:"true"` 7497} 7498 7499// String returns the string representation. 7500// 7501// API parameter values that are decorated as "sensitive" in the API will not 7502// be included in the string output. The member name will be present, but the 7503// value will be replaced with "sensitive". 7504func (s ListMultipartUploadsInput) String() string { 7505 return awsutil.Prettify(s) 7506} 7507 7508// GoString returns the string representation. 7509// 7510// API parameter values that are decorated as "sensitive" in the API will not 7511// be included in the string output. The member name will be present, but the 7512// value will be replaced with "sensitive". 7513func (s ListMultipartUploadsInput) GoString() string { 7514 return s.String() 7515} 7516 7517// Validate inspects the fields of the type to determine if they are valid. 7518func (s *ListMultipartUploadsInput) Validate() error { 7519 invalidParams := request.ErrInvalidParams{Context: "ListMultipartUploadsInput"} 7520 if s.AccountId == nil { 7521 invalidParams.Add(request.NewErrParamRequired("AccountId")) 7522 } 7523 if s.AccountId != nil && len(*s.AccountId) < 1 { 7524 invalidParams.Add(request.NewErrParamMinLen("AccountId", 1)) 7525 } 7526 if s.VaultName == nil { 7527 invalidParams.Add(request.NewErrParamRequired("VaultName")) 7528 } 7529 if s.VaultName != nil && len(*s.VaultName) < 1 { 7530 invalidParams.Add(request.NewErrParamMinLen("VaultName", 1)) 7531 } 7532 7533 if invalidParams.Len() > 0 { 7534 return invalidParams 7535 } 7536 return nil 7537} 7538 7539// SetAccountId sets the AccountId field's value. 7540func (s *ListMultipartUploadsInput) SetAccountId(v string) *ListMultipartUploadsInput { 7541 s.AccountId = &v 7542 return s 7543} 7544 7545// SetLimit sets the Limit field's value. 7546func (s *ListMultipartUploadsInput) SetLimit(v string) *ListMultipartUploadsInput { 7547 s.Limit = &v 7548 return s 7549} 7550 7551// SetMarker sets the Marker field's value. 7552func (s *ListMultipartUploadsInput) SetMarker(v string) *ListMultipartUploadsInput { 7553 s.Marker = &v 7554 return s 7555} 7556 7557// SetVaultName sets the VaultName field's value. 7558func (s *ListMultipartUploadsInput) SetVaultName(v string) *ListMultipartUploadsInput { 7559 s.VaultName = &v 7560 return s 7561} 7562 7563// Contains the Amazon S3 Glacier response to your request. 7564type ListMultipartUploadsOutput struct { 7565 _ struct{} `type:"structure"` 7566 7567 // An opaque string that represents where to continue pagination of the results. 7568 // You use the marker in a new List Multipart Uploads request to obtain more 7569 // uploads in the list. If there are no more uploads, this value is null. 7570 Marker *string `type:"string"` 7571 7572 // A list of in-progress multipart uploads. 7573 UploadsList []*UploadListElement `type:"list"` 7574} 7575 7576// String returns the string representation. 7577// 7578// API parameter values that are decorated as "sensitive" in the API will not 7579// be included in the string output. The member name will be present, but the 7580// value will be replaced with "sensitive". 7581func (s ListMultipartUploadsOutput) String() string { 7582 return awsutil.Prettify(s) 7583} 7584 7585// GoString returns the string representation. 7586// 7587// API parameter values that are decorated as "sensitive" in the API will not 7588// be included in the string output. The member name will be present, but the 7589// value will be replaced with "sensitive". 7590func (s ListMultipartUploadsOutput) GoString() string { 7591 return s.String() 7592} 7593 7594// SetMarker sets the Marker field's value. 7595func (s *ListMultipartUploadsOutput) SetMarker(v string) *ListMultipartUploadsOutput { 7596 s.Marker = &v 7597 return s 7598} 7599 7600// SetUploadsList sets the UploadsList field's value. 7601func (s *ListMultipartUploadsOutput) SetUploadsList(v []*UploadListElement) *ListMultipartUploadsOutput { 7602 s.UploadsList = v 7603 return s 7604} 7605 7606// Provides options for retrieving a list of parts of an archive that have been 7607// uploaded in a specific multipart upload. 7608type ListPartsInput struct { 7609 _ struct{} `type:"structure" nopayload:"true"` 7610 7611 // The AccountId value is the AWS account ID of the account that owns the vault. 7612 // You can either specify an AWS account ID or optionally a single '-' (hyphen), 7613 // in which case Amazon S3 Glacier uses the AWS account ID associated with the 7614 // credentials used to sign the request. If you use an account ID, do not include 7615 // any hyphens ('-') in the ID. 7616 // 7617 // AccountId is a required field 7618 AccountId *string `location:"uri" locationName:"accountId" type:"string" required:"true"` 7619 7620 // The maximum number of parts to be returned. The default limit is 50. The 7621 // number of parts returned might be fewer than the specified limit, but the 7622 // number of returned parts never exceeds the limit. 7623 Limit *string `location:"querystring" locationName:"limit" type:"string"` 7624 7625 // An opaque string used for pagination. This value specifies the part at which 7626 // the listing of parts should begin. Get the marker value from the response 7627 // of a previous List Parts response. You need only include the marker if you 7628 // are continuing the pagination of results started in a previous List Parts 7629 // request. 7630 Marker *string `location:"querystring" locationName:"marker" type:"string"` 7631 7632 // The upload ID of the multipart upload. 7633 // 7634 // UploadId is a required field 7635 UploadId *string `location:"uri" locationName:"uploadId" type:"string" required:"true"` 7636 7637 // The name of the vault. 7638 // 7639 // VaultName is a required field 7640 VaultName *string `location:"uri" locationName:"vaultName" type:"string" required:"true"` 7641} 7642 7643// String returns the string representation. 7644// 7645// API parameter values that are decorated as "sensitive" in the API will not 7646// be included in the string output. The member name will be present, but the 7647// value will be replaced with "sensitive". 7648func (s ListPartsInput) String() string { 7649 return awsutil.Prettify(s) 7650} 7651 7652// GoString returns the string representation. 7653// 7654// API parameter values that are decorated as "sensitive" in the API will not 7655// be included in the string output. The member name will be present, but the 7656// value will be replaced with "sensitive". 7657func (s ListPartsInput) GoString() string { 7658 return s.String() 7659} 7660 7661// Validate inspects the fields of the type to determine if they are valid. 7662func (s *ListPartsInput) Validate() error { 7663 invalidParams := request.ErrInvalidParams{Context: "ListPartsInput"} 7664 if s.AccountId == nil { 7665 invalidParams.Add(request.NewErrParamRequired("AccountId")) 7666 } 7667 if s.AccountId != nil && len(*s.AccountId) < 1 { 7668 invalidParams.Add(request.NewErrParamMinLen("AccountId", 1)) 7669 } 7670 if s.UploadId == nil { 7671 invalidParams.Add(request.NewErrParamRequired("UploadId")) 7672 } 7673 if s.UploadId != nil && len(*s.UploadId) < 1 { 7674 invalidParams.Add(request.NewErrParamMinLen("UploadId", 1)) 7675 } 7676 if s.VaultName == nil { 7677 invalidParams.Add(request.NewErrParamRequired("VaultName")) 7678 } 7679 if s.VaultName != nil && len(*s.VaultName) < 1 { 7680 invalidParams.Add(request.NewErrParamMinLen("VaultName", 1)) 7681 } 7682 7683 if invalidParams.Len() > 0 { 7684 return invalidParams 7685 } 7686 return nil 7687} 7688 7689// SetAccountId sets the AccountId field's value. 7690func (s *ListPartsInput) SetAccountId(v string) *ListPartsInput { 7691 s.AccountId = &v 7692 return s 7693} 7694 7695// SetLimit sets the Limit field's value. 7696func (s *ListPartsInput) SetLimit(v string) *ListPartsInput { 7697 s.Limit = &v 7698 return s 7699} 7700 7701// SetMarker sets the Marker field's value. 7702func (s *ListPartsInput) SetMarker(v string) *ListPartsInput { 7703 s.Marker = &v 7704 return s 7705} 7706 7707// SetUploadId sets the UploadId field's value. 7708func (s *ListPartsInput) SetUploadId(v string) *ListPartsInput { 7709 s.UploadId = &v 7710 return s 7711} 7712 7713// SetVaultName sets the VaultName field's value. 7714func (s *ListPartsInput) SetVaultName(v string) *ListPartsInput { 7715 s.VaultName = &v 7716 return s 7717} 7718 7719// Contains the Amazon S3 Glacier response to your request. 7720type ListPartsOutput struct { 7721 _ struct{} `type:"structure"` 7722 7723 // The description of the archive that was specified in the Initiate Multipart 7724 // Upload request. 7725 ArchiveDescription *string `type:"string"` 7726 7727 // The UTC time at which the multipart upload was initiated. 7728 CreationDate *string `type:"string"` 7729 7730 // An opaque string that represents where to continue pagination of the results. 7731 // You use the marker in a new List Parts request to obtain more jobs in the 7732 // list. If there are no more parts, this value is null. 7733 Marker *string `type:"string"` 7734 7735 // The ID of the upload to which the parts are associated. 7736 MultipartUploadId *string `type:"string"` 7737 7738 // The part size in bytes. This is the same value that you specified in the 7739 // Initiate Multipart Upload request. 7740 PartSizeInBytes *int64 `type:"long"` 7741 7742 // A list of the part sizes of the multipart upload. Each object in the array 7743 // contains a RangeBytes and sha256-tree-hash name/value pair. 7744 Parts []*PartListElement `type:"list"` 7745 7746 // The Amazon Resource Name (ARN) of the vault to which the multipart upload 7747 // was initiated. 7748 VaultARN *string `type:"string"` 7749} 7750 7751// String returns the string representation. 7752// 7753// API parameter values that are decorated as "sensitive" in the API will not 7754// be included in the string output. The member name will be present, but the 7755// value will be replaced with "sensitive". 7756func (s ListPartsOutput) String() string { 7757 return awsutil.Prettify(s) 7758} 7759 7760// GoString returns the string representation. 7761// 7762// API parameter values that are decorated as "sensitive" in the API will not 7763// be included in the string output. The member name will be present, but the 7764// value will be replaced with "sensitive". 7765func (s ListPartsOutput) GoString() string { 7766 return s.String() 7767} 7768 7769// SetArchiveDescription sets the ArchiveDescription field's value. 7770func (s *ListPartsOutput) SetArchiveDescription(v string) *ListPartsOutput { 7771 s.ArchiveDescription = &v 7772 return s 7773} 7774 7775// SetCreationDate sets the CreationDate field's value. 7776func (s *ListPartsOutput) SetCreationDate(v string) *ListPartsOutput { 7777 s.CreationDate = &v 7778 return s 7779} 7780 7781// SetMarker sets the Marker field's value. 7782func (s *ListPartsOutput) SetMarker(v string) *ListPartsOutput { 7783 s.Marker = &v 7784 return s 7785} 7786 7787// SetMultipartUploadId sets the MultipartUploadId field's value. 7788func (s *ListPartsOutput) SetMultipartUploadId(v string) *ListPartsOutput { 7789 s.MultipartUploadId = &v 7790 return s 7791} 7792 7793// SetPartSizeInBytes sets the PartSizeInBytes field's value. 7794func (s *ListPartsOutput) SetPartSizeInBytes(v int64) *ListPartsOutput { 7795 s.PartSizeInBytes = &v 7796 return s 7797} 7798 7799// SetParts sets the Parts field's value. 7800func (s *ListPartsOutput) SetParts(v []*PartListElement) *ListPartsOutput { 7801 s.Parts = v 7802 return s 7803} 7804 7805// SetVaultARN sets the VaultARN field's value. 7806func (s *ListPartsOutput) SetVaultARN(v string) *ListPartsOutput { 7807 s.VaultARN = &v 7808 return s 7809} 7810 7811type ListProvisionedCapacityInput struct { 7812 _ struct{} `type:"structure" nopayload:"true"` 7813 7814 // The AWS account ID of the account that owns the vault. You can either specify 7815 // an AWS account ID or optionally a single '-' (hyphen), in which case Amazon 7816 // S3 Glacier uses the AWS account ID associated with the credentials used to 7817 // sign the request. If you use an account ID, don't include any hyphens ('-') 7818 // in the ID. 7819 // 7820 // AccountId is a required field 7821 AccountId *string `location:"uri" locationName:"accountId" type:"string" required:"true"` 7822} 7823 7824// String returns the string representation. 7825// 7826// API parameter values that are decorated as "sensitive" in the API will not 7827// be included in the string output. The member name will be present, but the 7828// value will be replaced with "sensitive". 7829func (s ListProvisionedCapacityInput) String() string { 7830 return awsutil.Prettify(s) 7831} 7832 7833// GoString returns the string representation. 7834// 7835// API parameter values that are decorated as "sensitive" in the API will not 7836// be included in the string output. The member name will be present, but the 7837// value will be replaced with "sensitive". 7838func (s ListProvisionedCapacityInput) GoString() string { 7839 return s.String() 7840} 7841 7842// Validate inspects the fields of the type to determine if they are valid. 7843func (s *ListProvisionedCapacityInput) Validate() error { 7844 invalidParams := request.ErrInvalidParams{Context: "ListProvisionedCapacityInput"} 7845 if s.AccountId == nil { 7846 invalidParams.Add(request.NewErrParamRequired("AccountId")) 7847 } 7848 if s.AccountId != nil && len(*s.AccountId) < 1 { 7849 invalidParams.Add(request.NewErrParamMinLen("AccountId", 1)) 7850 } 7851 7852 if invalidParams.Len() > 0 { 7853 return invalidParams 7854 } 7855 return nil 7856} 7857 7858// SetAccountId sets the AccountId field's value. 7859func (s *ListProvisionedCapacityInput) SetAccountId(v string) *ListProvisionedCapacityInput { 7860 s.AccountId = &v 7861 return s 7862} 7863 7864type ListProvisionedCapacityOutput struct { 7865 _ struct{} `type:"structure"` 7866 7867 // The response body contains the following JSON fields. 7868 ProvisionedCapacityList []*ProvisionedCapacityDescription `type:"list"` 7869} 7870 7871// String returns the string representation. 7872// 7873// API parameter values that are decorated as "sensitive" in the API will not 7874// be included in the string output. The member name will be present, but the 7875// value will be replaced with "sensitive". 7876func (s ListProvisionedCapacityOutput) String() string { 7877 return awsutil.Prettify(s) 7878} 7879 7880// GoString returns the string representation. 7881// 7882// API parameter values that are decorated as "sensitive" in the API will not 7883// be included in the string output. The member name will be present, but the 7884// value will be replaced with "sensitive". 7885func (s ListProvisionedCapacityOutput) GoString() string { 7886 return s.String() 7887} 7888 7889// SetProvisionedCapacityList sets the ProvisionedCapacityList field's value. 7890func (s *ListProvisionedCapacityOutput) SetProvisionedCapacityList(v []*ProvisionedCapacityDescription) *ListProvisionedCapacityOutput { 7891 s.ProvisionedCapacityList = v 7892 return s 7893} 7894 7895// The input value for ListTagsForVaultInput. 7896type ListTagsForVaultInput struct { 7897 _ struct{} `type:"structure" nopayload:"true"` 7898 7899 // The AccountId value is the AWS account ID of the account that owns the vault. 7900 // You can either specify an AWS account ID or optionally a single '-' (hyphen), 7901 // in which case Amazon S3 Glacier uses the AWS account ID associated with the 7902 // credentials used to sign the request. If you use an account ID, do not include 7903 // any hyphens ('-') in the ID. 7904 // 7905 // AccountId is a required field 7906 AccountId *string `location:"uri" locationName:"accountId" type:"string" required:"true"` 7907 7908 // The name of the vault. 7909 // 7910 // VaultName is a required field 7911 VaultName *string `location:"uri" locationName:"vaultName" type:"string" required:"true"` 7912} 7913 7914// String returns the string representation. 7915// 7916// API parameter values that are decorated as "sensitive" in the API will not 7917// be included in the string output. The member name will be present, but the 7918// value will be replaced with "sensitive". 7919func (s ListTagsForVaultInput) String() string { 7920 return awsutil.Prettify(s) 7921} 7922 7923// GoString returns the string representation. 7924// 7925// API parameter values that are decorated as "sensitive" in the API will not 7926// be included in the string output. The member name will be present, but the 7927// value will be replaced with "sensitive". 7928func (s ListTagsForVaultInput) GoString() string { 7929 return s.String() 7930} 7931 7932// Validate inspects the fields of the type to determine if they are valid. 7933func (s *ListTagsForVaultInput) Validate() error { 7934 invalidParams := request.ErrInvalidParams{Context: "ListTagsForVaultInput"} 7935 if s.AccountId == nil { 7936 invalidParams.Add(request.NewErrParamRequired("AccountId")) 7937 } 7938 if s.AccountId != nil && len(*s.AccountId) < 1 { 7939 invalidParams.Add(request.NewErrParamMinLen("AccountId", 1)) 7940 } 7941 if s.VaultName == nil { 7942 invalidParams.Add(request.NewErrParamRequired("VaultName")) 7943 } 7944 if s.VaultName != nil && len(*s.VaultName) < 1 { 7945 invalidParams.Add(request.NewErrParamMinLen("VaultName", 1)) 7946 } 7947 7948 if invalidParams.Len() > 0 { 7949 return invalidParams 7950 } 7951 return nil 7952} 7953 7954// SetAccountId sets the AccountId field's value. 7955func (s *ListTagsForVaultInput) SetAccountId(v string) *ListTagsForVaultInput { 7956 s.AccountId = &v 7957 return s 7958} 7959 7960// SetVaultName sets the VaultName field's value. 7961func (s *ListTagsForVaultInput) SetVaultName(v string) *ListTagsForVaultInput { 7962 s.VaultName = &v 7963 return s 7964} 7965 7966// Contains the Amazon S3 Glacier response to your request. 7967type ListTagsForVaultOutput struct { 7968 _ struct{} `type:"structure"` 7969 7970 // The tags attached to the vault. Each tag is composed of a key and a value. 7971 Tags map[string]*string `type:"map"` 7972} 7973 7974// String returns the string representation. 7975// 7976// API parameter values that are decorated as "sensitive" in the API will not 7977// be included in the string output. The member name will be present, but the 7978// value will be replaced with "sensitive". 7979func (s ListTagsForVaultOutput) String() string { 7980 return awsutil.Prettify(s) 7981} 7982 7983// GoString returns the string representation. 7984// 7985// API parameter values that are decorated as "sensitive" in the API will not 7986// be included in the string output. The member name will be present, but the 7987// value will be replaced with "sensitive". 7988func (s ListTagsForVaultOutput) GoString() string { 7989 return s.String() 7990} 7991 7992// SetTags sets the Tags field's value. 7993func (s *ListTagsForVaultOutput) SetTags(v map[string]*string) *ListTagsForVaultOutput { 7994 s.Tags = v 7995 return s 7996} 7997 7998// Provides options to retrieve the vault list owned by the calling user's account. 7999// The list provides metadata information for each vault. 8000type ListVaultsInput struct { 8001 _ struct{} `type:"structure" nopayload:"true"` 8002 8003 // The AccountId value is the AWS account ID. This value must match the AWS 8004 // account ID associated with the credentials used to sign the request. You 8005 // can either specify an AWS account ID or optionally a single '-' (hyphen), 8006 // in which case Amazon Glacier uses the AWS account ID associated with the 8007 // credentials used to sign the request. If you specify your account ID, do 8008 // not include any hyphens ('-') in the ID. 8009 // 8010 // AccountId is a required field 8011 AccountId *string `location:"uri" locationName:"accountId" type:"string" required:"true"` 8012 8013 // The maximum number of vaults to be returned. The default limit is 10. The 8014 // number of vaults returned might be fewer than the specified limit, but the 8015 // number of returned vaults never exceeds the limit. 8016 Limit *string `location:"querystring" locationName:"limit" type:"string"` 8017 8018 // A string used for pagination. The marker specifies the vault ARN after which 8019 // the listing of vaults should begin. 8020 Marker *string `location:"querystring" locationName:"marker" type:"string"` 8021} 8022 8023// String returns the string representation. 8024// 8025// API parameter values that are decorated as "sensitive" in the API will not 8026// be included in the string output. The member name will be present, but the 8027// value will be replaced with "sensitive". 8028func (s ListVaultsInput) String() string { 8029 return awsutil.Prettify(s) 8030} 8031 8032// GoString returns the string representation. 8033// 8034// API parameter values that are decorated as "sensitive" in the API will not 8035// be included in the string output. The member name will be present, but the 8036// value will be replaced with "sensitive". 8037func (s ListVaultsInput) GoString() string { 8038 return s.String() 8039} 8040 8041// Validate inspects the fields of the type to determine if they are valid. 8042func (s *ListVaultsInput) Validate() error { 8043 invalidParams := request.ErrInvalidParams{Context: "ListVaultsInput"} 8044 if s.AccountId == nil { 8045 invalidParams.Add(request.NewErrParamRequired("AccountId")) 8046 } 8047 if s.AccountId != nil && len(*s.AccountId) < 1 { 8048 invalidParams.Add(request.NewErrParamMinLen("AccountId", 1)) 8049 } 8050 8051 if invalidParams.Len() > 0 { 8052 return invalidParams 8053 } 8054 return nil 8055} 8056 8057// SetAccountId sets the AccountId field's value. 8058func (s *ListVaultsInput) SetAccountId(v string) *ListVaultsInput { 8059 s.AccountId = &v 8060 return s 8061} 8062 8063// SetLimit sets the Limit field's value. 8064func (s *ListVaultsInput) SetLimit(v string) *ListVaultsInput { 8065 s.Limit = &v 8066 return s 8067} 8068 8069// SetMarker sets the Marker field's value. 8070func (s *ListVaultsInput) SetMarker(v string) *ListVaultsInput { 8071 s.Marker = &v 8072 return s 8073} 8074 8075// Contains the Amazon S3 Glacier response to your request. 8076type ListVaultsOutput struct { 8077 _ struct{} `type:"structure"` 8078 8079 // The vault ARN at which to continue pagination of the results. You use the 8080 // marker in another List Vaults request to obtain more vaults in the list. 8081 Marker *string `type:"string"` 8082 8083 // List of vaults. 8084 VaultList []*DescribeVaultOutput `type:"list"` 8085} 8086 8087// String returns the string representation. 8088// 8089// API parameter values that are decorated as "sensitive" in the API will not 8090// be included in the string output. The member name will be present, but the 8091// value will be replaced with "sensitive". 8092func (s ListVaultsOutput) String() string { 8093 return awsutil.Prettify(s) 8094} 8095 8096// GoString returns the string representation. 8097// 8098// API parameter values that are decorated as "sensitive" in the API will not 8099// be included in the string output. The member name will be present, but the 8100// value will be replaced with "sensitive". 8101func (s ListVaultsOutput) GoString() string { 8102 return s.String() 8103} 8104 8105// SetMarker sets the Marker field's value. 8106func (s *ListVaultsOutput) SetMarker(v string) *ListVaultsOutput { 8107 s.Marker = &v 8108 return s 8109} 8110 8111// SetVaultList sets the VaultList field's value. 8112func (s *ListVaultsOutput) SetVaultList(v []*DescribeVaultOutput) *ListVaultsOutput { 8113 s.VaultList = v 8114 return s 8115} 8116 8117// Returned if a required header or parameter is missing from the request. 8118type MissingParameterValueException struct { 8119 _ struct{} `type:"structure"` 8120 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 8121 8122 // 400 Bad Request 8123 Code_ *string `locationName:"code" type:"string"` 8124 8125 // Returned if no authentication data is found for the request. 8126 Message_ *string `locationName:"message" type:"string"` 8127 8128 // Client. 8129 Type *string `locationName:"type" type:"string"` 8130} 8131 8132// String returns the string representation. 8133// 8134// API parameter values that are decorated as "sensitive" in the API will not 8135// be included in the string output. The member name will be present, but the 8136// value will be replaced with "sensitive". 8137func (s MissingParameterValueException) String() string { 8138 return awsutil.Prettify(s) 8139} 8140 8141// GoString returns the string representation. 8142// 8143// API parameter values that are decorated as "sensitive" in the API will not 8144// be included in the string output. The member name will be present, but the 8145// value will be replaced with "sensitive". 8146func (s MissingParameterValueException) GoString() string { 8147 return s.String() 8148} 8149 8150func newErrorMissingParameterValueException(v protocol.ResponseMetadata) error { 8151 return &MissingParameterValueException{ 8152 RespMetadata: v, 8153 } 8154} 8155 8156// Code returns the exception type name. 8157func (s *MissingParameterValueException) Code() string { 8158 return "MissingParameterValueException" 8159} 8160 8161// Message returns the exception's message. 8162func (s *MissingParameterValueException) Message() string { 8163 if s.Message_ != nil { 8164 return *s.Message_ 8165 } 8166 return "" 8167} 8168 8169// OrigErr always returns nil, satisfies awserr.Error interface. 8170func (s *MissingParameterValueException) OrigErr() error { 8171 return nil 8172} 8173 8174func (s *MissingParameterValueException) Error() string { 8175 return fmt.Sprintf("%s: %s\n%s", s.Code(), s.Message(), s.String()) 8176} 8177 8178// Status code returns the HTTP status code for the request's response error. 8179func (s *MissingParameterValueException) StatusCode() int { 8180 return s.RespMetadata.StatusCode 8181} 8182 8183// RequestID returns the service's response RequestID for request. 8184func (s *MissingParameterValueException) RequestID() string { 8185 return s.RespMetadata.RequestID 8186} 8187 8188// Contains information about the location where the select job results are 8189// stored. 8190type OutputLocation struct { 8191 _ struct{} `type:"structure"` 8192 8193 // Describes an S3 location that will receive the results of the job request. 8194 S3 *S3Location `type:"structure"` 8195} 8196 8197// String returns the string representation. 8198// 8199// API parameter values that are decorated as "sensitive" in the API will not 8200// be included in the string output. The member name will be present, but the 8201// value will be replaced with "sensitive". 8202func (s OutputLocation) String() string { 8203 return awsutil.Prettify(s) 8204} 8205 8206// GoString returns the string representation. 8207// 8208// API parameter values that are decorated as "sensitive" in the API will not 8209// be included in the string output. The member name will be present, but the 8210// value will be replaced with "sensitive". 8211func (s OutputLocation) GoString() string { 8212 return s.String() 8213} 8214 8215// Validate inspects the fields of the type to determine if they are valid. 8216func (s *OutputLocation) Validate() error { 8217 invalidParams := request.ErrInvalidParams{Context: "OutputLocation"} 8218 if s.S3 != nil { 8219 if err := s.S3.Validate(); err != nil { 8220 invalidParams.AddNested("S3", err.(request.ErrInvalidParams)) 8221 } 8222 } 8223 8224 if invalidParams.Len() > 0 { 8225 return invalidParams 8226 } 8227 return nil 8228} 8229 8230// SetS3 sets the S3 field's value. 8231func (s *OutputLocation) SetS3(v *S3Location) *OutputLocation { 8232 s.S3 = v 8233 return s 8234} 8235 8236// Describes how the select output is serialized. 8237type OutputSerialization struct { 8238 _ struct{} `type:"structure"` 8239 8240 // Describes the serialization of CSV-encoded query results. 8241 Csv *CSVOutput `locationName:"csv" type:"structure"` 8242} 8243 8244// String returns the string representation. 8245// 8246// API parameter values that are decorated as "sensitive" in the API will not 8247// be included in the string output. The member name will be present, but the 8248// value will be replaced with "sensitive". 8249func (s OutputSerialization) String() string { 8250 return awsutil.Prettify(s) 8251} 8252 8253// GoString returns the string representation. 8254// 8255// API parameter values that are decorated as "sensitive" in the API will not 8256// be included in the string output. The member name will be present, but the 8257// value will be replaced with "sensitive". 8258func (s OutputSerialization) GoString() string { 8259 return s.String() 8260} 8261 8262// SetCsv sets the Csv field's value. 8263func (s *OutputSerialization) SetCsv(v *CSVOutput) *OutputSerialization { 8264 s.Csv = v 8265 return s 8266} 8267 8268// A list of the part sizes of the multipart upload. 8269type PartListElement struct { 8270 _ struct{} `type:"structure"` 8271 8272 // The byte range of a part, inclusive of the upper value of the range. 8273 RangeInBytes *string `type:"string"` 8274 8275 // The SHA256 tree hash value that Amazon S3 Glacier calculated for the part. 8276 // This field is never null. 8277 SHA256TreeHash *string `type:"string"` 8278} 8279 8280// String returns the string representation. 8281// 8282// API parameter values that are decorated as "sensitive" in the API will not 8283// be included in the string output. The member name will be present, but the 8284// value will be replaced with "sensitive". 8285func (s PartListElement) String() string { 8286 return awsutil.Prettify(s) 8287} 8288 8289// GoString returns the string representation. 8290// 8291// API parameter values that are decorated as "sensitive" in the API will not 8292// be included in the string output. The member name will be present, but the 8293// value will be replaced with "sensitive". 8294func (s PartListElement) GoString() string { 8295 return s.String() 8296} 8297 8298// SetRangeInBytes sets the RangeInBytes field's value. 8299func (s *PartListElement) SetRangeInBytes(v string) *PartListElement { 8300 s.RangeInBytes = &v 8301 return s 8302} 8303 8304// SetSHA256TreeHash sets the SHA256TreeHash field's value. 8305func (s *PartListElement) SetSHA256TreeHash(v string) *PartListElement { 8306 s.SHA256TreeHash = &v 8307 return s 8308} 8309 8310// Returned if a retrieval job would exceed the current data policy's retrieval 8311// rate limit. For more information about data retrieval policies, 8312type PolicyEnforcedException struct { 8313 _ struct{} `type:"structure"` 8314 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 8315 8316 // PolicyEnforcedException 8317 Code_ *string `locationName:"code" type:"string"` 8318 8319 // InitiateJob request denied by current data retrieval policy. 8320 Message_ *string `locationName:"message" type:"string"` 8321 8322 // Client 8323 Type *string `locationName:"type" type:"string"` 8324} 8325 8326// String returns the string representation. 8327// 8328// API parameter values that are decorated as "sensitive" in the API will not 8329// be included in the string output. The member name will be present, but the 8330// value will be replaced with "sensitive". 8331func (s PolicyEnforcedException) String() string { 8332 return awsutil.Prettify(s) 8333} 8334 8335// GoString returns the string representation. 8336// 8337// API parameter values that are decorated as "sensitive" in the API will not 8338// be included in the string output. The member name will be present, but the 8339// value will be replaced with "sensitive". 8340func (s PolicyEnforcedException) GoString() string { 8341 return s.String() 8342} 8343 8344func newErrorPolicyEnforcedException(v protocol.ResponseMetadata) error { 8345 return &PolicyEnforcedException{ 8346 RespMetadata: v, 8347 } 8348} 8349 8350// Code returns the exception type name. 8351func (s *PolicyEnforcedException) Code() string { 8352 return "PolicyEnforcedException" 8353} 8354 8355// Message returns the exception's message. 8356func (s *PolicyEnforcedException) Message() string { 8357 if s.Message_ != nil { 8358 return *s.Message_ 8359 } 8360 return "" 8361} 8362 8363// OrigErr always returns nil, satisfies awserr.Error interface. 8364func (s *PolicyEnforcedException) OrigErr() error { 8365 return nil 8366} 8367 8368func (s *PolicyEnforcedException) Error() string { 8369 return fmt.Sprintf("%s: %s\n%s", s.Code(), s.Message(), s.String()) 8370} 8371 8372// Status code returns the HTTP status code for the request's response error. 8373func (s *PolicyEnforcedException) StatusCode() int { 8374 return s.RespMetadata.StatusCode 8375} 8376 8377// RequestID returns the service's response RequestID for request. 8378func (s *PolicyEnforcedException) RequestID() string { 8379 return s.RespMetadata.RequestID 8380} 8381 8382// The definition for a provisioned capacity unit. 8383type ProvisionedCapacityDescription struct { 8384 _ struct{} `type:"structure"` 8385 8386 // The ID that identifies the provisioned capacity unit. 8387 CapacityId *string `type:"string"` 8388 8389 // The date that the provisioned capacity unit expires, in Universal Coordinated 8390 // Time (UTC). 8391 ExpirationDate *string `type:"string"` 8392 8393 // The date that the provisioned capacity unit was purchased, in Universal Coordinated 8394 // Time (UTC). 8395 StartDate *string `type:"string"` 8396} 8397 8398// String returns the string representation. 8399// 8400// API parameter values that are decorated as "sensitive" in the API will not 8401// be included in the string output. The member name will be present, but the 8402// value will be replaced with "sensitive". 8403func (s ProvisionedCapacityDescription) String() string { 8404 return awsutil.Prettify(s) 8405} 8406 8407// GoString returns the string representation. 8408// 8409// API parameter values that are decorated as "sensitive" in the API will not 8410// be included in the string output. The member name will be present, but the 8411// value will be replaced with "sensitive". 8412func (s ProvisionedCapacityDescription) GoString() string { 8413 return s.String() 8414} 8415 8416// SetCapacityId sets the CapacityId field's value. 8417func (s *ProvisionedCapacityDescription) SetCapacityId(v string) *ProvisionedCapacityDescription { 8418 s.CapacityId = &v 8419 return s 8420} 8421 8422// SetExpirationDate sets the ExpirationDate field's value. 8423func (s *ProvisionedCapacityDescription) SetExpirationDate(v string) *ProvisionedCapacityDescription { 8424 s.ExpirationDate = &v 8425 return s 8426} 8427 8428// SetStartDate sets the StartDate field's value. 8429func (s *ProvisionedCapacityDescription) SetStartDate(v string) *ProvisionedCapacityDescription { 8430 s.StartDate = &v 8431 return s 8432} 8433 8434type PurchaseProvisionedCapacityInput struct { 8435 _ struct{} `type:"structure" nopayload:"true"` 8436 8437 // The AWS account ID of the account that owns the vault. You can either specify 8438 // an AWS account ID or optionally a single '-' (hyphen), in which case Amazon 8439 // S3 Glacier uses the AWS account ID associated with the credentials used to 8440 // sign the request. If you use an account ID, don't include any hyphens ('-') 8441 // in the ID. 8442 // 8443 // AccountId is a required field 8444 AccountId *string `location:"uri" locationName:"accountId" type:"string" required:"true"` 8445} 8446 8447// String returns the string representation. 8448// 8449// API parameter values that are decorated as "sensitive" in the API will not 8450// be included in the string output. The member name will be present, but the 8451// value will be replaced with "sensitive". 8452func (s PurchaseProvisionedCapacityInput) String() string { 8453 return awsutil.Prettify(s) 8454} 8455 8456// GoString returns the string representation. 8457// 8458// API parameter values that are decorated as "sensitive" in the API will not 8459// be included in the string output. The member name will be present, but the 8460// value will be replaced with "sensitive". 8461func (s PurchaseProvisionedCapacityInput) GoString() string { 8462 return s.String() 8463} 8464 8465// Validate inspects the fields of the type to determine if they are valid. 8466func (s *PurchaseProvisionedCapacityInput) Validate() error { 8467 invalidParams := request.ErrInvalidParams{Context: "PurchaseProvisionedCapacityInput"} 8468 if s.AccountId == nil { 8469 invalidParams.Add(request.NewErrParamRequired("AccountId")) 8470 } 8471 if s.AccountId != nil && len(*s.AccountId) < 1 { 8472 invalidParams.Add(request.NewErrParamMinLen("AccountId", 1)) 8473 } 8474 8475 if invalidParams.Len() > 0 { 8476 return invalidParams 8477 } 8478 return nil 8479} 8480 8481// SetAccountId sets the AccountId field's value. 8482func (s *PurchaseProvisionedCapacityInput) SetAccountId(v string) *PurchaseProvisionedCapacityInput { 8483 s.AccountId = &v 8484 return s 8485} 8486 8487type PurchaseProvisionedCapacityOutput struct { 8488 _ struct{} `type:"structure"` 8489 8490 // The ID that identifies the provisioned capacity unit. 8491 CapacityId *string `location:"header" locationName:"x-amz-capacity-id" type:"string"` 8492} 8493 8494// String returns the string representation. 8495// 8496// API parameter values that are decorated as "sensitive" in the API will not 8497// be included in the string output. The member name will be present, but the 8498// value will be replaced with "sensitive". 8499func (s PurchaseProvisionedCapacityOutput) String() string { 8500 return awsutil.Prettify(s) 8501} 8502 8503// GoString returns the string representation. 8504// 8505// API parameter values that are decorated as "sensitive" in the API will not 8506// be included in the string output. The member name will be present, but the 8507// value will be replaced with "sensitive". 8508func (s PurchaseProvisionedCapacityOutput) GoString() string { 8509 return s.String() 8510} 8511 8512// SetCapacityId sets the CapacityId field's value. 8513func (s *PurchaseProvisionedCapacityOutput) SetCapacityId(v string) *PurchaseProvisionedCapacityOutput { 8514 s.CapacityId = &v 8515 return s 8516} 8517 8518// The input value for RemoveTagsFromVaultInput. 8519type RemoveTagsFromVaultInput struct { 8520 _ struct{} `type:"structure"` 8521 8522 // The AccountId value is the AWS account ID of the account that owns the vault. 8523 // You can either specify an AWS account ID or optionally a single '-' (hyphen), 8524 // in which case Amazon S3 Glacier uses the AWS account ID associated with the 8525 // credentials used to sign the request. If you use an account ID, do not include 8526 // any hyphens ('-') in the ID. 8527 // 8528 // AccountId is a required field 8529 AccountId *string `location:"uri" locationName:"accountId" type:"string" required:"true"` 8530 8531 // A list of tag keys. Each corresponding tag is removed from the vault. 8532 TagKeys []*string `type:"list"` 8533 8534 // The name of the vault. 8535 // 8536 // VaultName is a required field 8537 VaultName *string `location:"uri" locationName:"vaultName" type:"string" required:"true"` 8538} 8539 8540// String returns the string representation. 8541// 8542// API parameter values that are decorated as "sensitive" in the API will not 8543// be included in the string output. The member name will be present, but the 8544// value will be replaced with "sensitive". 8545func (s RemoveTagsFromVaultInput) String() string { 8546 return awsutil.Prettify(s) 8547} 8548 8549// GoString returns the string representation. 8550// 8551// API parameter values that are decorated as "sensitive" in the API will not 8552// be included in the string output. The member name will be present, but the 8553// value will be replaced with "sensitive". 8554func (s RemoveTagsFromVaultInput) GoString() string { 8555 return s.String() 8556} 8557 8558// Validate inspects the fields of the type to determine if they are valid. 8559func (s *RemoveTagsFromVaultInput) Validate() error { 8560 invalidParams := request.ErrInvalidParams{Context: "RemoveTagsFromVaultInput"} 8561 if s.AccountId == nil { 8562 invalidParams.Add(request.NewErrParamRequired("AccountId")) 8563 } 8564 if s.AccountId != nil && len(*s.AccountId) < 1 { 8565 invalidParams.Add(request.NewErrParamMinLen("AccountId", 1)) 8566 } 8567 if s.VaultName == nil { 8568 invalidParams.Add(request.NewErrParamRequired("VaultName")) 8569 } 8570 if s.VaultName != nil && len(*s.VaultName) < 1 { 8571 invalidParams.Add(request.NewErrParamMinLen("VaultName", 1)) 8572 } 8573 8574 if invalidParams.Len() > 0 { 8575 return invalidParams 8576 } 8577 return nil 8578} 8579 8580// SetAccountId sets the AccountId field's value. 8581func (s *RemoveTagsFromVaultInput) SetAccountId(v string) *RemoveTagsFromVaultInput { 8582 s.AccountId = &v 8583 return s 8584} 8585 8586// SetTagKeys sets the TagKeys field's value. 8587func (s *RemoveTagsFromVaultInput) SetTagKeys(v []*string) *RemoveTagsFromVaultInput { 8588 s.TagKeys = v 8589 return s 8590} 8591 8592// SetVaultName sets the VaultName field's value. 8593func (s *RemoveTagsFromVaultInput) SetVaultName(v string) *RemoveTagsFromVaultInput { 8594 s.VaultName = &v 8595 return s 8596} 8597 8598type RemoveTagsFromVaultOutput struct { 8599 _ struct{} `type:"structure"` 8600} 8601 8602// String returns the string representation. 8603// 8604// API parameter values that are decorated as "sensitive" in the API will not 8605// be included in the string output. The member name will be present, but the 8606// value will be replaced with "sensitive". 8607func (s RemoveTagsFromVaultOutput) String() string { 8608 return awsutil.Prettify(s) 8609} 8610 8611// GoString returns the string representation. 8612// 8613// API parameter values that are decorated as "sensitive" in the API will not 8614// be included in the string output. The member name will be present, but the 8615// value will be replaced with "sensitive". 8616func (s RemoveTagsFromVaultOutput) GoString() string { 8617 return s.String() 8618} 8619 8620// Returned if, when uploading an archive, Amazon S3 Glacier times out while 8621// receiving the upload. 8622type RequestTimeoutException struct { 8623 _ struct{} `type:"structure"` 8624 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 8625 8626 // 408 Request Timeout 8627 Code_ *string `locationName:"code" type:"string"` 8628 8629 // Returned if, when uploading an archive, Amazon S3 Glacier times out while 8630 // receiving the upload. 8631 Message_ *string `locationName:"message" type:"string"` 8632 8633 // Client 8634 Type *string `locationName:"type" type:"string"` 8635} 8636 8637// String returns the string representation. 8638// 8639// API parameter values that are decorated as "sensitive" in the API will not 8640// be included in the string output. The member name will be present, but the 8641// value will be replaced with "sensitive". 8642func (s RequestTimeoutException) String() string { 8643 return awsutil.Prettify(s) 8644} 8645 8646// GoString returns the string representation. 8647// 8648// API parameter values that are decorated as "sensitive" in the API will not 8649// be included in the string output. The member name will be present, but the 8650// value will be replaced with "sensitive". 8651func (s RequestTimeoutException) GoString() string { 8652 return s.String() 8653} 8654 8655func newErrorRequestTimeoutException(v protocol.ResponseMetadata) error { 8656 return &RequestTimeoutException{ 8657 RespMetadata: v, 8658 } 8659} 8660 8661// Code returns the exception type name. 8662func (s *RequestTimeoutException) Code() string { 8663 return "RequestTimeoutException" 8664} 8665 8666// Message returns the exception's message. 8667func (s *RequestTimeoutException) Message() string { 8668 if s.Message_ != nil { 8669 return *s.Message_ 8670 } 8671 return "" 8672} 8673 8674// OrigErr always returns nil, satisfies awserr.Error interface. 8675func (s *RequestTimeoutException) OrigErr() error { 8676 return nil 8677} 8678 8679func (s *RequestTimeoutException) Error() string { 8680 return fmt.Sprintf("%s: %s\n%s", s.Code(), s.Message(), s.String()) 8681} 8682 8683// Status code returns the HTTP status code for the request's response error. 8684func (s *RequestTimeoutException) StatusCode() int { 8685 return s.RespMetadata.StatusCode 8686} 8687 8688// RequestID returns the service's response RequestID for request. 8689func (s *RequestTimeoutException) RequestID() string { 8690 return s.RespMetadata.RequestID 8691} 8692 8693// Returned if the specified resource (such as a vault, upload ID, or job ID) 8694// doesn't exist. 8695type ResourceNotFoundException struct { 8696 _ struct{} `type:"structure"` 8697 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 8698 8699 // 404 Not Found 8700 Code_ *string `locationName:"code" type:"string"` 8701 8702 // Returned if the specified resource (such as a vault, upload ID, or job ID) 8703 // doesn't exist. 8704 Message_ *string `locationName:"message" type:"string"` 8705 8706 // Client 8707 Type *string `locationName:"type" type:"string"` 8708} 8709 8710// String returns the string representation. 8711// 8712// API parameter values that are decorated as "sensitive" in the API will not 8713// be included in the string output. The member name will be present, but the 8714// value will be replaced with "sensitive". 8715func (s ResourceNotFoundException) String() string { 8716 return awsutil.Prettify(s) 8717} 8718 8719// GoString returns the string representation. 8720// 8721// API parameter values that are decorated as "sensitive" in the API will not 8722// be included in the string output. The member name will be present, but the 8723// value will be replaced with "sensitive". 8724func (s ResourceNotFoundException) GoString() string { 8725 return s.String() 8726} 8727 8728func newErrorResourceNotFoundException(v protocol.ResponseMetadata) error { 8729 return &ResourceNotFoundException{ 8730 RespMetadata: v, 8731 } 8732} 8733 8734// Code returns the exception type name. 8735func (s *ResourceNotFoundException) Code() string { 8736 return "ResourceNotFoundException" 8737} 8738 8739// Message returns the exception's message. 8740func (s *ResourceNotFoundException) Message() string { 8741 if s.Message_ != nil { 8742 return *s.Message_ 8743 } 8744 return "" 8745} 8746 8747// OrigErr always returns nil, satisfies awserr.Error interface. 8748func (s *ResourceNotFoundException) OrigErr() error { 8749 return nil 8750} 8751 8752func (s *ResourceNotFoundException) Error() string { 8753 return fmt.Sprintf("%s: %s\n%s", s.Code(), s.Message(), s.String()) 8754} 8755 8756// Status code returns the HTTP status code for the request's response error. 8757func (s *ResourceNotFoundException) StatusCode() int { 8758 return s.RespMetadata.StatusCode 8759} 8760 8761// RequestID returns the service's response RequestID for request. 8762func (s *ResourceNotFoundException) RequestID() string { 8763 return s.RespMetadata.RequestID 8764} 8765 8766// Contains information about the location in Amazon S3 where the select job 8767// results are stored. 8768type S3Location struct { 8769 _ struct{} `type:"structure"` 8770 8771 // A list of grants that control access to the staged results. 8772 AccessControlList []*Grant `type:"list"` 8773 8774 // The name of the Amazon S3 bucket where the job results are stored. 8775 BucketName *string `type:"string"` 8776 8777 // The canned access control list (ACL) to apply to the job results. 8778 CannedACL *string `type:"string" enum:"CannedACL"` 8779 8780 // Contains information about the encryption used to store the job results in 8781 // Amazon S3. 8782 Encryption *Encryption `type:"structure"` 8783 8784 // The prefix that is prepended to the results for this request. 8785 Prefix *string `type:"string"` 8786 8787 // The storage class used to store the job results. 8788 StorageClass *string `type:"string" enum:"StorageClass"` 8789 8790 // The tag-set that is applied to the job results. 8791 Tagging map[string]*string `type:"map"` 8792 8793 // A map of metadata to store with the job results in Amazon S3. 8794 UserMetadata map[string]*string `type:"map"` 8795} 8796 8797// String returns the string representation. 8798// 8799// API parameter values that are decorated as "sensitive" in the API will not 8800// be included in the string output. The member name will be present, but the 8801// value will be replaced with "sensitive". 8802func (s S3Location) String() string { 8803 return awsutil.Prettify(s) 8804} 8805 8806// GoString returns the string representation. 8807// 8808// API parameter values that are decorated as "sensitive" in the API will not 8809// be included in the string output. The member name will be present, but the 8810// value will be replaced with "sensitive". 8811func (s S3Location) GoString() string { 8812 return s.String() 8813} 8814 8815// Validate inspects the fields of the type to determine if they are valid. 8816func (s *S3Location) Validate() error { 8817 invalidParams := request.ErrInvalidParams{Context: "S3Location"} 8818 if s.AccessControlList != nil { 8819 for i, v := range s.AccessControlList { 8820 if v == nil { 8821 continue 8822 } 8823 if err := v.Validate(); err != nil { 8824 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "AccessControlList", i), err.(request.ErrInvalidParams)) 8825 } 8826 } 8827 } 8828 8829 if invalidParams.Len() > 0 { 8830 return invalidParams 8831 } 8832 return nil 8833} 8834 8835// SetAccessControlList sets the AccessControlList field's value. 8836func (s *S3Location) SetAccessControlList(v []*Grant) *S3Location { 8837 s.AccessControlList = v 8838 return s 8839} 8840 8841// SetBucketName sets the BucketName field's value. 8842func (s *S3Location) SetBucketName(v string) *S3Location { 8843 s.BucketName = &v 8844 return s 8845} 8846 8847// SetCannedACL sets the CannedACL field's value. 8848func (s *S3Location) SetCannedACL(v string) *S3Location { 8849 s.CannedACL = &v 8850 return s 8851} 8852 8853// SetEncryption sets the Encryption field's value. 8854func (s *S3Location) SetEncryption(v *Encryption) *S3Location { 8855 s.Encryption = v 8856 return s 8857} 8858 8859// SetPrefix sets the Prefix field's value. 8860func (s *S3Location) SetPrefix(v string) *S3Location { 8861 s.Prefix = &v 8862 return s 8863} 8864 8865// SetStorageClass sets the StorageClass field's value. 8866func (s *S3Location) SetStorageClass(v string) *S3Location { 8867 s.StorageClass = &v 8868 return s 8869} 8870 8871// SetTagging sets the Tagging field's value. 8872func (s *S3Location) SetTagging(v map[string]*string) *S3Location { 8873 s.Tagging = v 8874 return s 8875} 8876 8877// SetUserMetadata sets the UserMetadata field's value. 8878func (s *S3Location) SetUserMetadata(v map[string]*string) *S3Location { 8879 s.UserMetadata = v 8880 return s 8881} 8882 8883// Contains information about the parameters used for a select. 8884type SelectParameters struct { 8885 _ struct{} `type:"structure"` 8886 8887 // The expression that is used to select the object. 8888 Expression *string `type:"string"` 8889 8890 // The type of the provided expression, for example SQL. 8891 ExpressionType *string `type:"string" enum:"ExpressionType"` 8892 8893 // Describes the serialization format of the object. 8894 InputSerialization *InputSerialization `type:"structure"` 8895 8896 // Describes how the results of the select job are serialized. 8897 OutputSerialization *OutputSerialization `type:"structure"` 8898} 8899 8900// String returns the string representation. 8901// 8902// API parameter values that are decorated as "sensitive" in the API will not 8903// be included in the string output. The member name will be present, but the 8904// value will be replaced with "sensitive". 8905func (s SelectParameters) String() string { 8906 return awsutil.Prettify(s) 8907} 8908 8909// GoString returns the string representation. 8910// 8911// API parameter values that are decorated as "sensitive" in the API will not 8912// be included in the string output. The member name will be present, but the 8913// value will be replaced with "sensitive". 8914func (s SelectParameters) GoString() string { 8915 return s.String() 8916} 8917 8918// SetExpression sets the Expression field's value. 8919func (s *SelectParameters) SetExpression(v string) *SelectParameters { 8920 s.Expression = &v 8921 return s 8922} 8923 8924// SetExpressionType sets the ExpressionType field's value. 8925func (s *SelectParameters) SetExpressionType(v string) *SelectParameters { 8926 s.ExpressionType = &v 8927 return s 8928} 8929 8930// SetInputSerialization sets the InputSerialization field's value. 8931func (s *SelectParameters) SetInputSerialization(v *InputSerialization) *SelectParameters { 8932 s.InputSerialization = v 8933 return s 8934} 8935 8936// SetOutputSerialization sets the OutputSerialization field's value. 8937func (s *SelectParameters) SetOutputSerialization(v *OutputSerialization) *SelectParameters { 8938 s.OutputSerialization = v 8939 return s 8940} 8941 8942// Returned if the service cannot complete the request. 8943type ServiceUnavailableException struct { 8944 _ struct{} `type:"structure"` 8945 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 8946 8947 // 500 Internal Server Error 8948 Code_ *string `locationName:"code" type:"string"` 8949 8950 // Returned if the service cannot complete the request. 8951 Message_ *string `locationName:"message" type:"string"` 8952 8953 // Server 8954 Type *string `locationName:"type" type:"string"` 8955} 8956 8957// String returns the string representation. 8958// 8959// API parameter values that are decorated as "sensitive" in the API will not 8960// be included in the string output. The member name will be present, but the 8961// value will be replaced with "sensitive". 8962func (s ServiceUnavailableException) String() string { 8963 return awsutil.Prettify(s) 8964} 8965 8966// GoString returns the string representation. 8967// 8968// API parameter values that are decorated as "sensitive" in the API will not 8969// be included in the string output. The member name will be present, but the 8970// value will be replaced with "sensitive". 8971func (s ServiceUnavailableException) GoString() string { 8972 return s.String() 8973} 8974 8975func newErrorServiceUnavailableException(v protocol.ResponseMetadata) error { 8976 return &ServiceUnavailableException{ 8977 RespMetadata: v, 8978 } 8979} 8980 8981// Code returns the exception type name. 8982func (s *ServiceUnavailableException) Code() string { 8983 return "ServiceUnavailableException" 8984} 8985 8986// Message returns the exception's message. 8987func (s *ServiceUnavailableException) Message() string { 8988 if s.Message_ != nil { 8989 return *s.Message_ 8990 } 8991 return "" 8992} 8993 8994// OrigErr always returns nil, satisfies awserr.Error interface. 8995func (s *ServiceUnavailableException) OrigErr() error { 8996 return nil 8997} 8998 8999func (s *ServiceUnavailableException) Error() string { 9000 return fmt.Sprintf("%s: %s\n%s", s.Code(), s.Message(), s.String()) 9001} 9002 9003// Status code returns the HTTP status code for the request's response error. 9004func (s *ServiceUnavailableException) StatusCode() int { 9005 return s.RespMetadata.StatusCode 9006} 9007 9008// RequestID returns the service's response RequestID for request. 9009func (s *ServiceUnavailableException) RequestID() string { 9010 return s.RespMetadata.RequestID 9011} 9012 9013// SetDataRetrievalPolicy input. 9014type SetDataRetrievalPolicyInput struct { 9015 _ struct{} `type:"structure"` 9016 9017 // The AccountId value is the AWS account ID. This value must match the AWS 9018 // account ID associated with the credentials used to sign the request. You 9019 // can either specify an AWS account ID or optionally a single '-' (hyphen), 9020 // in which case Amazon Glacier uses the AWS account ID associated with the 9021 // credentials used to sign the request. If you specify your account ID, do 9022 // not include any hyphens ('-') in the ID. 9023 // 9024 // AccountId is a required field 9025 AccountId *string `location:"uri" locationName:"accountId" type:"string" required:"true"` 9026 9027 // The data retrieval policy in JSON format. 9028 Policy *DataRetrievalPolicy `type:"structure"` 9029} 9030 9031// String returns the string representation. 9032// 9033// API parameter values that are decorated as "sensitive" in the API will not 9034// be included in the string output. The member name will be present, but the 9035// value will be replaced with "sensitive". 9036func (s SetDataRetrievalPolicyInput) String() string { 9037 return awsutil.Prettify(s) 9038} 9039 9040// GoString returns the string representation. 9041// 9042// API parameter values that are decorated as "sensitive" in the API will not 9043// be included in the string output. The member name will be present, but the 9044// value will be replaced with "sensitive". 9045func (s SetDataRetrievalPolicyInput) GoString() string { 9046 return s.String() 9047} 9048 9049// Validate inspects the fields of the type to determine if they are valid. 9050func (s *SetDataRetrievalPolicyInput) Validate() error { 9051 invalidParams := request.ErrInvalidParams{Context: "SetDataRetrievalPolicyInput"} 9052 if s.AccountId == nil { 9053 invalidParams.Add(request.NewErrParamRequired("AccountId")) 9054 } 9055 if s.AccountId != nil && len(*s.AccountId) < 1 { 9056 invalidParams.Add(request.NewErrParamMinLen("AccountId", 1)) 9057 } 9058 9059 if invalidParams.Len() > 0 { 9060 return invalidParams 9061 } 9062 return nil 9063} 9064 9065// SetAccountId sets the AccountId field's value. 9066func (s *SetDataRetrievalPolicyInput) SetAccountId(v string) *SetDataRetrievalPolicyInput { 9067 s.AccountId = &v 9068 return s 9069} 9070 9071// SetPolicy sets the Policy field's value. 9072func (s *SetDataRetrievalPolicyInput) SetPolicy(v *DataRetrievalPolicy) *SetDataRetrievalPolicyInput { 9073 s.Policy = v 9074 return s 9075} 9076 9077type SetDataRetrievalPolicyOutput struct { 9078 _ struct{} `type:"structure"` 9079} 9080 9081// String returns the string representation. 9082// 9083// API parameter values that are decorated as "sensitive" in the API will not 9084// be included in the string output. The member name will be present, but the 9085// value will be replaced with "sensitive". 9086func (s SetDataRetrievalPolicyOutput) String() string { 9087 return awsutil.Prettify(s) 9088} 9089 9090// GoString returns the string representation. 9091// 9092// API parameter values that are decorated as "sensitive" in the API will not 9093// be included in the string output. The member name will be present, but the 9094// value will be replaced with "sensitive". 9095func (s SetDataRetrievalPolicyOutput) GoString() string { 9096 return s.String() 9097} 9098 9099// SetVaultAccessPolicy input. 9100type SetVaultAccessPolicyInput struct { 9101 _ struct{} `type:"structure" payload:"Policy"` 9102 9103 // The AccountId value is the AWS account ID of the account that owns the vault. 9104 // You can either specify an AWS account ID or optionally a single '-' (hyphen), 9105 // in which case Amazon S3 Glacier uses the AWS account ID associated with the 9106 // credentials used to sign the request. If you use an account ID, do not include 9107 // any hyphens ('-') in the ID. 9108 // 9109 // AccountId is a required field 9110 AccountId *string `location:"uri" locationName:"accountId" type:"string" required:"true"` 9111 9112 // The vault access policy as a JSON string. 9113 Policy *VaultAccessPolicy `locationName:"policy" type:"structure"` 9114 9115 // The name of the vault. 9116 // 9117 // VaultName is a required field 9118 VaultName *string `location:"uri" locationName:"vaultName" type:"string" required:"true"` 9119} 9120 9121// String returns the string representation. 9122// 9123// API parameter values that are decorated as "sensitive" in the API will not 9124// be included in the string output. The member name will be present, but the 9125// value will be replaced with "sensitive". 9126func (s SetVaultAccessPolicyInput) String() string { 9127 return awsutil.Prettify(s) 9128} 9129 9130// GoString returns the string representation. 9131// 9132// API parameter values that are decorated as "sensitive" in the API will not 9133// be included in the string output. The member name will be present, but the 9134// value will be replaced with "sensitive". 9135func (s SetVaultAccessPolicyInput) GoString() string { 9136 return s.String() 9137} 9138 9139// Validate inspects the fields of the type to determine if they are valid. 9140func (s *SetVaultAccessPolicyInput) Validate() error { 9141 invalidParams := request.ErrInvalidParams{Context: "SetVaultAccessPolicyInput"} 9142 if s.AccountId == nil { 9143 invalidParams.Add(request.NewErrParamRequired("AccountId")) 9144 } 9145 if s.AccountId != nil && len(*s.AccountId) < 1 { 9146 invalidParams.Add(request.NewErrParamMinLen("AccountId", 1)) 9147 } 9148 if s.VaultName == nil { 9149 invalidParams.Add(request.NewErrParamRequired("VaultName")) 9150 } 9151 if s.VaultName != nil && len(*s.VaultName) < 1 { 9152 invalidParams.Add(request.NewErrParamMinLen("VaultName", 1)) 9153 } 9154 9155 if invalidParams.Len() > 0 { 9156 return invalidParams 9157 } 9158 return nil 9159} 9160 9161// SetAccountId sets the AccountId field's value. 9162func (s *SetVaultAccessPolicyInput) SetAccountId(v string) *SetVaultAccessPolicyInput { 9163 s.AccountId = &v 9164 return s 9165} 9166 9167// SetPolicy sets the Policy field's value. 9168func (s *SetVaultAccessPolicyInput) SetPolicy(v *VaultAccessPolicy) *SetVaultAccessPolicyInput { 9169 s.Policy = v 9170 return s 9171} 9172 9173// SetVaultName sets the VaultName field's value. 9174func (s *SetVaultAccessPolicyInput) SetVaultName(v string) *SetVaultAccessPolicyInput { 9175 s.VaultName = &v 9176 return s 9177} 9178 9179type SetVaultAccessPolicyOutput struct { 9180 _ struct{} `type:"structure"` 9181} 9182 9183// String returns the string representation. 9184// 9185// API parameter values that are decorated as "sensitive" in the API will not 9186// be included in the string output. The member name will be present, but the 9187// value will be replaced with "sensitive". 9188func (s SetVaultAccessPolicyOutput) String() string { 9189 return awsutil.Prettify(s) 9190} 9191 9192// GoString returns the string representation. 9193// 9194// API parameter values that are decorated as "sensitive" in the API will not 9195// be included in the string output. The member name will be present, but the 9196// value will be replaced with "sensitive". 9197func (s SetVaultAccessPolicyOutput) GoString() string { 9198 return s.String() 9199} 9200 9201// Provides options to configure notifications that will be sent when specific 9202// events happen to a vault. 9203type SetVaultNotificationsInput struct { 9204 _ struct{} `type:"structure" payload:"VaultNotificationConfig"` 9205 9206 // The AccountId value is the AWS account ID of the account that owns the vault. 9207 // You can either specify an AWS account ID or optionally a single '-' (hyphen), 9208 // in which case Amazon S3 Glacier uses the AWS account ID associated with the 9209 // credentials used to sign the request. If you use an account ID, do not include 9210 // any hyphens ('-') in the ID. 9211 // 9212 // AccountId is a required field 9213 AccountId *string `location:"uri" locationName:"accountId" type:"string" required:"true"` 9214 9215 // The name of the vault. 9216 // 9217 // VaultName is a required field 9218 VaultName *string `location:"uri" locationName:"vaultName" type:"string" required:"true"` 9219 9220 // Provides options for specifying notification configuration. 9221 VaultNotificationConfig *VaultNotificationConfig `locationName:"vaultNotificationConfig" type:"structure"` 9222} 9223 9224// String returns the string representation. 9225// 9226// API parameter values that are decorated as "sensitive" in the API will not 9227// be included in the string output. The member name will be present, but the 9228// value will be replaced with "sensitive". 9229func (s SetVaultNotificationsInput) String() string { 9230 return awsutil.Prettify(s) 9231} 9232 9233// GoString returns the string representation. 9234// 9235// API parameter values that are decorated as "sensitive" in the API will not 9236// be included in the string output. The member name will be present, but the 9237// value will be replaced with "sensitive". 9238func (s SetVaultNotificationsInput) GoString() string { 9239 return s.String() 9240} 9241 9242// Validate inspects the fields of the type to determine if they are valid. 9243func (s *SetVaultNotificationsInput) Validate() error { 9244 invalidParams := request.ErrInvalidParams{Context: "SetVaultNotificationsInput"} 9245 if s.AccountId == nil { 9246 invalidParams.Add(request.NewErrParamRequired("AccountId")) 9247 } 9248 if s.AccountId != nil && len(*s.AccountId) < 1 { 9249 invalidParams.Add(request.NewErrParamMinLen("AccountId", 1)) 9250 } 9251 if s.VaultName == nil { 9252 invalidParams.Add(request.NewErrParamRequired("VaultName")) 9253 } 9254 if s.VaultName != nil && len(*s.VaultName) < 1 { 9255 invalidParams.Add(request.NewErrParamMinLen("VaultName", 1)) 9256 } 9257 9258 if invalidParams.Len() > 0 { 9259 return invalidParams 9260 } 9261 return nil 9262} 9263 9264// SetAccountId sets the AccountId field's value. 9265func (s *SetVaultNotificationsInput) SetAccountId(v string) *SetVaultNotificationsInput { 9266 s.AccountId = &v 9267 return s 9268} 9269 9270// SetVaultName sets the VaultName field's value. 9271func (s *SetVaultNotificationsInput) SetVaultName(v string) *SetVaultNotificationsInput { 9272 s.VaultName = &v 9273 return s 9274} 9275 9276// SetVaultNotificationConfig sets the VaultNotificationConfig field's value. 9277func (s *SetVaultNotificationsInput) SetVaultNotificationConfig(v *VaultNotificationConfig) *SetVaultNotificationsInput { 9278 s.VaultNotificationConfig = v 9279 return s 9280} 9281 9282type SetVaultNotificationsOutput struct { 9283 _ struct{} `type:"structure"` 9284} 9285 9286// String returns the string representation. 9287// 9288// API parameter values that are decorated as "sensitive" in the API will not 9289// be included in the string output. The member name will be present, but the 9290// value will be replaced with "sensitive". 9291func (s SetVaultNotificationsOutput) String() string { 9292 return awsutil.Prettify(s) 9293} 9294 9295// GoString returns the string representation. 9296// 9297// API parameter values that are decorated as "sensitive" in the API will not 9298// be included in the string output. The member name will be present, but the 9299// value will be replaced with "sensitive". 9300func (s SetVaultNotificationsOutput) GoString() string { 9301 return s.String() 9302} 9303 9304// Provides options to add an archive to a vault. 9305type UploadArchiveInput struct { 9306 _ struct{} `type:"structure" payload:"Body"` 9307 9308 // The AccountId value is the AWS account ID of the account that owns the vault. 9309 // You can either specify an AWS account ID or optionally a single '-' (hyphen), 9310 // in which case Amazon S3 Glacier uses the AWS account ID associated with the 9311 // credentials used to sign the request. If you use an account ID, do not include 9312 // any hyphens ('-') in the ID. 9313 // 9314 // AccountId is a required field 9315 AccountId *string `location:"uri" locationName:"accountId" type:"string" required:"true"` 9316 9317 // The optional description of the archive you are uploading. 9318 ArchiveDescription *string `location:"header" locationName:"x-amz-archive-description" type:"string"` 9319 9320 // The data to upload. 9321 Body io.ReadSeeker `locationName:"body" type:"blob"` 9322 9323 // The SHA256 tree hash of the data being uploaded. 9324 Checksum *string `location:"header" locationName:"x-amz-sha256-tree-hash" type:"string"` 9325 9326 // The name of the vault. 9327 // 9328 // VaultName is a required field 9329 VaultName *string `location:"uri" locationName:"vaultName" type:"string" required:"true"` 9330} 9331 9332// String returns the string representation. 9333// 9334// API parameter values that are decorated as "sensitive" in the API will not 9335// be included in the string output. The member name will be present, but the 9336// value will be replaced with "sensitive". 9337func (s UploadArchiveInput) String() string { 9338 return awsutil.Prettify(s) 9339} 9340 9341// GoString returns the string representation. 9342// 9343// API parameter values that are decorated as "sensitive" in the API will not 9344// be included in the string output. The member name will be present, but the 9345// value will be replaced with "sensitive". 9346func (s UploadArchiveInput) GoString() string { 9347 return s.String() 9348} 9349 9350// Validate inspects the fields of the type to determine if they are valid. 9351func (s *UploadArchiveInput) Validate() error { 9352 invalidParams := request.ErrInvalidParams{Context: "UploadArchiveInput"} 9353 if s.AccountId == nil { 9354 invalidParams.Add(request.NewErrParamRequired("AccountId")) 9355 } 9356 if s.AccountId != nil && len(*s.AccountId) < 1 { 9357 invalidParams.Add(request.NewErrParamMinLen("AccountId", 1)) 9358 } 9359 if s.VaultName == nil { 9360 invalidParams.Add(request.NewErrParamRequired("VaultName")) 9361 } 9362 if s.VaultName != nil && len(*s.VaultName) < 1 { 9363 invalidParams.Add(request.NewErrParamMinLen("VaultName", 1)) 9364 } 9365 9366 if invalidParams.Len() > 0 { 9367 return invalidParams 9368 } 9369 return nil 9370} 9371 9372// SetAccountId sets the AccountId field's value. 9373func (s *UploadArchiveInput) SetAccountId(v string) *UploadArchiveInput { 9374 s.AccountId = &v 9375 return s 9376} 9377 9378// SetArchiveDescription sets the ArchiveDescription field's value. 9379func (s *UploadArchiveInput) SetArchiveDescription(v string) *UploadArchiveInput { 9380 s.ArchiveDescription = &v 9381 return s 9382} 9383 9384// SetBody sets the Body field's value. 9385func (s *UploadArchiveInput) SetBody(v io.ReadSeeker) *UploadArchiveInput { 9386 s.Body = v 9387 return s 9388} 9389 9390// SetChecksum sets the Checksum field's value. 9391func (s *UploadArchiveInput) SetChecksum(v string) *UploadArchiveInput { 9392 s.Checksum = &v 9393 return s 9394} 9395 9396// SetVaultName sets the VaultName field's value. 9397func (s *UploadArchiveInput) SetVaultName(v string) *UploadArchiveInput { 9398 s.VaultName = &v 9399 return s 9400} 9401 9402// A list of in-progress multipart uploads for a vault. 9403type UploadListElement struct { 9404 _ struct{} `type:"structure"` 9405 9406 // The description of the archive that was specified in the Initiate Multipart 9407 // Upload request. 9408 ArchiveDescription *string `type:"string"` 9409 9410 // The UTC time at which the multipart upload was initiated. 9411 CreationDate *string `type:"string"` 9412 9413 // The ID of a multipart upload. 9414 MultipartUploadId *string `type:"string"` 9415 9416 // The part size, in bytes, specified in the Initiate Multipart Upload request. 9417 // This is the size of all the parts in the upload except the last part, which 9418 // may be smaller than this size. 9419 PartSizeInBytes *int64 `type:"long"` 9420 9421 // The Amazon Resource Name (ARN) of the vault that contains the archive. 9422 VaultARN *string `type:"string"` 9423} 9424 9425// String returns the string representation. 9426// 9427// API parameter values that are decorated as "sensitive" in the API will not 9428// be included in the string output. The member name will be present, but the 9429// value will be replaced with "sensitive". 9430func (s UploadListElement) String() string { 9431 return awsutil.Prettify(s) 9432} 9433 9434// GoString returns the string representation. 9435// 9436// API parameter values that are decorated as "sensitive" in the API will not 9437// be included in the string output. The member name will be present, but the 9438// value will be replaced with "sensitive". 9439func (s UploadListElement) GoString() string { 9440 return s.String() 9441} 9442 9443// SetArchiveDescription sets the ArchiveDescription field's value. 9444func (s *UploadListElement) SetArchiveDescription(v string) *UploadListElement { 9445 s.ArchiveDescription = &v 9446 return s 9447} 9448 9449// SetCreationDate sets the CreationDate field's value. 9450func (s *UploadListElement) SetCreationDate(v string) *UploadListElement { 9451 s.CreationDate = &v 9452 return s 9453} 9454 9455// SetMultipartUploadId sets the MultipartUploadId field's value. 9456func (s *UploadListElement) SetMultipartUploadId(v string) *UploadListElement { 9457 s.MultipartUploadId = &v 9458 return s 9459} 9460 9461// SetPartSizeInBytes sets the PartSizeInBytes field's value. 9462func (s *UploadListElement) SetPartSizeInBytes(v int64) *UploadListElement { 9463 s.PartSizeInBytes = &v 9464 return s 9465} 9466 9467// SetVaultARN sets the VaultARN field's value. 9468func (s *UploadListElement) SetVaultARN(v string) *UploadListElement { 9469 s.VaultARN = &v 9470 return s 9471} 9472 9473// Provides options to upload a part of an archive in a multipart upload operation. 9474type UploadMultipartPartInput struct { 9475 _ struct{} `type:"structure" payload:"Body"` 9476 9477 // The AccountId value is the AWS account ID of the account that owns the vault. 9478 // You can either specify an AWS account ID or optionally a single '-' (hyphen), 9479 // in which case Amazon S3 Glacier uses the AWS account ID associated with the 9480 // credentials used to sign the request. If you use an account ID, do not include 9481 // any hyphens ('-') in the ID. 9482 // 9483 // AccountId is a required field 9484 AccountId *string `location:"uri" locationName:"accountId" type:"string" required:"true"` 9485 9486 // The data to upload. 9487 Body io.ReadSeeker `locationName:"body" type:"blob"` 9488 9489 // The SHA256 tree hash of the data being uploaded. 9490 Checksum *string `location:"header" locationName:"x-amz-sha256-tree-hash" type:"string"` 9491 9492 // Identifies the range of bytes in the assembled archive that will be uploaded 9493 // in this part. Amazon S3 Glacier uses this information to assemble the archive 9494 // in the proper sequence. The format of this header follows RFC 2616. An example 9495 // header is Content-Range:bytes 0-4194303/*. 9496 Range *string `location:"header" locationName:"Content-Range" type:"string"` 9497 9498 // The upload ID of the multipart upload. 9499 // 9500 // UploadId is a required field 9501 UploadId *string `location:"uri" locationName:"uploadId" type:"string" required:"true"` 9502 9503 // The name of the vault. 9504 // 9505 // VaultName is a required field 9506 VaultName *string `location:"uri" locationName:"vaultName" type:"string" required:"true"` 9507} 9508 9509// String returns the string representation. 9510// 9511// API parameter values that are decorated as "sensitive" in the API will not 9512// be included in the string output. The member name will be present, but the 9513// value will be replaced with "sensitive". 9514func (s UploadMultipartPartInput) String() string { 9515 return awsutil.Prettify(s) 9516} 9517 9518// GoString returns the string representation. 9519// 9520// API parameter values that are decorated as "sensitive" in the API will not 9521// be included in the string output. The member name will be present, but the 9522// value will be replaced with "sensitive". 9523func (s UploadMultipartPartInput) GoString() string { 9524 return s.String() 9525} 9526 9527// Validate inspects the fields of the type to determine if they are valid. 9528func (s *UploadMultipartPartInput) Validate() error { 9529 invalidParams := request.ErrInvalidParams{Context: "UploadMultipartPartInput"} 9530 if s.AccountId == nil { 9531 invalidParams.Add(request.NewErrParamRequired("AccountId")) 9532 } 9533 if s.AccountId != nil && len(*s.AccountId) < 1 { 9534 invalidParams.Add(request.NewErrParamMinLen("AccountId", 1)) 9535 } 9536 if s.UploadId == nil { 9537 invalidParams.Add(request.NewErrParamRequired("UploadId")) 9538 } 9539 if s.UploadId != nil && len(*s.UploadId) < 1 { 9540 invalidParams.Add(request.NewErrParamMinLen("UploadId", 1)) 9541 } 9542 if s.VaultName == nil { 9543 invalidParams.Add(request.NewErrParamRequired("VaultName")) 9544 } 9545 if s.VaultName != nil && len(*s.VaultName) < 1 { 9546 invalidParams.Add(request.NewErrParamMinLen("VaultName", 1)) 9547 } 9548 9549 if invalidParams.Len() > 0 { 9550 return invalidParams 9551 } 9552 return nil 9553} 9554 9555// SetAccountId sets the AccountId field's value. 9556func (s *UploadMultipartPartInput) SetAccountId(v string) *UploadMultipartPartInput { 9557 s.AccountId = &v 9558 return s 9559} 9560 9561// SetBody sets the Body field's value. 9562func (s *UploadMultipartPartInput) SetBody(v io.ReadSeeker) *UploadMultipartPartInput { 9563 s.Body = v 9564 return s 9565} 9566 9567// SetChecksum sets the Checksum field's value. 9568func (s *UploadMultipartPartInput) SetChecksum(v string) *UploadMultipartPartInput { 9569 s.Checksum = &v 9570 return s 9571} 9572 9573// SetRange sets the Range field's value. 9574func (s *UploadMultipartPartInput) SetRange(v string) *UploadMultipartPartInput { 9575 s.Range = &v 9576 return s 9577} 9578 9579// SetUploadId sets the UploadId field's value. 9580func (s *UploadMultipartPartInput) SetUploadId(v string) *UploadMultipartPartInput { 9581 s.UploadId = &v 9582 return s 9583} 9584 9585// SetVaultName sets the VaultName field's value. 9586func (s *UploadMultipartPartInput) SetVaultName(v string) *UploadMultipartPartInput { 9587 s.VaultName = &v 9588 return s 9589} 9590 9591// Contains the Amazon S3 Glacier response to your request. 9592type UploadMultipartPartOutput struct { 9593 _ struct{} `type:"structure"` 9594 9595 // The SHA256 tree hash that Amazon S3 Glacier computed for the uploaded part. 9596 Checksum *string `location:"header" locationName:"x-amz-sha256-tree-hash" type:"string"` 9597} 9598 9599// String returns the string representation. 9600// 9601// API parameter values that are decorated as "sensitive" in the API will not 9602// be included in the string output. The member name will be present, but the 9603// value will be replaced with "sensitive". 9604func (s UploadMultipartPartOutput) String() string { 9605 return awsutil.Prettify(s) 9606} 9607 9608// GoString returns the string representation. 9609// 9610// API parameter values that are decorated as "sensitive" in the API will not 9611// be included in the string output. The member name will be present, but the 9612// value will be replaced with "sensitive". 9613func (s UploadMultipartPartOutput) GoString() string { 9614 return s.String() 9615} 9616 9617// SetChecksum sets the Checksum field's value. 9618func (s *UploadMultipartPartOutput) SetChecksum(v string) *UploadMultipartPartOutput { 9619 s.Checksum = &v 9620 return s 9621} 9622 9623// Contains the vault access policy. 9624type VaultAccessPolicy struct { 9625 _ struct{} `type:"structure"` 9626 9627 // The vault access policy. 9628 Policy *string `type:"string"` 9629} 9630 9631// String returns the string representation. 9632// 9633// API parameter values that are decorated as "sensitive" in the API will not 9634// be included in the string output. The member name will be present, but the 9635// value will be replaced with "sensitive". 9636func (s VaultAccessPolicy) String() string { 9637 return awsutil.Prettify(s) 9638} 9639 9640// GoString returns the string representation. 9641// 9642// API parameter values that are decorated as "sensitive" in the API will not 9643// be included in the string output. The member name will be present, but the 9644// value will be replaced with "sensitive". 9645func (s VaultAccessPolicy) GoString() string { 9646 return s.String() 9647} 9648 9649// SetPolicy sets the Policy field's value. 9650func (s *VaultAccessPolicy) SetPolicy(v string) *VaultAccessPolicy { 9651 s.Policy = &v 9652 return s 9653} 9654 9655// Contains the vault lock policy. 9656type VaultLockPolicy struct { 9657 _ struct{} `type:"structure"` 9658 9659 // The vault lock policy. 9660 Policy *string `type:"string"` 9661} 9662 9663// String returns the string representation. 9664// 9665// API parameter values that are decorated as "sensitive" in the API will not 9666// be included in the string output. The member name will be present, but the 9667// value will be replaced with "sensitive". 9668func (s VaultLockPolicy) String() string { 9669 return awsutil.Prettify(s) 9670} 9671 9672// GoString returns the string representation. 9673// 9674// API parameter values that are decorated as "sensitive" in the API will not 9675// be included in the string output. The member name will be present, but the 9676// value will be replaced with "sensitive". 9677func (s VaultLockPolicy) GoString() string { 9678 return s.String() 9679} 9680 9681// SetPolicy sets the Policy field's value. 9682func (s *VaultLockPolicy) SetPolicy(v string) *VaultLockPolicy { 9683 s.Policy = &v 9684 return s 9685} 9686 9687// Represents a vault's notification configuration. 9688type VaultNotificationConfig struct { 9689 _ struct{} `type:"structure"` 9690 9691 // A list of one or more events for which Amazon S3 Glacier will send a notification 9692 // to the specified Amazon SNS topic. 9693 Events []*string `type:"list"` 9694 9695 // The Amazon Simple Notification Service (Amazon SNS) topic Amazon Resource 9696 // Name (ARN). 9697 SNSTopic *string `type:"string"` 9698} 9699 9700// String returns the string representation. 9701// 9702// API parameter values that are decorated as "sensitive" in the API will not 9703// be included in the string output. The member name will be present, but the 9704// value will be replaced with "sensitive". 9705func (s VaultNotificationConfig) String() string { 9706 return awsutil.Prettify(s) 9707} 9708 9709// GoString returns the string representation. 9710// 9711// API parameter values that are decorated as "sensitive" in the API will not 9712// be included in the string output. The member name will be present, but the 9713// value will be replaced with "sensitive". 9714func (s VaultNotificationConfig) GoString() string { 9715 return s.String() 9716} 9717 9718// SetEvents sets the Events field's value. 9719func (s *VaultNotificationConfig) SetEvents(v []*string) *VaultNotificationConfig { 9720 s.Events = v 9721 return s 9722} 9723 9724// SetSNSTopic sets the SNSTopic field's value. 9725func (s *VaultNotificationConfig) SetSNSTopic(v string) *VaultNotificationConfig { 9726 s.SNSTopic = &v 9727 return s 9728} 9729 9730const ( 9731 // ActionCodeArchiveRetrieval is a ActionCode enum value 9732 ActionCodeArchiveRetrieval = "ArchiveRetrieval" 9733 9734 // ActionCodeInventoryRetrieval is a ActionCode enum value 9735 ActionCodeInventoryRetrieval = "InventoryRetrieval" 9736 9737 // ActionCodeSelect is a ActionCode enum value 9738 ActionCodeSelect = "Select" 9739) 9740 9741// ActionCode_Values returns all elements of the ActionCode enum 9742func ActionCode_Values() []string { 9743 return []string{ 9744 ActionCodeArchiveRetrieval, 9745 ActionCodeInventoryRetrieval, 9746 ActionCodeSelect, 9747 } 9748} 9749 9750const ( 9751 // CannedACLPrivate is a CannedACL enum value 9752 CannedACLPrivate = "private" 9753 9754 // CannedACLPublicRead is a CannedACL enum value 9755 CannedACLPublicRead = "public-read" 9756 9757 // CannedACLPublicReadWrite is a CannedACL enum value 9758 CannedACLPublicReadWrite = "public-read-write" 9759 9760 // CannedACLAwsExecRead is a CannedACL enum value 9761 CannedACLAwsExecRead = "aws-exec-read" 9762 9763 // CannedACLAuthenticatedRead is a CannedACL enum value 9764 CannedACLAuthenticatedRead = "authenticated-read" 9765 9766 // CannedACLBucketOwnerRead is a CannedACL enum value 9767 CannedACLBucketOwnerRead = "bucket-owner-read" 9768 9769 // CannedACLBucketOwnerFullControl is a CannedACL enum value 9770 CannedACLBucketOwnerFullControl = "bucket-owner-full-control" 9771) 9772 9773// CannedACL_Values returns all elements of the CannedACL enum 9774func CannedACL_Values() []string { 9775 return []string{ 9776 CannedACLPrivate, 9777 CannedACLPublicRead, 9778 CannedACLPublicReadWrite, 9779 CannedACLAwsExecRead, 9780 CannedACLAuthenticatedRead, 9781 CannedACLBucketOwnerRead, 9782 CannedACLBucketOwnerFullControl, 9783 } 9784} 9785 9786const ( 9787 // EncryptionTypeAwsKms is a EncryptionType enum value 9788 EncryptionTypeAwsKms = "aws:kms" 9789 9790 // EncryptionTypeAes256 is a EncryptionType enum value 9791 EncryptionTypeAes256 = "AES256" 9792) 9793 9794// EncryptionType_Values returns all elements of the EncryptionType enum 9795func EncryptionType_Values() []string { 9796 return []string{ 9797 EncryptionTypeAwsKms, 9798 EncryptionTypeAes256, 9799 } 9800} 9801 9802const ( 9803 // ExpressionTypeSql is a ExpressionType enum value 9804 ExpressionTypeSql = "SQL" 9805) 9806 9807// ExpressionType_Values returns all elements of the ExpressionType enum 9808func ExpressionType_Values() []string { 9809 return []string{ 9810 ExpressionTypeSql, 9811 } 9812} 9813 9814const ( 9815 // FileHeaderInfoUse is a FileHeaderInfo enum value 9816 FileHeaderInfoUse = "USE" 9817 9818 // FileHeaderInfoIgnore is a FileHeaderInfo enum value 9819 FileHeaderInfoIgnore = "IGNORE" 9820 9821 // FileHeaderInfoNone is a FileHeaderInfo enum value 9822 FileHeaderInfoNone = "NONE" 9823) 9824 9825// FileHeaderInfo_Values returns all elements of the FileHeaderInfo enum 9826func FileHeaderInfo_Values() []string { 9827 return []string{ 9828 FileHeaderInfoUse, 9829 FileHeaderInfoIgnore, 9830 FileHeaderInfoNone, 9831 } 9832} 9833 9834const ( 9835 // PermissionFullControl is a Permission enum value 9836 PermissionFullControl = "FULL_CONTROL" 9837 9838 // PermissionWrite is a Permission enum value 9839 PermissionWrite = "WRITE" 9840 9841 // PermissionWriteAcp is a Permission enum value 9842 PermissionWriteAcp = "WRITE_ACP" 9843 9844 // PermissionRead is a Permission enum value 9845 PermissionRead = "READ" 9846 9847 // PermissionReadAcp is a Permission enum value 9848 PermissionReadAcp = "READ_ACP" 9849) 9850 9851// Permission_Values returns all elements of the Permission enum 9852func Permission_Values() []string { 9853 return []string{ 9854 PermissionFullControl, 9855 PermissionWrite, 9856 PermissionWriteAcp, 9857 PermissionRead, 9858 PermissionReadAcp, 9859 } 9860} 9861 9862const ( 9863 // QuoteFieldsAlways is a QuoteFields enum value 9864 QuoteFieldsAlways = "ALWAYS" 9865 9866 // QuoteFieldsAsneeded is a QuoteFields enum value 9867 QuoteFieldsAsneeded = "ASNEEDED" 9868) 9869 9870// QuoteFields_Values returns all elements of the QuoteFields enum 9871func QuoteFields_Values() []string { 9872 return []string{ 9873 QuoteFieldsAlways, 9874 QuoteFieldsAsneeded, 9875 } 9876} 9877 9878const ( 9879 // StatusCodeInProgress is a StatusCode enum value 9880 StatusCodeInProgress = "InProgress" 9881 9882 // StatusCodeSucceeded is a StatusCode enum value 9883 StatusCodeSucceeded = "Succeeded" 9884 9885 // StatusCodeFailed is a StatusCode enum value 9886 StatusCodeFailed = "Failed" 9887) 9888 9889// StatusCode_Values returns all elements of the StatusCode enum 9890func StatusCode_Values() []string { 9891 return []string{ 9892 StatusCodeInProgress, 9893 StatusCodeSucceeded, 9894 StatusCodeFailed, 9895 } 9896} 9897 9898const ( 9899 // StorageClassStandard is a StorageClass enum value 9900 StorageClassStandard = "STANDARD" 9901 9902 // StorageClassReducedRedundancy is a StorageClass enum value 9903 StorageClassReducedRedundancy = "REDUCED_REDUNDANCY" 9904 9905 // StorageClassStandardIa is a StorageClass enum value 9906 StorageClassStandardIa = "STANDARD_IA" 9907) 9908 9909// StorageClass_Values returns all elements of the StorageClass enum 9910func StorageClass_Values() []string { 9911 return []string{ 9912 StorageClassStandard, 9913 StorageClassReducedRedundancy, 9914 StorageClassStandardIa, 9915 } 9916} 9917 9918const ( 9919 // TypeAmazonCustomerByEmail is a Type enum value 9920 TypeAmazonCustomerByEmail = "AmazonCustomerByEmail" 9921 9922 // TypeCanonicalUser is a Type enum value 9923 TypeCanonicalUser = "CanonicalUser" 9924 9925 // TypeGroup is a Type enum value 9926 TypeGroup = "Group" 9927) 9928 9929// Type_Values returns all elements of the Type enum 9930func Type_Values() []string { 9931 return []string{ 9932 TypeAmazonCustomerByEmail, 9933 TypeCanonicalUser, 9934 TypeGroup, 9935 } 9936} 9937