1// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT. 2 3package transfer 4 5import ( 6 "fmt" 7 "time" 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/jsonrpc" 14) 15 16const opCreateServer = "CreateServer" 17 18// CreateServerRequest generates a "aws/request.Request" representing the 19// client's request for the CreateServer 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 CreateServer for more information on using the CreateServer 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 CreateServerRequest method. 34// req, resp := client.CreateServerRequest(params) 35// 36// err := req.Send() 37// if err == nil { // resp is now filled 38// fmt.Println(resp) 39// } 40// 41// See also, https://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/CreateServer 42func (c *Transfer) CreateServerRequest(input *CreateServerInput) (req *request.Request, output *CreateServerOutput) { 43 op := &request.Operation{ 44 Name: opCreateServer, 45 HTTPMethod: "POST", 46 HTTPPath: "/", 47 } 48 49 if input == nil { 50 input = &CreateServerInput{} 51 } 52 53 output = &CreateServerOutput{} 54 req = c.newRequest(op, input, output) 55 return 56} 57 58// CreateServer API operation for AWS Transfer Family. 59// 60// Instantiates an autoscaling virtual server based on the selected file transfer 61// protocol in AWS. When you make updates to your file transfer protocol-enabled 62// server or when you work with users, use the service-generated ServerId property 63// that is assigned to the newly created server. 64// 65// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 66// with awserr.Error's Code and Message methods to get detailed information about 67// the error. 68// 69// See the AWS API reference guide for AWS Transfer Family's 70// API operation CreateServer for usage and error information. 71// 72// Returned Error Types: 73// * AccessDeniedException 74// You do not have sufficient access to perform this action. 75// 76// * ServiceUnavailableException 77// The request has failed because the AWS Transfer Family service is not available. 78// 79// * InternalServiceError 80// This exception is thrown when an error occurs in the AWS Transfer Family 81// service. 82// 83// * InvalidRequestException 84// This exception is thrown when the client submits a malformed request. 85// 86// * ResourceExistsException 87// The requested resource does not exist. 88// 89// * ThrottlingException 90// The request was denied due to request throttling. 91// 92// HTTP Status Code: 400 93// 94// See also, https://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/CreateServer 95func (c *Transfer) CreateServer(input *CreateServerInput) (*CreateServerOutput, error) { 96 req, out := c.CreateServerRequest(input) 97 return out, req.Send() 98} 99 100// CreateServerWithContext is the same as CreateServer with the addition of 101// the ability to pass a context and additional request options. 102// 103// See CreateServer for details on how to use this API operation. 104// 105// The context must be non-nil and will be used for request cancellation. If 106// the context is nil a panic will occur. In the future the SDK may create 107// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 108// for more information on using Contexts. 109func (c *Transfer) CreateServerWithContext(ctx aws.Context, input *CreateServerInput, opts ...request.Option) (*CreateServerOutput, error) { 110 req, out := c.CreateServerRequest(input) 111 req.SetContext(ctx) 112 req.ApplyOptions(opts...) 113 return out, req.Send() 114} 115 116const opCreateUser = "CreateUser" 117 118// CreateUserRequest generates a "aws/request.Request" representing the 119// client's request for the CreateUser operation. The "output" return 120// value will be populated with the request's response once the request completes 121// successfully. 122// 123// Use "Send" method on the returned Request to send the API call to the service. 124// the "output" return value is not valid until after Send returns without error. 125// 126// See CreateUser for more information on using the CreateUser 127// API call, and error handling. 128// 129// This method is useful when you want to inject custom logic or configuration 130// into the SDK's request lifecycle. Such as custom headers, or retry logic. 131// 132// 133// // Example sending a request using the CreateUserRequest method. 134// req, resp := client.CreateUserRequest(params) 135// 136// err := req.Send() 137// if err == nil { // resp is now filled 138// fmt.Println(resp) 139// } 140// 141// See also, https://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/CreateUser 142func (c *Transfer) CreateUserRequest(input *CreateUserInput) (req *request.Request, output *CreateUserOutput) { 143 op := &request.Operation{ 144 Name: opCreateUser, 145 HTTPMethod: "POST", 146 HTTPPath: "/", 147 } 148 149 if input == nil { 150 input = &CreateUserInput{} 151 } 152 153 output = &CreateUserOutput{} 154 req = c.newRequest(op, input, output) 155 return 156} 157 158// CreateUser API operation for AWS Transfer Family. 159// 160// Creates a user and associates them with an existing file transfer protocol-enabled 161// server. You can only create and associate users with servers that have the 162// IdentityProviderType set to SERVICE_MANAGED. Using parameters for CreateUser, 163// you can specify the user name, set the home directory, store the user's public 164// key, and assign the user's AWS Identity and Access Management (IAM) role. 165// You can also optionally add a scope-down policy, and assign metadata with 166// tags that can be used to group and search for users. 167// 168// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 169// with awserr.Error's Code and Message methods to get detailed information about 170// the error. 171// 172// See the AWS API reference guide for AWS Transfer Family's 173// API operation CreateUser for usage and error information. 174// 175// Returned Error Types: 176// * ServiceUnavailableException 177// The request has failed because the AWS Transfer Family service is not available. 178// 179// * InternalServiceError 180// This exception is thrown when an error occurs in the AWS Transfer Family 181// service. 182// 183// * InvalidRequestException 184// This exception is thrown when the client submits a malformed request. 185// 186// * ResourceExistsException 187// The requested resource does not exist. 188// 189// * ResourceNotFoundException 190// This exception is thrown when a resource is not found by the AWS Transfer 191// Family service. 192// 193// See also, https://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/CreateUser 194func (c *Transfer) CreateUser(input *CreateUserInput) (*CreateUserOutput, error) { 195 req, out := c.CreateUserRequest(input) 196 return out, req.Send() 197} 198 199// CreateUserWithContext is the same as CreateUser with the addition of 200// the ability to pass a context and additional request options. 201// 202// See CreateUser for details on how to use this API operation. 203// 204// The context must be non-nil and will be used for request cancellation. If 205// the context is nil a panic will occur. In the future the SDK may create 206// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 207// for more information on using Contexts. 208func (c *Transfer) CreateUserWithContext(ctx aws.Context, input *CreateUserInput, opts ...request.Option) (*CreateUserOutput, error) { 209 req, out := c.CreateUserRequest(input) 210 req.SetContext(ctx) 211 req.ApplyOptions(opts...) 212 return out, req.Send() 213} 214 215const opDeleteServer = "DeleteServer" 216 217// DeleteServerRequest generates a "aws/request.Request" representing the 218// client's request for the DeleteServer operation. The "output" return 219// value will be populated with the request's response once the request completes 220// successfully. 221// 222// Use "Send" method on the returned Request to send the API call to the service. 223// the "output" return value is not valid until after Send returns without error. 224// 225// See DeleteServer for more information on using the DeleteServer 226// API call, and error handling. 227// 228// This method is useful when you want to inject custom logic or configuration 229// into the SDK's request lifecycle. Such as custom headers, or retry logic. 230// 231// 232// // Example sending a request using the DeleteServerRequest method. 233// req, resp := client.DeleteServerRequest(params) 234// 235// err := req.Send() 236// if err == nil { // resp is now filled 237// fmt.Println(resp) 238// } 239// 240// See also, https://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/DeleteServer 241func (c *Transfer) DeleteServerRequest(input *DeleteServerInput) (req *request.Request, output *DeleteServerOutput) { 242 op := &request.Operation{ 243 Name: opDeleteServer, 244 HTTPMethod: "POST", 245 HTTPPath: "/", 246 } 247 248 if input == nil { 249 input = &DeleteServerInput{} 250 } 251 252 output = &DeleteServerOutput{} 253 req = c.newRequest(op, input, output) 254 req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 255 return 256} 257 258// DeleteServer API operation for AWS Transfer Family. 259// 260// Deletes the file transfer protocol-enabled server that you specify. 261// 262// No response returns from this operation. 263// 264// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 265// with awserr.Error's Code and Message methods to get detailed information about 266// the error. 267// 268// See the AWS API reference guide for AWS Transfer Family's 269// API operation DeleteServer for usage and error information. 270// 271// Returned Error Types: 272// * AccessDeniedException 273// You do not have sufficient access to perform this action. 274// 275// * ServiceUnavailableException 276// The request has failed because the AWS Transfer Family service is not available. 277// 278// * InternalServiceError 279// This exception is thrown when an error occurs in the AWS Transfer Family 280// service. 281// 282// * InvalidRequestException 283// This exception is thrown when the client submits a malformed request. 284// 285// * ResourceNotFoundException 286// This exception is thrown when a resource is not found by the AWS Transfer 287// Family service. 288// 289// See also, https://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/DeleteServer 290func (c *Transfer) DeleteServer(input *DeleteServerInput) (*DeleteServerOutput, error) { 291 req, out := c.DeleteServerRequest(input) 292 return out, req.Send() 293} 294 295// DeleteServerWithContext is the same as DeleteServer with the addition of 296// the ability to pass a context and additional request options. 297// 298// See DeleteServer for details on how to use this API operation. 299// 300// The context must be non-nil and will be used for request cancellation. If 301// the context is nil a panic will occur. In the future the SDK may create 302// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 303// for more information on using Contexts. 304func (c *Transfer) DeleteServerWithContext(ctx aws.Context, input *DeleteServerInput, opts ...request.Option) (*DeleteServerOutput, error) { 305 req, out := c.DeleteServerRequest(input) 306 req.SetContext(ctx) 307 req.ApplyOptions(opts...) 308 return out, req.Send() 309} 310 311const opDeleteSshPublicKey = "DeleteSshPublicKey" 312 313// DeleteSshPublicKeyRequest generates a "aws/request.Request" representing the 314// client's request for the DeleteSshPublicKey operation. The "output" return 315// value will be populated with the request's response once the request completes 316// successfully. 317// 318// Use "Send" method on the returned Request to send the API call to the service. 319// the "output" return value is not valid until after Send returns without error. 320// 321// See DeleteSshPublicKey for more information on using the DeleteSshPublicKey 322// API call, and error handling. 323// 324// This method is useful when you want to inject custom logic or configuration 325// into the SDK's request lifecycle. Such as custom headers, or retry logic. 326// 327// 328// // Example sending a request using the DeleteSshPublicKeyRequest method. 329// req, resp := client.DeleteSshPublicKeyRequest(params) 330// 331// err := req.Send() 332// if err == nil { // resp is now filled 333// fmt.Println(resp) 334// } 335// 336// See also, https://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/DeleteSshPublicKey 337func (c *Transfer) DeleteSshPublicKeyRequest(input *DeleteSshPublicKeyInput) (req *request.Request, output *DeleteSshPublicKeyOutput) { 338 op := &request.Operation{ 339 Name: opDeleteSshPublicKey, 340 HTTPMethod: "POST", 341 HTTPPath: "/", 342 } 343 344 if input == nil { 345 input = &DeleteSshPublicKeyInput{} 346 } 347 348 output = &DeleteSshPublicKeyOutput{} 349 req = c.newRequest(op, input, output) 350 req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 351 return 352} 353 354// DeleteSshPublicKey API operation for AWS Transfer Family. 355// 356// Deletes a user's Secure Shell (SSH) public key. 357// 358// No response is returned from this operation. 359// 360// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 361// with awserr.Error's Code and Message methods to get detailed information about 362// the error. 363// 364// See the AWS API reference guide for AWS Transfer Family's 365// API operation DeleteSshPublicKey for usage and error information. 366// 367// Returned Error Types: 368// * ServiceUnavailableException 369// The request has failed because the AWS Transfer Family service is not available. 370// 371// * InternalServiceError 372// This exception is thrown when an error occurs in the AWS Transfer Family 373// service. 374// 375// * InvalidRequestException 376// This exception is thrown when the client submits a malformed request. 377// 378// * ResourceNotFoundException 379// This exception is thrown when a resource is not found by the AWS Transfer 380// Family service. 381// 382// * ThrottlingException 383// The request was denied due to request throttling. 384// 385// HTTP Status Code: 400 386// 387// See also, https://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/DeleteSshPublicKey 388func (c *Transfer) DeleteSshPublicKey(input *DeleteSshPublicKeyInput) (*DeleteSshPublicKeyOutput, error) { 389 req, out := c.DeleteSshPublicKeyRequest(input) 390 return out, req.Send() 391} 392 393// DeleteSshPublicKeyWithContext is the same as DeleteSshPublicKey with the addition of 394// the ability to pass a context and additional request options. 395// 396// See DeleteSshPublicKey for details on how to use this API operation. 397// 398// The context must be non-nil and will be used for request cancellation. If 399// the context is nil a panic will occur. In the future the SDK may create 400// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 401// for more information on using Contexts. 402func (c *Transfer) DeleteSshPublicKeyWithContext(ctx aws.Context, input *DeleteSshPublicKeyInput, opts ...request.Option) (*DeleteSshPublicKeyOutput, error) { 403 req, out := c.DeleteSshPublicKeyRequest(input) 404 req.SetContext(ctx) 405 req.ApplyOptions(opts...) 406 return out, req.Send() 407} 408 409const opDeleteUser = "DeleteUser" 410 411// DeleteUserRequest generates a "aws/request.Request" representing the 412// client's request for the DeleteUser operation. The "output" return 413// value will be populated with the request's response once the request completes 414// successfully. 415// 416// Use "Send" method on the returned Request to send the API call to the service. 417// the "output" return value is not valid until after Send returns without error. 418// 419// See DeleteUser for more information on using the DeleteUser 420// API call, and error handling. 421// 422// This method is useful when you want to inject custom logic or configuration 423// into the SDK's request lifecycle. Such as custom headers, or retry logic. 424// 425// 426// // Example sending a request using the DeleteUserRequest method. 427// req, resp := client.DeleteUserRequest(params) 428// 429// err := req.Send() 430// if err == nil { // resp is now filled 431// fmt.Println(resp) 432// } 433// 434// See also, https://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/DeleteUser 435func (c *Transfer) DeleteUserRequest(input *DeleteUserInput) (req *request.Request, output *DeleteUserOutput) { 436 op := &request.Operation{ 437 Name: opDeleteUser, 438 HTTPMethod: "POST", 439 HTTPPath: "/", 440 } 441 442 if input == nil { 443 input = &DeleteUserInput{} 444 } 445 446 output = &DeleteUserOutput{} 447 req = c.newRequest(op, input, output) 448 req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 449 return 450} 451 452// DeleteUser API operation for AWS Transfer Family. 453// 454// Deletes the user belonging to a file transfer protocol-enabled server you 455// specify. 456// 457// No response returns from this operation. 458// 459// When you delete a user from a server, the user's information is lost. 460// 461// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 462// with awserr.Error's Code and Message methods to get detailed information about 463// the error. 464// 465// See the AWS API reference guide for AWS Transfer Family's 466// API operation DeleteUser for usage and error information. 467// 468// Returned Error Types: 469// * ServiceUnavailableException 470// The request has failed because the AWS Transfer Family service is not available. 471// 472// * InternalServiceError 473// This exception is thrown when an error occurs in the AWS Transfer Family 474// service. 475// 476// * InvalidRequestException 477// This exception is thrown when the client submits a malformed request. 478// 479// * ResourceNotFoundException 480// This exception is thrown when a resource is not found by the AWS Transfer 481// Family service. 482// 483// See also, https://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/DeleteUser 484func (c *Transfer) DeleteUser(input *DeleteUserInput) (*DeleteUserOutput, error) { 485 req, out := c.DeleteUserRequest(input) 486 return out, req.Send() 487} 488 489// DeleteUserWithContext is the same as DeleteUser with the addition of 490// the ability to pass a context and additional request options. 491// 492// See DeleteUser for details on how to use this API operation. 493// 494// The context must be non-nil and will be used for request cancellation. If 495// the context is nil a panic will occur. In the future the SDK may create 496// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 497// for more information on using Contexts. 498func (c *Transfer) DeleteUserWithContext(ctx aws.Context, input *DeleteUserInput, opts ...request.Option) (*DeleteUserOutput, error) { 499 req, out := c.DeleteUserRequest(input) 500 req.SetContext(ctx) 501 req.ApplyOptions(opts...) 502 return out, req.Send() 503} 504 505const opDescribeSecurityPolicy = "DescribeSecurityPolicy" 506 507// DescribeSecurityPolicyRequest generates a "aws/request.Request" representing the 508// client's request for the DescribeSecurityPolicy operation. The "output" return 509// value will be populated with the request's response once the request completes 510// successfully. 511// 512// Use "Send" method on the returned Request to send the API call to the service. 513// the "output" return value is not valid until after Send returns without error. 514// 515// See DescribeSecurityPolicy for more information on using the DescribeSecurityPolicy 516// API call, and error handling. 517// 518// This method is useful when you want to inject custom logic or configuration 519// into the SDK's request lifecycle. Such as custom headers, or retry logic. 520// 521// 522// // Example sending a request using the DescribeSecurityPolicyRequest method. 523// req, resp := client.DescribeSecurityPolicyRequest(params) 524// 525// err := req.Send() 526// if err == nil { // resp is now filled 527// fmt.Println(resp) 528// } 529// 530// See also, https://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/DescribeSecurityPolicy 531func (c *Transfer) DescribeSecurityPolicyRequest(input *DescribeSecurityPolicyInput) (req *request.Request, output *DescribeSecurityPolicyOutput) { 532 op := &request.Operation{ 533 Name: opDescribeSecurityPolicy, 534 HTTPMethod: "POST", 535 HTTPPath: "/", 536 } 537 538 if input == nil { 539 input = &DescribeSecurityPolicyInput{} 540 } 541 542 output = &DescribeSecurityPolicyOutput{} 543 req = c.newRequest(op, input, output) 544 return 545} 546 547// DescribeSecurityPolicy API operation for AWS Transfer Family. 548// 549// Describes the security policy that is attached to your file transfer protocol-enabled 550// server. The response contains a description of the security policy's properties. 551// For more information about security policies, see Working with security policies 552// (https://docs.aws.amazon.com/transfer/latest/userguide/security-policies.html). 553// 554// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 555// with awserr.Error's Code and Message methods to get detailed information about 556// the error. 557// 558// See the AWS API reference guide for AWS Transfer Family's 559// API operation DescribeSecurityPolicy for usage and error information. 560// 561// Returned Error Types: 562// * ServiceUnavailableException 563// The request has failed because the AWS Transfer Family service is not available. 564// 565// * InternalServiceError 566// This exception is thrown when an error occurs in the AWS Transfer Family 567// service. 568// 569// * InvalidRequestException 570// This exception is thrown when the client submits a malformed request. 571// 572// * ResourceNotFoundException 573// This exception is thrown when a resource is not found by the AWS Transfer 574// Family service. 575// 576// See also, https://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/DescribeSecurityPolicy 577func (c *Transfer) DescribeSecurityPolicy(input *DescribeSecurityPolicyInput) (*DescribeSecurityPolicyOutput, error) { 578 req, out := c.DescribeSecurityPolicyRequest(input) 579 return out, req.Send() 580} 581 582// DescribeSecurityPolicyWithContext is the same as DescribeSecurityPolicy with the addition of 583// the ability to pass a context and additional request options. 584// 585// See DescribeSecurityPolicy for details on how to use this API operation. 586// 587// The context must be non-nil and will be used for request cancellation. If 588// the context is nil a panic will occur. In the future the SDK may create 589// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 590// for more information on using Contexts. 591func (c *Transfer) DescribeSecurityPolicyWithContext(ctx aws.Context, input *DescribeSecurityPolicyInput, opts ...request.Option) (*DescribeSecurityPolicyOutput, error) { 592 req, out := c.DescribeSecurityPolicyRequest(input) 593 req.SetContext(ctx) 594 req.ApplyOptions(opts...) 595 return out, req.Send() 596} 597 598const opDescribeServer = "DescribeServer" 599 600// DescribeServerRequest generates a "aws/request.Request" representing the 601// client's request for the DescribeServer operation. The "output" return 602// value will be populated with the request's response once the request completes 603// successfully. 604// 605// Use "Send" method on the returned Request to send the API call to the service. 606// the "output" return value is not valid until after Send returns without error. 607// 608// See DescribeServer for more information on using the DescribeServer 609// API call, and error handling. 610// 611// This method is useful when you want to inject custom logic or configuration 612// into the SDK's request lifecycle. Such as custom headers, or retry logic. 613// 614// 615// // Example sending a request using the DescribeServerRequest method. 616// req, resp := client.DescribeServerRequest(params) 617// 618// err := req.Send() 619// if err == nil { // resp is now filled 620// fmt.Println(resp) 621// } 622// 623// See also, https://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/DescribeServer 624func (c *Transfer) DescribeServerRequest(input *DescribeServerInput) (req *request.Request, output *DescribeServerOutput) { 625 op := &request.Operation{ 626 Name: opDescribeServer, 627 HTTPMethod: "POST", 628 HTTPPath: "/", 629 } 630 631 if input == nil { 632 input = &DescribeServerInput{} 633 } 634 635 output = &DescribeServerOutput{} 636 req = c.newRequest(op, input, output) 637 return 638} 639 640// DescribeServer API operation for AWS Transfer Family. 641// 642// Describes a file transfer protocol-enabled server that you specify by passing 643// the ServerId parameter. 644// 645// The response contains a description of a server's properties. When you set 646// EndpointType to VPC, the response will contain the EndpointDetails. 647// 648// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 649// with awserr.Error's Code and Message methods to get detailed information about 650// the error. 651// 652// See the AWS API reference guide for AWS Transfer Family's 653// API operation DescribeServer for usage and error information. 654// 655// Returned Error Types: 656// * ServiceUnavailableException 657// The request has failed because the AWS Transfer Family service is not available. 658// 659// * InternalServiceError 660// This exception is thrown when an error occurs in the AWS Transfer Family 661// service. 662// 663// * InvalidRequestException 664// This exception is thrown when the client submits a malformed request. 665// 666// * ResourceNotFoundException 667// This exception is thrown when a resource is not found by the AWS Transfer 668// Family service. 669// 670// See also, https://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/DescribeServer 671func (c *Transfer) DescribeServer(input *DescribeServerInput) (*DescribeServerOutput, error) { 672 req, out := c.DescribeServerRequest(input) 673 return out, req.Send() 674} 675 676// DescribeServerWithContext is the same as DescribeServer with the addition of 677// the ability to pass a context and additional request options. 678// 679// See DescribeServer for details on how to use this API operation. 680// 681// The context must be non-nil and will be used for request cancellation. If 682// the context is nil a panic will occur. In the future the SDK may create 683// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 684// for more information on using Contexts. 685func (c *Transfer) DescribeServerWithContext(ctx aws.Context, input *DescribeServerInput, opts ...request.Option) (*DescribeServerOutput, error) { 686 req, out := c.DescribeServerRequest(input) 687 req.SetContext(ctx) 688 req.ApplyOptions(opts...) 689 return out, req.Send() 690} 691 692const opDescribeUser = "DescribeUser" 693 694// DescribeUserRequest generates a "aws/request.Request" representing the 695// client's request for the DescribeUser operation. The "output" return 696// value will be populated with the request's response once the request completes 697// successfully. 698// 699// Use "Send" method on the returned Request to send the API call to the service. 700// the "output" return value is not valid until after Send returns without error. 701// 702// See DescribeUser for more information on using the DescribeUser 703// API call, and error handling. 704// 705// This method is useful when you want to inject custom logic or configuration 706// into the SDK's request lifecycle. Such as custom headers, or retry logic. 707// 708// 709// // Example sending a request using the DescribeUserRequest method. 710// req, resp := client.DescribeUserRequest(params) 711// 712// err := req.Send() 713// if err == nil { // resp is now filled 714// fmt.Println(resp) 715// } 716// 717// See also, https://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/DescribeUser 718func (c *Transfer) DescribeUserRequest(input *DescribeUserInput) (req *request.Request, output *DescribeUserOutput) { 719 op := &request.Operation{ 720 Name: opDescribeUser, 721 HTTPMethod: "POST", 722 HTTPPath: "/", 723 } 724 725 if input == nil { 726 input = &DescribeUserInput{} 727 } 728 729 output = &DescribeUserOutput{} 730 req = c.newRequest(op, input, output) 731 return 732} 733 734// DescribeUser API operation for AWS Transfer Family. 735// 736// Describes the user assigned to the specific file transfer protocol-enabled 737// server, as identified by its ServerId property. 738// 739// The response from this call returns the properties of the user associated 740// with the ServerId value that was specified. 741// 742// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 743// with awserr.Error's Code and Message methods to get detailed information about 744// the error. 745// 746// See the AWS API reference guide for AWS Transfer Family's 747// API operation DescribeUser for usage and error information. 748// 749// Returned Error Types: 750// * ServiceUnavailableException 751// The request has failed because the AWS Transfer Family service is not available. 752// 753// * InternalServiceError 754// This exception is thrown when an error occurs in the AWS Transfer Family 755// service. 756// 757// * InvalidRequestException 758// This exception is thrown when the client submits a malformed request. 759// 760// * ResourceNotFoundException 761// This exception is thrown when a resource is not found by the AWS Transfer 762// Family service. 763// 764// See also, https://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/DescribeUser 765func (c *Transfer) DescribeUser(input *DescribeUserInput) (*DescribeUserOutput, error) { 766 req, out := c.DescribeUserRequest(input) 767 return out, req.Send() 768} 769 770// DescribeUserWithContext is the same as DescribeUser with the addition of 771// the ability to pass a context and additional request options. 772// 773// See DescribeUser for details on how to use this API operation. 774// 775// The context must be non-nil and will be used for request cancellation. If 776// the context is nil a panic will occur. In the future the SDK may create 777// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 778// for more information on using Contexts. 779func (c *Transfer) DescribeUserWithContext(ctx aws.Context, input *DescribeUserInput, opts ...request.Option) (*DescribeUserOutput, error) { 780 req, out := c.DescribeUserRequest(input) 781 req.SetContext(ctx) 782 req.ApplyOptions(opts...) 783 return out, req.Send() 784} 785 786const opImportSshPublicKey = "ImportSshPublicKey" 787 788// ImportSshPublicKeyRequest generates a "aws/request.Request" representing the 789// client's request for the ImportSshPublicKey operation. The "output" return 790// value will be populated with the request's response once the request completes 791// successfully. 792// 793// Use "Send" method on the returned Request to send the API call to the service. 794// the "output" return value is not valid until after Send returns without error. 795// 796// See ImportSshPublicKey for more information on using the ImportSshPublicKey 797// API call, and error handling. 798// 799// This method is useful when you want to inject custom logic or configuration 800// into the SDK's request lifecycle. Such as custom headers, or retry logic. 801// 802// 803// // Example sending a request using the ImportSshPublicKeyRequest method. 804// req, resp := client.ImportSshPublicKeyRequest(params) 805// 806// err := req.Send() 807// if err == nil { // resp is now filled 808// fmt.Println(resp) 809// } 810// 811// See also, https://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/ImportSshPublicKey 812func (c *Transfer) ImportSshPublicKeyRequest(input *ImportSshPublicKeyInput) (req *request.Request, output *ImportSshPublicKeyOutput) { 813 op := &request.Operation{ 814 Name: opImportSshPublicKey, 815 HTTPMethod: "POST", 816 HTTPPath: "/", 817 } 818 819 if input == nil { 820 input = &ImportSshPublicKeyInput{} 821 } 822 823 output = &ImportSshPublicKeyOutput{} 824 req = c.newRequest(op, input, output) 825 return 826} 827 828// ImportSshPublicKey API operation for AWS Transfer Family. 829// 830// Adds a Secure Shell (SSH) public key to a user account identified by a UserName 831// value assigned to the specific file transfer protocol-enabled server, identified 832// by ServerId. 833// 834// The response returns the UserName value, the ServerId value, and the name 835// of the SshPublicKeyId. 836// 837// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 838// with awserr.Error's Code and Message methods to get detailed information about 839// the error. 840// 841// See the AWS API reference guide for AWS Transfer Family's 842// API operation ImportSshPublicKey for usage and error information. 843// 844// Returned Error Types: 845// * ServiceUnavailableException 846// The request has failed because the AWS Transfer Family service is not available. 847// 848// * InternalServiceError 849// This exception is thrown when an error occurs in the AWS Transfer Family 850// service. 851// 852// * InvalidRequestException 853// This exception is thrown when the client submits a malformed request. 854// 855// * ResourceExistsException 856// The requested resource does not exist. 857// 858// * ResourceNotFoundException 859// This exception is thrown when a resource is not found by the AWS Transfer 860// Family service. 861// 862// * ThrottlingException 863// The request was denied due to request throttling. 864// 865// HTTP Status Code: 400 866// 867// See also, https://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/ImportSshPublicKey 868func (c *Transfer) ImportSshPublicKey(input *ImportSshPublicKeyInput) (*ImportSshPublicKeyOutput, error) { 869 req, out := c.ImportSshPublicKeyRequest(input) 870 return out, req.Send() 871} 872 873// ImportSshPublicKeyWithContext is the same as ImportSshPublicKey with the addition of 874// the ability to pass a context and additional request options. 875// 876// See ImportSshPublicKey for details on how to use this API operation. 877// 878// The context must be non-nil and will be used for request cancellation. If 879// the context is nil a panic will occur. In the future the SDK may create 880// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 881// for more information on using Contexts. 882func (c *Transfer) ImportSshPublicKeyWithContext(ctx aws.Context, input *ImportSshPublicKeyInput, opts ...request.Option) (*ImportSshPublicKeyOutput, error) { 883 req, out := c.ImportSshPublicKeyRequest(input) 884 req.SetContext(ctx) 885 req.ApplyOptions(opts...) 886 return out, req.Send() 887} 888 889const opListSecurityPolicies = "ListSecurityPolicies" 890 891// ListSecurityPoliciesRequest generates a "aws/request.Request" representing the 892// client's request for the ListSecurityPolicies operation. The "output" return 893// value will be populated with the request's response once the request completes 894// successfully. 895// 896// Use "Send" method on the returned Request to send the API call to the service. 897// the "output" return value is not valid until after Send returns without error. 898// 899// See ListSecurityPolicies for more information on using the ListSecurityPolicies 900// API call, and error handling. 901// 902// This method is useful when you want to inject custom logic or configuration 903// into the SDK's request lifecycle. Such as custom headers, or retry logic. 904// 905// 906// // Example sending a request using the ListSecurityPoliciesRequest method. 907// req, resp := client.ListSecurityPoliciesRequest(params) 908// 909// err := req.Send() 910// if err == nil { // resp is now filled 911// fmt.Println(resp) 912// } 913// 914// See also, https://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/ListSecurityPolicies 915func (c *Transfer) ListSecurityPoliciesRequest(input *ListSecurityPoliciesInput) (req *request.Request, output *ListSecurityPoliciesOutput) { 916 op := &request.Operation{ 917 Name: opListSecurityPolicies, 918 HTTPMethod: "POST", 919 HTTPPath: "/", 920 Paginator: &request.Paginator{ 921 InputTokens: []string{"NextToken"}, 922 OutputTokens: []string{"NextToken"}, 923 LimitToken: "MaxResults", 924 TruncationToken: "", 925 }, 926 } 927 928 if input == nil { 929 input = &ListSecurityPoliciesInput{} 930 } 931 932 output = &ListSecurityPoliciesOutput{} 933 req = c.newRequest(op, input, output) 934 return 935} 936 937// ListSecurityPolicies API operation for AWS Transfer Family. 938// 939// Lists the security policies that are attached to your file transfer protocol-enabled 940// servers. 941// 942// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 943// with awserr.Error's Code and Message methods to get detailed information about 944// the error. 945// 946// See the AWS API reference guide for AWS Transfer Family's 947// API operation ListSecurityPolicies for usage and error information. 948// 949// Returned Error Types: 950// * ServiceUnavailableException 951// The request has failed because the AWS Transfer Family service is not available. 952// 953// * InternalServiceError 954// This exception is thrown when an error occurs in the AWS Transfer Family 955// service. 956// 957// * InvalidNextTokenException 958// The NextToken parameter that was passed is invalid. 959// 960// * InvalidRequestException 961// This exception is thrown when the client submits a malformed request. 962// 963// See also, https://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/ListSecurityPolicies 964func (c *Transfer) ListSecurityPolicies(input *ListSecurityPoliciesInput) (*ListSecurityPoliciesOutput, error) { 965 req, out := c.ListSecurityPoliciesRequest(input) 966 return out, req.Send() 967} 968 969// ListSecurityPoliciesWithContext is the same as ListSecurityPolicies with the addition of 970// the ability to pass a context and additional request options. 971// 972// See ListSecurityPolicies for details on how to use this API operation. 973// 974// The context must be non-nil and will be used for request cancellation. If 975// the context is nil a panic will occur. In the future the SDK may create 976// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 977// for more information on using Contexts. 978func (c *Transfer) ListSecurityPoliciesWithContext(ctx aws.Context, input *ListSecurityPoliciesInput, opts ...request.Option) (*ListSecurityPoliciesOutput, error) { 979 req, out := c.ListSecurityPoliciesRequest(input) 980 req.SetContext(ctx) 981 req.ApplyOptions(opts...) 982 return out, req.Send() 983} 984 985// ListSecurityPoliciesPages iterates over the pages of a ListSecurityPolicies operation, 986// calling the "fn" function with the response data for each page. To stop 987// iterating, return false from the fn function. 988// 989// See ListSecurityPolicies method for more information on how to use this operation. 990// 991// Note: This operation can generate multiple requests to a service. 992// 993// // Example iterating over at most 3 pages of a ListSecurityPolicies operation. 994// pageNum := 0 995// err := client.ListSecurityPoliciesPages(params, 996// func(page *transfer.ListSecurityPoliciesOutput, lastPage bool) bool { 997// pageNum++ 998// fmt.Println(page) 999// return pageNum <= 3 1000// }) 1001// 1002func (c *Transfer) ListSecurityPoliciesPages(input *ListSecurityPoliciesInput, fn func(*ListSecurityPoliciesOutput, bool) bool) error { 1003 return c.ListSecurityPoliciesPagesWithContext(aws.BackgroundContext(), input, fn) 1004} 1005 1006// ListSecurityPoliciesPagesWithContext same as ListSecurityPoliciesPages except 1007// it takes a Context and allows setting request options on the pages. 1008// 1009// The context must be non-nil and will be used for request cancellation. If 1010// the context is nil a panic will occur. In the future the SDK may create 1011// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1012// for more information on using Contexts. 1013func (c *Transfer) ListSecurityPoliciesPagesWithContext(ctx aws.Context, input *ListSecurityPoliciesInput, fn func(*ListSecurityPoliciesOutput, bool) bool, opts ...request.Option) error { 1014 p := request.Pagination{ 1015 NewRequest: func() (*request.Request, error) { 1016 var inCpy *ListSecurityPoliciesInput 1017 if input != nil { 1018 tmp := *input 1019 inCpy = &tmp 1020 } 1021 req, _ := c.ListSecurityPoliciesRequest(inCpy) 1022 req.SetContext(ctx) 1023 req.ApplyOptions(opts...) 1024 return req, nil 1025 }, 1026 } 1027 1028 for p.Next() { 1029 if !fn(p.Page().(*ListSecurityPoliciesOutput), !p.HasNextPage()) { 1030 break 1031 } 1032 } 1033 1034 return p.Err() 1035} 1036 1037const opListServers = "ListServers" 1038 1039// ListServersRequest generates a "aws/request.Request" representing the 1040// client's request for the ListServers operation. The "output" return 1041// value will be populated with the request's response once the request completes 1042// successfully. 1043// 1044// Use "Send" method on the returned Request to send the API call to the service. 1045// the "output" return value is not valid until after Send returns without error. 1046// 1047// See ListServers for more information on using the ListServers 1048// API call, and error handling. 1049// 1050// This method is useful when you want to inject custom logic or configuration 1051// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1052// 1053// 1054// // Example sending a request using the ListServersRequest method. 1055// req, resp := client.ListServersRequest(params) 1056// 1057// err := req.Send() 1058// if err == nil { // resp is now filled 1059// fmt.Println(resp) 1060// } 1061// 1062// See also, https://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/ListServers 1063func (c *Transfer) ListServersRequest(input *ListServersInput) (req *request.Request, output *ListServersOutput) { 1064 op := &request.Operation{ 1065 Name: opListServers, 1066 HTTPMethod: "POST", 1067 HTTPPath: "/", 1068 Paginator: &request.Paginator{ 1069 InputTokens: []string{"NextToken"}, 1070 OutputTokens: []string{"NextToken"}, 1071 LimitToken: "MaxResults", 1072 TruncationToken: "", 1073 }, 1074 } 1075 1076 if input == nil { 1077 input = &ListServersInput{} 1078 } 1079 1080 output = &ListServersOutput{} 1081 req = c.newRequest(op, input, output) 1082 return 1083} 1084 1085// ListServers API operation for AWS Transfer Family. 1086// 1087// Lists the file transfer protocol-enabled servers that are associated with 1088// your AWS account. 1089// 1090// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1091// with awserr.Error's Code and Message methods to get detailed information about 1092// the error. 1093// 1094// See the AWS API reference guide for AWS Transfer Family's 1095// API operation ListServers for usage and error information. 1096// 1097// Returned Error Types: 1098// * ServiceUnavailableException 1099// The request has failed because the AWS Transfer Family service is not available. 1100// 1101// * InternalServiceError 1102// This exception is thrown when an error occurs in the AWS Transfer Family 1103// service. 1104// 1105// * InvalidNextTokenException 1106// The NextToken parameter that was passed is invalid. 1107// 1108// * InvalidRequestException 1109// This exception is thrown when the client submits a malformed request. 1110// 1111// See also, https://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/ListServers 1112func (c *Transfer) ListServers(input *ListServersInput) (*ListServersOutput, error) { 1113 req, out := c.ListServersRequest(input) 1114 return out, req.Send() 1115} 1116 1117// ListServersWithContext is the same as ListServers with the addition of 1118// the ability to pass a context and additional request options. 1119// 1120// See ListServers for details on how to use this API operation. 1121// 1122// The context must be non-nil and will be used for request cancellation. If 1123// the context is nil a panic will occur. In the future the SDK may create 1124// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1125// for more information on using Contexts. 1126func (c *Transfer) ListServersWithContext(ctx aws.Context, input *ListServersInput, opts ...request.Option) (*ListServersOutput, error) { 1127 req, out := c.ListServersRequest(input) 1128 req.SetContext(ctx) 1129 req.ApplyOptions(opts...) 1130 return out, req.Send() 1131} 1132 1133// ListServersPages iterates over the pages of a ListServers operation, 1134// calling the "fn" function with the response data for each page. To stop 1135// iterating, return false from the fn function. 1136// 1137// See ListServers method for more information on how to use this operation. 1138// 1139// Note: This operation can generate multiple requests to a service. 1140// 1141// // Example iterating over at most 3 pages of a ListServers operation. 1142// pageNum := 0 1143// err := client.ListServersPages(params, 1144// func(page *transfer.ListServersOutput, lastPage bool) bool { 1145// pageNum++ 1146// fmt.Println(page) 1147// return pageNum <= 3 1148// }) 1149// 1150func (c *Transfer) ListServersPages(input *ListServersInput, fn func(*ListServersOutput, bool) bool) error { 1151 return c.ListServersPagesWithContext(aws.BackgroundContext(), input, fn) 1152} 1153 1154// ListServersPagesWithContext same as ListServersPages except 1155// it takes a Context and allows setting request options on the pages. 1156// 1157// The context must be non-nil and will be used for request cancellation. If 1158// the context is nil a panic will occur. In the future the SDK may create 1159// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1160// for more information on using Contexts. 1161func (c *Transfer) ListServersPagesWithContext(ctx aws.Context, input *ListServersInput, fn func(*ListServersOutput, bool) bool, opts ...request.Option) error { 1162 p := request.Pagination{ 1163 NewRequest: func() (*request.Request, error) { 1164 var inCpy *ListServersInput 1165 if input != nil { 1166 tmp := *input 1167 inCpy = &tmp 1168 } 1169 req, _ := c.ListServersRequest(inCpy) 1170 req.SetContext(ctx) 1171 req.ApplyOptions(opts...) 1172 return req, nil 1173 }, 1174 } 1175 1176 for p.Next() { 1177 if !fn(p.Page().(*ListServersOutput), !p.HasNextPage()) { 1178 break 1179 } 1180 } 1181 1182 return p.Err() 1183} 1184 1185const opListTagsForResource = "ListTagsForResource" 1186 1187// ListTagsForResourceRequest generates a "aws/request.Request" representing the 1188// client's request for the ListTagsForResource operation. The "output" return 1189// value will be populated with the request's response once the request completes 1190// successfully. 1191// 1192// Use "Send" method on the returned Request to send the API call to the service. 1193// the "output" return value is not valid until after Send returns without error. 1194// 1195// See ListTagsForResource for more information on using the ListTagsForResource 1196// API call, and error handling. 1197// 1198// This method is useful when you want to inject custom logic or configuration 1199// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1200// 1201// 1202// // Example sending a request using the ListTagsForResourceRequest method. 1203// req, resp := client.ListTagsForResourceRequest(params) 1204// 1205// err := req.Send() 1206// if err == nil { // resp is now filled 1207// fmt.Println(resp) 1208// } 1209// 1210// See also, https://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/ListTagsForResource 1211func (c *Transfer) ListTagsForResourceRequest(input *ListTagsForResourceInput) (req *request.Request, output *ListTagsForResourceOutput) { 1212 op := &request.Operation{ 1213 Name: opListTagsForResource, 1214 HTTPMethod: "POST", 1215 HTTPPath: "/", 1216 Paginator: &request.Paginator{ 1217 InputTokens: []string{"NextToken"}, 1218 OutputTokens: []string{"NextToken"}, 1219 LimitToken: "MaxResults", 1220 TruncationToken: "", 1221 }, 1222 } 1223 1224 if input == nil { 1225 input = &ListTagsForResourceInput{} 1226 } 1227 1228 output = &ListTagsForResourceOutput{} 1229 req = c.newRequest(op, input, output) 1230 return 1231} 1232 1233// ListTagsForResource API operation for AWS Transfer Family. 1234// 1235// Lists all of the tags associated with the Amazon Resource Number (ARN) you 1236// specify. The resource can be a user, server, or role. 1237// 1238// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1239// with awserr.Error's Code and Message methods to get detailed information about 1240// the error. 1241// 1242// See the AWS API reference guide for AWS Transfer Family's 1243// API operation ListTagsForResource for usage and error information. 1244// 1245// Returned Error Types: 1246// * ServiceUnavailableException 1247// The request has failed because the AWS Transfer Family service is not available. 1248// 1249// * InternalServiceError 1250// This exception is thrown when an error occurs in the AWS Transfer Family 1251// service. 1252// 1253// * InvalidNextTokenException 1254// The NextToken parameter that was passed is invalid. 1255// 1256// * InvalidRequestException 1257// This exception is thrown when the client submits a malformed request. 1258// 1259// See also, https://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/ListTagsForResource 1260func (c *Transfer) ListTagsForResource(input *ListTagsForResourceInput) (*ListTagsForResourceOutput, error) { 1261 req, out := c.ListTagsForResourceRequest(input) 1262 return out, req.Send() 1263} 1264 1265// ListTagsForResourceWithContext is the same as ListTagsForResource with the addition of 1266// the ability to pass a context and additional request options. 1267// 1268// See ListTagsForResource for details on how to use this API operation. 1269// 1270// The context must be non-nil and will be used for request cancellation. If 1271// the context is nil a panic will occur. In the future the SDK may create 1272// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1273// for more information on using Contexts. 1274func (c *Transfer) ListTagsForResourceWithContext(ctx aws.Context, input *ListTagsForResourceInput, opts ...request.Option) (*ListTagsForResourceOutput, error) { 1275 req, out := c.ListTagsForResourceRequest(input) 1276 req.SetContext(ctx) 1277 req.ApplyOptions(opts...) 1278 return out, req.Send() 1279} 1280 1281// ListTagsForResourcePages iterates over the pages of a ListTagsForResource operation, 1282// calling the "fn" function with the response data for each page. To stop 1283// iterating, return false from the fn function. 1284// 1285// See ListTagsForResource method for more information on how to use this operation. 1286// 1287// Note: This operation can generate multiple requests to a service. 1288// 1289// // Example iterating over at most 3 pages of a ListTagsForResource operation. 1290// pageNum := 0 1291// err := client.ListTagsForResourcePages(params, 1292// func(page *transfer.ListTagsForResourceOutput, lastPage bool) bool { 1293// pageNum++ 1294// fmt.Println(page) 1295// return pageNum <= 3 1296// }) 1297// 1298func (c *Transfer) ListTagsForResourcePages(input *ListTagsForResourceInput, fn func(*ListTagsForResourceOutput, bool) bool) error { 1299 return c.ListTagsForResourcePagesWithContext(aws.BackgroundContext(), input, fn) 1300} 1301 1302// ListTagsForResourcePagesWithContext same as ListTagsForResourcePages except 1303// it takes a Context and allows setting request options on the pages. 1304// 1305// The context must be non-nil and will be used for request cancellation. If 1306// the context is nil a panic will occur. In the future the SDK may create 1307// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1308// for more information on using Contexts. 1309func (c *Transfer) ListTagsForResourcePagesWithContext(ctx aws.Context, input *ListTagsForResourceInput, fn func(*ListTagsForResourceOutput, bool) bool, opts ...request.Option) error { 1310 p := request.Pagination{ 1311 NewRequest: func() (*request.Request, error) { 1312 var inCpy *ListTagsForResourceInput 1313 if input != nil { 1314 tmp := *input 1315 inCpy = &tmp 1316 } 1317 req, _ := c.ListTagsForResourceRequest(inCpy) 1318 req.SetContext(ctx) 1319 req.ApplyOptions(opts...) 1320 return req, nil 1321 }, 1322 } 1323 1324 for p.Next() { 1325 if !fn(p.Page().(*ListTagsForResourceOutput), !p.HasNextPage()) { 1326 break 1327 } 1328 } 1329 1330 return p.Err() 1331} 1332 1333const opListUsers = "ListUsers" 1334 1335// ListUsersRequest generates a "aws/request.Request" representing the 1336// client's request for the ListUsers operation. The "output" return 1337// value will be populated with the request's response once the request completes 1338// successfully. 1339// 1340// Use "Send" method on the returned Request to send the API call to the service. 1341// the "output" return value is not valid until after Send returns without error. 1342// 1343// See ListUsers for more information on using the ListUsers 1344// API call, and error handling. 1345// 1346// This method is useful when you want to inject custom logic or configuration 1347// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1348// 1349// 1350// // Example sending a request using the ListUsersRequest method. 1351// req, resp := client.ListUsersRequest(params) 1352// 1353// err := req.Send() 1354// if err == nil { // resp is now filled 1355// fmt.Println(resp) 1356// } 1357// 1358// See also, https://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/ListUsers 1359func (c *Transfer) ListUsersRequest(input *ListUsersInput) (req *request.Request, output *ListUsersOutput) { 1360 op := &request.Operation{ 1361 Name: opListUsers, 1362 HTTPMethod: "POST", 1363 HTTPPath: "/", 1364 Paginator: &request.Paginator{ 1365 InputTokens: []string{"NextToken"}, 1366 OutputTokens: []string{"NextToken"}, 1367 LimitToken: "MaxResults", 1368 TruncationToken: "", 1369 }, 1370 } 1371 1372 if input == nil { 1373 input = &ListUsersInput{} 1374 } 1375 1376 output = &ListUsersOutput{} 1377 req = c.newRequest(op, input, output) 1378 return 1379} 1380 1381// ListUsers API operation for AWS Transfer Family. 1382// 1383// Lists the users for a file transfer protocol-enabled server that you specify 1384// by passing the ServerId parameter. 1385// 1386// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1387// with awserr.Error's Code and Message methods to get detailed information about 1388// the error. 1389// 1390// See the AWS API reference guide for AWS Transfer Family's 1391// API operation ListUsers for usage and error information. 1392// 1393// Returned Error Types: 1394// * ServiceUnavailableException 1395// The request has failed because the AWS Transfer Family service is not available. 1396// 1397// * InternalServiceError 1398// This exception is thrown when an error occurs in the AWS Transfer Family 1399// service. 1400// 1401// * InvalidNextTokenException 1402// The NextToken parameter that was passed is invalid. 1403// 1404// * InvalidRequestException 1405// This exception is thrown when the client submits a malformed request. 1406// 1407// * ResourceNotFoundException 1408// This exception is thrown when a resource is not found by the AWS Transfer 1409// Family service. 1410// 1411// See also, https://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/ListUsers 1412func (c *Transfer) ListUsers(input *ListUsersInput) (*ListUsersOutput, error) { 1413 req, out := c.ListUsersRequest(input) 1414 return out, req.Send() 1415} 1416 1417// ListUsersWithContext is the same as ListUsers with the addition of 1418// the ability to pass a context and additional request options. 1419// 1420// See ListUsers for details on how to use this API operation. 1421// 1422// The context must be non-nil and will be used for request cancellation. If 1423// the context is nil a panic will occur. In the future the SDK may create 1424// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1425// for more information on using Contexts. 1426func (c *Transfer) ListUsersWithContext(ctx aws.Context, input *ListUsersInput, opts ...request.Option) (*ListUsersOutput, error) { 1427 req, out := c.ListUsersRequest(input) 1428 req.SetContext(ctx) 1429 req.ApplyOptions(opts...) 1430 return out, req.Send() 1431} 1432 1433// ListUsersPages iterates over the pages of a ListUsers operation, 1434// calling the "fn" function with the response data for each page. To stop 1435// iterating, return false from the fn function. 1436// 1437// See ListUsers method for more information on how to use this operation. 1438// 1439// Note: This operation can generate multiple requests to a service. 1440// 1441// // Example iterating over at most 3 pages of a ListUsers operation. 1442// pageNum := 0 1443// err := client.ListUsersPages(params, 1444// func(page *transfer.ListUsersOutput, lastPage bool) bool { 1445// pageNum++ 1446// fmt.Println(page) 1447// return pageNum <= 3 1448// }) 1449// 1450func (c *Transfer) ListUsersPages(input *ListUsersInput, fn func(*ListUsersOutput, bool) bool) error { 1451 return c.ListUsersPagesWithContext(aws.BackgroundContext(), input, fn) 1452} 1453 1454// ListUsersPagesWithContext same as ListUsersPages except 1455// it takes a Context and allows setting request options on the pages. 1456// 1457// The context must be non-nil and will be used for request cancellation. If 1458// the context is nil a panic will occur. In the future the SDK may create 1459// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1460// for more information on using Contexts. 1461func (c *Transfer) ListUsersPagesWithContext(ctx aws.Context, input *ListUsersInput, fn func(*ListUsersOutput, bool) bool, opts ...request.Option) error { 1462 p := request.Pagination{ 1463 NewRequest: func() (*request.Request, error) { 1464 var inCpy *ListUsersInput 1465 if input != nil { 1466 tmp := *input 1467 inCpy = &tmp 1468 } 1469 req, _ := c.ListUsersRequest(inCpy) 1470 req.SetContext(ctx) 1471 req.ApplyOptions(opts...) 1472 return req, nil 1473 }, 1474 } 1475 1476 for p.Next() { 1477 if !fn(p.Page().(*ListUsersOutput), !p.HasNextPage()) { 1478 break 1479 } 1480 } 1481 1482 return p.Err() 1483} 1484 1485const opStartServer = "StartServer" 1486 1487// StartServerRequest generates a "aws/request.Request" representing the 1488// client's request for the StartServer operation. The "output" return 1489// value will be populated with the request's response once the request completes 1490// successfully. 1491// 1492// Use "Send" method on the returned Request to send the API call to the service. 1493// the "output" return value is not valid until after Send returns without error. 1494// 1495// See StartServer for more information on using the StartServer 1496// API call, and error handling. 1497// 1498// This method is useful when you want to inject custom logic or configuration 1499// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1500// 1501// 1502// // Example sending a request using the StartServerRequest method. 1503// req, resp := client.StartServerRequest(params) 1504// 1505// err := req.Send() 1506// if err == nil { // resp is now filled 1507// fmt.Println(resp) 1508// } 1509// 1510// See also, https://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/StartServer 1511func (c *Transfer) StartServerRequest(input *StartServerInput) (req *request.Request, output *StartServerOutput) { 1512 op := &request.Operation{ 1513 Name: opStartServer, 1514 HTTPMethod: "POST", 1515 HTTPPath: "/", 1516 } 1517 1518 if input == nil { 1519 input = &StartServerInput{} 1520 } 1521 1522 output = &StartServerOutput{} 1523 req = c.newRequest(op, input, output) 1524 req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 1525 return 1526} 1527 1528// StartServer API operation for AWS Transfer Family. 1529// 1530// Changes the state of a file transfer protocol-enabled server from OFFLINE 1531// to ONLINE. It has no impact on a server that is already ONLINE. An ONLINE 1532// server can accept and process file transfer jobs. 1533// 1534// The state of STARTING indicates that the server is in an intermediate state, 1535// either not fully able to respond, or not fully online. The values of START_FAILED 1536// can indicate an error condition. 1537// 1538// No response is returned from this call. 1539// 1540// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1541// with awserr.Error's Code and Message methods to get detailed information about 1542// the error. 1543// 1544// See the AWS API reference guide for AWS Transfer Family's 1545// API operation StartServer for usage and error information. 1546// 1547// Returned Error Types: 1548// * ServiceUnavailableException 1549// The request has failed because the AWS Transfer Family service is not available. 1550// 1551// * InternalServiceError 1552// This exception is thrown when an error occurs in the AWS Transfer Family 1553// service. 1554// 1555// * InvalidRequestException 1556// This exception is thrown when the client submits a malformed request. 1557// 1558// * ResourceNotFoundException 1559// This exception is thrown when a resource is not found by the AWS Transfer 1560// Family service. 1561// 1562// * ThrottlingException 1563// The request was denied due to request throttling. 1564// 1565// HTTP Status Code: 400 1566// 1567// See also, https://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/StartServer 1568func (c *Transfer) StartServer(input *StartServerInput) (*StartServerOutput, error) { 1569 req, out := c.StartServerRequest(input) 1570 return out, req.Send() 1571} 1572 1573// StartServerWithContext is the same as StartServer with the addition of 1574// the ability to pass a context and additional request options. 1575// 1576// See StartServer for details on how to use this API operation. 1577// 1578// The context must be non-nil and will be used for request cancellation. If 1579// the context is nil a panic will occur. In the future the SDK may create 1580// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1581// for more information on using Contexts. 1582func (c *Transfer) StartServerWithContext(ctx aws.Context, input *StartServerInput, opts ...request.Option) (*StartServerOutput, error) { 1583 req, out := c.StartServerRequest(input) 1584 req.SetContext(ctx) 1585 req.ApplyOptions(opts...) 1586 return out, req.Send() 1587} 1588 1589const opStopServer = "StopServer" 1590 1591// StopServerRequest generates a "aws/request.Request" representing the 1592// client's request for the StopServer operation. The "output" return 1593// value will be populated with the request's response once the request completes 1594// successfully. 1595// 1596// Use "Send" method on the returned Request to send the API call to the service. 1597// the "output" return value is not valid until after Send returns without error. 1598// 1599// See StopServer for more information on using the StopServer 1600// API call, and error handling. 1601// 1602// This method is useful when you want to inject custom logic or configuration 1603// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1604// 1605// 1606// // Example sending a request using the StopServerRequest method. 1607// req, resp := client.StopServerRequest(params) 1608// 1609// err := req.Send() 1610// if err == nil { // resp is now filled 1611// fmt.Println(resp) 1612// } 1613// 1614// See also, https://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/StopServer 1615func (c *Transfer) StopServerRequest(input *StopServerInput) (req *request.Request, output *StopServerOutput) { 1616 op := &request.Operation{ 1617 Name: opStopServer, 1618 HTTPMethod: "POST", 1619 HTTPPath: "/", 1620 } 1621 1622 if input == nil { 1623 input = &StopServerInput{} 1624 } 1625 1626 output = &StopServerOutput{} 1627 req = c.newRequest(op, input, output) 1628 req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 1629 return 1630} 1631 1632// StopServer API operation for AWS Transfer Family. 1633// 1634// Changes the state of a file transfer protocol-enabled server from ONLINE 1635// to OFFLINE. An OFFLINE server cannot accept and process file transfer jobs. 1636// Information tied to your server, such as server and user properties, are 1637// not affected by stopping your server. 1638// 1639// Stopping the server will not reduce or impact your file transfer protocol 1640// endpoint billing; you must delete the server to stop being billed. 1641// 1642// The state of STOPPING indicates that the server is in an intermediate state, 1643// either not fully able to respond, or not fully offline. The values of STOP_FAILED 1644// can indicate an error condition. 1645// 1646// No response is returned from this call. 1647// 1648// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1649// with awserr.Error's Code and Message methods to get detailed information about 1650// the error. 1651// 1652// See the AWS API reference guide for AWS Transfer Family's 1653// API operation StopServer for usage and error information. 1654// 1655// Returned Error Types: 1656// * ServiceUnavailableException 1657// The request has failed because the AWS Transfer Family service is not available. 1658// 1659// * InternalServiceError 1660// This exception is thrown when an error occurs in the AWS Transfer Family 1661// service. 1662// 1663// * InvalidRequestException 1664// This exception is thrown when the client submits a malformed request. 1665// 1666// * ResourceNotFoundException 1667// This exception is thrown when a resource is not found by the AWS Transfer 1668// Family service. 1669// 1670// * ThrottlingException 1671// The request was denied due to request throttling. 1672// 1673// HTTP Status Code: 400 1674// 1675// See also, https://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/StopServer 1676func (c *Transfer) StopServer(input *StopServerInput) (*StopServerOutput, error) { 1677 req, out := c.StopServerRequest(input) 1678 return out, req.Send() 1679} 1680 1681// StopServerWithContext is the same as StopServer with the addition of 1682// the ability to pass a context and additional request options. 1683// 1684// See StopServer for details on how to use this API operation. 1685// 1686// The context must be non-nil and will be used for request cancellation. If 1687// the context is nil a panic will occur. In the future the SDK may create 1688// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1689// for more information on using Contexts. 1690func (c *Transfer) StopServerWithContext(ctx aws.Context, input *StopServerInput, opts ...request.Option) (*StopServerOutput, error) { 1691 req, out := c.StopServerRequest(input) 1692 req.SetContext(ctx) 1693 req.ApplyOptions(opts...) 1694 return out, req.Send() 1695} 1696 1697const opTagResource = "TagResource" 1698 1699// TagResourceRequest generates a "aws/request.Request" representing the 1700// client's request for the TagResource operation. The "output" return 1701// value will be populated with the request's response once the request completes 1702// successfully. 1703// 1704// Use "Send" method on the returned Request to send the API call to the service. 1705// the "output" return value is not valid until after Send returns without error. 1706// 1707// See TagResource for more information on using the TagResource 1708// API call, and error handling. 1709// 1710// This method is useful when you want to inject custom logic or configuration 1711// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1712// 1713// 1714// // Example sending a request using the TagResourceRequest method. 1715// req, resp := client.TagResourceRequest(params) 1716// 1717// err := req.Send() 1718// if err == nil { // resp is now filled 1719// fmt.Println(resp) 1720// } 1721// 1722// See also, https://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/TagResource 1723func (c *Transfer) TagResourceRequest(input *TagResourceInput) (req *request.Request, output *TagResourceOutput) { 1724 op := &request.Operation{ 1725 Name: opTagResource, 1726 HTTPMethod: "POST", 1727 HTTPPath: "/", 1728 } 1729 1730 if input == nil { 1731 input = &TagResourceInput{} 1732 } 1733 1734 output = &TagResourceOutput{} 1735 req = c.newRequest(op, input, output) 1736 req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 1737 return 1738} 1739 1740// TagResource API operation for AWS Transfer Family. 1741// 1742// Attaches a key-value pair to a resource, as identified by its Amazon Resource 1743// Name (ARN). Resources are users, servers, roles, and other entities. 1744// 1745// There is no response returned from this call. 1746// 1747// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1748// with awserr.Error's Code and Message methods to get detailed information about 1749// the error. 1750// 1751// See the AWS API reference guide for AWS Transfer Family's 1752// API operation TagResource for usage and error information. 1753// 1754// Returned Error Types: 1755// * ServiceUnavailableException 1756// The request has failed because the AWS Transfer Family service is not available. 1757// 1758// * InternalServiceError 1759// This exception is thrown when an error occurs in the AWS Transfer Family 1760// service. 1761// 1762// * InvalidRequestException 1763// This exception is thrown when the client submits a malformed request. 1764// 1765// * ResourceNotFoundException 1766// This exception is thrown when a resource is not found by the AWS Transfer 1767// Family service. 1768// 1769// See also, https://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/TagResource 1770func (c *Transfer) TagResource(input *TagResourceInput) (*TagResourceOutput, error) { 1771 req, out := c.TagResourceRequest(input) 1772 return out, req.Send() 1773} 1774 1775// TagResourceWithContext is the same as TagResource with the addition of 1776// the ability to pass a context and additional request options. 1777// 1778// See TagResource for details on how to use this API operation. 1779// 1780// The context must be non-nil and will be used for request cancellation. If 1781// the context is nil a panic will occur. In the future the SDK may create 1782// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1783// for more information on using Contexts. 1784func (c *Transfer) TagResourceWithContext(ctx aws.Context, input *TagResourceInput, opts ...request.Option) (*TagResourceOutput, error) { 1785 req, out := c.TagResourceRequest(input) 1786 req.SetContext(ctx) 1787 req.ApplyOptions(opts...) 1788 return out, req.Send() 1789} 1790 1791const opTestIdentityProvider = "TestIdentityProvider" 1792 1793// TestIdentityProviderRequest generates a "aws/request.Request" representing the 1794// client's request for the TestIdentityProvider operation. The "output" return 1795// value will be populated with the request's response once the request completes 1796// successfully. 1797// 1798// Use "Send" method on the returned Request to send the API call to the service. 1799// the "output" return value is not valid until after Send returns without error. 1800// 1801// See TestIdentityProvider for more information on using the TestIdentityProvider 1802// API call, and error handling. 1803// 1804// This method is useful when you want to inject custom logic or configuration 1805// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1806// 1807// 1808// // Example sending a request using the TestIdentityProviderRequest method. 1809// req, resp := client.TestIdentityProviderRequest(params) 1810// 1811// err := req.Send() 1812// if err == nil { // resp is now filled 1813// fmt.Println(resp) 1814// } 1815// 1816// See also, https://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/TestIdentityProvider 1817func (c *Transfer) TestIdentityProviderRequest(input *TestIdentityProviderInput) (req *request.Request, output *TestIdentityProviderOutput) { 1818 op := &request.Operation{ 1819 Name: opTestIdentityProvider, 1820 HTTPMethod: "POST", 1821 HTTPPath: "/", 1822 } 1823 1824 if input == nil { 1825 input = &TestIdentityProviderInput{} 1826 } 1827 1828 output = &TestIdentityProviderOutput{} 1829 req = c.newRequest(op, input, output) 1830 return 1831} 1832 1833// TestIdentityProvider API operation for AWS Transfer Family. 1834// 1835// If the IdentityProviderType of a file transfer protocol-enabled server is 1836// API_Gateway, tests whether your API Gateway is set up successfully. We highly 1837// recommend that you call this operation to test your authentication method 1838// as soon as you create your server. By doing so, you can troubleshoot issues 1839// with the API Gateway integration to ensure that your users can successfully 1840// use the service. 1841// 1842// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1843// with awserr.Error's Code and Message methods to get detailed information about 1844// the error. 1845// 1846// See the AWS API reference guide for AWS Transfer Family's 1847// API operation TestIdentityProvider for usage and error information. 1848// 1849// Returned Error Types: 1850// * ServiceUnavailableException 1851// The request has failed because the AWS Transfer Family service is not available. 1852// 1853// * InternalServiceError 1854// This exception is thrown when an error occurs in the AWS Transfer Family 1855// service. 1856// 1857// * InvalidRequestException 1858// This exception is thrown when the client submits a malformed request. 1859// 1860// * ResourceNotFoundException 1861// This exception is thrown when a resource is not found by the AWS Transfer 1862// Family service. 1863// 1864// See also, https://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/TestIdentityProvider 1865func (c *Transfer) TestIdentityProvider(input *TestIdentityProviderInput) (*TestIdentityProviderOutput, error) { 1866 req, out := c.TestIdentityProviderRequest(input) 1867 return out, req.Send() 1868} 1869 1870// TestIdentityProviderWithContext is the same as TestIdentityProvider with the addition of 1871// the ability to pass a context and additional request options. 1872// 1873// See TestIdentityProvider for details on how to use this API operation. 1874// 1875// The context must be non-nil and will be used for request cancellation. If 1876// the context is nil a panic will occur. In the future the SDK may create 1877// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1878// for more information on using Contexts. 1879func (c *Transfer) TestIdentityProviderWithContext(ctx aws.Context, input *TestIdentityProviderInput, opts ...request.Option) (*TestIdentityProviderOutput, error) { 1880 req, out := c.TestIdentityProviderRequest(input) 1881 req.SetContext(ctx) 1882 req.ApplyOptions(opts...) 1883 return out, req.Send() 1884} 1885 1886const opUntagResource = "UntagResource" 1887 1888// UntagResourceRequest generates a "aws/request.Request" representing the 1889// client's request for the UntagResource operation. The "output" return 1890// value will be populated with the request's response once the request completes 1891// successfully. 1892// 1893// Use "Send" method on the returned Request to send the API call to the service. 1894// the "output" return value is not valid until after Send returns without error. 1895// 1896// See UntagResource for more information on using the UntagResource 1897// API call, and error handling. 1898// 1899// This method is useful when you want to inject custom logic or configuration 1900// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1901// 1902// 1903// // Example sending a request using the UntagResourceRequest method. 1904// req, resp := client.UntagResourceRequest(params) 1905// 1906// err := req.Send() 1907// if err == nil { // resp is now filled 1908// fmt.Println(resp) 1909// } 1910// 1911// See also, https://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/UntagResource 1912func (c *Transfer) UntagResourceRequest(input *UntagResourceInput) (req *request.Request, output *UntagResourceOutput) { 1913 op := &request.Operation{ 1914 Name: opUntagResource, 1915 HTTPMethod: "POST", 1916 HTTPPath: "/", 1917 } 1918 1919 if input == nil { 1920 input = &UntagResourceInput{} 1921 } 1922 1923 output = &UntagResourceOutput{} 1924 req = c.newRequest(op, input, output) 1925 req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 1926 return 1927} 1928 1929// UntagResource API operation for AWS Transfer Family. 1930// 1931// Detaches a key-value pair from a resource, as identified by its Amazon Resource 1932// Name (ARN). Resources are users, servers, roles, and other entities. 1933// 1934// No response is returned from this call. 1935// 1936// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1937// with awserr.Error's Code and Message methods to get detailed information about 1938// the error. 1939// 1940// See the AWS API reference guide for AWS Transfer Family's 1941// API operation UntagResource for usage and error information. 1942// 1943// Returned Error Types: 1944// * ServiceUnavailableException 1945// The request has failed because the AWS Transfer Family service is not available. 1946// 1947// * InternalServiceError 1948// This exception is thrown when an error occurs in the AWS Transfer Family 1949// service. 1950// 1951// * InvalidRequestException 1952// This exception is thrown when the client submits a malformed request. 1953// 1954// * ResourceNotFoundException 1955// This exception is thrown when a resource is not found by the AWS Transfer 1956// Family service. 1957// 1958// See also, https://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/UntagResource 1959func (c *Transfer) UntagResource(input *UntagResourceInput) (*UntagResourceOutput, error) { 1960 req, out := c.UntagResourceRequest(input) 1961 return out, req.Send() 1962} 1963 1964// UntagResourceWithContext is the same as UntagResource with the addition of 1965// the ability to pass a context and additional request options. 1966// 1967// See UntagResource for details on how to use this API operation. 1968// 1969// The context must be non-nil and will be used for request cancellation. If 1970// the context is nil a panic will occur. In the future the SDK may create 1971// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1972// for more information on using Contexts. 1973func (c *Transfer) UntagResourceWithContext(ctx aws.Context, input *UntagResourceInput, opts ...request.Option) (*UntagResourceOutput, error) { 1974 req, out := c.UntagResourceRequest(input) 1975 req.SetContext(ctx) 1976 req.ApplyOptions(opts...) 1977 return out, req.Send() 1978} 1979 1980const opUpdateServer = "UpdateServer" 1981 1982// UpdateServerRequest generates a "aws/request.Request" representing the 1983// client's request for the UpdateServer operation. The "output" return 1984// value will be populated with the request's response once the request completes 1985// successfully. 1986// 1987// Use "Send" method on the returned Request to send the API call to the service. 1988// the "output" return value is not valid until after Send returns without error. 1989// 1990// See UpdateServer for more information on using the UpdateServer 1991// API call, and error handling. 1992// 1993// This method is useful when you want to inject custom logic or configuration 1994// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1995// 1996// 1997// // Example sending a request using the UpdateServerRequest method. 1998// req, resp := client.UpdateServerRequest(params) 1999// 2000// err := req.Send() 2001// if err == nil { // resp is now filled 2002// fmt.Println(resp) 2003// } 2004// 2005// See also, https://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/UpdateServer 2006func (c *Transfer) UpdateServerRequest(input *UpdateServerInput) (req *request.Request, output *UpdateServerOutput) { 2007 op := &request.Operation{ 2008 Name: opUpdateServer, 2009 HTTPMethod: "POST", 2010 HTTPPath: "/", 2011 } 2012 2013 if input == nil { 2014 input = &UpdateServerInput{} 2015 } 2016 2017 output = &UpdateServerOutput{} 2018 req = c.newRequest(op, input, output) 2019 return 2020} 2021 2022// UpdateServer API operation for AWS Transfer Family. 2023// 2024// Updates the file transfer protocol-enabled server's properties after that 2025// server has been created. 2026// 2027// The UpdateServer call returns the ServerId of the server you updated. 2028// 2029// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2030// with awserr.Error's Code and Message methods to get detailed information about 2031// the error. 2032// 2033// See the AWS API reference guide for AWS Transfer Family's 2034// API operation UpdateServer for usage and error information. 2035// 2036// Returned Error Types: 2037// * AccessDeniedException 2038// You do not have sufficient access to perform this action. 2039// 2040// * ServiceUnavailableException 2041// The request has failed because the AWS Transfer Family service is not available. 2042// 2043// * ConflictException 2044// This exception is thrown when the UpdatServer is called for a file transfer 2045// protocol-enabled server that has VPC as the endpoint type and the server's 2046// VpcEndpointID is not in the available state. 2047// 2048// * InternalServiceError 2049// This exception is thrown when an error occurs in the AWS Transfer Family 2050// service. 2051// 2052// * InvalidRequestException 2053// This exception is thrown when the client submits a malformed request. 2054// 2055// * ResourceExistsException 2056// The requested resource does not exist. 2057// 2058// * ResourceNotFoundException 2059// This exception is thrown when a resource is not found by the AWS Transfer 2060// Family service. 2061// 2062// * ThrottlingException 2063// The request was denied due to request throttling. 2064// 2065// HTTP Status Code: 400 2066// 2067// See also, https://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/UpdateServer 2068func (c *Transfer) UpdateServer(input *UpdateServerInput) (*UpdateServerOutput, error) { 2069 req, out := c.UpdateServerRequest(input) 2070 return out, req.Send() 2071} 2072 2073// UpdateServerWithContext is the same as UpdateServer with the addition of 2074// the ability to pass a context and additional request options. 2075// 2076// See UpdateServer for details on how to use this API operation. 2077// 2078// The context must be non-nil and will be used for request cancellation. If 2079// the context is nil a panic will occur. In the future the SDK may create 2080// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2081// for more information on using Contexts. 2082func (c *Transfer) UpdateServerWithContext(ctx aws.Context, input *UpdateServerInput, opts ...request.Option) (*UpdateServerOutput, error) { 2083 req, out := c.UpdateServerRequest(input) 2084 req.SetContext(ctx) 2085 req.ApplyOptions(opts...) 2086 return out, req.Send() 2087} 2088 2089const opUpdateUser = "UpdateUser" 2090 2091// UpdateUserRequest generates a "aws/request.Request" representing the 2092// client's request for the UpdateUser operation. The "output" return 2093// value will be populated with the request's response once the request completes 2094// successfully. 2095// 2096// Use "Send" method on the returned Request to send the API call to the service. 2097// the "output" return value is not valid until after Send returns without error. 2098// 2099// See UpdateUser for more information on using the UpdateUser 2100// API call, and error handling. 2101// 2102// This method is useful when you want to inject custom logic or configuration 2103// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2104// 2105// 2106// // Example sending a request using the UpdateUserRequest method. 2107// req, resp := client.UpdateUserRequest(params) 2108// 2109// err := req.Send() 2110// if err == nil { // resp is now filled 2111// fmt.Println(resp) 2112// } 2113// 2114// See also, https://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/UpdateUser 2115func (c *Transfer) UpdateUserRequest(input *UpdateUserInput) (req *request.Request, output *UpdateUserOutput) { 2116 op := &request.Operation{ 2117 Name: opUpdateUser, 2118 HTTPMethod: "POST", 2119 HTTPPath: "/", 2120 } 2121 2122 if input == nil { 2123 input = &UpdateUserInput{} 2124 } 2125 2126 output = &UpdateUserOutput{} 2127 req = c.newRequest(op, input, output) 2128 return 2129} 2130 2131// UpdateUser API operation for AWS Transfer Family. 2132// 2133// Assigns new properties to a user. Parameters you pass modify any or all of 2134// the following: the home directory, role, and policy for the UserName and 2135// ServerId you specify. 2136// 2137// The response returns the ServerId and the UserName for the updated user. 2138// 2139// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2140// with awserr.Error's Code and Message methods to get detailed information about 2141// the error. 2142// 2143// See the AWS API reference guide for AWS Transfer Family's 2144// API operation UpdateUser for usage and error information. 2145// 2146// Returned Error Types: 2147// * ServiceUnavailableException 2148// The request has failed because the AWS Transfer Family service is not available. 2149// 2150// * InternalServiceError 2151// This exception is thrown when an error occurs in the AWS Transfer Family 2152// service. 2153// 2154// * InvalidRequestException 2155// This exception is thrown when the client submits a malformed request. 2156// 2157// * ResourceNotFoundException 2158// This exception is thrown when a resource is not found by the AWS Transfer 2159// Family service. 2160// 2161// * ThrottlingException 2162// The request was denied due to request throttling. 2163// 2164// HTTP Status Code: 400 2165// 2166// See also, https://docs.aws.amazon.com/goto/WebAPI/transfer-2018-11-05/UpdateUser 2167func (c *Transfer) UpdateUser(input *UpdateUserInput) (*UpdateUserOutput, error) { 2168 req, out := c.UpdateUserRequest(input) 2169 return out, req.Send() 2170} 2171 2172// UpdateUserWithContext is the same as UpdateUser with the addition of 2173// the ability to pass a context and additional request options. 2174// 2175// See UpdateUser for details on how to use this API operation. 2176// 2177// The context must be non-nil and will be used for request cancellation. If 2178// the context is nil a panic will occur. In the future the SDK may create 2179// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2180// for more information on using Contexts. 2181func (c *Transfer) UpdateUserWithContext(ctx aws.Context, input *UpdateUserInput, opts ...request.Option) (*UpdateUserOutput, error) { 2182 req, out := c.UpdateUserRequest(input) 2183 req.SetContext(ctx) 2184 req.ApplyOptions(opts...) 2185 return out, req.Send() 2186} 2187 2188// You do not have sufficient access to perform this action. 2189type AccessDeniedException struct { 2190 _ struct{} `type:"structure"` 2191 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 2192 2193 Message_ *string `locationName:"Message" type:"string"` 2194} 2195 2196// String returns the string representation 2197func (s AccessDeniedException) String() string { 2198 return awsutil.Prettify(s) 2199} 2200 2201// GoString returns the string representation 2202func (s AccessDeniedException) GoString() string { 2203 return s.String() 2204} 2205 2206func newErrorAccessDeniedException(v protocol.ResponseMetadata) error { 2207 return &AccessDeniedException{ 2208 RespMetadata: v, 2209 } 2210} 2211 2212// Code returns the exception type name. 2213func (s *AccessDeniedException) Code() string { 2214 return "AccessDeniedException" 2215} 2216 2217// Message returns the exception's message. 2218func (s *AccessDeniedException) Message() string { 2219 if s.Message_ != nil { 2220 return *s.Message_ 2221 } 2222 return "" 2223} 2224 2225// OrigErr always returns nil, satisfies awserr.Error interface. 2226func (s *AccessDeniedException) OrigErr() error { 2227 return nil 2228} 2229 2230func (s *AccessDeniedException) Error() string { 2231 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 2232} 2233 2234// Status code returns the HTTP status code for the request's response error. 2235func (s *AccessDeniedException) StatusCode() int { 2236 return s.RespMetadata.StatusCode 2237} 2238 2239// RequestID returns the service's response RequestID for request. 2240func (s *AccessDeniedException) RequestID() string { 2241 return s.RespMetadata.RequestID 2242} 2243 2244// This exception is thrown when the UpdatServer is called for a file transfer 2245// protocol-enabled server that has VPC as the endpoint type and the server's 2246// VpcEndpointID is not in the available state. 2247type ConflictException struct { 2248 _ struct{} `type:"structure"` 2249 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 2250 2251 Message_ *string `locationName:"Message" type:"string"` 2252} 2253 2254// String returns the string representation 2255func (s ConflictException) String() string { 2256 return awsutil.Prettify(s) 2257} 2258 2259// GoString returns the string representation 2260func (s ConflictException) GoString() string { 2261 return s.String() 2262} 2263 2264func newErrorConflictException(v protocol.ResponseMetadata) error { 2265 return &ConflictException{ 2266 RespMetadata: v, 2267 } 2268} 2269 2270// Code returns the exception type name. 2271func (s *ConflictException) Code() string { 2272 return "ConflictException" 2273} 2274 2275// Message returns the exception's message. 2276func (s *ConflictException) Message() string { 2277 if s.Message_ != nil { 2278 return *s.Message_ 2279 } 2280 return "" 2281} 2282 2283// OrigErr always returns nil, satisfies awserr.Error interface. 2284func (s *ConflictException) OrigErr() error { 2285 return nil 2286} 2287 2288func (s *ConflictException) Error() string { 2289 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 2290} 2291 2292// Status code returns the HTTP status code for the request's response error. 2293func (s *ConflictException) StatusCode() int { 2294 return s.RespMetadata.StatusCode 2295} 2296 2297// RequestID returns the service's response RequestID for request. 2298func (s *ConflictException) RequestID() string { 2299 return s.RespMetadata.RequestID 2300} 2301 2302type CreateServerInput struct { 2303 _ struct{} `type:"structure"` 2304 2305 // The Amazon Resource Name (ARN) of the AWS Certificate Manager (ACM) certificate. 2306 // Required when Protocols is set to FTPS. 2307 // 2308 // To request a new public certificate, see Request a public certificate (https://docs.aws.amazon.com/acm/latest/userguide/gs-acm-request-public.html) 2309 // in the AWS Certificate Manager User Guide. 2310 // 2311 // To import an existing certificate into ACM, see Importing certificates into 2312 // ACM (https://docs.aws.amazon.com/acm/latest/userguide/import-certificate.html) 2313 // in the AWS Certificate Manager User Guide. 2314 // 2315 // To request a private certificate to use FTPS through private IP addresses, 2316 // see Request a private certificate (https://docs.aws.amazon.com/acm/latest/userguide/gs-acm-request-private.html) 2317 // in the AWS Certificate Manager User Guide. 2318 // 2319 // Certificates with the following cryptographic algorithms and key sizes are 2320 // supported: 2321 // 2322 // * 2048-bit RSA (RSA_2048) 2323 // 2324 // * 4096-bit RSA (RSA_4096) 2325 // 2326 // * Elliptic Prime Curve 256 bit (EC_prime256v1) 2327 // 2328 // * Elliptic Prime Curve 384 bit (EC_secp384r1) 2329 // 2330 // * Elliptic Prime Curve 521 bit (EC_secp521r1) 2331 // 2332 // The certificate must be a valid SSL/TLS X.509 version 3 certificate with 2333 // FQDN or IP address specified and information about the issuer. 2334 Certificate *string `type:"string"` 2335 2336 Domain *string `type:"string" enum:"Domain"` 2337 2338 // The virtual private cloud (VPC) endpoint settings that are configured for 2339 // your server. When you host your endpoint within your VPC, you can make it 2340 // accessible only to resources within your VPC, or you can attach Elastic IPs 2341 // and make it accessible to clients over the internet. Your VPC's default security 2342 // groups are automatically assigned to your endpoint. 2343 EndpointDetails *EndpointDetails `type:"structure"` 2344 2345 // The type of VPC endpoint that you want your server to connect to. You can 2346 // choose to connect to the public internet or a VPC endpoint. With a VPC endpoint, 2347 // you can restrict access to your server and resources only within your VPC. 2348 // 2349 // It is recommended that you use VPC as the EndpointType. With this endpoint 2350 // type, you have the option to directly associate up to three Elastic IPv4 2351 // addresses (BYO IP included) with your server's endpoint and use VPC security 2352 // groups to restrict traffic by the client's public IP address. This is not 2353 // possible with EndpointType set to VPC_ENDPOINT. 2354 EndpointType *string `type:"string" enum:"EndpointType"` 2355 2356 // The RSA private key as generated by the ssh-keygen -N "" -m PEM -f my-new-server-key 2357 // command. 2358 // 2359 // If you aren't planning to migrate existing users from an existing SFTP-enabled 2360 // server to a new server, don't update the host key. Accidentally changing 2361 // a server's host key can be disruptive. 2362 // 2363 // For more information, see Change the host key for your SFTP-enabled server 2364 // (https://docs.aws.amazon.com/transfer/latest/userguide/edit-server-config.html#configuring-servers-change-host-key) 2365 // in the AWS Transfer Family User Guide. 2366 HostKey *string `type:"string" sensitive:"true"` 2367 2368 // Required when IdentityProviderType is set to API_GATEWAY. Accepts an array 2369 // containing all of the information required to call a customer-supplied authentication 2370 // API, including the API Gateway URL. Not required when IdentityProviderType 2371 // is set to SERVICE_MANAGED. 2372 IdentityProviderDetails *IdentityProviderDetails `type:"structure"` 2373 2374 // Specifies the mode of authentication for a server. The default value is SERVICE_MANAGED, 2375 // which allows you to store and access user credentials within the AWS Transfer 2376 // Family service. Use the API_GATEWAY value to integrate with an identity provider 2377 // of your choosing. The API_GATEWAY setting requires you to provide an API 2378 // Gateway endpoint URL to call for authentication using the IdentityProviderDetails 2379 // parameter. 2380 IdentityProviderType *string `type:"string" enum:"IdentityProviderType"` 2381 2382 // Allows the service to write your users' activity to your Amazon CloudWatch 2383 // logs for monitoring and auditing purposes. 2384 LoggingRole *string `min:"20" type:"string"` 2385 2386 // Specifies the file transfer protocol or protocols over which your file transfer 2387 // protocol client can connect to your server's endpoint. The available protocols 2388 // are: 2389 // 2390 // * SFTP (Secure Shell (SSH) File Transfer Protocol): File transfer over 2391 // SSH 2392 // 2393 // * FTPS (File Transfer Protocol Secure): File transfer with TLS encryption 2394 // 2395 // * FTP (File Transfer Protocol): Unencrypted file transfer 2396 // 2397 // If you select FTPS, you must choose a certificate stored in AWS Certificate 2398 // Manager (ACM) which will be used to identify your server when clients connect 2399 // to it over FTPS. 2400 // 2401 // If Protocol includes either FTP or FTPS, then the EndpointType must be VPC 2402 // and the IdentityProviderType must be API_GATEWAY. 2403 // 2404 // If Protocol includes FTP, then AddressAllocationIds cannot be associated. 2405 // 2406 // If Protocol is set only to SFTP, the EndpointType can be set to PUBLIC and 2407 // the IdentityProviderType can be set to SERVICE_MANAGED. 2408 Protocols []*string `min:"1" type:"list"` 2409 2410 // Specifies the name of the security policy that is attached to the server. 2411 SecurityPolicyName *string `type:"string"` 2412 2413 // Key-value pairs that can be used to group and search for servers. 2414 Tags []*Tag `min:"1" type:"list"` 2415} 2416 2417// String returns the string representation 2418func (s CreateServerInput) String() string { 2419 return awsutil.Prettify(s) 2420} 2421 2422// GoString returns the string representation 2423func (s CreateServerInput) GoString() string { 2424 return s.String() 2425} 2426 2427// Validate inspects the fields of the type to determine if they are valid. 2428func (s *CreateServerInput) Validate() error { 2429 invalidParams := request.ErrInvalidParams{Context: "CreateServerInput"} 2430 if s.LoggingRole != nil && len(*s.LoggingRole) < 20 { 2431 invalidParams.Add(request.NewErrParamMinLen("LoggingRole", 20)) 2432 } 2433 if s.Protocols != nil && len(s.Protocols) < 1 { 2434 invalidParams.Add(request.NewErrParamMinLen("Protocols", 1)) 2435 } 2436 if s.Tags != nil && len(s.Tags) < 1 { 2437 invalidParams.Add(request.NewErrParamMinLen("Tags", 1)) 2438 } 2439 if s.EndpointDetails != nil { 2440 if err := s.EndpointDetails.Validate(); err != nil { 2441 invalidParams.AddNested("EndpointDetails", err.(request.ErrInvalidParams)) 2442 } 2443 } 2444 if s.IdentityProviderDetails != nil { 2445 if err := s.IdentityProviderDetails.Validate(); err != nil { 2446 invalidParams.AddNested("IdentityProviderDetails", err.(request.ErrInvalidParams)) 2447 } 2448 } 2449 if s.Tags != nil { 2450 for i, v := range s.Tags { 2451 if v == nil { 2452 continue 2453 } 2454 if err := v.Validate(); err != nil { 2455 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Tags", i), err.(request.ErrInvalidParams)) 2456 } 2457 } 2458 } 2459 2460 if invalidParams.Len() > 0 { 2461 return invalidParams 2462 } 2463 return nil 2464} 2465 2466// SetCertificate sets the Certificate field's value. 2467func (s *CreateServerInput) SetCertificate(v string) *CreateServerInput { 2468 s.Certificate = &v 2469 return s 2470} 2471 2472// SetDomain sets the Domain field's value. 2473func (s *CreateServerInput) SetDomain(v string) *CreateServerInput { 2474 s.Domain = &v 2475 return s 2476} 2477 2478// SetEndpointDetails sets the EndpointDetails field's value. 2479func (s *CreateServerInput) SetEndpointDetails(v *EndpointDetails) *CreateServerInput { 2480 s.EndpointDetails = v 2481 return s 2482} 2483 2484// SetEndpointType sets the EndpointType field's value. 2485func (s *CreateServerInput) SetEndpointType(v string) *CreateServerInput { 2486 s.EndpointType = &v 2487 return s 2488} 2489 2490// SetHostKey sets the HostKey field's value. 2491func (s *CreateServerInput) SetHostKey(v string) *CreateServerInput { 2492 s.HostKey = &v 2493 return s 2494} 2495 2496// SetIdentityProviderDetails sets the IdentityProviderDetails field's value. 2497func (s *CreateServerInput) SetIdentityProviderDetails(v *IdentityProviderDetails) *CreateServerInput { 2498 s.IdentityProviderDetails = v 2499 return s 2500} 2501 2502// SetIdentityProviderType sets the IdentityProviderType field's value. 2503func (s *CreateServerInput) SetIdentityProviderType(v string) *CreateServerInput { 2504 s.IdentityProviderType = &v 2505 return s 2506} 2507 2508// SetLoggingRole sets the LoggingRole field's value. 2509func (s *CreateServerInput) SetLoggingRole(v string) *CreateServerInput { 2510 s.LoggingRole = &v 2511 return s 2512} 2513 2514// SetProtocols sets the Protocols field's value. 2515func (s *CreateServerInput) SetProtocols(v []*string) *CreateServerInput { 2516 s.Protocols = v 2517 return s 2518} 2519 2520// SetSecurityPolicyName sets the SecurityPolicyName field's value. 2521func (s *CreateServerInput) SetSecurityPolicyName(v string) *CreateServerInput { 2522 s.SecurityPolicyName = &v 2523 return s 2524} 2525 2526// SetTags sets the Tags field's value. 2527func (s *CreateServerInput) SetTags(v []*Tag) *CreateServerInput { 2528 s.Tags = v 2529 return s 2530} 2531 2532type CreateServerOutput struct { 2533 _ struct{} `type:"structure"` 2534 2535 // The service-assigned ID of the server that is created. 2536 // 2537 // ServerId is a required field 2538 ServerId *string `min:"19" type:"string" required:"true"` 2539} 2540 2541// String returns the string representation 2542func (s CreateServerOutput) String() string { 2543 return awsutil.Prettify(s) 2544} 2545 2546// GoString returns the string representation 2547func (s CreateServerOutput) GoString() string { 2548 return s.String() 2549} 2550 2551// SetServerId sets the ServerId field's value. 2552func (s *CreateServerOutput) SetServerId(v string) *CreateServerOutput { 2553 s.ServerId = &v 2554 return s 2555} 2556 2557type CreateUserInput struct { 2558 _ struct{} `type:"structure"` 2559 2560 // The landing directory (folder) for a user when they log in to the server 2561 // using the client. 2562 // 2563 // An example is your-Amazon-S3-bucket-name>/home/username . 2564 HomeDirectory *string `type:"string"` 2565 2566 // Logical directory mappings that specify what Amazon S3 paths and keys should 2567 // be visible to your user and how you want to make them visible. You will need 2568 // to specify the "Entry" and "Target" pair, where Entry shows how the path 2569 // is made visible and Target is the actual Amazon S3 path. If you only specify 2570 // a target, it will be displayed as is. You will need to also make sure that 2571 // your IAM role provides access to paths in Target. The following is an example. 2572 // 2573 // '[ "/bucket2/documentation", { "Entry": "your-personal-report.pdf", "Target": 2574 // "/bucket3/customized-reports/${transfer:UserName}.pdf" } ]' 2575 // 2576 // In most cases, you can use this value instead of the scope-down policy to 2577 // lock your user down to the designated home directory ("chroot"). To do this, 2578 // you can set Entry to '/' and set Target to the HomeDirectory parameter value. 2579 // 2580 // If the target of a logical directory entry does not exist in Amazon S3, the 2581 // entry will be ignored. As a workaround, you can use the Amazon S3 API to 2582 // create 0 byte objects as place holders for your directory. If using the CLI, 2583 // use the s3api call instead of s3 so you can use the put-object operation. 2584 // For example, you use the following: aws s3api put-object --bucket bucketname 2585 // --key path/to/folder/. Make sure that the end of the key name ends in a '/' 2586 // for it to be considered a folder. 2587 HomeDirectoryMappings []*HomeDirectoryMapEntry `min:"1" type:"list"` 2588 2589 // The type of landing directory (folder) you want your users' home directory 2590 // to be when they log into the server. If you set it to PATH, the user will 2591 // see the absolute Amazon S3 bucket paths as is in their file transfer protocol 2592 // clients. If you set it LOGICAL, you will need to provide mappings in the 2593 // HomeDirectoryMappings for how you want to make Amazon S3 paths visible to 2594 // your users. 2595 HomeDirectoryType *string `type:"string" enum:"HomeDirectoryType"` 2596 2597 // A scope-down policy for your user so you can use the same IAM role across 2598 // multiple users. This policy scopes down user access to portions of their 2599 // Amazon S3 bucket. Variables that you can use inside this policy include ${Transfer:UserName}, 2600 // ${Transfer:HomeDirectory}, and ${Transfer:HomeBucket}. 2601 // 2602 // For scope-down policies, AWS Transfer Family stores the policy as a JSON 2603 // blob, instead of the Amazon Resource Name (ARN) of the policy. You save the 2604 // policy as a JSON blob and pass it in the Policy argument. 2605 // 2606 // For an example of a scope-down policy, see Creating a scope-down policy (https://docs.aws.amazon.com/transfer/latest/userguide/users.html#users-policies-scope-down). 2607 // 2608 // For more information, see AssumeRole (https://docs.aws.amazon.com/STS/latest/APIReference/API_AssumeRole.html) 2609 // in the AWS Security Token Service API Reference. 2610 Policy *string `type:"string"` 2611 2612 PosixProfile *PosixProfile `type:"structure"` 2613 2614 // The IAM role that controls your users' access to your Amazon S3 bucket. The 2615 // policies attached to this role will determine the level of access you want 2616 // to provide your users when transferring files into and out of your Amazon 2617 // S3 bucket or buckets. The IAM role should also contain a trust relationship 2618 // that allows the server to access your resources when servicing your users' 2619 // transfer requests. 2620 // 2621 // Role is a required field 2622 Role *string `min:"20" type:"string" required:"true"` 2623 2624 // A system-assigned unique identifier for a server instance. This is the specific 2625 // server that you added your user to. 2626 // 2627 // ServerId is a required field 2628 ServerId *string `min:"19" type:"string" required:"true"` 2629 2630 // The public portion of the Secure Shell (SSH) key used to authenticate the 2631 // user to the server. 2632 SshPublicKeyBody *string `type:"string"` 2633 2634 // Key-value pairs that can be used to group and search for users. Tags are 2635 // metadata attached to users for any purpose. 2636 Tags []*Tag `min:"1" type:"list"` 2637 2638 // A unique string that identifies a user and is associated with a as specified 2639 // by the ServerId. This user name must be a minimum of 3 and a maximum of 100 2640 // characters long. The following are valid characters: a-z, A-Z, 0-9, underscore 2641 // '_', hyphen '-', period '.', and at sign '@'. The user name can't start with 2642 // a hyphen, period, or at sign. 2643 // 2644 // UserName is a required field 2645 UserName *string `min:"3" type:"string" required:"true"` 2646} 2647 2648// String returns the string representation 2649func (s CreateUserInput) String() string { 2650 return awsutil.Prettify(s) 2651} 2652 2653// GoString returns the string representation 2654func (s CreateUserInput) GoString() string { 2655 return s.String() 2656} 2657 2658// Validate inspects the fields of the type to determine if they are valid. 2659func (s *CreateUserInput) Validate() error { 2660 invalidParams := request.ErrInvalidParams{Context: "CreateUserInput"} 2661 if s.HomeDirectoryMappings != nil && len(s.HomeDirectoryMappings) < 1 { 2662 invalidParams.Add(request.NewErrParamMinLen("HomeDirectoryMappings", 1)) 2663 } 2664 if s.Role == nil { 2665 invalidParams.Add(request.NewErrParamRequired("Role")) 2666 } 2667 if s.Role != nil && len(*s.Role) < 20 { 2668 invalidParams.Add(request.NewErrParamMinLen("Role", 20)) 2669 } 2670 if s.ServerId == nil { 2671 invalidParams.Add(request.NewErrParamRequired("ServerId")) 2672 } 2673 if s.ServerId != nil && len(*s.ServerId) < 19 { 2674 invalidParams.Add(request.NewErrParamMinLen("ServerId", 19)) 2675 } 2676 if s.Tags != nil && len(s.Tags) < 1 { 2677 invalidParams.Add(request.NewErrParamMinLen("Tags", 1)) 2678 } 2679 if s.UserName == nil { 2680 invalidParams.Add(request.NewErrParamRequired("UserName")) 2681 } 2682 if s.UserName != nil && len(*s.UserName) < 3 { 2683 invalidParams.Add(request.NewErrParamMinLen("UserName", 3)) 2684 } 2685 if s.HomeDirectoryMappings != nil { 2686 for i, v := range s.HomeDirectoryMappings { 2687 if v == nil { 2688 continue 2689 } 2690 if err := v.Validate(); err != nil { 2691 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "HomeDirectoryMappings", i), err.(request.ErrInvalidParams)) 2692 } 2693 } 2694 } 2695 if s.PosixProfile != nil { 2696 if err := s.PosixProfile.Validate(); err != nil { 2697 invalidParams.AddNested("PosixProfile", err.(request.ErrInvalidParams)) 2698 } 2699 } 2700 if s.Tags != nil { 2701 for i, v := range s.Tags { 2702 if v == nil { 2703 continue 2704 } 2705 if err := v.Validate(); err != nil { 2706 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Tags", i), err.(request.ErrInvalidParams)) 2707 } 2708 } 2709 } 2710 2711 if invalidParams.Len() > 0 { 2712 return invalidParams 2713 } 2714 return nil 2715} 2716 2717// SetHomeDirectory sets the HomeDirectory field's value. 2718func (s *CreateUserInput) SetHomeDirectory(v string) *CreateUserInput { 2719 s.HomeDirectory = &v 2720 return s 2721} 2722 2723// SetHomeDirectoryMappings sets the HomeDirectoryMappings field's value. 2724func (s *CreateUserInput) SetHomeDirectoryMappings(v []*HomeDirectoryMapEntry) *CreateUserInput { 2725 s.HomeDirectoryMappings = v 2726 return s 2727} 2728 2729// SetHomeDirectoryType sets the HomeDirectoryType field's value. 2730func (s *CreateUserInput) SetHomeDirectoryType(v string) *CreateUserInput { 2731 s.HomeDirectoryType = &v 2732 return s 2733} 2734 2735// SetPolicy sets the Policy field's value. 2736func (s *CreateUserInput) SetPolicy(v string) *CreateUserInput { 2737 s.Policy = &v 2738 return s 2739} 2740 2741// SetPosixProfile sets the PosixProfile field's value. 2742func (s *CreateUserInput) SetPosixProfile(v *PosixProfile) *CreateUserInput { 2743 s.PosixProfile = v 2744 return s 2745} 2746 2747// SetRole sets the Role field's value. 2748func (s *CreateUserInput) SetRole(v string) *CreateUserInput { 2749 s.Role = &v 2750 return s 2751} 2752 2753// SetServerId sets the ServerId field's value. 2754func (s *CreateUserInput) SetServerId(v string) *CreateUserInput { 2755 s.ServerId = &v 2756 return s 2757} 2758 2759// SetSshPublicKeyBody sets the SshPublicKeyBody field's value. 2760func (s *CreateUserInput) SetSshPublicKeyBody(v string) *CreateUserInput { 2761 s.SshPublicKeyBody = &v 2762 return s 2763} 2764 2765// SetTags sets the Tags field's value. 2766func (s *CreateUserInput) SetTags(v []*Tag) *CreateUserInput { 2767 s.Tags = v 2768 return s 2769} 2770 2771// SetUserName sets the UserName field's value. 2772func (s *CreateUserInput) SetUserName(v string) *CreateUserInput { 2773 s.UserName = &v 2774 return s 2775} 2776 2777type CreateUserOutput struct { 2778 _ struct{} `type:"structure"` 2779 2780 // The ID of the server that the user is attached to. 2781 // 2782 // ServerId is a required field 2783 ServerId *string `min:"19" type:"string" required:"true"` 2784 2785 // A unique string that identifies a user account associated with a server. 2786 // 2787 // UserName is a required field 2788 UserName *string `min:"3" type:"string" required:"true"` 2789} 2790 2791// String returns the string representation 2792func (s CreateUserOutput) String() string { 2793 return awsutil.Prettify(s) 2794} 2795 2796// GoString returns the string representation 2797func (s CreateUserOutput) GoString() string { 2798 return s.String() 2799} 2800 2801// SetServerId sets the ServerId field's value. 2802func (s *CreateUserOutput) SetServerId(v string) *CreateUserOutput { 2803 s.ServerId = &v 2804 return s 2805} 2806 2807// SetUserName sets the UserName field's value. 2808func (s *CreateUserOutput) SetUserName(v string) *CreateUserOutput { 2809 s.UserName = &v 2810 return s 2811} 2812 2813type DeleteServerInput struct { 2814 _ struct{} `type:"structure"` 2815 2816 // A unique system-assigned identifier for a server instance. 2817 // 2818 // ServerId is a required field 2819 ServerId *string `min:"19" type:"string" required:"true"` 2820} 2821 2822// String returns the string representation 2823func (s DeleteServerInput) String() string { 2824 return awsutil.Prettify(s) 2825} 2826 2827// GoString returns the string representation 2828func (s DeleteServerInput) GoString() string { 2829 return s.String() 2830} 2831 2832// Validate inspects the fields of the type to determine if they are valid. 2833func (s *DeleteServerInput) Validate() error { 2834 invalidParams := request.ErrInvalidParams{Context: "DeleteServerInput"} 2835 if s.ServerId == nil { 2836 invalidParams.Add(request.NewErrParamRequired("ServerId")) 2837 } 2838 if s.ServerId != nil && len(*s.ServerId) < 19 { 2839 invalidParams.Add(request.NewErrParamMinLen("ServerId", 19)) 2840 } 2841 2842 if invalidParams.Len() > 0 { 2843 return invalidParams 2844 } 2845 return nil 2846} 2847 2848// SetServerId sets the ServerId field's value. 2849func (s *DeleteServerInput) SetServerId(v string) *DeleteServerInput { 2850 s.ServerId = &v 2851 return s 2852} 2853 2854type DeleteServerOutput struct { 2855 _ struct{} `type:"structure"` 2856} 2857 2858// String returns the string representation 2859func (s DeleteServerOutput) String() string { 2860 return awsutil.Prettify(s) 2861} 2862 2863// GoString returns the string representation 2864func (s DeleteServerOutput) GoString() string { 2865 return s.String() 2866} 2867 2868type DeleteSshPublicKeyInput struct { 2869 _ struct{} `type:"structure"` 2870 2871 // A system-assigned unique identifier for a file transfer protocol-enabled 2872 // server instance that has the user assigned to it. 2873 // 2874 // ServerId is a required field 2875 ServerId *string `min:"19" type:"string" required:"true"` 2876 2877 // A unique identifier used to reference your user's specific SSH key. 2878 // 2879 // SshPublicKeyId is a required field 2880 SshPublicKeyId *string `min:"21" type:"string" required:"true"` 2881 2882 // A unique string that identifies a user whose public key is being deleted. 2883 // 2884 // UserName is a required field 2885 UserName *string `min:"3" type:"string" required:"true"` 2886} 2887 2888// String returns the string representation 2889func (s DeleteSshPublicKeyInput) String() string { 2890 return awsutil.Prettify(s) 2891} 2892 2893// GoString returns the string representation 2894func (s DeleteSshPublicKeyInput) GoString() string { 2895 return s.String() 2896} 2897 2898// Validate inspects the fields of the type to determine if they are valid. 2899func (s *DeleteSshPublicKeyInput) Validate() error { 2900 invalidParams := request.ErrInvalidParams{Context: "DeleteSshPublicKeyInput"} 2901 if s.ServerId == nil { 2902 invalidParams.Add(request.NewErrParamRequired("ServerId")) 2903 } 2904 if s.ServerId != nil && len(*s.ServerId) < 19 { 2905 invalidParams.Add(request.NewErrParamMinLen("ServerId", 19)) 2906 } 2907 if s.SshPublicKeyId == nil { 2908 invalidParams.Add(request.NewErrParamRequired("SshPublicKeyId")) 2909 } 2910 if s.SshPublicKeyId != nil && len(*s.SshPublicKeyId) < 21 { 2911 invalidParams.Add(request.NewErrParamMinLen("SshPublicKeyId", 21)) 2912 } 2913 if s.UserName == nil { 2914 invalidParams.Add(request.NewErrParamRequired("UserName")) 2915 } 2916 if s.UserName != nil && len(*s.UserName) < 3 { 2917 invalidParams.Add(request.NewErrParamMinLen("UserName", 3)) 2918 } 2919 2920 if invalidParams.Len() > 0 { 2921 return invalidParams 2922 } 2923 return nil 2924} 2925 2926// SetServerId sets the ServerId field's value. 2927func (s *DeleteSshPublicKeyInput) SetServerId(v string) *DeleteSshPublicKeyInput { 2928 s.ServerId = &v 2929 return s 2930} 2931 2932// SetSshPublicKeyId sets the SshPublicKeyId field's value. 2933func (s *DeleteSshPublicKeyInput) SetSshPublicKeyId(v string) *DeleteSshPublicKeyInput { 2934 s.SshPublicKeyId = &v 2935 return s 2936} 2937 2938// SetUserName sets the UserName field's value. 2939func (s *DeleteSshPublicKeyInput) SetUserName(v string) *DeleteSshPublicKeyInput { 2940 s.UserName = &v 2941 return s 2942} 2943 2944type DeleteSshPublicKeyOutput struct { 2945 _ struct{} `type:"structure"` 2946} 2947 2948// String returns the string representation 2949func (s DeleteSshPublicKeyOutput) String() string { 2950 return awsutil.Prettify(s) 2951} 2952 2953// GoString returns the string representation 2954func (s DeleteSshPublicKeyOutput) GoString() string { 2955 return s.String() 2956} 2957 2958type DeleteUserInput struct { 2959 _ struct{} `type:"structure"` 2960 2961 // A system-assigned unique identifier for a server instance that has the user 2962 // assigned to it. 2963 // 2964 // ServerId is a required field 2965 ServerId *string `min:"19" type:"string" required:"true"` 2966 2967 // A unique string that identifies a user that is being deleted from a server. 2968 // 2969 // UserName is a required field 2970 UserName *string `min:"3" type:"string" required:"true"` 2971} 2972 2973// String returns the string representation 2974func (s DeleteUserInput) String() string { 2975 return awsutil.Prettify(s) 2976} 2977 2978// GoString returns the string representation 2979func (s DeleteUserInput) GoString() string { 2980 return s.String() 2981} 2982 2983// Validate inspects the fields of the type to determine if they are valid. 2984func (s *DeleteUserInput) Validate() error { 2985 invalidParams := request.ErrInvalidParams{Context: "DeleteUserInput"} 2986 if s.ServerId == nil { 2987 invalidParams.Add(request.NewErrParamRequired("ServerId")) 2988 } 2989 if s.ServerId != nil && len(*s.ServerId) < 19 { 2990 invalidParams.Add(request.NewErrParamMinLen("ServerId", 19)) 2991 } 2992 if s.UserName == nil { 2993 invalidParams.Add(request.NewErrParamRequired("UserName")) 2994 } 2995 if s.UserName != nil && len(*s.UserName) < 3 { 2996 invalidParams.Add(request.NewErrParamMinLen("UserName", 3)) 2997 } 2998 2999 if invalidParams.Len() > 0 { 3000 return invalidParams 3001 } 3002 return nil 3003} 3004 3005// SetServerId sets the ServerId field's value. 3006func (s *DeleteUserInput) SetServerId(v string) *DeleteUserInput { 3007 s.ServerId = &v 3008 return s 3009} 3010 3011// SetUserName sets the UserName field's value. 3012func (s *DeleteUserInput) SetUserName(v string) *DeleteUserInput { 3013 s.UserName = &v 3014 return s 3015} 3016 3017type DeleteUserOutput struct { 3018 _ struct{} `type:"structure"` 3019} 3020 3021// String returns the string representation 3022func (s DeleteUserOutput) String() string { 3023 return awsutil.Prettify(s) 3024} 3025 3026// GoString returns the string representation 3027func (s DeleteUserOutput) GoString() string { 3028 return s.String() 3029} 3030 3031type DescribeSecurityPolicyInput struct { 3032 _ struct{} `type:"structure"` 3033 3034 // Specifies the name of the security policy that is attached to the server. 3035 // 3036 // SecurityPolicyName is a required field 3037 SecurityPolicyName *string `type:"string" required:"true"` 3038} 3039 3040// String returns the string representation 3041func (s DescribeSecurityPolicyInput) String() string { 3042 return awsutil.Prettify(s) 3043} 3044 3045// GoString returns the string representation 3046func (s DescribeSecurityPolicyInput) GoString() string { 3047 return s.String() 3048} 3049 3050// Validate inspects the fields of the type to determine if they are valid. 3051func (s *DescribeSecurityPolicyInput) Validate() error { 3052 invalidParams := request.ErrInvalidParams{Context: "DescribeSecurityPolicyInput"} 3053 if s.SecurityPolicyName == nil { 3054 invalidParams.Add(request.NewErrParamRequired("SecurityPolicyName")) 3055 } 3056 3057 if invalidParams.Len() > 0 { 3058 return invalidParams 3059 } 3060 return nil 3061} 3062 3063// SetSecurityPolicyName sets the SecurityPolicyName field's value. 3064func (s *DescribeSecurityPolicyInput) SetSecurityPolicyName(v string) *DescribeSecurityPolicyInput { 3065 s.SecurityPolicyName = &v 3066 return s 3067} 3068 3069type DescribeSecurityPolicyOutput struct { 3070 _ struct{} `type:"structure"` 3071 3072 // An array containing the properties of the security policy. 3073 // 3074 // SecurityPolicy is a required field 3075 SecurityPolicy *DescribedSecurityPolicy `type:"structure" required:"true"` 3076} 3077 3078// String returns the string representation 3079func (s DescribeSecurityPolicyOutput) String() string { 3080 return awsutil.Prettify(s) 3081} 3082 3083// GoString returns the string representation 3084func (s DescribeSecurityPolicyOutput) GoString() string { 3085 return s.String() 3086} 3087 3088// SetSecurityPolicy sets the SecurityPolicy field's value. 3089func (s *DescribeSecurityPolicyOutput) SetSecurityPolicy(v *DescribedSecurityPolicy) *DescribeSecurityPolicyOutput { 3090 s.SecurityPolicy = v 3091 return s 3092} 3093 3094type DescribeServerInput struct { 3095 _ struct{} `type:"structure"` 3096 3097 // A system-assigned unique identifier for a server. 3098 // 3099 // ServerId is a required field 3100 ServerId *string `min:"19" type:"string" required:"true"` 3101} 3102 3103// String returns the string representation 3104func (s DescribeServerInput) String() string { 3105 return awsutil.Prettify(s) 3106} 3107 3108// GoString returns the string representation 3109func (s DescribeServerInput) GoString() string { 3110 return s.String() 3111} 3112 3113// Validate inspects the fields of the type to determine if they are valid. 3114func (s *DescribeServerInput) Validate() error { 3115 invalidParams := request.ErrInvalidParams{Context: "DescribeServerInput"} 3116 if s.ServerId == nil { 3117 invalidParams.Add(request.NewErrParamRequired("ServerId")) 3118 } 3119 if s.ServerId != nil && len(*s.ServerId) < 19 { 3120 invalidParams.Add(request.NewErrParamMinLen("ServerId", 19)) 3121 } 3122 3123 if invalidParams.Len() > 0 { 3124 return invalidParams 3125 } 3126 return nil 3127} 3128 3129// SetServerId sets the ServerId field's value. 3130func (s *DescribeServerInput) SetServerId(v string) *DescribeServerInput { 3131 s.ServerId = &v 3132 return s 3133} 3134 3135type DescribeServerOutput struct { 3136 _ struct{} `type:"structure"` 3137 3138 // An array containing the properties of a server with the ServerID you specified. 3139 // 3140 // Server is a required field 3141 Server *DescribedServer `type:"structure" required:"true"` 3142} 3143 3144// String returns the string representation 3145func (s DescribeServerOutput) String() string { 3146 return awsutil.Prettify(s) 3147} 3148 3149// GoString returns the string representation 3150func (s DescribeServerOutput) GoString() string { 3151 return s.String() 3152} 3153 3154// SetServer sets the Server field's value. 3155func (s *DescribeServerOutput) SetServer(v *DescribedServer) *DescribeServerOutput { 3156 s.Server = v 3157 return s 3158} 3159 3160type DescribeUserInput struct { 3161 _ struct{} `type:"structure"` 3162 3163 // A system-assigned unique identifier for a server that has this user assigned. 3164 // 3165 // ServerId is a required field 3166 ServerId *string `min:"19" type:"string" required:"true"` 3167 3168 // The name of the user assigned to one or more servers. User names are part 3169 // of the sign-in credentials to use the AWS Transfer Family service and perform 3170 // file transfer tasks. 3171 // 3172 // UserName is a required field 3173 UserName *string `min:"3" type:"string" required:"true"` 3174} 3175 3176// String returns the string representation 3177func (s DescribeUserInput) String() string { 3178 return awsutil.Prettify(s) 3179} 3180 3181// GoString returns the string representation 3182func (s DescribeUserInput) GoString() string { 3183 return s.String() 3184} 3185 3186// Validate inspects the fields of the type to determine if they are valid. 3187func (s *DescribeUserInput) Validate() error { 3188 invalidParams := request.ErrInvalidParams{Context: "DescribeUserInput"} 3189 if s.ServerId == nil { 3190 invalidParams.Add(request.NewErrParamRequired("ServerId")) 3191 } 3192 if s.ServerId != nil && len(*s.ServerId) < 19 { 3193 invalidParams.Add(request.NewErrParamMinLen("ServerId", 19)) 3194 } 3195 if s.UserName == nil { 3196 invalidParams.Add(request.NewErrParamRequired("UserName")) 3197 } 3198 if s.UserName != nil && len(*s.UserName) < 3 { 3199 invalidParams.Add(request.NewErrParamMinLen("UserName", 3)) 3200 } 3201 3202 if invalidParams.Len() > 0 { 3203 return invalidParams 3204 } 3205 return nil 3206} 3207 3208// SetServerId sets the ServerId field's value. 3209func (s *DescribeUserInput) SetServerId(v string) *DescribeUserInput { 3210 s.ServerId = &v 3211 return s 3212} 3213 3214// SetUserName sets the UserName field's value. 3215func (s *DescribeUserInput) SetUserName(v string) *DescribeUserInput { 3216 s.UserName = &v 3217 return s 3218} 3219 3220type DescribeUserOutput struct { 3221 _ struct{} `type:"structure"` 3222 3223 // A system-assigned unique identifier for a server that has this user assigned. 3224 // 3225 // ServerId is a required field 3226 ServerId *string `min:"19" type:"string" required:"true"` 3227 3228 // An array containing the properties of the user account for the ServerID value 3229 // that you specified. 3230 // 3231 // User is a required field 3232 User *DescribedUser `type:"structure" required:"true"` 3233} 3234 3235// String returns the string representation 3236func (s DescribeUserOutput) String() string { 3237 return awsutil.Prettify(s) 3238} 3239 3240// GoString returns the string representation 3241func (s DescribeUserOutput) GoString() string { 3242 return s.String() 3243} 3244 3245// SetServerId sets the ServerId field's value. 3246func (s *DescribeUserOutput) SetServerId(v string) *DescribeUserOutput { 3247 s.ServerId = &v 3248 return s 3249} 3250 3251// SetUser sets the User field's value. 3252func (s *DescribeUserOutput) SetUser(v *DescribedUser) *DescribeUserOutput { 3253 s.User = v 3254 return s 3255} 3256 3257// Describes the properties of a security policy that was specified. For more 3258// information about security policies, see Working with security policies (https://docs.aws.amazon.com/transfer/latest/userguide/security-policies.html). 3259type DescribedSecurityPolicy struct { 3260 _ struct{} `type:"structure"` 3261 3262 // Specifies whether this policy enables Federal Information Processing Standards 3263 // (FIPS). 3264 Fips *bool `type:"boolean"` 3265 3266 // Specifies the name of the security policy that is attached to the server. 3267 // 3268 // SecurityPolicyName is a required field 3269 SecurityPolicyName *string `type:"string" required:"true"` 3270 3271 // Specifies the enabled Secure Shell (SSH) cipher encryption algorithms in 3272 // the security policy that is attached to the server. 3273 SshCiphers []*string `type:"list"` 3274 3275 // Specifies the enabled SSH key exchange (KEX) encryption algorithms in the 3276 // security policy that is attached to the server. 3277 SshKexs []*string `type:"list"` 3278 3279 // Specifies the enabled SSH message authentication code (MAC) encryption algorithms 3280 // in the security policy that is attached to the server. 3281 SshMacs []*string `type:"list"` 3282 3283 // Specifies the enabled Transport Layer Security (TLS) cipher encryption algorithms 3284 // in the security policy that is attached to the server. 3285 TlsCiphers []*string `type:"list"` 3286} 3287 3288// String returns the string representation 3289func (s DescribedSecurityPolicy) String() string { 3290 return awsutil.Prettify(s) 3291} 3292 3293// GoString returns the string representation 3294func (s DescribedSecurityPolicy) GoString() string { 3295 return s.String() 3296} 3297 3298// SetFips sets the Fips field's value. 3299func (s *DescribedSecurityPolicy) SetFips(v bool) *DescribedSecurityPolicy { 3300 s.Fips = &v 3301 return s 3302} 3303 3304// SetSecurityPolicyName sets the SecurityPolicyName field's value. 3305func (s *DescribedSecurityPolicy) SetSecurityPolicyName(v string) *DescribedSecurityPolicy { 3306 s.SecurityPolicyName = &v 3307 return s 3308} 3309 3310// SetSshCiphers sets the SshCiphers field's value. 3311func (s *DescribedSecurityPolicy) SetSshCiphers(v []*string) *DescribedSecurityPolicy { 3312 s.SshCiphers = v 3313 return s 3314} 3315 3316// SetSshKexs sets the SshKexs field's value. 3317func (s *DescribedSecurityPolicy) SetSshKexs(v []*string) *DescribedSecurityPolicy { 3318 s.SshKexs = v 3319 return s 3320} 3321 3322// SetSshMacs sets the SshMacs field's value. 3323func (s *DescribedSecurityPolicy) SetSshMacs(v []*string) *DescribedSecurityPolicy { 3324 s.SshMacs = v 3325 return s 3326} 3327 3328// SetTlsCiphers sets the TlsCiphers field's value. 3329func (s *DescribedSecurityPolicy) SetTlsCiphers(v []*string) *DescribedSecurityPolicy { 3330 s.TlsCiphers = v 3331 return s 3332} 3333 3334// Describes the properties of a file transfer protocol-enabled server that 3335// was specified. 3336type DescribedServer struct { 3337 _ struct{} `type:"structure"` 3338 3339 // Specifies the unique Amazon Resource Name (ARN) of the server. 3340 // 3341 // Arn is a required field 3342 Arn *string `min:"20" type:"string" required:"true"` 3343 3344 // Specifies the ARN of the AWS Certificate Manager (ACM) certificate. Required 3345 // when Protocols is set to FTPS. 3346 Certificate *string `type:"string"` 3347 3348 Domain *string `type:"string" enum:"Domain"` 3349 3350 // Specifies the virtual private cloud (VPC) endpoint settings that you configured 3351 // for your server. 3352 EndpointDetails *EndpointDetails `type:"structure"` 3353 3354 // Defines the type of endpoint that your server is connected to. If your server 3355 // is connected to a VPC endpoint, your server isn't accessible over the public 3356 // internet. 3357 EndpointType *string `type:"string" enum:"EndpointType"` 3358 3359 // Specifies the Base64-encoded SHA256 fingerprint of the server's host key. 3360 // This value is equivalent to the output of the ssh-keygen -l -f my-new-server-key 3361 // command. 3362 HostKeyFingerprint *string `type:"string"` 3363 3364 // Specifies information to call a customer-supplied authentication API. This 3365 // field is not populated when the IdentityProviderType of a server is SERVICE_MANAGED. 3366 IdentityProviderDetails *IdentityProviderDetails `type:"structure"` 3367 3368 // Specifies the mode of authentication method enabled for this service. A value 3369 // of SERVICE_MANAGED means that you are using this server to store and access 3370 // user credentials within the service. A value of API_GATEWAY indicates that 3371 // you have integrated an API Gateway endpoint that will be invoked for authenticating 3372 // your user into the service. 3373 IdentityProviderType *string `type:"string" enum:"IdentityProviderType"` 3374 3375 // Specifies the AWS Identity and Access Management (IAM) role that allows a 3376 // server to turn on Amazon CloudWatch logging for Amazon S3 events. When set, 3377 // user activity can be viewed in your CloudWatch logs. 3378 LoggingRole *string `min:"20" type:"string"` 3379 3380 // Specifies the file transfer protocol or protocols over which your file transfer 3381 // protocol client can connect to your server's endpoint. The available protocols 3382 // are: 3383 // 3384 // * SFTP (Secure Shell (SSH) File Transfer Protocol): File transfer over 3385 // SSH 3386 // 3387 // * FTPS (File Transfer Protocol Secure): File transfer with TLS encryption 3388 // 3389 // * FTP (File Transfer Protocol): Unencrypted file transfer 3390 Protocols []*string `min:"1" type:"list"` 3391 3392 // Specifies the name of the security policy that is attached to the server. 3393 SecurityPolicyName *string `type:"string"` 3394 3395 // Specifies the unique system-assigned identifier for a server that you instantiate. 3396 ServerId *string `min:"19" type:"string"` 3397 3398 // Specifies the condition of a server for the server that was described. A 3399 // value of ONLINE indicates that the server can accept jobs and transfer files. 3400 // A State value of OFFLINE means that the server cannot perform file transfer 3401 // operations. 3402 // 3403 // The states of STARTING and STOPPING indicate that the server is in an intermediate 3404 // state, either not fully able to respond, or not fully offline. The values 3405 // of START_FAILED or STOP_FAILED can indicate an error condition. 3406 State *string `type:"string" enum:"State"` 3407 3408 // Specifies the key-value pairs that you can use to search for and group servers 3409 // that were assigned to the server that was described. 3410 Tags []*Tag `min:"1" type:"list"` 3411 3412 // Specifies the number of users that are assigned to a server you specified 3413 // with the ServerId. 3414 UserCount *int64 `type:"integer"` 3415} 3416 3417// String returns the string representation 3418func (s DescribedServer) String() string { 3419 return awsutil.Prettify(s) 3420} 3421 3422// GoString returns the string representation 3423func (s DescribedServer) GoString() string { 3424 return s.String() 3425} 3426 3427// SetArn sets the Arn field's value. 3428func (s *DescribedServer) SetArn(v string) *DescribedServer { 3429 s.Arn = &v 3430 return s 3431} 3432 3433// SetCertificate sets the Certificate field's value. 3434func (s *DescribedServer) SetCertificate(v string) *DescribedServer { 3435 s.Certificate = &v 3436 return s 3437} 3438 3439// SetDomain sets the Domain field's value. 3440func (s *DescribedServer) SetDomain(v string) *DescribedServer { 3441 s.Domain = &v 3442 return s 3443} 3444 3445// SetEndpointDetails sets the EndpointDetails field's value. 3446func (s *DescribedServer) SetEndpointDetails(v *EndpointDetails) *DescribedServer { 3447 s.EndpointDetails = v 3448 return s 3449} 3450 3451// SetEndpointType sets the EndpointType field's value. 3452func (s *DescribedServer) SetEndpointType(v string) *DescribedServer { 3453 s.EndpointType = &v 3454 return s 3455} 3456 3457// SetHostKeyFingerprint sets the HostKeyFingerprint field's value. 3458func (s *DescribedServer) SetHostKeyFingerprint(v string) *DescribedServer { 3459 s.HostKeyFingerprint = &v 3460 return s 3461} 3462 3463// SetIdentityProviderDetails sets the IdentityProviderDetails field's value. 3464func (s *DescribedServer) SetIdentityProviderDetails(v *IdentityProviderDetails) *DescribedServer { 3465 s.IdentityProviderDetails = v 3466 return s 3467} 3468 3469// SetIdentityProviderType sets the IdentityProviderType field's value. 3470func (s *DescribedServer) SetIdentityProviderType(v string) *DescribedServer { 3471 s.IdentityProviderType = &v 3472 return s 3473} 3474 3475// SetLoggingRole sets the LoggingRole field's value. 3476func (s *DescribedServer) SetLoggingRole(v string) *DescribedServer { 3477 s.LoggingRole = &v 3478 return s 3479} 3480 3481// SetProtocols sets the Protocols field's value. 3482func (s *DescribedServer) SetProtocols(v []*string) *DescribedServer { 3483 s.Protocols = v 3484 return s 3485} 3486 3487// SetSecurityPolicyName sets the SecurityPolicyName field's value. 3488func (s *DescribedServer) SetSecurityPolicyName(v string) *DescribedServer { 3489 s.SecurityPolicyName = &v 3490 return s 3491} 3492 3493// SetServerId sets the ServerId field's value. 3494func (s *DescribedServer) SetServerId(v string) *DescribedServer { 3495 s.ServerId = &v 3496 return s 3497} 3498 3499// SetState sets the State field's value. 3500func (s *DescribedServer) SetState(v string) *DescribedServer { 3501 s.State = &v 3502 return s 3503} 3504 3505// SetTags sets the Tags field's value. 3506func (s *DescribedServer) SetTags(v []*Tag) *DescribedServer { 3507 s.Tags = v 3508 return s 3509} 3510 3511// SetUserCount sets the UserCount field's value. 3512func (s *DescribedServer) SetUserCount(v int64) *DescribedServer { 3513 s.UserCount = &v 3514 return s 3515} 3516 3517// Describes the properties of a user that was specified. 3518type DescribedUser struct { 3519 _ struct{} `type:"structure"` 3520 3521 // Specifies the unique Amazon Resource Name (ARN) for the user that was requested 3522 // to be described. 3523 // 3524 // Arn is a required field 3525 Arn *string `min:"20" type:"string" required:"true"` 3526 3527 // Specifies the landing directory (or folder), which is the location that files 3528 // are written to or read from in an Amazon S3 bucket, for the described user. 3529 // An example is your-Amazon-S3-bucket-name>/home/username . 3530 HomeDirectory *string `type:"string"` 3531 3532 // Specifies the logical directory mappings that specify what Amazon S3 paths 3533 // and keys should be visible to your user and how you want to make them visible. 3534 // You will need to specify the "Entry" and "Target" pair, where Entry shows 3535 // how the path is made visible and Target is the actual Amazon S3 path. If 3536 // you only specify a target, it will be displayed as is. You will need to also 3537 // make sure that your AWS Identity and Access Management (IAM) role provides 3538 // access to paths in Target. 3539 // 3540 // In most cases, you can use this value instead of the scope-down policy to 3541 // lock your user down to the designated home directory ("chroot"). To do this, 3542 // you can set Entry to '/' and set Target to the HomeDirectory parameter value. 3543 HomeDirectoryMappings []*HomeDirectoryMapEntry `min:"1" type:"list"` 3544 3545 // Specifies the type of landing directory (folder) you mapped for your users 3546 // to see when they log into the file transfer protocol-enabled server. If you 3547 // set it to PATH, the user will see the absolute Amazon S3 bucket paths as 3548 // is in their file transfer protocol clients. If you set it LOGICAL, you will 3549 // need to provide mappings in the HomeDirectoryMappings for how you want to 3550 // make Amazon S3 paths visible to your users. 3551 HomeDirectoryType *string `type:"string" enum:"HomeDirectoryType"` 3552 3553 // Specifies the name of the policy in use for the described user. 3554 Policy *string `type:"string"` 3555 3556 PosixProfile *PosixProfile `type:"structure"` 3557 3558 // Specifies the IAM role that controls your users' access to your Amazon S3 3559 // bucket. The policies attached to this role will determine the level of access 3560 // you want to provide your users when transferring files into and out of your 3561 // Amazon S3 bucket or buckets. The IAM role should also contain a trust relationship 3562 // that allows a server to access your resources when servicing your users' 3563 // transfer requests. 3564 Role *string `min:"20" type:"string"` 3565 3566 // Specifies the public key portion of the Secure Shell (SSH) keys stored for 3567 // the described user. 3568 SshPublicKeys []*SshPublicKey `type:"list"` 3569 3570 // Specifies the key-value pairs for the user requested. Tag can be used to 3571 // search for and group users for a variety of purposes. 3572 Tags []*Tag `min:"1" type:"list"` 3573 3574 // Specifies the name of the user that was requested to be described. User names 3575 // are used for authentication purposes. This is the string that will be used 3576 // by your user when they log in to your server. 3577 UserName *string `min:"3" type:"string"` 3578} 3579 3580// String returns the string representation 3581func (s DescribedUser) String() string { 3582 return awsutil.Prettify(s) 3583} 3584 3585// GoString returns the string representation 3586func (s DescribedUser) GoString() string { 3587 return s.String() 3588} 3589 3590// SetArn sets the Arn field's value. 3591func (s *DescribedUser) SetArn(v string) *DescribedUser { 3592 s.Arn = &v 3593 return s 3594} 3595 3596// SetHomeDirectory sets the HomeDirectory field's value. 3597func (s *DescribedUser) SetHomeDirectory(v string) *DescribedUser { 3598 s.HomeDirectory = &v 3599 return s 3600} 3601 3602// SetHomeDirectoryMappings sets the HomeDirectoryMappings field's value. 3603func (s *DescribedUser) SetHomeDirectoryMappings(v []*HomeDirectoryMapEntry) *DescribedUser { 3604 s.HomeDirectoryMappings = v 3605 return s 3606} 3607 3608// SetHomeDirectoryType sets the HomeDirectoryType field's value. 3609func (s *DescribedUser) SetHomeDirectoryType(v string) *DescribedUser { 3610 s.HomeDirectoryType = &v 3611 return s 3612} 3613 3614// SetPolicy sets the Policy field's value. 3615func (s *DescribedUser) SetPolicy(v string) *DescribedUser { 3616 s.Policy = &v 3617 return s 3618} 3619 3620// SetPosixProfile sets the PosixProfile field's value. 3621func (s *DescribedUser) SetPosixProfile(v *PosixProfile) *DescribedUser { 3622 s.PosixProfile = v 3623 return s 3624} 3625 3626// SetRole sets the Role field's value. 3627func (s *DescribedUser) SetRole(v string) *DescribedUser { 3628 s.Role = &v 3629 return s 3630} 3631 3632// SetSshPublicKeys sets the SshPublicKeys field's value. 3633func (s *DescribedUser) SetSshPublicKeys(v []*SshPublicKey) *DescribedUser { 3634 s.SshPublicKeys = v 3635 return s 3636} 3637 3638// SetTags sets the Tags field's value. 3639func (s *DescribedUser) SetTags(v []*Tag) *DescribedUser { 3640 s.Tags = v 3641 return s 3642} 3643 3644// SetUserName sets the UserName field's value. 3645func (s *DescribedUser) SetUserName(v string) *DescribedUser { 3646 s.UserName = &v 3647 return s 3648} 3649 3650// The virtual private cloud (VPC) endpoint settings that are configured for 3651// your file transfer protocol-enabled server. With a VPC endpoint, you can 3652// restrict access to your server and resources only within your VPC. To control 3653// incoming internet traffic, invoke the UpdateServer API and attach an Elastic 3654// IP to your server's endpoint. 3655type EndpointDetails struct { 3656 _ struct{} `type:"structure"` 3657 3658 // A list of address allocation IDs that are required to attach an Elastic IP 3659 // address to your server's endpoint. 3660 // 3661 // This property can only be set when EndpointType is set to VPC and it is only 3662 // valid in the UpdateServer API. 3663 AddressAllocationIds []*string `type:"list"` 3664 3665 // A list of security groups IDs that are available to attach to your server's 3666 // endpoint. 3667 // 3668 // This property can only be set when EndpointType is set to VPC. 3669 // 3670 // You can only edit the SecurityGroupIds property in the UpdateServer API and 3671 // only if you are changing the EndpointType from PUBLIC or VPC_ENDPOINT to 3672 // VPC. 3673 SecurityGroupIds []*string `type:"list"` 3674 3675 // A list of subnet IDs that are required to host your server endpoint in your 3676 // VPC. 3677 // 3678 // This property can only be set when EndpointType is set to VPC. 3679 SubnetIds []*string `type:"list"` 3680 3681 // The ID of the VPC endpoint. 3682 // 3683 // This property can only be set when EndpointType is set to VPC_ENDPOINT. 3684 VpcEndpointId *string `min:"22" type:"string"` 3685 3686 // The VPC ID of the VPC in which a server's endpoint will be hosted. 3687 // 3688 // This property can only be set when EndpointType is set to VPC. 3689 VpcId *string `type:"string"` 3690} 3691 3692// String returns the string representation 3693func (s EndpointDetails) String() string { 3694 return awsutil.Prettify(s) 3695} 3696 3697// GoString returns the string representation 3698func (s EndpointDetails) GoString() string { 3699 return s.String() 3700} 3701 3702// Validate inspects the fields of the type to determine if they are valid. 3703func (s *EndpointDetails) Validate() error { 3704 invalidParams := request.ErrInvalidParams{Context: "EndpointDetails"} 3705 if s.VpcEndpointId != nil && len(*s.VpcEndpointId) < 22 { 3706 invalidParams.Add(request.NewErrParamMinLen("VpcEndpointId", 22)) 3707 } 3708 3709 if invalidParams.Len() > 0 { 3710 return invalidParams 3711 } 3712 return nil 3713} 3714 3715// SetAddressAllocationIds sets the AddressAllocationIds field's value. 3716func (s *EndpointDetails) SetAddressAllocationIds(v []*string) *EndpointDetails { 3717 s.AddressAllocationIds = v 3718 return s 3719} 3720 3721// SetSecurityGroupIds sets the SecurityGroupIds field's value. 3722func (s *EndpointDetails) SetSecurityGroupIds(v []*string) *EndpointDetails { 3723 s.SecurityGroupIds = v 3724 return s 3725} 3726 3727// SetSubnetIds sets the SubnetIds field's value. 3728func (s *EndpointDetails) SetSubnetIds(v []*string) *EndpointDetails { 3729 s.SubnetIds = v 3730 return s 3731} 3732 3733// SetVpcEndpointId sets the VpcEndpointId field's value. 3734func (s *EndpointDetails) SetVpcEndpointId(v string) *EndpointDetails { 3735 s.VpcEndpointId = &v 3736 return s 3737} 3738 3739// SetVpcId sets the VpcId field's value. 3740func (s *EndpointDetails) SetVpcId(v string) *EndpointDetails { 3741 s.VpcId = &v 3742 return s 3743} 3744 3745// Represents an object that contains entries and targets for HomeDirectoryMappings. 3746type HomeDirectoryMapEntry struct { 3747 _ struct{} `type:"structure"` 3748 3749 // Represents an entry and a target for HomeDirectoryMappings. 3750 // 3751 // Entry is a required field 3752 Entry *string `type:"string" required:"true"` 3753 3754 // Represents the map target that is used in a HomeDirectorymapEntry. 3755 // 3756 // Target is a required field 3757 Target *string `type:"string" required:"true"` 3758} 3759 3760// String returns the string representation 3761func (s HomeDirectoryMapEntry) String() string { 3762 return awsutil.Prettify(s) 3763} 3764 3765// GoString returns the string representation 3766func (s HomeDirectoryMapEntry) GoString() string { 3767 return s.String() 3768} 3769 3770// Validate inspects the fields of the type to determine if they are valid. 3771func (s *HomeDirectoryMapEntry) Validate() error { 3772 invalidParams := request.ErrInvalidParams{Context: "HomeDirectoryMapEntry"} 3773 if s.Entry == nil { 3774 invalidParams.Add(request.NewErrParamRequired("Entry")) 3775 } 3776 if s.Target == nil { 3777 invalidParams.Add(request.NewErrParamRequired("Target")) 3778 } 3779 3780 if invalidParams.Len() > 0 { 3781 return invalidParams 3782 } 3783 return nil 3784} 3785 3786// SetEntry sets the Entry field's value. 3787func (s *HomeDirectoryMapEntry) SetEntry(v string) *HomeDirectoryMapEntry { 3788 s.Entry = &v 3789 return s 3790} 3791 3792// SetTarget sets the Target field's value. 3793func (s *HomeDirectoryMapEntry) SetTarget(v string) *HomeDirectoryMapEntry { 3794 s.Target = &v 3795 return s 3796} 3797 3798// Returns information related to the type of user authentication that is in 3799// use for a file transfer protocol-enabled server's users. A server can have 3800// only one method of authentication. 3801type IdentityProviderDetails struct { 3802 _ struct{} `type:"structure"` 3803 3804 // Provides the type of InvocationRole used to authenticate the user account. 3805 InvocationRole *string `min:"20" type:"string"` 3806 3807 // Provides the location of the service endpoint used to authenticate users. 3808 Url *string `type:"string"` 3809} 3810 3811// String returns the string representation 3812func (s IdentityProviderDetails) String() string { 3813 return awsutil.Prettify(s) 3814} 3815 3816// GoString returns the string representation 3817func (s IdentityProviderDetails) GoString() string { 3818 return s.String() 3819} 3820 3821// Validate inspects the fields of the type to determine if they are valid. 3822func (s *IdentityProviderDetails) Validate() error { 3823 invalidParams := request.ErrInvalidParams{Context: "IdentityProviderDetails"} 3824 if s.InvocationRole != nil && len(*s.InvocationRole) < 20 { 3825 invalidParams.Add(request.NewErrParamMinLen("InvocationRole", 20)) 3826 } 3827 3828 if invalidParams.Len() > 0 { 3829 return invalidParams 3830 } 3831 return nil 3832} 3833 3834// SetInvocationRole sets the InvocationRole field's value. 3835func (s *IdentityProviderDetails) SetInvocationRole(v string) *IdentityProviderDetails { 3836 s.InvocationRole = &v 3837 return s 3838} 3839 3840// SetUrl sets the Url field's value. 3841func (s *IdentityProviderDetails) SetUrl(v string) *IdentityProviderDetails { 3842 s.Url = &v 3843 return s 3844} 3845 3846type ImportSshPublicKeyInput struct { 3847 _ struct{} `type:"structure"` 3848 3849 // A system-assigned unique identifier for a server. 3850 // 3851 // ServerId is a required field 3852 ServerId *string `min:"19" type:"string" required:"true"` 3853 3854 // The public key portion of an SSH key pair. 3855 // 3856 // SshPublicKeyBody is a required field 3857 SshPublicKeyBody *string `type:"string" required:"true"` 3858 3859 // The name of the user account that is assigned to one or more servers. 3860 // 3861 // UserName is a required field 3862 UserName *string `min:"3" type:"string" required:"true"` 3863} 3864 3865// String returns the string representation 3866func (s ImportSshPublicKeyInput) String() string { 3867 return awsutil.Prettify(s) 3868} 3869 3870// GoString returns the string representation 3871func (s ImportSshPublicKeyInput) GoString() string { 3872 return s.String() 3873} 3874 3875// Validate inspects the fields of the type to determine if they are valid. 3876func (s *ImportSshPublicKeyInput) Validate() error { 3877 invalidParams := request.ErrInvalidParams{Context: "ImportSshPublicKeyInput"} 3878 if s.ServerId == nil { 3879 invalidParams.Add(request.NewErrParamRequired("ServerId")) 3880 } 3881 if s.ServerId != nil && len(*s.ServerId) < 19 { 3882 invalidParams.Add(request.NewErrParamMinLen("ServerId", 19)) 3883 } 3884 if s.SshPublicKeyBody == nil { 3885 invalidParams.Add(request.NewErrParamRequired("SshPublicKeyBody")) 3886 } 3887 if s.UserName == nil { 3888 invalidParams.Add(request.NewErrParamRequired("UserName")) 3889 } 3890 if s.UserName != nil && len(*s.UserName) < 3 { 3891 invalidParams.Add(request.NewErrParamMinLen("UserName", 3)) 3892 } 3893 3894 if invalidParams.Len() > 0 { 3895 return invalidParams 3896 } 3897 return nil 3898} 3899 3900// SetServerId sets the ServerId field's value. 3901func (s *ImportSshPublicKeyInput) SetServerId(v string) *ImportSshPublicKeyInput { 3902 s.ServerId = &v 3903 return s 3904} 3905 3906// SetSshPublicKeyBody sets the SshPublicKeyBody field's value. 3907func (s *ImportSshPublicKeyInput) SetSshPublicKeyBody(v string) *ImportSshPublicKeyInput { 3908 s.SshPublicKeyBody = &v 3909 return s 3910} 3911 3912// SetUserName sets the UserName field's value. 3913func (s *ImportSshPublicKeyInput) SetUserName(v string) *ImportSshPublicKeyInput { 3914 s.UserName = &v 3915 return s 3916} 3917 3918// Identifies the user, the server they belong to, and the identifier of the 3919// SSH public key associated with that user. A user can have more than one key 3920// on each server that they are associated with. 3921type ImportSshPublicKeyOutput struct { 3922 _ struct{} `type:"structure"` 3923 3924 // A system-assigned unique identifier for a server. 3925 // 3926 // ServerId is a required field 3927 ServerId *string `min:"19" type:"string" required:"true"` 3928 3929 // The name given to a public key by the system that was imported. 3930 // 3931 // SshPublicKeyId is a required field 3932 SshPublicKeyId *string `min:"21" type:"string" required:"true"` 3933 3934 // A user name assigned to the ServerID value that you specified. 3935 // 3936 // UserName is a required field 3937 UserName *string `min:"3" type:"string" required:"true"` 3938} 3939 3940// String returns the string representation 3941func (s ImportSshPublicKeyOutput) String() string { 3942 return awsutil.Prettify(s) 3943} 3944 3945// GoString returns the string representation 3946func (s ImportSshPublicKeyOutput) GoString() string { 3947 return s.String() 3948} 3949 3950// SetServerId sets the ServerId field's value. 3951func (s *ImportSshPublicKeyOutput) SetServerId(v string) *ImportSshPublicKeyOutput { 3952 s.ServerId = &v 3953 return s 3954} 3955 3956// SetSshPublicKeyId sets the SshPublicKeyId field's value. 3957func (s *ImportSshPublicKeyOutput) SetSshPublicKeyId(v string) *ImportSshPublicKeyOutput { 3958 s.SshPublicKeyId = &v 3959 return s 3960} 3961 3962// SetUserName sets the UserName field's value. 3963func (s *ImportSshPublicKeyOutput) SetUserName(v string) *ImportSshPublicKeyOutput { 3964 s.UserName = &v 3965 return s 3966} 3967 3968// This exception is thrown when an error occurs in the AWS Transfer Family 3969// service. 3970type InternalServiceError struct { 3971 _ struct{} `type:"structure"` 3972 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 3973 3974 Message_ *string `locationName:"Message" type:"string"` 3975} 3976 3977// String returns the string representation 3978func (s InternalServiceError) String() string { 3979 return awsutil.Prettify(s) 3980} 3981 3982// GoString returns the string representation 3983func (s InternalServiceError) GoString() string { 3984 return s.String() 3985} 3986 3987func newErrorInternalServiceError(v protocol.ResponseMetadata) error { 3988 return &InternalServiceError{ 3989 RespMetadata: v, 3990 } 3991} 3992 3993// Code returns the exception type name. 3994func (s *InternalServiceError) Code() string { 3995 return "InternalServiceError" 3996} 3997 3998// Message returns the exception's message. 3999func (s *InternalServiceError) Message() string { 4000 if s.Message_ != nil { 4001 return *s.Message_ 4002 } 4003 return "" 4004} 4005 4006// OrigErr always returns nil, satisfies awserr.Error interface. 4007func (s *InternalServiceError) OrigErr() error { 4008 return nil 4009} 4010 4011func (s *InternalServiceError) Error() string { 4012 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 4013} 4014 4015// Status code returns the HTTP status code for the request's response error. 4016func (s *InternalServiceError) StatusCode() int { 4017 return s.RespMetadata.StatusCode 4018} 4019 4020// RequestID returns the service's response RequestID for request. 4021func (s *InternalServiceError) RequestID() string { 4022 return s.RespMetadata.RequestID 4023} 4024 4025// The NextToken parameter that was passed is invalid. 4026type InvalidNextTokenException struct { 4027 _ struct{} `type:"structure"` 4028 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 4029 4030 Message_ *string `locationName:"Message" type:"string"` 4031} 4032 4033// String returns the string representation 4034func (s InvalidNextTokenException) String() string { 4035 return awsutil.Prettify(s) 4036} 4037 4038// GoString returns the string representation 4039func (s InvalidNextTokenException) GoString() string { 4040 return s.String() 4041} 4042 4043func newErrorInvalidNextTokenException(v protocol.ResponseMetadata) error { 4044 return &InvalidNextTokenException{ 4045 RespMetadata: v, 4046 } 4047} 4048 4049// Code returns the exception type name. 4050func (s *InvalidNextTokenException) Code() string { 4051 return "InvalidNextTokenException" 4052} 4053 4054// Message returns the exception's message. 4055func (s *InvalidNextTokenException) Message() string { 4056 if s.Message_ != nil { 4057 return *s.Message_ 4058 } 4059 return "" 4060} 4061 4062// OrigErr always returns nil, satisfies awserr.Error interface. 4063func (s *InvalidNextTokenException) OrigErr() error { 4064 return nil 4065} 4066 4067func (s *InvalidNextTokenException) Error() string { 4068 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 4069} 4070 4071// Status code returns the HTTP status code for the request's response error. 4072func (s *InvalidNextTokenException) StatusCode() int { 4073 return s.RespMetadata.StatusCode 4074} 4075 4076// RequestID returns the service's response RequestID for request. 4077func (s *InvalidNextTokenException) RequestID() string { 4078 return s.RespMetadata.RequestID 4079} 4080 4081// This exception is thrown when the client submits a malformed request. 4082type InvalidRequestException struct { 4083 _ struct{} `type:"structure"` 4084 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 4085 4086 Message_ *string `locationName:"Message" type:"string"` 4087} 4088 4089// String returns the string representation 4090func (s InvalidRequestException) String() string { 4091 return awsutil.Prettify(s) 4092} 4093 4094// GoString returns the string representation 4095func (s InvalidRequestException) GoString() string { 4096 return s.String() 4097} 4098 4099func newErrorInvalidRequestException(v protocol.ResponseMetadata) error { 4100 return &InvalidRequestException{ 4101 RespMetadata: v, 4102 } 4103} 4104 4105// Code returns the exception type name. 4106func (s *InvalidRequestException) Code() string { 4107 return "InvalidRequestException" 4108} 4109 4110// Message returns the exception's message. 4111func (s *InvalidRequestException) Message() string { 4112 if s.Message_ != nil { 4113 return *s.Message_ 4114 } 4115 return "" 4116} 4117 4118// OrigErr always returns nil, satisfies awserr.Error interface. 4119func (s *InvalidRequestException) OrigErr() error { 4120 return nil 4121} 4122 4123func (s *InvalidRequestException) Error() string { 4124 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 4125} 4126 4127// Status code returns the HTTP status code for the request's response error. 4128func (s *InvalidRequestException) StatusCode() int { 4129 return s.RespMetadata.StatusCode 4130} 4131 4132// RequestID returns the service's response RequestID for request. 4133func (s *InvalidRequestException) RequestID() string { 4134 return s.RespMetadata.RequestID 4135} 4136 4137type ListSecurityPoliciesInput struct { 4138 _ struct{} `type:"structure"` 4139 4140 // Specifies the number of security policies to return as a response to the 4141 // ListSecurityPolicies query. 4142 MaxResults *int64 `min:"1" type:"integer"` 4143 4144 // When additional results are obtained from the ListSecurityPolicies command, 4145 // a NextToken parameter is returned in the output. You can then pass the NextToken 4146 // parameter in a subsequent command to continue listing additional security 4147 // policies. 4148 NextToken *string `min:"1" type:"string"` 4149} 4150 4151// String returns the string representation 4152func (s ListSecurityPoliciesInput) String() string { 4153 return awsutil.Prettify(s) 4154} 4155 4156// GoString returns the string representation 4157func (s ListSecurityPoliciesInput) GoString() string { 4158 return s.String() 4159} 4160 4161// Validate inspects the fields of the type to determine if they are valid. 4162func (s *ListSecurityPoliciesInput) Validate() error { 4163 invalidParams := request.ErrInvalidParams{Context: "ListSecurityPoliciesInput"} 4164 if s.MaxResults != nil && *s.MaxResults < 1 { 4165 invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) 4166 } 4167 if s.NextToken != nil && len(*s.NextToken) < 1 { 4168 invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) 4169 } 4170 4171 if invalidParams.Len() > 0 { 4172 return invalidParams 4173 } 4174 return nil 4175} 4176 4177// SetMaxResults sets the MaxResults field's value. 4178func (s *ListSecurityPoliciesInput) SetMaxResults(v int64) *ListSecurityPoliciesInput { 4179 s.MaxResults = &v 4180 return s 4181} 4182 4183// SetNextToken sets the NextToken field's value. 4184func (s *ListSecurityPoliciesInput) SetNextToken(v string) *ListSecurityPoliciesInput { 4185 s.NextToken = &v 4186 return s 4187} 4188 4189type ListSecurityPoliciesOutput struct { 4190 _ struct{} `type:"structure"` 4191 4192 // When you can get additional results from the ListSecurityPolicies operation, 4193 // a NextToken parameter is returned in the output. In a following command, 4194 // you can pass in the NextToken parameter to continue listing security policies. 4195 NextToken *string `min:"1" type:"string"` 4196 4197 // An array of security policies that were listed. 4198 // 4199 // SecurityPolicyNames is a required field 4200 SecurityPolicyNames []*string `type:"list" required:"true"` 4201} 4202 4203// String returns the string representation 4204func (s ListSecurityPoliciesOutput) String() string { 4205 return awsutil.Prettify(s) 4206} 4207 4208// GoString returns the string representation 4209func (s ListSecurityPoliciesOutput) GoString() string { 4210 return s.String() 4211} 4212 4213// SetNextToken sets the NextToken field's value. 4214func (s *ListSecurityPoliciesOutput) SetNextToken(v string) *ListSecurityPoliciesOutput { 4215 s.NextToken = &v 4216 return s 4217} 4218 4219// SetSecurityPolicyNames sets the SecurityPolicyNames field's value. 4220func (s *ListSecurityPoliciesOutput) SetSecurityPolicyNames(v []*string) *ListSecurityPoliciesOutput { 4221 s.SecurityPolicyNames = v 4222 return s 4223} 4224 4225type ListServersInput struct { 4226 _ struct{} `type:"structure"` 4227 4228 // Specifies the number of servers to return as a response to the ListServers 4229 // query. 4230 MaxResults *int64 `min:"1" type:"integer"` 4231 4232 // When additional results are obtained from the ListServers command, a NextToken 4233 // parameter is returned in the output. You can then pass the NextToken parameter 4234 // in a subsequent command to continue listing additional servers. 4235 NextToken *string `min:"1" type:"string"` 4236} 4237 4238// String returns the string representation 4239func (s ListServersInput) String() string { 4240 return awsutil.Prettify(s) 4241} 4242 4243// GoString returns the string representation 4244func (s ListServersInput) GoString() string { 4245 return s.String() 4246} 4247 4248// Validate inspects the fields of the type to determine if they are valid. 4249func (s *ListServersInput) Validate() error { 4250 invalidParams := request.ErrInvalidParams{Context: "ListServersInput"} 4251 if s.MaxResults != nil && *s.MaxResults < 1 { 4252 invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) 4253 } 4254 if s.NextToken != nil && len(*s.NextToken) < 1 { 4255 invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) 4256 } 4257 4258 if invalidParams.Len() > 0 { 4259 return invalidParams 4260 } 4261 return nil 4262} 4263 4264// SetMaxResults sets the MaxResults field's value. 4265func (s *ListServersInput) SetMaxResults(v int64) *ListServersInput { 4266 s.MaxResults = &v 4267 return s 4268} 4269 4270// SetNextToken sets the NextToken field's value. 4271func (s *ListServersInput) SetNextToken(v string) *ListServersInput { 4272 s.NextToken = &v 4273 return s 4274} 4275 4276type ListServersOutput struct { 4277 _ struct{} `type:"structure"` 4278 4279 // When you can get additional results from the ListServers operation, a NextToken 4280 // parameter is returned in the output. In a following command, you can pass 4281 // in the NextToken parameter to continue listing additional servers. 4282 NextToken *string `min:"1" type:"string"` 4283 4284 // An array of servers that were listed. 4285 // 4286 // Servers is a required field 4287 Servers []*ListedServer `type:"list" required:"true"` 4288} 4289 4290// String returns the string representation 4291func (s ListServersOutput) String() string { 4292 return awsutil.Prettify(s) 4293} 4294 4295// GoString returns the string representation 4296func (s ListServersOutput) GoString() string { 4297 return s.String() 4298} 4299 4300// SetNextToken sets the NextToken field's value. 4301func (s *ListServersOutput) SetNextToken(v string) *ListServersOutput { 4302 s.NextToken = &v 4303 return s 4304} 4305 4306// SetServers sets the Servers field's value. 4307func (s *ListServersOutput) SetServers(v []*ListedServer) *ListServersOutput { 4308 s.Servers = v 4309 return s 4310} 4311 4312type ListTagsForResourceInput struct { 4313 _ struct{} `type:"structure"` 4314 4315 // Requests the tags associated with a particular Amazon Resource Name (ARN). 4316 // An ARN is an identifier for a specific AWS resource, such as a server, user, 4317 // or role. 4318 // 4319 // Arn is a required field 4320 Arn *string `min:"20" type:"string" required:"true"` 4321 4322 // Specifies the number of tags to return as a response to the ListTagsForResource 4323 // request. 4324 MaxResults *int64 `min:"1" type:"integer"` 4325 4326 // When you request additional results from the ListTagsForResource operation, 4327 // a NextToken parameter is returned in the input. You can then pass in a subsequent 4328 // command to the NextToken parameter to continue listing additional tags. 4329 NextToken *string `min:"1" type:"string"` 4330} 4331 4332// String returns the string representation 4333func (s ListTagsForResourceInput) String() string { 4334 return awsutil.Prettify(s) 4335} 4336 4337// GoString returns the string representation 4338func (s ListTagsForResourceInput) GoString() string { 4339 return s.String() 4340} 4341 4342// Validate inspects the fields of the type to determine if they are valid. 4343func (s *ListTagsForResourceInput) Validate() error { 4344 invalidParams := request.ErrInvalidParams{Context: "ListTagsForResourceInput"} 4345 if s.Arn == nil { 4346 invalidParams.Add(request.NewErrParamRequired("Arn")) 4347 } 4348 if s.Arn != nil && len(*s.Arn) < 20 { 4349 invalidParams.Add(request.NewErrParamMinLen("Arn", 20)) 4350 } 4351 if s.MaxResults != nil && *s.MaxResults < 1 { 4352 invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) 4353 } 4354 if s.NextToken != nil && len(*s.NextToken) < 1 { 4355 invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) 4356 } 4357 4358 if invalidParams.Len() > 0 { 4359 return invalidParams 4360 } 4361 return nil 4362} 4363 4364// SetArn sets the Arn field's value. 4365func (s *ListTagsForResourceInput) SetArn(v string) *ListTagsForResourceInput { 4366 s.Arn = &v 4367 return s 4368} 4369 4370// SetMaxResults sets the MaxResults field's value. 4371func (s *ListTagsForResourceInput) SetMaxResults(v int64) *ListTagsForResourceInput { 4372 s.MaxResults = &v 4373 return s 4374} 4375 4376// SetNextToken sets the NextToken field's value. 4377func (s *ListTagsForResourceInput) SetNextToken(v string) *ListTagsForResourceInput { 4378 s.NextToken = &v 4379 return s 4380} 4381 4382type ListTagsForResourceOutput struct { 4383 _ struct{} `type:"structure"` 4384 4385 // The ARN you specified to list the tags of. 4386 Arn *string `min:"20" type:"string"` 4387 4388 // When you can get additional results from the ListTagsForResource call, a 4389 // NextToken parameter is returned in the output. You can then pass in a subsequent 4390 // command to the NextToken parameter to continue listing additional tags. 4391 NextToken *string `min:"1" type:"string"` 4392 4393 // Key-value pairs that are assigned to a resource, usually for the purpose 4394 // of grouping and searching for items. Tags are metadata that you define. 4395 Tags []*Tag `min:"1" type:"list"` 4396} 4397 4398// String returns the string representation 4399func (s ListTagsForResourceOutput) String() string { 4400 return awsutil.Prettify(s) 4401} 4402 4403// GoString returns the string representation 4404func (s ListTagsForResourceOutput) GoString() string { 4405 return s.String() 4406} 4407 4408// SetArn sets the Arn field's value. 4409func (s *ListTagsForResourceOutput) SetArn(v string) *ListTagsForResourceOutput { 4410 s.Arn = &v 4411 return s 4412} 4413 4414// SetNextToken sets the NextToken field's value. 4415func (s *ListTagsForResourceOutput) SetNextToken(v string) *ListTagsForResourceOutput { 4416 s.NextToken = &v 4417 return s 4418} 4419 4420// SetTags sets the Tags field's value. 4421func (s *ListTagsForResourceOutput) SetTags(v []*Tag) *ListTagsForResourceOutput { 4422 s.Tags = v 4423 return s 4424} 4425 4426type ListUsersInput struct { 4427 _ struct{} `type:"structure"` 4428 4429 // Specifies the number of users to return as a response to the ListUsers request. 4430 MaxResults *int64 `min:"1" type:"integer"` 4431 4432 // When you can get additional results from the ListUsers call, a NextToken 4433 // parameter is returned in the output. You can then pass in a subsequent command 4434 // to the NextToken parameter to continue listing additional users. 4435 NextToken *string `min:"1" type:"string"` 4436 4437 // A system-assigned unique identifier for a server that has users assigned 4438 // to it. 4439 // 4440 // ServerId is a required field 4441 ServerId *string `min:"19" type:"string" required:"true"` 4442} 4443 4444// String returns the string representation 4445func (s ListUsersInput) String() string { 4446 return awsutil.Prettify(s) 4447} 4448 4449// GoString returns the string representation 4450func (s ListUsersInput) GoString() string { 4451 return s.String() 4452} 4453 4454// Validate inspects the fields of the type to determine if they are valid. 4455func (s *ListUsersInput) Validate() error { 4456 invalidParams := request.ErrInvalidParams{Context: "ListUsersInput"} 4457 if s.MaxResults != nil && *s.MaxResults < 1 { 4458 invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) 4459 } 4460 if s.NextToken != nil && len(*s.NextToken) < 1 { 4461 invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) 4462 } 4463 if s.ServerId == nil { 4464 invalidParams.Add(request.NewErrParamRequired("ServerId")) 4465 } 4466 if s.ServerId != nil && len(*s.ServerId) < 19 { 4467 invalidParams.Add(request.NewErrParamMinLen("ServerId", 19)) 4468 } 4469 4470 if invalidParams.Len() > 0 { 4471 return invalidParams 4472 } 4473 return nil 4474} 4475 4476// SetMaxResults sets the MaxResults field's value. 4477func (s *ListUsersInput) SetMaxResults(v int64) *ListUsersInput { 4478 s.MaxResults = &v 4479 return s 4480} 4481 4482// SetNextToken sets the NextToken field's value. 4483func (s *ListUsersInput) SetNextToken(v string) *ListUsersInput { 4484 s.NextToken = &v 4485 return s 4486} 4487 4488// SetServerId sets the ServerId field's value. 4489func (s *ListUsersInput) SetServerId(v string) *ListUsersInput { 4490 s.ServerId = &v 4491 return s 4492} 4493 4494type ListUsersOutput struct { 4495 _ struct{} `type:"structure"` 4496 4497 // When you can get additional results from the ListUsers call, a NextToken 4498 // parameter is returned in the output. You can then pass in a subsequent command 4499 // to the NextToken parameter to continue listing additional users. 4500 NextToken *string `min:"1" type:"string"` 4501 4502 // A system-assigned unique identifier for a server that the users are assigned 4503 // to. 4504 // 4505 // ServerId is a required field 4506 ServerId *string `min:"19" type:"string" required:"true"` 4507 4508 // Returns the user accounts and their properties for the ServerId value that 4509 // you specify. 4510 // 4511 // Users is a required field 4512 Users []*ListedUser `type:"list" required:"true"` 4513} 4514 4515// String returns the string representation 4516func (s ListUsersOutput) String() string { 4517 return awsutil.Prettify(s) 4518} 4519 4520// GoString returns the string representation 4521func (s ListUsersOutput) GoString() string { 4522 return s.String() 4523} 4524 4525// SetNextToken sets the NextToken field's value. 4526func (s *ListUsersOutput) SetNextToken(v string) *ListUsersOutput { 4527 s.NextToken = &v 4528 return s 4529} 4530 4531// SetServerId sets the ServerId field's value. 4532func (s *ListUsersOutput) SetServerId(v string) *ListUsersOutput { 4533 s.ServerId = &v 4534 return s 4535} 4536 4537// SetUsers sets the Users field's value. 4538func (s *ListUsersOutput) SetUsers(v []*ListedUser) *ListUsersOutput { 4539 s.Users = v 4540 return s 4541} 4542 4543// Returns properties of a file transfer protocol-enabled server that was specified. 4544type ListedServer struct { 4545 _ struct{} `type:"structure"` 4546 4547 // Specifies the unique Amazon Resource Name (ARN) for a server to be listed. 4548 // 4549 // Arn is a required field 4550 Arn *string `min:"20" type:"string" required:"true"` 4551 4552 Domain *string `type:"string" enum:"Domain"` 4553 4554 // Specifies the type of VPC endpoint that your server is connected to. If your 4555 // server is connected to a VPC endpoint, your server isn't accessible over 4556 // the public internet. 4557 EndpointType *string `type:"string" enum:"EndpointType"` 4558 4559 // Specifies the authentication method used to validate a user for a server 4560 // that was specified. This can include Secure Shell (SSH), user name and password 4561 // combinations, or your own custom authentication method. Valid values include 4562 // SERVICE_MANAGED or API_GATEWAY. 4563 IdentityProviderType *string `type:"string" enum:"IdentityProviderType"` 4564 4565 // Specifies the AWS Identity and Access Management (IAM) role that allows a 4566 // server to turn on Amazon CloudWatch logging. 4567 LoggingRole *string `min:"20" type:"string"` 4568 4569 // Specifies the unique system assigned identifier for the servers that were 4570 // listed. 4571 ServerId *string `min:"19" type:"string"` 4572 4573 // Specifies the condition of a server for the server that was described. A 4574 // value of ONLINE indicates that the server can accept jobs and transfer files. 4575 // A State value of OFFLINE means that the server cannot perform file transfer 4576 // operations. 4577 // 4578 // The states of STARTING and STOPPING indicate that the server is in an intermediate 4579 // state, either not fully able to respond, or not fully offline. The values 4580 // of START_FAILED or STOP_FAILED can indicate an error condition. 4581 State *string `type:"string" enum:"State"` 4582 4583 // Specifies the number of users that are assigned to a server you specified 4584 // with the ServerId. 4585 UserCount *int64 `type:"integer"` 4586} 4587 4588// String returns the string representation 4589func (s ListedServer) String() string { 4590 return awsutil.Prettify(s) 4591} 4592 4593// GoString returns the string representation 4594func (s ListedServer) GoString() string { 4595 return s.String() 4596} 4597 4598// SetArn sets the Arn field's value. 4599func (s *ListedServer) SetArn(v string) *ListedServer { 4600 s.Arn = &v 4601 return s 4602} 4603 4604// SetDomain sets the Domain field's value. 4605func (s *ListedServer) SetDomain(v string) *ListedServer { 4606 s.Domain = &v 4607 return s 4608} 4609 4610// SetEndpointType sets the EndpointType field's value. 4611func (s *ListedServer) SetEndpointType(v string) *ListedServer { 4612 s.EndpointType = &v 4613 return s 4614} 4615 4616// SetIdentityProviderType sets the IdentityProviderType field's value. 4617func (s *ListedServer) SetIdentityProviderType(v string) *ListedServer { 4618 s.IdentityProviderType = &v 4619 return s 4620} 4621 4622// SetLoggingRole sets the LoggingRole field's value. 4623func (s *ListedServer) SetLoggingRole(v string) *ListedServer { 4624 s.LoggingRole = &v 4625 return s 4626} 4627 4628// SetServerId sets the ServerId field's value. 4629func (s *ListedServer) SetServerId(v string) *ListedServer { 4630 s.ServerId = &v 4631 return s 4632} 4633 4634// SetState sets the State field's value. 4635func (s *ListedServer) SetState(v string) *ListedServer { 4636 s.State = &v 4637 return s 4638} 4639 4640// SetUserCount sets the UserCount field's value. 4641func (s *ListedServer) SetUserCount(v int64) *ListedServer { 4642 s.UserCount = &v 4643 return s 4644} 4645 4646// Returns properties of the user that you specify. 4647type ListedUser struct { 4648 _ struct{} `type:"structure"` 4649 4650 // Provides the unique Amazon Resource Name (ARN) for the user that you want 4651 // to learn about. 4652 // 4653 // Arn is a required field 4654 Arn *string `min:"20" type:"string" required:"true"` 4655 4656 // Specifies the location that files are written to or read from an Amazon S3 4657 // bucket for the user you specify by their ARN. 4658 HomeDirectory *string `type:"string"` 4659 4660 // Specifies the type of landing directory (folder) you mapped for your users' 4661 // home directory. If you set it to PATH, the user will see the absolute Amazon 4662 // S3 bucket paths as is in their file transfer protocol clients. If you set 4663 // it LOGICAL, you will need to provide mappings in the HomeDirectoryMappings 4664 // for how you want to make Amazon S3 paths visible to your users. 4665 HomeDirectoryType *string `type:"string" enum:"HomeDirectoryType"` 4666 4667 // Specifies the role that is in use by this user. A role is an AWS Identity 4668 // and Access Management (IAM) entity that, in this case, allows a file transfer 4669 // protocol-enabled server to act on a user's behalf. It allows the server to 4670 // inherit the trust relationship that enables that user to perform file operations 4671 // to their Amazon S3 bucket. 4672 Role *string `min:"20" type:"string"` 4673 4674 // Specifies the number of SSH public keys stored for the user you specified. 4675 SshPublicKeyCount *int64 `type:"integer"` 4676 4677 // Specifies the name of the user whose ARN was specified. User names are used 4678 // for authentication purposes. 4679 UserName *string `min:"3" type:"string"` 4680} 4681 4682// String returns the string representation 4683func (s ListedUser) String() string { 4684 return awsutil.Prettify(s) 4685} 4686 4687// GoString returns the string representation 4688func (s ListedUser) GoString() string { 4689 return s.String() 4690} 4691 4692// SetArn sets the Arn field's value. 4693func (s *ListedUser) SetArn(v string) *ListedUser { 4694 s.Arn = &v 4695 return s 4696} 4697 4698// SetHomeDirectory sets the HomeDirectory field's value. 4699func (s *ListedUser) SetHomeDirectory(v string) *ListedUser { 4700 s.HomeDirectory = &v 4701 return s 4702} 4703 4704// SetHomeDirectoryType sets the HomeDirectoryType field's value. 4705func (s *ListedUser) SetHomeDirectoryType(v string) *ListedUser { 4706 s.HomeDirectoryType = &v 4707 return s 4708} 4709 4710// SetRole sets the Role field's value. 4711func (s *ListedUser) SetRole(v string) *ListedUser { 4712 s.Role = &v 4713 return s 4714} 4715 4716// SetSshPublicKeyCount sets the SshPublicKeyCount field's value. 4717func (s *ListedUser) SetSshPublicKeyCount(v int64) *ListedUser { 4718 s.SshPublicKeyCount = &v 4719 return s 4720} 4721 4722// SetUserName sets the UserName field's value. 4723func (s *ListedUser) SetUserName(v string) *ListedUser { 4724 s.UserName = &v 4725 return s 4726} 4727 4728type PosixProfile struct { 4729 _ struct{} `type:"structure"` 4730 4731 // Gid is a required field 4732 Gid *int64 `type:"long" required:"true"` 4733 4734 SecondaryGids []*int64 `type:"list"` 4735 4736 // Uid is a required field 4737 Uid *int64 `type:"long" required:"true"` 4738} 4739 4740// String returns the string representation 4741func (s PosixProfile) String() string { 4742 return awsutil.Prettify(s) 4743} 4744 4745// GoString returns the string representation 4746func (s PosixProfile) GoString() string { 4747 return s.String() 4748} 4749 4750// Validate inspects the fields of the type to determine if they are valid. 4751func (s *PosixProfile) Validate() error { 4752 invalidParams := request.ErrInvalidParams{Context: "PosixProfile"} 4753 if s.Gid == nil { 4754 invalidParams.Add(request.NewErrParamRequired("Gid")) 4755 } 4756 if s.Uid == nil { 4757 invalidParams.Add(request.NewErrParamRequired("Uid")) 4758 } 4759 4760 if invalidParams.Len() > 0 { 4761 return invalidParams 4762 } 4763 return nil 4764} 4765 4766// SetGid sets the Gid field's value. 4767func (s *PosixProfile) SetGid(v int64) *PosixProfile { 4768 s.Gid = &v 4769 return s 4770} 4771 4772// SetSecondaryGids sets the SecondaryGids field's value. 4773func (s *PosixProfile) SetSecondaryGids(v []*int64) *PosixProfile { 4774 s.SecondaryGids = v 4775 return s 4776} 4777 4778// SetUid sets the Uid field's value. 4779func (s *PosixProfile) SetUid(v int64) *PosixProfile { 4780 s.Uid = &v 4781 return s 4782} 4783 4784// The requested resource does not exist. 4785type ResourceExistsException struct { 4786 _ struct{} `type:"structure"` 4787 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 4788 4789 Message_ *string `locationName:"Message" type:"string"` 4790 4791 // Resource is a required field 4792 Resource *string `type:"string" required:"true"` 4793 4794 // ResourceType is a required field 4795 ResourceType *string `type:"string" required:"true"` 4796} 4797 4798// String returns the string representation 4799func (s ResourceExistsException) String() string { 4800 return awsutil.Prettify(s) 4801} 4802 4803// GoString returns the string representation 4804func (s ResourceExistsException) GoString() string { 4805 return s.String() 4806} 4807 4808func newErrorResourceExistsException(v protocol.ResponseMetadata) error { 4809 return &ResourceExistsException{ 4810 RespMetadata: v, 4811 } 4812} 4813 4814// Code returns the exception type name. 4815func (s *ResourceExistsException) Code() string { 4816 return "ResourceExistsException" 4817} 4818 4819// Message returns the exception's message. 4820func (s *ResourceExistsException) Message() string { 4821 if s.Message_ != nil { 4822 return *s.Message_ 4823 } 4824 return "" 4825} 4826 4827// OrigErr always returns nil, satisfies awserr.Error interface. 4828func (s *ResourceExistsException) OrigErr() error { 4829 return nil 4830} 4831 4832func (s *ResourceExistsException) Error() string { 4833 return fmt.Sprintf("%s: %s\n%s", s.Code(), s.Message(), s.String()) 4834} 4835 4836// Status code returns the HTTP status code for the request's response error. 4837func (s *ResourceExistsException) StatusCode() int { 4838 return s.RespMetadata.StatusCode 4839} 4840 4841// RequestID returns the service's response RequestID for request. 4842func (s *ResourceExistsException) RequestID() string { 4843 return s.RespMetadata.RequestID 4844} 4845 4846// This exception is thrown when a resource is not found by the AWS Transfer 4847// Family service. 4848type ResourceNotFoundException struct { 4849 _ struct{} `type:"structure"` 4850 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 4851 4852 Message_ *string `locationName:"Message" type:"string"` 4853 4854 // Resource is a required field 4855 Resource *string `type:"string" required:"true"` 4856 4857 // ResourceType is a required field 4858 ResourceType *string `type:"string" required:"true"` 4859} 4860 4861// String returns the string representation 4862func (s ResourceNotFoundException) String() string { 4863 return awsutil.Prettify(s) 4864} 4865 4866// GoString returns the string representation 4867func (s ResourceNotFoundException) GoString() string { 4868 return s.String() 4869} 4870 4871func newErrorResourceNotFoundException(v protocol.ResponseMetadata) error { 4872 return &ResourceNotFoundException{ 4873 RespMetadata: v, 4874 } 4875} 4876 4877// Code returns the exception type name. 4878func (s *ResourceNotFoundException) Code() string { 4879 return "ResourceNotFoundException" 4880} 4881 4882// Message returns the exception's message. 4883func (s *ResourceNotFoundException) Message() string { 4884 if s.Message_ != nil { 4885 return *s.Message_ 4886 } 4887 return "" 4888} 4889 4890// OrigErr always returns nil, satisfies awserr.Error interface. 4891func (s *ResourceNotFoundException) OrigErr() error { 4892 return nil 4893} 4894 4895func (s *ResourceNotFoundException) Error() string { 4896 return fmt.Sprintf("%s: %s\n%s", s.Code(), s.Message(), s.String()) 4897} 4898 4899// Status code returns the HTTP status code for the request's response error. 4900func (s *ResourceNotFoundException) StatusCode() int { 4901 return s.RespMetadata.StatusCode 4902} 4903 4904// RequestID returns the service's response RequestID for request. 4905func (s *ResourceNotFoundException) RequestID() string { 4906 return s.RespMetadata.RequestID 4907} 4908 4909// The request has failed because the AWS Transfer Family service is not available. 4910type ServiceUnavailableException struct { 4911 _ struct{} `type:"structure"` 4912 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 4913 4914 Message_ *string `locationName:"Message" type:"string"` 4915} 4916 4917// String returns the string representation 4918func (s ServiceUnavailableException) String() string { 4919 return awsutil.Prettify(s) 4920} 4921 4922// GoString returns the string representation 4923func (s ServiceUnavailableException) GoString() string { 4924 return s.String() 4925} 4926 4927func newErrorServiceUnavailableException(v protocol.ResponseMetadata) error { 4928 return &ServiceUnavailableException{ 4929 RespMetadata: v, 4930 } 4931} 4932 4933// Code returns the exception type name. 4934func (s *ServiceUnavailableException) Code() string { 4935 return "ServiceUnavailableException" 4936} 4937 4938// Message returns the exception's message. 4939func (s *ServiceUnavailableException) Message() string { 4940 if s.Message_ != nil { 4941 return *s.Message_ 4942 } 4943 return "" 4944} 4945 4946// OrigErr always returns nil, satisfies awserr.Error interface. 4947func (s *ServiceUnavailableException) OrigErr() error { 4948 return nil 4949} 4950 4951func (s *ServiceUnavailableException) Error() string { 4952 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 4953} 4954 4955// Status code returns the HTTP status code for the request's response error. 4956func (s *ServiceUnavailableException) StatusCode() int { 4957 return s.RespMetadata.StatusCode 4958} 4959 4960// RequestID returns the service's response RequestID for request. 4961func (s *ServiceUnavailableException) RequestID() string { 4962 return s.RespMetadata.RequestID 4963} 4964 4965// Provides information about the public Secure Shell (SSH) key that is associated 4966// with a user account for the specific file transfer protocol-enabled server 4967// (as identified by ServerId). The information returned includes the date the 4968// key was imported, the public key contents, and the public key ID. A user 4969// can store more than one SSH public key associated with their user name on 4970// a specific server. 4971type SshPublicKey struct { 4972 _ struct{} `type:"structure"` 4973 4974 // Specifies the date that the public key was added to the user account. 4975 // 4976 // DateImported is a required field 4977 DateImported *time.Time `type:"timestamp" required:"true"` 4978 4979 // Specifies the content of the SSH public key as specified by the PublicKeyId. 4980 // 4981 // SshPublicKeyBody is a required field 4982 SshPublicKeyBody *string `type:"string" required:"true"` 4983 4984 // Specifies the SshPublicKeyId parameter contains the identifier of the public 4985 // key. 4986 // 4987 // SshPublicKeyId is a required field 4988 SshPublicKeyId *string `min:"21" type:"string" required:"true"` 4989} 4990 4991// String returns the string representation 4992func (s SshPublicKey) String() string { 4993 return awsutil.Prettify(s) 4994} 4995 4996// GoString returns the string representation 4997func (s SshPublicKey) GoString() string { 4998 return s.String() 4999} 5000 5001// SetDateImported sets the DateImported field's value. 5002func (s *SshPublicKey) SetDateImported(v time.Time) *SshPublicKey { 5003 s.DateImported = &v 5004 return s 5005} 5006 5007// SetSshPublicKeyBody sets the SshPublicKeyBody field's value. 5008func (s *SshPublicKey) SetSshPublicKeyBody(v string) *SshPublicKey { 5009 s.SshPublicKeyBody = &v 5010 return s 5011} 5012 5013// SetSshPublicKeyId sets the SshPublicKeyId field's value. 5014func (s *SshPublicKey) SetSshPublicKeyId(v string) *SshPublicKey { 5015 s.SshPublicKeyId = &v 5016 return s 5017} 5018 5019type StartServerInput struct { 5020 _ struct{} `type:"structure"` 5021 5022 // A system-assigned unique identifier for a server that you start. 5023 // 5024 // ServerId is a required field 5025 ServerId *string `min:"19" type:"string" required:"true"` 5026} 5027 5028// String returns the string representation 5029func (s StartServerInput) String() string { 5030 return awsutil.Prettify(s) 5031} 5032 5033// GoString returns the string representation 5034func (s StartServerInput) GoString() string { 5035 return s.String() 5036} 5037 5038// Validate inspects the fields of the type to determine if they are valid. 5039func (s *StartServerInput) Validate() error { 5040 invalidParams := request.ErrInvalidParams{Context: "StartServerInput"} 5041 if s.ServerId == nil { 5042 invalidParams.Add(request.NewErrParamRequired("ServerId")) 5043 } 5044 if s.ServerId != nil && len(*s.ServerId) < 19 { 5045 invalidParams.Add(request.NewErrParamMinLen("ServerId", 19)) 5046 } 5047 5048 if invalidParams.Len() > 0 { 5049 return invalidParams 5050 } 5051 return nil 5052} 5053 5054// SetServerId sets the ServerId field's value. 5055func (s *StartServerInput) SetServerId(v string) *StartServerInput { 5056 s.ServerId = &v 5057 return s 5058} 5059 5060type StartServerOutput struct { 5061 _ struct{} `type:"structure"` 5062} 5063 5064// String returns the string representation 5065func (s StartServerOutput) String() string { 5066 return awsutil.Prettify(s) 5067} 5068 5069// GoString returns the string representation 5070func (s StartServerOutput) GoString() string { 5071 return s.String() 5072} 5073 5074type StopServerInput struct { 5075 _ struct{} `type:"structure"` 5076 5077 // A system-assigned unique identifier for a server that you stopped. 5078 // 5079 // ServerId is a required field 5080 ServerId *string `min:"19" type:"string" required:"true"` 5081} 5082 5083// String returns the string representation 5084func (s StopServerInput) String() string { 5085 return awsutil.Prettify(s) 5086} 5087 5088// GoString returns the string representation 5089func (s StopServerInput) GoString() string { 5090 return s.String() 5091} 5092 5093// Validate inspects the fields of the type to determine if they are valid. 5094func (s *StopServerInput) Validate() error { 5095 invalidParams := request.ErrInvalidParams{Context: "StopServerInput"} 5096 if s.ServerId == nil { 5097 invalidParams.Add(request.NewErrParamRequired("ServerId")) 5098 } 5099 if s.ServerId != nil && len(*s.ServerId) < 19 { 5100 invalidParams.Add(request.NewErrParamMinLen("ServerId", 19)) 5101 } 5102 5103 if invalidParams.Len() > 0 { 5104 return invalidParams 5105 } 5106 return nil 5107} 5108 5109// SetServerId sets the ServerId field's value. 5110func (s *StopServerInput) SetServerId(v string) *StopServerInput { 5111 s.ServerId = &v 5112 return s 5113} 5114 5115type StopServerOutput struct { 5116 _ struct{} `type:"structure"` 5117} 5118 5119// String returns the string representation 5120func (s StopServerOutput) String() string { 5121 return awsutil.Prettify(s) 5122} 5123 5124// GoString returns the string representation 5125func (s StopServerOutput) GoString() string { 5126 return s.String() 5127} 5128 5129// Creates a key-value pair for a specific resource. Tags are metadata that 5130// you can use to search for and group a resource for various purposes. You 5131// can apply tags to servers, users, and roles. A tag key can take more than 5132// one value. For example, to group servers for accounting purposes, you might 5133// create a tag called Group and assign the values Research and Accounting to 5134// that group. 5135type Tag struct { 5136 _ struct{} `type:"structure"` 5137 5138 // The name assigned to the tag that you create. 5139 // 5140 // Key is a required field 5141 Key *string `type:"string" required:"true"` 5142 5143 // Contains one or more values that you assigned to the key name you create. 5144 // 5145 // Value is a required field 5146 Value *string `type:"string" required:"true"` 5147} 5148 5149// String returns the string representation 5150func (s Tag) String() string { 5151 return awsutil.Prettify(s) 5152} 5153 5154// GoString returns the string representation 5155func (s Tag) GoString() string { 5156 return s.String() 5157} 5158 5159// Validate inspects the fields of the type to determine if they are valid. 5160func (s *Tag) Validate() error { 5161 invalidParams := request.ErrInvalidParams{Context: "Tag"} 5162 if s.Key == nil { 5163 invalidParams.Add(request.NewErrParamRequired("Key")) 5164 } 5165 if s.Value == nil { 5166 invalidParams.Add(request.NewErrParamRequired("Value")) 5167 } 5168 5169 if invalidParams.Len() > 0 { 5170 return invalidParams 5171 } 5172 return nil 5173} 5174 5175// SetKey sets the Key field's value. 5176func (s *Tag) SetKey(v string) *Tag { 5177 s.Key = &v 5178 return s 5179} 5180 5181// SetValue sets the Value field's value. 5182func (s *Tag) SetValue(v string) *Tag { 5183 s.Value = &v 5184 return s 5185} 5186 5187type TagResourceInput struct { 5188 _ struct{} `type:"structure"` 5189 5190 // An Amazon Resource Name (ARN) for a specific AWS resource, such as a server, 5191 // user, or role. 5192 // 5193 // Arn is a required field 5194 Arn *string `min:"20" type:"string" required:"true"` 5195 5196 // Key-value pairs assigned to ARNs that you can use to group and search for 5197 // resources by type. You can attach this metadata to user accounts for any 5198 // purpose. 5199 // 5200 // Tags is a required field 5201 Tags []*Tag `min:"1" type:"list" required:"true"` 5202} 5203 5204// String returns the string representation 5205func (s TagResourceInput) String() string { 5206 return awsutil.Prettify(s) 5207} 5208 5209// GoString returns the string representation 5210func (s TagResourceInput) GoString() string { 5211 return s.String() 5212} 5213 5214// Validate inspects the fields of the type to determine if they are valid. 5215func (s *TagResourceInput) Validate() error { 5216 invalidParams := request.ErrInvalidParams{Context: "TagResourceInput"} 5217 if s.Arn == nil { 5218 invalidParams.Add(request.NewErrParamRequired("Arn")) 5219 } 5220 if s.Arn != nil && len(*s.Arn) < 20 { 5221 invalidParams.Add(request.NewErrParamMinLen("Arn", 20)) 5222 } 5223 if s.Tags == nil { 5224 invalidParams.Add(request.NewErrParamRequired("Tags")) 5225 } 5226 if s.Tags != nil && len(s.Tags) < 1 { 5227 invalidParams.Add(request.NewErrParamMinLen("Tags", 1)) 5228 } 5229 if s.Tags != nil { 5230 for i, v := range s.Tags { 5231 if v == nil { 5232 continue 5233 } 5234 if err := v.Validate(); err != nil { 5235 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Tags", i), err.(request.ErrInvalidParams)) 5236 } 5237 } 5238 } 5239 5240 if invalidParams.Len() > 0 { 5241 return invalidParams 5242 } 5243 return nil 5244} 5245 5246// SetArn sets the Arn field's value. 5247func (s *TagResourceInput) SetArn(v string) *TagResourceInput { 5248 s.Arn = &v 5249 return s 5250} 5251 5252// SetTags sets the Tags field's value. 5253func (s *TagResourceInput) SetTags(v []*Tag) *TagResourceInput { 5254 s.Tags = v 5255 return s 5256} 5257 5258type TagResourceOutput struct { 5259 _ struct{} `type:"structure"` 5260} 5261 5262// String returns the string representation 5263func (s TagResourceOutput) String() string { 5264 return awsutil.Prettify(s) 5265} 5266 5267// GoString returns the string representation 5268func (s TagResourceOutput) GoString() string { 5269 return s.String() 5270} 5271 5272type TestIdentityProviderInput struct { 5273 _ struct{} `type:"structure"` 5274 5275 // A system-assigned identifier for a specific server. That server's user authentication 5276 // method is tested with a user name and password. 5277 // 5278 // ServerId is a required field 5279 ServerId *string `min:"19" type:"string" required:"true"` 5280 5281 // The type of file transfer protocol to be tested. 5282 // 5283 // The available protocols are: 5284 // 5285 // * Secure Shell (SSH) File Transfer Protocol (SFTP) 5286 // 5287 // * File Transfer Protocol Secure (FTPS) 5288 // 5289 // * File Transfer Protocol (FTP) 5290 ServerProtocol *string `type:"string" enum:"Protocol"` 5291 5292 // The source IP address of the user account to be tested. 5293 SourceIp *string `type:"string"` 5294 5295 // The name of the user account to be tested. 5296 // 5297 // UserName is a required field 5298 UserName *string `min:"3" type:"string" required:"true"` 5299 5300 // The password of the user account to be tested. 5301 UserPassword *string `type:"string" sensitive:"true"` 5302} 5303 5304// String returns the string representation 5305func (s TestIdentityProviderInput) String() string { 5306 return awsutil.Prettify(s) 5307} 5308 5309// GoString returns the string representation 5310func (s TestIdentityProviderInput) GoString() string { 5311 return s.String() 5312} 5313 5314// Validate inspects the fields of the type to determine if they are valid. 5315func (s *TestIdentityProviderInput) Validate() error { 5316 invalidParams := request.ErrInvalidParams{Context: "TestIdentityProviderInput"} 5317 if s.ServerId == nil { 5318 invalidParams.Add(request.NewErrParamRequired("ServerId")) 5319 } 5320 if s.ServerId != nil && len(*s.ServerId) < 19 { 5321 invalidParams.Add(request.NewErrParamMinLen("ServerId", 19)) 5322 } 5323 if s.UserName == nil { 5324 invalidParams.Add(request.NewErrParamRequired("UserName")) 5325 } 5326 if s.UserName != nil && len(*s.UserName) < 3 { 5327 invalidParams.Add(request.NewErrParamMinLen("UserName", 3)) 5328 } 5329 5330 if invalidParams.Len() > 0 { 5331 return invalidParams 5332 } 5333 return nil 5334} 5335 5336// SetServerId sets the ServerId field's value. 5337func (s *TestIdentityProviderInput) SetServerId(v string) *TestIdentityProviderInput { 5338 s.ServerId = &v 5339 return s 5340} 5341 5342// SetServerProtocol sets the ServerProtocol field's value. 5343func (s *TestIdentityProviderInput) SetServerProtocol(v string) *TestIdentityProviderInput { 5344 s.ServerProtocol = &v 5345 return s 5346} 5347 5348// SetSourceIp sets the SourceIp field's value. 5349func (s *TestIdentityProviderInput) SetSourceIp(v string) *TestIdentityProviderInput { 5350 s.SourceIp = &v 5351 return s 5352} 5353 5354// SetUserName sets the UserName field's value. 5355func (s *TestIdentityProviderInput) SetUserName(v string) *TestIdentityProviderInput { 5356 s.UserName = &v 5357 return s 5358} 5359 5360// SetUserPassword sets the UserPassword field's value. 5361func (s *TestIdentityProviderInput) SetUserPassword(v string) *TestIdentityProviderInput { 5362 s.UserPassword = &v 5363 return s 5364} 5365 5366type TestIdentityProviderOutput struct { 5367 _ struct{} `type:"structure"` 5368 5369 // A message that indicates whether the test was successful or not. 5370 Message *string `type:"string"` 5371 5372 // The response that is returned from your API Gateway. 5373 Response *string `type:"string"` 5374 5375 // The HTTP status code that is the response from your API Gateway. 5376 // 5377 // StatusCode is a required field 5378 StatusCode *int64 `type:"integer" required:"true"` 5379 5380 // The endpoint of the service used to authenticate a user. 5381 // 5382 // Url is a required field 5383 Url *string `type:"string" required:"true"` 5384} 5385 5386// String returns the string representation 5387func (s TestIdentityProviderOutput) String() string { 5388 return awsutil.Prettify(s) 5389} 5390 5391// GoString returns the string representation 5392func (s TestIdentityProviderOutput) GoString() string { 5393 return s.String() 5394} 5395 5396// SetMessage sets the Message field's value. 5397func (s *TestIdentityProviderOutput) SetMessage(v string) *TestIdentityProviderOutput { 5398 s.Message = &v 5399 return s 5400} 5401 5402// SetResponse sets the Response field's value. 5403func (s *TestIdentityProviderOutput) SetResponse(v string) *TestIdentityProviderOutput { 5404 s.Response = &v 5405 return s 5406} 5407 5408// SetStatusCode sets the StatusCode field's value. 5409func (s *TestIdentityProviderOutput) SetStatusCode(v int64) *TestIdentityProviderOutput { 5410 s.StatusCode = &v 5411 return s 5412} 5413 5414// SetUrl sets the Url field's value. 5415func (s *TestIdentityProviderOutput) SetUrl(v string) *TestIdentityProviderOutput { 5416 s.Url = &v 5417 return s 5418} 5419 5420// The request was denied due to request throttling. 5421// 5422// HTTP Status Code: 400 5423type ThrottlingException struct { 5424 _ struct{} `type:"structure"` 5425 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 5426 5427 Message_ *string `locationName:"message" type:"string"` 5428 5429 RetryAfterSeconds *string `type:"string"` 5430} 5431 5432// String returns the string representation 5433func (s ThrottlingException) String() string { 5434 return awsutil.Prettify(s) 5435} 5436 5437// GoString returns the string representation 5438func (s ThrottlingException) GoString() string { 5439 return s.String() 5440} 5441 5442func newErrorThrottlingException(v protocol.ResponseMetadata) error { 5443 return &ThrottlingException{ 5444 RespMetadata: v, 5445 } 5446} 5447 5448// Code returns the exception type name. 5449func (s *ThrottlingException) Code() string { 5450 return "ThrottlingException" 5451} 5452 5453// Message returns the exception's message. 5454func (s *ThrottlingException) Message() string { 5455 if s.Message_ != nil { 5456 return *s.Message_ 5457 } 5458 return "" 5459} 5460 5461// OrigErr always returns nil, satisfies awserr.Error interface. 5462func (s *ThrottlingException) OrigErr() error { 5463 return nil 5464} 5465 5466func (s *ThrottlingException) Error() string { 5467 return fmt.Sprintf("%s: %s\n%s", s.Code(), s.Message(), s.String()) 5468} 5469 5470// Status code returns the HTTP status code for the request's response error. 5471func (s *ThrottlingException) StatusCode() int { 5472 return s.RespMetadata.StatusCode 5473} 5474 5475// RequestID returns the service's response RequestID for request. 5476func (s *ThrottlingException) RequestID() string { 5477 return s.RespMetadata.RequestID 5478} 5479 5480type UntagResourceInput struct { 5481 _ struct{} `type:"structure"` 5482 5483 // The value of the resource that will have the tag removed. An Amazon Resource 5484 // Name (ARN) is an identifier for a specific AWS resource, such as a server, 5485 // user, or role. 5486 // 5487 // Arn is a required field 5488 Arn *string `min:"20" type:"string" required:"true"` 5489 5490 // TagKeys are key-value pairs assigned to ARNs that can be used to group and 5491 // search for resources by type. This metadata can be attached to resources 5492 // for any purpose. 5493 // 5494 // TagKeys is a required field 5495 TagKeys []*string `min:"1" type:"list" required:"true"` 5496} 5497 5498// String returns the string representation 5499func (s UntagResourceInput) String() string { 5500 return awsutil.Prettify(s) 5501} 5502 5503// GoString returns the string representation 5504func (s UntagResourceInput) GoString() string { 5505 return s.String() 5506} 5507 5508// Validate inspects the fields of the type to determine if they are valid. 5509func (s *UntagResourceInput) Validate() error { 5510 invalidParams := request.ErrInvalidParams{Context: "UntagResourceInput"} 5511 if s.Arn == nil { 5512 invalidParams.Add(request.NewErrParamRequired("Arn")) 5513 } 5514 if s.Arn != nil && len(*s.Arn) < 20 { 5515 invalidParams.Add(request.NewErrParamMinLen("Arn", 20)) 5516 } 5517 if s.TagKeys == nil { 5518 invalidParams.Add(request.NewErrParamRequired("TagKeys")) 5519 } 5520 if s.TagKeys != nil && len(s.TagKeys) < 1 { 5521 invalidParams.Add(request.NewErrParamMinLen("TagKeys", 1)) 5522 } 5523 5524 if invalidParams.Len() > 0 { 5525 return invalidParams 5526 } 5527 return nil 5528} 5529 5530// SetArn sets the Arn field's value. 5531func (s *UntagResourceInput) SetArn(v string) *UntagResourceInput { 5532 s.Arn = &v 5533 return s 5534} 5535 5536// SetTagKeys sets the TagKeys field's value. 5537func (s *UntagResourceInput) SetTagKeys(v []*string) *UntagResourceInput { 5538 s.TagKeys = v 5539 return s 5540} 5541 5542type UntagResourceOutput struct { 5543 _ struct{} `type:"structure"` 5544} 5545 5546// String returns the string representation 5547func (s UntagResourceOutput) String() string { 5548 return awsutil.Prettify(s) 5549} 5550 5551// GoString returns the string representation 5552func (s UntagResourceOutput) GoString() string { 5553 return s.String() 5554} 5555 5556type UpdateServerInput struct { 5557 _ struct{} `type:"structure"` 5558 5559 // The Amazon Resource Name (ARN) of the AWS Certificate Manager (ACM) certificate. 5560 // Required when Protocols is set to FTPS. 5561 // 5562 // To request a new public certificate, see Request a public certificate (https://docs.aws.amazon.com/acm/latest/userguide/gs-acm-request-public.html) 5563 // in the AWS Certificate Manager User Guide. 5564 // 5565 // To import an existing certificate into ACM, see Importing certificates into 5566 // ACM (https://docs.aws.amazon.com/acm/latest/userguide/import-certificate.html) 5567 // in the AWS Certificate Manager User Guide. 5568 // 5569 // To request a private certificate to use FTPS through private IP addresses, 5570 // see Request a private certificate (https://docs.aws.amazon.com/acm/latest/userguide/gs-acm-request-private.html) 5571 // in the AWS Certificate Manager User Guide. 5572 // 5573 // Certificates with the following cryptographic algorithms and key sizes are 5574 // supported: 5575 // 5576 // * 2048-bit RSA (RSA_2048) 5577 // 5578 // * 4096-bit RSA (RSA_4096) 5579 // 5580 // * Elliptic Prime Curve 256 bit (EC_prime256v1) 5581 // 5582 // * Elliptic Prime Curve 384 bit (EC_secp384r1) 5583 // 5584 // * Elliptic Prime Curve 521 bit (EC_secp521r1) 5585 // 5586 // The certificate must be a valid SSL/TLS X.509 version 3 certificate with 5587 // FQDN or IP address specified and information about the issuer. 5588 Certificate *string `type:"string"` 5589 5590 // The virtual private cloud (VPC) endpoint settings that are configured for 5591 // your server. With a VPC endpoint, you can restrict access to your server 5592 // to resources only within your VPC. To control incoming internet traffic, 5593 // you will need to associate one or more Elastic IP addresses with your server's 5594 // endpoint. 5595 EndpointDetails *EndpointDetails `type:"structure"` 5596 5597 // The type of endpoint that you want your server to connect to. You can choose 5598 // to connect to the public internet or a VPC endpoint. With a VPC endpoint, 5599 // you can restrict access to your server and resources only within your VPC. 5600 // 5601 // It is recommended that you use VPC as the EndpointType. With this endpoint 5602 // type, you have the option to directly associate up to three Elastic IPv4 5603 // addresses (BYO IP included) with your server's endpoint and use VPC security 5604 // groups to restrict traffic by the client's public IP address. This is not 5605 // possible with EndpointType set to VPC_ENDPOINT. 5606 EndpointType *string `type:"string" enum:"EndpointType"` 5607 5608 // The RSA private key as generated by ssh-keygen -N "" -m PEM -f my-new-server-key. 5609 // 5610 // If you aren't planning to migrate existing users from an existing server 5611 // to a new server, don't update the host key. Accidentally changing a server's 5612 // host key can be disruptive. 5613 // 5614 // For more information, see Change the host key for your SFTP-enabled server 5615 // (https://docs.aws.amazon.com/transfer/latest/userguide/edit-server-config.html#configuring-servers-change-host-key) 5616 // in the AWS Transfer Family User Guide. 5617 HostKey *string `type:"string" sensitive:"true"` 5618 5619 // An array containing all of the information required to call a customer's 5620 // authentication API method. 5621 IdentityProviderDetails *IdentityProviderDetails `type:"structure"` 5622 5623 // Changes the AWS Identity and Access Management (IAM) role that allows Amazon 5624 // S3 events to be logged in Amazon CloudWatch, turning logging on or off. 5625 LoggingRole *string `type:"string"` 5626 5627 // Specifies the file transfer protocol or protocols over which your file transfer 5628 // protocol client can connect to your server's endpoint. The available protocols 5629 // are: 5630 // 5631 // * Secure Shell (SSH) File Transfer Protocol (SFTP): File transfer over 5632 // SSH 5633 // 5634 // * File Transfer Protocol Secure (FTPS): File transfer with TLS encryption 5635 // 5636 // * File Transfer Protocol (FTP): Unencrypted file transfer 5637 // 5638 // If you select FTPS, you must choose a certificate stored in AWS Certificate 5639 // Manager (ACM) which will be used to identify your server when clients connect 5640 // to it over FTPS. 5641 // 5642 // If Protocol includes either FTP or FTPS, then the EndpointType must be VPC 5643 // and the IdentityProviderType must be API_GATEWAY. 5644 // 5645 // If Protocol includes FTP, then AddressAllocationIds cannot be associated. 5646 // 5647 // If Protocol is set only to SFTP, the EndpointType can be set to PUBLIC and 5648 // the IdentityProviderType can be set to SERVICE_MANAGED. 5649 Protocols []*string `min:"1" type:"list"` 5650 5651 // Specifies the name of the security policy that is attached to the server. 5652 SecurityPolicyName *string `type:"string"` 5653 5654 // A system-assigned unique identifier for a server instance that the user account 5655 // is assigned to. 5656 // 5657 // ServerId is a required field 5658 ServerId *string `min:"19" type:"string" required:"true"` 5659} 5660 5661// String returns the string representation 5662func (s UpdateServerInput) String() string { 5663 return awsutil.Prettify(s) 5664} 5665 5666// GoString returns the string representation 5667func (s UpdateServerInput) GoString() string { 5668 return s.String() 5669} 5670 5671// Validate inspects the fields of the type to determine if they are valid. 5672func (s *UpdateServerInput) Validate() error { 5673 invalidParams := request.ErrInvalidParams{Context: "UpdateServerInput"} 5674 if s.Protocols != nil && len(s.Protocols) < 1 { 5675 invalidParams.Add(request.NewErrParamMinLen("Protocols", 1)) 5676 } 5677 if s.ServerId == nil { 5678 invalidParams.Add(request.NewErrParamRequired("ServerId")) 5679 } 5680 if s.ServerId != nil && len(*s.ServerId) < 19 { 5681 invalidParams.Add(request.NewErrParamMinLen("ServerId", 19)) 5682 } 5683 if s.EndpointDetails != nil { 5684 if err := s.EndpointDetails.Validate(); err != nil { 5685 invalidParams.AddNested("EndpointDetails", err.(request.ErrInvalidParams)) 5686 } 5687 } 5688 if s.IdentityProviderDetails != nil { 5689 if err := s.IdentityProviderDetails.Validate(); err != nil { 5690 invalidParams.AddNested("IdentityProviderDetails", err.(request.ErrInvalidParams)) 5691 } 5692 } 5693 5694 if invalidParams.Len() > 0 { 5695 return invalidParams 5696 } 5697 return nil 5698} 5699 5700// SetCertificate sets the Certificate field's value. 5701func (s *UpdateServerInput) SetCertificate(v string) *UpdateServerInput { 5702 s.Certificate = &v 5703 return s 5704} 5705 5706// SetEndpointDetails sets the EndpointDetails field's value. 5707func (s *UpdateServerInput) SetEndpointDetails(v *EndpointDetails) *UpdateServerInput { 5708 s.EndpointDetails = v 5709 return s 5710} 5711 5712// SetEndpointType sets the EndpointType field's value. 5713func (s *UpdateServerInput) SetEndpointType(v string) *UpdateServerInput { 5714 s.EndpointType = &v 5715 return s 5716} 5717 5718// SetHostKey sets the HostKey field's value. 5719func (s *UpdateServerInput) SetHostKey(v string) *UpdateServerInput { 5720 s.HostKey = &v 5721 return s 5722} 5723 5724// SetIdentityProviderDetails sets the IdentityProviderDetails field's value. 5725func (s *UpdateServerInput) SetIdentityProviderDetails(v *IdentityProviderDetails) *UpdateServerInput { 5726 s.IdentityProviderDetails = v 5727 return s 5728} 5729 5730// SetLoggingRole sets the LoggingRole field's value. 5731func (s *UpdateServerInput) SetLoggingRole(v string) *UpdateServerInput { 5732 s.LoggingRole = &v 5733 return s 5734} 5735 5736// SetProtocols sets the Protocols field's value. 5737func (s *UpdateServerInput) SetProtocols(v []*string) *UpdateServerInput { 5738 s.Protocols = v 5739 return s 5740} 5741 5742// SetSecurityPolicyName sets the SecurityPolicyName field's value. 5743func (s *UpdateServerInput) SetSecurityPolicyName(v string) *UpdateServerInput { 5744 s.SecurityPolicyName = &v 5745 return s 5746} 5747 5748// SetServerId sets the ServerId field's value. 5749func (s *UpdateServerInput) SetServerId(v string) *UpdateServerInput { 5750 s.ServerId = &v 5751 return s 5752} 5753 5754type UpdateServerOutput struct { 5755 _ struct{} `type:"structure"` 5756 5757 // A system-assigned unique identifier for a server that the user account is 5758 // assigned to. 5759 // 5760 // ServerId is a required field 5761 ServerId *string `min:"19" type:"string" required:"true"` 5762} 5763 5764// String returns the string representation 5765func (s UpdateServerOutput) String() string { 5766 return awsutil.Prettify(s) 5767} 5768 5769// GoString returns the string representation 5770func (s UpdateServerOutput) GoString() string { 5771 return s.String() 5772} 5773 5774// SetServerId sets the ServerId field's value. 5775func (s *UpdateServerOutput) SetServerId(v string) *UpdateServerOutput { 5776 s.ServerId = &v 5777 return s 5778} 5779 5780type UpdateUserInput struct { 5781 _ struct{} `type:"structure"` 5782 5783 // Specifies the landing directory (folder) for a user when they log in to the 5784 // server using their file transfer protocol client. 5785 // 5786 // An example is your-Amazon-S3-bucket-name>/home/username. 5787 HomeDirectory *string `type:"string"` 5788 5789 // Logical directory mappings that specify what Amazon S3 paths and keys should 5790 // be visible to your user and how you want to make them visible. You will need 5791 // to specify the "Entry" and "Target" pair, where Entry shows how the path 5792 // is made visible and Target is the actual Amazon S3 path. If you only specify 5793 // a target, it will be displayed as is. You will need to also make sure that 5794 // your IAM role provides access to paths in Target. The following is an example. 5795 // 5796 // '[ "/bucket2/documentation", { "Entry": "your-personal-report.pdf", "Target": 5797 // "/bucket3/customized-reports/${transfer:UserName}.pdf" } ]' 5798 // 5799 // In most cases, you can use this value instead of the scope-down policy to 5800 // lock your user down to the designated home directory ("chroot"). To do this, 5801 // you can set Entry to '/' and set Target to the HomeDirectory parameter value. 5802 // 5803 // If the target of a logical directory entry does not exist in Amazon S3, the 5804 // entry will be ignored. As a workaround, you can use the Amazon S3 API to 5805 // create 0 byte objects as place holders for your directory. If using the CLI, 5806 // use the s3api call instead of s3 so you can use the put-object operation. 5807 // For example, you use the following: aws s3api put-object --bucket bucketname 5808 // --key path/to/folder/. Make sure that the end of the key name ends in a / 5809 // for it to be considered a folder. 5810 HomeDirectoryMappings []*HomeDirectoryMapEntry `min:"1" type:"list"` 5811 5812 // The type of landing directory (folder) you want your users' home directory 5813 // to be when they log into the server. If you set it to PATH, the user will 5814 // see the absolute Amazon S3 bucket paths as is in their file transfer protocol 5815 // clients. If you set it LOGICAL, you will need to provide mappings in the 5816 // HomeDirectoryMappings for how you want to make Amazon S3 paths visible to 5817 // your users. 5818 HomeDirectoryType *string `type:"string" enum:"HomeDirectoryType"` 5819 5820 // Allows you to supply a scope-down policy for your user so you can use the 5821 // same IAM role across multiple users. The policy scopes down user access to 5822 // portions of your Amazon S3 bucket. Variables you can use inside this policy 5823 // include ${Transfer:UserName}, ${Transfer:HomeDirectory}, and ${Transfer:HomeBucket}. 5824 // 5825 // For scope-down policies, AWS Transfer Family stores the policy as a JSON 5826 // blob, instead of the Amazon Resource Name (ARN) of the policy. You save the 5827 // policy as a JSON blob and pass it in the Policy argument. 5828 // 5829 // For an example of a scope-down policy, see Creating a scope-down policy (https://docs.aws.amazon.com/transfer/latest/userguide/users.html#users-policies-scope-down). 5830 // 5831 // For more information, see AssumeRole (https://docs.aws.amazon.com/STS/latest/APIReference/API_AssumeRole.html) 5832 // in the AWS Security Token Service API Reference. 5833 Policy *string `type:"string"` 5834 5835 PosixProfile *PosixProfile `type:"structure"` 5836 5837 // The IAM role that controls your users' access to your Amazon S3 bucket. The 5838 // policies attached to this role will determine the level of access you want 5839 // to provide your users when transferring files into and out of your Amazon 5840 // S3 bucket or buckets. The IAM role should also contain a trust relationship 5841 // that allows the server to access your resources when servicing your users' 5842 // transfer requests. 5843 Role *string `min:"20" type:"string"` 5844 5845 // A system-assigned unique identifier for a server instance that the user account 5846 // is assigned to. 5847 // 5848 // ServerId is a required field 5849 ServerId *string `min:"19" type:"string" required:"true"` 5850 5851 // A unique string that identifies a user and is associated with a server as 5852 // specified by the ServerId. This user name must be a minimum of 3 and a maximum 5853 // of 100 characters long. The following are valid characters: a-z, A-Z, 0-9, 5854 // underscore '_', hyphen '-', period '.', and at sign '@'. The user name can't 5855 // start with a hyphen, period, or at sign. 5856 // 5857 // UserName is a required field 5858 UserName *string `min:"3" type:"string" required:"true"` 5859} 5860 5861// String returns the string representation 5862func (s UpdateUserInput) String() string { 5863 return awsutil.Prettify(s) 5864} 5865 5866// GoString returns the string representation 5867func (s UpdateUserInput) GoString() string { 5868 return s.String() 5869} 5870 5871// Validate inspects the fields of the type to determine if they are valid. 5872func (s *UpdateUserInput) Validate() error { 5873 invalidParams := request.ErrInvalidParams{Context: "UpdateUserInput"} 5874 if s.HomeDirectoryMappings != nil && len(s.HomeDirectoryMappings) < 1 { 5875 invalidParams.Add(request.NewErrParamMinLen("HomeDirectoryMappings", 1)) 5876 } 5877 if s.Role != nil && len(*s.Role) < 20 { 5878 invalidParams.Add(request.NewErrParamMinLen("Role", 20)) 5879 } 5880 if s.ServerId == nil { 5881 invalidParams.Add(request.NewErrParamRequired("ServerId")) 5882 } 5883 if s.ServerId != nil && len(*s.ServerId) < 19 { 5884 invalidParams.Add(request.NewErrParamMinLen("ServerId", 19)) 5885 } 5886 if s.UserName == nil { 5887 invalidParams.Add(request.NewErrParamRequired("UserName")) 5888 } 5889 if s.UserName != nil && len(*s.UserName) < 3 { 5890 invalidParams.Add(request.NewErrParamMinLen("UserName", 3)) 5891 } 5892 if s.HomeDirectoryMappings != nil { 5893 for i, v := range s.HomeDirectoryMappings { 5894 if v == nil { 5895 continue 5896 } 5897 if err := v.Validate(); err != nil { 5898 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "HomeDirectoryMappings", i), err.(request.ErrInvalidParams)) 5899 } 5900 } 5901 } 5902 if s.PosixProfile != nil { 5903 if err := s.PosixProfile.Validate(); err != nil { 5904 invalidParams.AddNested("PosixProfile", err.(request.ErrInvalidParams)) 5905 } 5906 } 5907 5908 if invalidParams.Len() > 0 { 5909 return invalidParams 5910 } 5911 return nil 5912} 5913 5914// SetHomeDirectory sets the HomeDirectory field's value. 5915func (s *UpdateUserInput) SetHomeDirectory(v string) *UpdateUserInput { 5916 s.HomeDirectory = &v 5917 return s 5918} 5919 5920// SetHomeDirectoryMappings sets the HomeDirectoryMappings field's value. 5921func (s *UpdateUserInput) SetHomeDirectoryMappings(v []*HomeDirectoryMapEntry) *UpdateUserInput { 5922 s.HomeDirectoryMappings = v 5923 return s 5924} 5925 5926// SetHomeDirectoryType sets the HomeDirectoryType field's value. 5927func (s *UpdateUserInput) SetHomeDirectoryType(v string) *UpdateUserInput { 5928 s.HomeDirectoryType = &v 5929 return s 5930} 5931 5932// SetPolicy sets the Policy field's value. 5933func (s *UpdateUserInput) SetPolicy(v string) *UpdateUserInput { 5934 s.Policy = &v 5935 return s 5936} 5937 5938// SetPosixProfile sets the PosixProfile field's value. 5939func (s *UpdateUserInput) SetPosixProfile(v *PosixProfile) *UpdateUserInput { 5940 s.PosixProfile = v 5941 return s 5942} 5943 5944// SetRole sets the Role field's value. 5945func (s *UpdateUserInput) SetRole(v string) *UpdateUserInput { 5946 s.Role = &v 5947 return s 5948} 5949 5950// SetServerId sets the ServerId field's value. 5951func (s *UpdateUserInput) SetServerId(v string) *UpdateUserInput { 5952 s.ServerId = &v 5953 return s 5954} 5955 5956// SetUserName sets the UserName field's value. 5957func (s *UpdateUserInput) SetUserName(v string) *UpdateUserInput { 5958 s.UserName = &v 5959 return s 5960} 5961 5962// UpdateUserResponse returns the user name and identifier for the request to 5963// update a user's properties. 5964type UpdateUserOutput struct { 5965 _ struct{} `type:"structure"` 5966 5967 // A system-assigned unique identifier for a server instance that the user account 5968 // is assigned to. 5969 // 5970 // ServerId is a required field 5971 ServerId *string `min:"19" type:"string" required:"true"` 5972 5973 // The unique identifier for a user that is assigned to a server instance that 5974 // was specified in the request. 5975 // 5976 // UserName is a required field 5977 UserName *string `min:"3" type:"string" required:"true"` 5978} 5979 5980// String returns the string representation 5981func (s UpdateUserOutput) String() string { 5982 return awsutil.Prettify(s) 5983} 5984 5985// GoString returns the string representation 5986func (s UpdateUserOutput) GoString() string { 5987 return s.String() 5988} 5989 5990// SetServerId sets the ServerId field's value. 5991func (s *UpdateUserOutput) SetServerId(v string) *UpdateUserOutput { 5992 s.ServerId = &v 5993 return s 5994} 5995 5996// SetUserName sets the UserName field's value. 5997func (s *UpdateUserOutput) SetUserName(v string) *UpdateUserOutput { 5998 s.UserName = &v 5999 return s 6000} 6001 6002const ( 6003 // DomainS3 is a Domain enum value 6004 DomainS3 = "S3" 6005 6006 // DomainEfs is a Domain enum value 6007 DomainEfs = "EFS" 6008) 6009 6010// Domain_Values returns all elements of the Domain enum 6011func Domain_Values() []string { 6012 return []string{ 6013 DomainS3, 6014 DomainEfs, 6015 } 6016} 6017 6018const ( 6019 // EndpointTypePublic is a EndpointType enum value 6020 EndpointTypePublic = "PUBLIC" 6021 6022 // EndpointTypeVpc is a EndpointType enum value 6023 EndpointTypeVpc = "VPC" 6024 6025 // EndpointTypeVpcEndpoint is a EndpointType enum value 6026 EndpointTypeVpcEndpoint = "VPC_ENDPOINT" 6027) 6028 6029// EndpointType_Values returns all elements of the EndpointType enum 6030func EndpointType_Values() []string { 6031 return []string{ 6032 EndpointTypePublic, 6033 EndpointTypeVpc, 6034 EndpointTypeVpcEndpoint, 6035 } 6036} 6037 6038const ( 6039 // HomeDirectoryTypePath is a HomeDirectoryType enum value 6040 HomeDirectoryTypePath = "PATH" 6041 6042 // HomeDirectoryTypeLogical is a HomeDirectoryType enum value 6043 HomeDirectoryTypeLogical = "LOGICAL" 6044) 6045 6046// HomeDirectoryType_Values returns all elements of the HomeDirectoryType enum 6047func HomeDirectoryType_Values() []string { 6048 return []string{ 6049 HomeDirectoryTypePath, 6050 HomeDirectoryTypeLogical, 6051 } 6052} 6053 6054// Returns information related to the type of user authentication that is in 6055// use for a file transfer protocol-enabled server's users. For SERVICE_MANAGED 6056// authentication, the Secure Shell (SSH) public keys are stored with a user 6057// on the server instance. For API_GATEWAY authentication, your custom authentication 6058// method is implemented by using an API call. The server can have only one 6059// method of authentication. 6060const ( 6061 // IdentityProviderTypeServiceManaged is a IdentityProviderType enum value 6062 IdentityProviderTypeServiceManaged = "SERVICE_MANAGED" 6063 6064 // IdentityProviderTypeApiGateway is a IdentityProviderType enum value 6065 IdentityProviderTypeApiGateway = "API_GATEWAY" 6066) 6067 6068// IdentityProviderType_Values returns all elements of the IdentityProviderType enum 6069func IdentityProviderType_Values() []string { 6070 return []string{ 6071 IdentityProviderTypeServiceManaged, 6072 IdentityProviderTypeApiGateway, 6073 } 6074} 6075 6076const ( 6077 // ProtocolSftp is a Protocol enum value 6078 ProtocolSftp = "SFTP" 6079 6080 // ProtocolFtp is a Protocol enum value 6081 ProtocolFtp = "FTP" 6082 6083 // ProtocolFtps is a Protocol enum value 6084 ProtocolFtps = "FTPS" 6085) 6086 6087// Protocol_Values returns all elements of the Protocol enum 6088func Protocol_Values() []string { 6089 return []string{ 6090 ProtocolSftp, 6091 ProtocolFtp, 6092 ProtocolFtps, 6093 } 6094} 6095 6096// Describes the condition of a file transfer protocol-enabled server with respect 6097// to its ability to perform file operations. There are six possible states: 6098// OFFLINE, ONLINE, STARTING, STOPPING, START_FAILED, and STOP_FAILED. 6099// 6100// OFFLINE indicates that the server exists, but that it is not available for 6101// file operations. ONLINE indicates that the server is available to perform 6102// file operations. STARTING indicates that the server's was instantiated, but 6103// the server is not yet available to perform file operations. Under normal 6104// conditions, it can take a couple of minutes for the server to be completely 6105// operational. Both START_FAILED and STOP_FAILED are error conditions. 6106const ( 6107 // StateOffline is a State enum value 6108 StateOffline = "OFFLINE" 6109 6110 // StateOnline is a State enum value 6111 StateOnline = "ONLINE" 6112 6113 // StateStarting is a State enum value 6114 StateStarting = "STARTING" 6115 6116 // StateStopping is a State enum value 6117 StateStopping = "STOPPING" 6118 6119 // StateStartFailed is a State enum value 6120 StateStartFailed = "START_FAILED" 6121 6122 // StateStopFailed is a State enum value 6123 StateStopFailed = "STOP_FAILED" 6124) 6125 6126// State_Values returns all elements of the State enum 6127func State_Values() []string { 6128 return []string{ 6129 StateOffline, 6130 StateOnline, 6131 StateStarting, 6132 StateStopping, 6133 StateStartFailed, 6134 StateStopFailed, 6135 } 6136} 6137