1// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT. 2 3package mobile 4 5import ( 6 "time" 7 8 "github.com/aws/aws-sdk-go/aws" 9 "github.com/aws/aws-sdk-go/aws/awsutil" 10 "github.com/aws/aws-sdk-go/aws/request" 11) 12 13const opCreateProject = "CreateProject" 14 15// CreateProjectRequest generates a "aws/request.Request" representing the 16// client's request for the CreateProject operation. The "output" return 17// value will be populated with the request's response once the request complets 18// successfuly. 19// 20// Use "Send" method on the returned Request to send the API call to the service. 21// the "output" return value is not valid until after Send returns without error. 22// 23// See CreateProject for more information on using the CreateProject 24// API call, and error handling. 25// 26// This method is useful when you want to inject custom logic or configuration 27// into the SDK's request lifecycle. Such as custom headers, or retry logic. 28// 29// 30// // Example sending a request using the CreateProjectRequest method. 31// req, resp := client.CreateProjectRequest(params) 32// 33// err := req.Send() 34// if err == nil { // resp is now filled 35// fmt.Println(resp) 36// } 37// 38// See also, https://docs.aws.amazon.com/goto/WebAPI/mobile-2017-07-01/CreateProject 39func (c *Mobile) CreateProjectRequest(input *CreateProjectInput) (req *request.Request, output *CreateProjectOutput) { 40 op := &request.Operation{ 41 Name: opCreateProject, 42 HTTPMethod: "POST", 43 HTTPPath: "/projects", 44 } 45 46 if input == nil { 47 input = &CreateProjectInput{} 48 } 49 50 output = &CreateProjectOutput{} 51 req = c.newRequest(op, input, output) 52 return 53} 54 55// CreateProject API operation for AWS Mobile. 56// 57// Creates an AWS Mobile Hub project. 58// 59// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 60// with awserr.Error's Code and Message methods to get detailed information about 61// the error. 62// 63// See the AWS API reference guide for AWS Mobile's 64// API operation CreateProject for usage and error information. 65// 66// Returned Error Codes: 67// * ErrCodeInternalFailureException "InternalFailureException" 68// The service has encountered an unexpected error condition which prevents 69// it from servicing the request. 70// 71// * ErrCodeServiceUnavailableException "ServiceUnavailableException" 72// The service is temporarily unavailable. The request should be retried after 73// some time delay. 74// 75// * ErrCodeUnauthorizedException "UnauthorizedException" 76// Credentials of the caller are insufficient to authorize the request. 77// 78// * ErrCodeTooManyRequestsException "TooManyRequestsException" 79// Too many requests have been received for this AWS account in too short a 80// time. The request should be retried after some time delay. 81// 82// * ErrCodeBadRequestException "BadRequestException" 83// The request cannot be processed because some parameter is not valid or the 84// project state prevents the operation from being performed. 85// 86// * ErrCodeNotFoundException "NotFoundException" 87// No entity can be found with the specified identifier. 88// 89// * ErrCodeLimitExceededException "LimitExceededException" 90// There are too many AWS Mobile Hub projects in the account or the account 91// has exceeded the maximum number of resources in some AWS service. You should 92// create another sub-account using AWS Organizations or remove some resources 93// and retry your request. 94// 95// See also, https://docs.aws.amazon.com/goto/WebAPI/mobile-2017-07-01/CreateProject 96func (c *Mobile) CreateProject(input *CreateProjectInput) (*CreateProjectOutput, error) { 97 req, out := c.CreateProjectRequest(input) 98 return out, req.Send() 99} 100 101// CreateProjectWithContext is the same as CreateProject with the addition of 102// the ability to pass a context and additional request options. 103// 104// See CreateProject for details on how to use this API operation. 105// 106// The context must be non-nil and will be used for request cancellation. If 107// the context is nil a panic will occur. In the future the SDK may create 108// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 109// for more information on using Contexts. 110func (c *Mobile) CreateProjectWithContext(ctx aws.Context, input *CreateProjectInput, opts ...request.Option) (*CreateProjectOutput, error) { 111 req, out := c.CreateProjectRequest(input) 112 req.SetContext(ctx) 113 req.ApplyOptions(opts...) 114 return out, req.Send() 115} 116 117const opDeleteProject = "DeleteProject" 118 119// DeleteProjectRequest generates a "aws/request.Request" representing the 120// client's request for the DeleteProject operation. The "output" return 121// value will be populated with the request's response once the request complets 122// successfuly. 123// 124// Use "Send" method on the returned Request to send the API call to the service. 125// the "output" return value is not valid until after Send returns without error. 126// 127// See DeleteProject for more information on using the DeleteProject 128// API call, and error handling. 129// 130// This method is useful when you want to inject custom logic or configuration 131// into the SDK's request lifecycle. Such as custom headers, or retry logic. 132// 133// 134// // Example sending a request using the DeleteProjectRequest method. 135// req, resp := client.DeleteProjectRequest(params) 136// 137// err := req.Send() 138// if err == nil { // resp is now filled 139// fmt.Println(resp) 140// } 141// 142// See also, https://docs.aws.amazon.com/goto/WebAPI/mobile-2017-07-01/DeleteProject 143func (c *Mobile) DeleteProjectRequest(input *DeleteProjectInput) (req *request.Request, output *DeleteProjectOutput) { 144 op := &request.Operation{ 145 Name: opDeleteProject, 146 HTTPMethod: "DELETE", 147 HTTPPath: "/projects/{projectId}", 148 } 149 150 if input == nil { 151 input = &DeleteProjectInput{} 152 } 153 154 output = &DeleteProjectOutput{} 155 req = c.newRequest(op, input, output) 156 return 157} 158 159// DeleteProject API operation for AWS Mobile. 160// 161// Delets a project in AWS Mobile Hub. 162// 163// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 164// with awserr.Error's Code and Message methods to get detailed information about 165// the error. 166// 167// See the AWS API reference guide for AWS Mobile's 168// API operation DeleteProject for usage and error information. 169// 170// Returned Error Codes: 171// * ErrCodeInternalFailureException "InternalFailureException" 172// The service has encountered an unexpected error condition which prevents 173// it from servicing the request. 174// 175// * ErrCodeServiceUnavailableException "ServiceUnavailableException" 176// The service is temporarily unavailable. The request should be retried after 177// some time delay. 178// 179// * ErrCodeUnauthorizedException "UnauthorizedException" 180// Credentials of the caller are insufficient to authorize the request. 181// 182// * ErrCodeTooManyRequestsException "TooManyRequestsException" 183// Too many requests have been received for this AWS account in too short a 184// time. The request should be retried after some time delay. 185// 186// * ErrCodeNotFoundException "NotFoundException" 187// No entity can be found with the specified identifier. 188// 189// See also, https://docs.aws.amazon.com/goto/WebAPI/mobile-2017-07-01/DeleteProject 190func (c *Mobile) DeleteProject(input *DeleteProjectInput) (*DeleteProjectOutput, error) { 191 req, out := c.DeleteProjectRequest(input) 192 return out, req.Send() 193} 194 195// DeleteProjectWithContext is the same as DeleteProject with the addition of 196// the ability to pass a context and additional request options. 197// 198// See DeleteProject for details on how to use this API operation. 199// 200// The context must be non-nil and will be used for request cancellation. If 201// the context is nil a panic will occur. In the future the SDK may create 202// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 203// for more information on using Contexts. 204func (c *Mobile) DeleteProjectWithContext(ctx aws.Context, input *DeleteProjectInput, opts ...request.Option) (*DeleteProjectOutput, error) { 205 req, out := c.DeleteProjectRequest(input) 206 req.SetContext(ctx) 207 req.ApplyOptions(opts...) 208 return out, req.Send() 209} 210 211const opDescribeBundle = "DescribeBundle" 212 213// DescribeBundleRequest generates a "aws/request.Request" representing the 214// client's request for the DescribeBundle operation. The "output" return 215// value will be populated with the request's response once the request complets 216// successfuly. 217// 218// Use "Send" method on the returned Request to send the API call to the service. 219// the "output" return value is not valid until after Send returns without error. 220// 221// See DescribeBundle for more information on using the DescribeBundle 222// API call, and error handling. 223// 224// This method is useful when you want to inject custom logic or configuration 225// into the SDK's request lifecycle. Such as custom headers, or retry logic. 226// 227// 228// // Example sending a request using the DescribeBundleRequest method. 229// req, resp := client.DescribeBundleRequest(params) 230// 231// err := req.Send() 232// if err == nil { // resp is now filled 233// fmt.Println(resp) 234// } 235// 236// See also, https://docs.aws.amazon.com/goto/WebAPI/mobile-2017-07-01/DescribeBundle 237func (c *Mobile) DescribeBundleRequest(input *DescribeBundleInput) (req *request.Request, output *DescribeBundleOutput) { 238 op := &request.Operation{ 239 Name: opDescribeBundle, 240 HTTPMethod: "GET", 241 HTTPPath: "/bundles/{bundleId}", 242 } 243 244 if input == nil { 245 input = &DescribeBundleInput{} 246 } 247 248 output = &DescribeBundleOutput{} 249 req = c.newRequest(op, input, output) 250 return 251} 252 253// DescribeBundle API operation for AWS Mobile. 254// 255// Get the bundle details for the requested bundle id. 256// 257// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 258// with awserr.Error's Code and Message methods to get detailed information about 259// the error. 260// 261// See the AWS API reference guide for AWS Mobile's 262// API operation DescribeBundle for usage and error information. 263// 264// Returned Error Codes: 265// * ErrCodeInternalFailureException "InternalFailureException" 266// The service has encountered an unexpected error condition which prevents 267// it from servicing the request. 268// 269// * ErrCodeServiceUnavailableException "ServiceUnavailableException" 270// The service is temporarily unavailable. The request should be retried after 271// some time delay. 272// 273// * ErrCodeUnauthorizedException "UnauthorizedException" 274// Credentials of the caller are insufficient to authorize the request. 275// 276// * ErrCodeTooManyRequestsException "TooManyRequestsException" 277// Too many requests have been received for this AWS account in too short a 278// time. The request should be retried after some time delay. 279// 280// * ErrCodeBadRequestException "BadRequestException" 281// The request cannot be processed because some parameter is not valid or the 282// project state prevents the operation from being performed. 283// 284// * ErrCodeNotFoundException "NotFoundException" 285// No entity can be found with the specified identifier. 286// 287// See also, https://docs.aws.amazon.com/goto/WebAPI/mobile-2017-07-01/DescribeBundle 288func (c *Mobile) DescribeBundle(input *DescribeBundleInput) (*DescribeBundleOutput, error) { 289 req, out := c.DescribeBundleRequest(input) 290 return out, req.Send() 291} 292 293// DescribeBundleWithContext is the same as DescribeBundle with the addition of 294// the ability to pass a context and additional request options. 295// 296// See DescribeBundle for details on how to use this API operation. 297// 298// The context must be non-nil and will be used for request cancellation. If 299// the context is nil a panic will occur. In the future the SDK may create 300// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 301// for more information on using Contexts. 302func (c *Mobile) DescribeBundleWithContext(ctx aws.Context, input *DescribeBundleInput, opts ...request.Option) (*DescribeBundleOutput, error) { 303 req, out := c.DescribeBundleRequest(input) 304 req.SetContext(ctx) 305 req.ApplyOptions(opts...) 306 return out, req.Send() 307} 308 309const opDescribeProject = "DescribeProject" 310 311// DescribeProjectRequest generates a "aws/request.Request" representing the 312// client's request for the DescribeProject operation. The "output" return 313// value will be populated with the request's response once the request complets 314// successfuly. 315// 316// Use "Send" method on the returned Request to send the API call to the service. 317// the "output" return value is not valid until after Send returns without error. 318// 319// See DescribeProject for more information on using the DescribeProject 320// API call, and error handling. 321// 322// This method is useful when you want to inject custom logic or configuration 323// into the SDK's request lifecycle. Such as custom headers, or retry logic. 324// 325// 326// // Example sending a request using the DescribeProjectRequest method. 327// req, resp := client.DescribeProjectRequest(params) 328// 329// err := req.Send() 330// if err == nil { // resp is now filled 331// fmt.Println(resp) 332// } 333// 334// See also, https://docs.aws.amazon.com/goto/WebAPI/mobile-2017-07-01/DescribeProject 335func (c *Mobile) DescribeProjectRequest(input *DescribeProjectInput) (req *request.Request, output *DescribeProjectOutput) { 336 op := &request.Operation{ 337 Name: opDescribeProject, 338 HTTPMethod: "GET", 339 HTTPPath: "/project", 340 } 341 342 if input == nil { 343 input = &DescribeProjectInput{} 344 } 345 346 output = &DescribeProjectOutput{} 347 req = c.newRequest(op, input, output) 348 return 349} 350 351// DescribeProject API operation for AWS Mobile. 352// 353// Gets details about a project in AWS Mobile Hub. 354// 355// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 356// with awserr.Error's Code and Message methods to get detailed information about 357// the error. 358// 359// See the AWS API reference guide for AWS Mobile's 360// API operation DescribeProject for usage and error information. 361// 362// Returned Error Codes: 363// * ErrCodeInternalFailureException "InternalFailureException" 364// The service has encountered an unexpected error condition which prevents 365// it from servicing the request. 366// 367// * ErrCodeServiceUnavailableException "ServiceUnavailableException" 368// The service is temporarily unavailable. The request should be retried after 369// some time delay. 370// 371// * ErrCodeUnauthorizedException "UnauthorizedException" 372// Credentials of the caller are insufficient to authorize the request. 373// 374// * ErrCodeTooManyRequestsException "TooManyRequestsException" 375// Too many requests have been received for this AWS account in too short a 376// time. The request should be retried after some time delay. 377// 378// * ErrCodeBadRequestException "BadRequestException" 379// The request cannot be processed because some parameter is not valid or the 380// project state prevents the operation from being performed. 381// 382// * ErrCodeNotFoundException "NotFoundException" 383// No entity can be found with the specified identifier. 384// 385// See also, https://docs.aws.amazon.com/goto/WebAPI/mobile-2017-07-01/DescribeProject 386func (c *Mobile) DescribeProject(input *DescribeProjectInput) (*DescribeProjectOutput, error) { 387 req, out := c.DescribeProjectRequest(input) 388 return out, req.Send() 389} 390 391// DescribeProjectWithContext is the same as DescribeProject with the addition of 392// the ability to pass a context and additional request options. 393// 394// See DescribeProject for details on how to use this API operation. 395// 396// The context must be non-nil and will be used for request cancellation. If 397// the context is nil a panic will occur. In the future the SDK may create 398// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 399// for more information on using Contexts. 400func (c *Mobile) DescribeProjectWithContext(ctx aws.Context, input *DescribeProjectInput, opts ...request.Option) (*DescribeProjectOutput, error) { 401 req, out := c.DescribeProjectRequest(input) 402 req.SetContext(ctx) 403 req.ApplyOptions(opts...) 404 return out, req.Send() 405} 406 407const opExportBundle = "ExportBundle" 408 409// ExportBundleRequest generates a "aws/request.Request" representing the 410// client's request for the ExportBundle operation. The "output" return 411// value will be populated with the request's response once the request complets 412// successfuly. 413// 414// Use "Send" method on the returned Request to send the API call to the service. 415// the "output" return value is not valid until after Send returns without error. 416// 417// See ExportBundle for more information on using the ExportBundle 418// API call, and error handling. 419// 420// This method is useful when you want to inject custom logic or configuration 421// into the SDK's request lifecycle. Such as custom headers, or retry logic. 422// 423// 424// // Example sending a request using the ExportBundleRequest method. 425// req, resp := client.ExportBundleRequest(params) 426// 427// err := req.Send() 428// if err == nil { // resp is now filled 429// fmt.Println(resp) 430// } 431// 432// See also, https://docs.aws.amazon.com/goto/WebAPI/mobile-2017-07-01/ExportBundle 433func (c *Mobile) ExportBundleRequest(input *ExportBundleInput) (req *request.Request, output *ExportBundleOutput) { 434 op := &request.Operation{ 435 Name: opExportBundle, 436 HTTPMethod: "POST", 437 HTTPPath: "/bundles/{bundleId}", 438 } 439 440 if input == nil { 441 input = &ExportBundleInput{} 442 } 443 444 output = &ExportBundleOutput{} 445 req = c.newRequest(op, input, output) 446 return 447} 448 449// ExportBundle API operation for AWS Mobile. 450// 451// Generates customized software development kit (SDK) and or tool packages 452// used to integrate mobile web or mobile app clients with backend AWS resources. 453// 454// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 455// with awserr.Error's Code and Message methods to get detailed information about 456// the error. 457// 458// See the AWS API reference guide for AWS Mobile's 459// API operation ExportBundle for usage and error information. 460// 461// Returned Error Codes: 462// * ErrCodeInternalFailureException "InternalFailureException" 463// The service has encountered an unexpected error condition which prevents 464// it from servicing the request. 465// 466// * ErrCodeServiceUnavailableException "ServiceUnavailableException" 467// The service is temporarily unavailable. The request should be retried after 468// some time delay. 469// 470// * ErrCodeUnauthorizedException "UnauthorizedException" 471// Credentials of the caller are insufficient to authorize the request. 472// 473// * ErrCodeTooManyRequestsException "TooManyRequestsException" 474// Too many requests have been received for this AWS account in too short a 475// time. The request should be retried after some time delay. 476// 477// * ErrCodeBadRequestException "BadRequestException" 478// The request cannot be processed because some parameter is not valid or the 479// project state prevents the operation from being performed. 480// 481// * ErrCodeNotFoundException "NotFoundException" 482// No entity can be found with the specified identifier. 483// 484// See also, https://docs.aws.amazon.com/goto/WebAPI/mobile-2017-07-01/ExportBundle 485func (c *Mobile) ExportBundle(input *ExportBundleInput) (*ExportBundleOutput, error) { 486 req, out := c.ExportBundleRequest(input) 487 return out, req.Send() 488} 489 490// ExportBundleWithContext is the same as ExportBundle with the addition of 491// the ability to pass a context and additional request options. 492// 493// See ExportBundle for details on how to use this API operation. 494// 495// The context must be non-nil and will be used for request cancellation. If 496// the context is nil a panic will occur. In the future the SDK may create 497// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 498// for more information on using Contexts. 499func (c *Mobile) ExportBundleWithContext(ctx aws.Context, input *ExportBundleInput, opts ...request.Option) (*ExportBundleOutput, error) { 500 req, out := c.ExportBundleRequest(input) 501 req.SetContext(ctx) 502 req.ApplyOptions(opts...) 503 return out, req.Send() 504} 505 506const opExportProject = "ExportProject" 507 508// ExportProjectRequest generates a "aws/request.Request" representing the 509// client's request for the ExportProject operation. The "output" return 510// value will be populated with the request's response once the request complets 511// successfuly. 512// 513// Use "Send" method on the returned Request to send the API call to the service. 514// the "output" return value is not valid until after Send returns without error. 515// 516// See ExportProject for more information on using the ExportProject 517// API call, and error handling. 518// 519// This method is useful when you want to inject custom logic or configuration 520// into the SDK's request lifecycle. Such as custom headers, or retry logic. 521// 522// 523// // Example sending a request using the ExportProjectRequest method. 524// req, resp := client.ExportProjectRequest(params) 525// 526// err := req.Send() 527// if err == nil { // resp is now filled 528// fmt.Println(resp) 529// } 530// 531// See also, https://docs.aws.amazon.com/goto/WebAPI/mobile-2017-07-01/ExportProject 532func (c *Mobile) ExportProjectRequest(input *ExportProjectInput) (req *request.Request, output *ExportProjectOutput) { 533 op := &request.Operation{ 534 Name: opExportProject, 535 HTTPMethod: "POST", 536 HTTPPath: "/exports/{projectId}", 537 } 538 539 if input == nil { 540 input = &ExportProjectInput{} 541 } 542 543 output = &ExportProjectOutput{} 544 req = c.newRequest(op, input, output) 545 return 546} 547 548// ExportProject API operation for AWS Mobile. 549// 550// Exports project configuration to a snapshot which can be downloaded and shared. 551// Note that mobile app push credentials are encrypted in exported projects, 552// so they can only be shared successfully within the same AWS account. 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 Mobile's 559// API operation ExportProject for usage and error information. 560// 561// Returned Error Codes: 562// * ErrCodeInternalFailureException "InternalFailureException" 563// The service has encountered an unexpected error condition which prevents 564// it from servicing the request. 565// 566// * ErrCodeServiceUnavailableException "ServiceUnavailableException" 567// The service is temporarily unavailable. The request should be retried after 568// some time delay. 569// 570// * ErrCodeUnauthorizedException "UnauthorizedException" 571// Credentials of the caller are insufficient to authorize the request. 572// 573// * ErrCodeTooManyRequestsException "TooManyRequestsException" 574// Too many requests have been received for this AWS account in too short a 575// time. The request should be retried after some time delay. 576// 577// * ErrCodeBadRequestException "BadRequestException" 578// The request cannot be processed because some parameter is not valid or the 579// project state prevents the operation from being performed. 580// 581// * ErrCodeNotFoundException "NotFoundException" 582// No entity can be found with the specified identifier. 583// 584// See also, https://docs.aws.amazon.com/goto/WebAPI/mobile-2017-07-01/ExportProject 585func (c *Mobile) ExportProject(input *ExportProjectInput) (*ExportProjectOutput, error) { 586 req, out := c.ExportProjectRequest(input) 587 return out, req.Send() 588} 589 590// ExportProjectWithContext is the same as ExportProject with the addition of 591// the ability to pass a context and additional request options. 592// 593// See ExportProject for details on how to use this API operation. 594// 595// The context must be non-nil and will be used for request cancellation. If 596// the context is nil a panic will occur. In the future the SDK may create 597// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 598// for more information on using Contexts. 599func (c *Mobile) ExportProjectWithContext(ctx aws.Context, input *ExportProjectInput, opts ...request.Option) (*ExportProjectOutput, error) { 600 req, out := c.ExportProjectRequest(input) 601 req.SetContext(ctx) 602 req.ApplyOptions(opts...) 603 return out, req.Send() 604} 605 606const opListBundles = "ListBundles" 607 608// ListBundlesRequest generates a "aws/request.Request" representing the 609// client's request for the ListBundles operation. The "output" return 610// value will be populated with the request's response once the request complets 611// successfuly. 612// 613// Use "Send" method on the returned Request to send the API call to the service. 614// the "output" return value is not valid until after Send returns without error. 615// 616// See ListBundles for more information on using the ListBundles 617// API call, and error handling. 618// 619// This method is useful when you want to inject custom logic or configuration 620// into the SDK's request lifecycle. Such as custom headers, or retry logic. 621// 622// 623// // Example sending a request using the ListBundlesRequest method. 624// req, resp := client.ListBundlesRequest(params) 625// 626// err := req.Send() 627// if err == nil { // resp is now filled 628// fmt.Println(resp) 629// } 630// 631// See also, https://docs.aws.amazon.com/goto/WebAPI/mobile-2017-07-01/ListBundles 632func (c *Mobile) ListBundlesRequest(input *ListBundlesInput) (req *request.Request, output *ListBundlesOutput) { 633 op := &request.Operation{ 634 Name: opListBundles, 635 HTTPMethod: "GET", 636 HTTPPath: "/bundles", 637 Paginator: &request.Paginator{ 638 InputTokens: []string{"nextToken"}, 639 OutputTokens: []string{"nextToken"}, 640 LimitToken: "maxResults", 641 TruncationToken: "", 642 }, 643 } 644 645 if input == nil { 646 input = &ListBundlesInput{} 647 } 648 649 output = &ListBundlesOutput{} 650 req = c.newRequest(op, input, output) 651 return 652} 653 654// ListBundles API operation for AWS Mobile. 655// 656// List all available bundles. 657// 658// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 659// with awserr.Error's Code and Message methods to get detailed information about 660// the error. 661// 662// See the AWS API reference guide for AWS Mobile's 663// API operation ListBundles for usage and error information. 664// 665// Returned Error Codes: 666// * ErrCodeInternalFailureException "InternalFailureException" 667// The service has encountered an unexpected error condition which prevents 668// it from servicing the request. 669// 670// * ErrCodeServiceUnavailableException "ServiceUnavailableException" 671// The service is temporarily unavailable. The request should be retried after 672// some time delay. 673// 674// * ErrCodeUnauthorizedException "UnauthorizedException" 675// Credentials of the caller are insufficient to authorize the request. 676// 677// * ErrCodeTooManyRequestsException "TooManyRequestsException" 678// Too many requests have been received for this AWS account in too short a 679// time. The request should be retried after some time delay. 680// 681// * ErrCodeBadRequestException "BadRequestException" 682// The request cannot be processed because some parameter is not valid or the 683// project state prevents the operation from being performed. 684// 685// See also, https://docs.aws.amazon.com/goto/WebAPI/mobile-2017-07-01/ListBundles 686func (c *Mobile) ListBundles(input *ListBundlesInput) (*ListBundlesOutput, error) { 687 req, out := c.ListBundlesRequest(input) 688 return out, req.Send() 689} 690 691// ListBundlesWithContext is the same as ListBundles with the addition of 692// the ability to pass a context and additional request options. 693// 694// See ListBundles for details on how to use this API operation. 695// 696// The context must be non-nil and will be used for request cancellation. If 697// the context is nil a panic will occur. In the future the SDK may create 698// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 699// for more information on using Contexts. 700func (c *Mobile) ListBundlesWithContext(ctx aws.Context, input *ListBundlesInput, opts ...request.Option) (*ListBundlesOutput, error) { 701 req, out := c.ListBundlesRequest(input) 702 req.SetContext(ctx) 703 req.ApplyOptions(opts...) 704 return out, req.Send() 705} 706 707// ListBundlesPages iterates over the pages of a ListBundles operation, 708// calling the "fn" function with the response data for each page. To stop 709// iterating, return false from the fn function. 710// 711// See ListBundles method for more information on how to use this operation. 712// 713// Note: This operation can generate multiple requests to a service. 714// 715// // Example iterating over at most 3 pages of a ListBundles operation. 716// pageNum := 0 717// err := client.ListBundlesPages(params, 718// func(page *ListBundlesOutput, lastPage bool) bool { 719// pageNum++ 720// fmt.Println(page) 721// return pageNum <= 3 722// }) 723// 724func (c *Mobile) ListBundlesPages(input *ListBundlesInput, fn func(*ListBundlesOutput, bool) bool) error { 725 return c.ListBundlesPagesWithContext(aws.BackgroundContext(), input, fn) 726} 727 728// ListBundlesPagesWithContext same as ListBundlesPages except 729// it takes a Context and allows setting request options on the pages. 730// 731// The context must be non-nil and will be used for request cancellation. If 732// the context is nil a panic will occur. In the future the SDK may create 733// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 734// for more information on using Contexts. 735func (c *Mobile) ListBundlesPagesWithContext(ctx aws.Context, input *ListBundlesInput, fn func(*ListBundlesOutput, bool) bool, opts ...request.Option) error { 736 p := request.Pagination{ 737 NewRequest: func() (*request.Request, error) { 738 var inCpy *ListBundlesInput 739 if input != nil { 740 tmp := *input 741 inCpy = &tmp 742 } 743 req, _ := c.ListBundlesRequest(inCpy) 744 req.SetContext(ctx) 745 req.ApplyOptions(opts...) 746 return req, nil 747 }, 748 } 749 750 cont := true 751 for p.Next() && cont { 752 cont = fn(p.Page().(*ListBundlesOutput), !p.HasNextPage()) 753 } 754 return p.Err() 755} 756 757const opListProjects = "ListProjects" 758 759// ListProjectsRequest generates a "aws/request.Request" representing the 760// client's request for the ListProjects operation. The "output" return 761// value will be populated with the request's response once the request complets 762// successfuly. 763// 764// Use "Send" method on the returned Request to send the API call to the service. 765// the "output" return value is not valid until after Send returns without error. 766// 767// See ListProjects for more information on using the ListProjects 768// API call, and error handling. 769// 770// This method is useful when you want to inject custom logic or configuration 771// into the SDK's request lifecycle. Such as custom headers, or retry logic. 772// 773// 774// // Example sending a request using the ListProjectsRequest method. 775// req, resp := client.ListProjectsRequest(params) 776// 777// err := req.Send() 778// if err == nil { // resp is now filled 779// fmt.Println(resp) 780// } 781// 782// See also, https://docs.aws.amazon.com/goto/WebAPI/mobile-2017-07-01/ListProjects 783func (c *Mobile) ListProjectsRequest(input *ListProjectsInput) (req *request.Request, output *ListProjectsOutput) { 784 op := &request.Operation{ 785 Name: opListProjects, 786 HTTPMethod: "GET", 787 HTTPPath: "/projects", 788 Paginator: &request.Paginator{ 789 InputTokens: []string{"nextToken"}, 790 OutputTokens: []string{"nextToken"}, 791 LimitToken: "maxResults", 792 TruncationToken: "", 793 }, 794 } 795 796 if input == nil { 797 input = &ListProjectsInput{} 798 } 799 800 output = &ListProjectsOutput{} 801 req = c.newRequest(op, input, output) 802 return 803} 804 805// ListProjects API operation for AWS Mobile. 806// 807// Lists projects in AWS Mobile Hub. 808// 809// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 810// with awserr.Error's Code and Message methods to get detailed information about 811// the error. 812// 813// See the AWS API reference guide for AWS Mobile's 814// API operation ListProjects for usage and error information. 815// 816// Returned Error Codes: 817// * ErrCodeInternalFailureException "InternalFailureException" 818// The service has encountered an unexpected error condition which prevents 819// it from servicing the request. 820// 821// * ErrCodeServiceUnavailableException "ServiceUnavailableException" 822// The service is temporarily unavailable. The request should be retried after 823// some time delay. 824// 825// * ErrCodeUnauthorizedException "UnauthorizedException" 826// Credentials of the caller are insufficient to authorize the request. 827// 828// * ErrCodeTooManyRequestsException "TooManyRequestsException" 829// Too many requests have been received for this AWS account in too short a 830// time. The request should be retried after some time delay. 831// 832// * ErrCodeBadRequestException "BadRequestException" 833// The request cannot be processed because some parameter is not valid or the 834// project state prevents the operation from being performed. 835// 836// See also, https://docs.aws.amazon.com/goto/WebAPI/mobile-2017-07-01/ListProjects 837func (c *Mobile) ListProjects(input *ListProjectsInput) (*ListProjectsOutput, error) { 838 req, out := c.ListProjectsRequest(input) 839 return out, req.Send() 840} 841 842// ListProjectsWithContext is the same as ListProjects with the addition of 843// the ability to pass a context and additional request options. 844// 845// See ListProjects for details on how to use this API operation. 846// 847// The context must be non-nil and will be used for request cancellation. If 848// the context is nil a panic will occur. In the future the SDK may create 849// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 850// for more information on using Contexts. 851func (c *Mobile) ListProjectsWithContext(ctx aws.Context, input *ListProjectsInput, opts ...request.Option) (*ListProjectsOutput, error) { 852 req, out := c.ListProjectsRequest(input) 853 req.SetContext(ctx) 854 req.ApplyOptions(opts...) 855 return out, req.Send() 856} 857 858// ListProjectsPages iterates over the pages of a ListProjects operation, 859// calling the "fn" function with the response data for each page. To stop 860// iterating, return false from the fn function. 861// 862// See ListProjects method for more information on how to use this operation. 863// 864// Note: This operation can generate multiple requests to a service. 865// 866// // Example iterating over at most 3 pages of a ListProjects operation. 867// pageNum := 0 868// err := client.ListProjectsPages(params, 869// func(page *ListProjectsOutput, lastPage bool) bool { 870// pageNum++ 871// fmt.Println(page) 872// return pageNum <= 3 873// }) 874// 875func (c *Mobile) ListProjectsPages(input *ListProjectsInput, fn func(*ListProjectsOutput, bool) bool) error { 876 return c.ListProjectsPagesWithContext(aws.BackgroundContext(), input, fn) 877} 878 879// ListProjectsPagesWithContext same as ListProjectsPages except 880// it takes a Context and allows setting request options on the pages. 881// 882// The context must be non-nil and will be used for request cancellation. If 883// the context is nil a panic will occur. In the future the SDK may create 884// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 885// for more information on using Contexts. 886func (c *Mobile) ListProjectsPagesWithContext(ctx aws.Context, input *ListProjectsInput, fn func(*ListProjectsOutput, bool) bool, opts ...request.Option) error { 887 p := request.Pagination{ 888 NewRequest: func() (*request.Request, error) { 889 var inCpy *ListProjectsInput 890 if input != nil { 891 tmp := *input 892 inCpy = &tmp 893 } 894 req, _ := c.ListProjectsRequest(inCpy) 895 req.SetContext(ctx) 896 req.ApplyOptions(opts...) 897 return req, nil 898 }, 899 } 900 901 cont := true 902 for p.Next() && cont { 903 cont = fn(p.Page().(*ListProjectsOutput), !p.HasNextPage()) 904 } 905 return p.Err() 906} 907 908const opUpdateProject = "UpdateProject" 909 910// UpdateProjectRequest generates a "aws/request.Request" representing the 911// client's request for the UpdateProject operation. The "output" return 912// value will be populated with the request's response once the request complets 913// successfuly. 914// 915// Use "Send" method on the returned Request to send the API call to the service. 916// the "output" return value is not valid until after Send returns without error. 917// 918// See UpdateProject for more information on using the UpdateProject 919// API call, and error handling. 920// 921// This method is useful when you want to inject custom logic or configuration 922// into the SDK's request lifecycle. Such as custom headers, or retry logic. 923// 924// 925// // Example sending a request using the UpdateProjectRequest method. 926// req, resp := client.UpdateProjectRequest(params) 927// 928// err := req.Send() 929// if err == nil { // resp is now filled 930// fmt.Println(resp) 931// } 932// 933// See also, https://docs.aws.amazon.com/goto/WebAPI/mobile-2017-07-01/UpdateProject 934func (c *Mobile) UpdateProjectRequest(input *UpdateProjectInput) (req *request.Request, output *UpdateProjectOutput) { 935 op := &request.Operation{ 936 Name: opUpdateProject, 937 HTTPMethod: "POST", 938 HTTPPath: "/update", 939 } 940 941 if input == nil { 942 input = &UpdateProjectInput{} 943 } 944 945 output = &UpdateProjectOutput{} 946 req = c.newRequest(op, input, output) 947 return 948} 949 950// UpdateProject API operation for AWS Mobile. 951// 952// Update an existing project. 953// 954// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 955// with awserr.Error's Code and Message methods to get detailed information about 956// the error. 957// 958// See the AWS API reference guide for AWS Mobile's 959// API operation UpdateProject for usage and error information. 960// 961// Returned Error Codes: 962// * ErrCodeInternalFailureException "InternalFailureException" 963// The service has encountered an unexpected error condition which prevents 964// it from servicing the request. 965// 966// * ErrCodeServiceUnavailableException "ServiceUnavailableException" 967// The service is temporarily unavailable. The request should be retried after 968// some time delay. 969// 970// * ErrCodeUnauthorizedException "UnauthorizedException" 971// Credentials of the caller are insufficient to authorize the request. 972// 973// * ErrCodeTooManyRequestsException "TooManyRequestsException" 974// Too many requests have been received for this AWS account in too short a 975// time. The request should be retried after some time delay. 976// 977// * ErrCodeBadRequestException "BadRequestException" 978// The request cannot be processed because some parameter is not valid or the 979// project state prevents the operation from being performed. 980// 981// * ErrCodeNotFoundException "NotFoundException" 982// No entity can be found with the specified identifier. 983// 984// * ErrCodeAccountActionRequiredException "AccountActionRequiredException" 985// Account Action is required in order to continue the request. 986// 987// * ErrCodeLimitExceededException "LimitExceededException" 988// There are too many AWS Mobile Hub projects in the account or the account 989// has exceeded the maximum number of resources in some AWS service. You should 990// create another sub-account using AWS Organizations or remove some resources 991// and retry your request. 992// 993// See also, https://docs.aws.amazon.com/goto/WebAPI/mobile-2017-07-01/UpdateProject 994func (c *Mobile) UpdateProject(input *UpdateProjectInput) (*UpdateProjectOutput, error) { 995 req, out := c.UpdateProjectRequest(input) 996 return out, req.Send() 997} 998 999// UpdateProjectWithContext is the same as UpdateProject with the addition of 1000// the ability to pass a context and additional request options. 1001// 1002// See UpdateProject for details on how to use this API operation. 1003// 1004// The context must be non-nil and will be used for request cancellation. If 1005// the context is nil a panic will occur. In the future the SDK may create 1006// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1007// for more information on using Contexts. 1008func (c *Mobile) UpdateProjectWithContext(ctx aws.Context, input *UpdateProjectInput, opts ...request.Option) (*UpdateProjectOutput, error) { 1009 req, out := c.UpdateProjectRequest(input) 1010 req.SetContext(ctx) 1011 req.ApplyOptions(opts...) 1012 return out, req.Send() 1013} 1014 1015// The details of the bundle. 1016// See also, https://docs.aws.amazon.com/goto/WebAPI/mobile-2017-07-01/BundleDetails 1017type BundleDetails struct { 1018 _ struct{} `type:"structure"` 1019 1020 // Developer desktop or mobile app or website platforms. 1021 AvailablePlatforms []*string `locationName:"availablePlatforms" type:"list"` 1022 1023 // Unique bundle identifier. 1024 BundleId *string `locationName:"bundleId" type:"string"` 1025 1026 // Description of the download bundle. 1027 Description *string `locationName:"description" type:"string"` 1028 1029 // Icon for the download bundle. 1030 IconUrl *string `locationName:"iconUrl" type:"string"` 1031 1032 // Title of the download bundle. 1033 Title *string `locationName:"title" type:"string"` 1034 1035 // Version of the download bundle. 1036 Version *string `locationName:"version" type:"string"` 1037} 1038 1039// String returns the string representation 1040func (s BundleDetails) String() string { 1041 return awsutil.Prettify(s) 1042} 1043 1044// GoString returns the string representation 1045func (s BundleDetails) GoString() string { 1046 return s.String() 1047} 1048 1049// SetAvailablePlatforms sets the AvailablePlatforms field's value. 1050func (s *BundleDetails) SetAvailablePlatforms(v []*string) *BundleDetails { 1051 s.AvailablePlatforms = v 1052 return s 1053} 1054 1055// SetBundleId sets the BundleId field's value. 1056func (s *BundleDetails) SetBundleId(v string) *BundleDetails { 1057 s.BundleId = &v 1058 return s 1059} 1060 1061// SetDescription sets the Description field's value. 1062func (s *BundleDetails) SetDescription(v string) *BundleDetails { 1063 s.Description = &v 1064 return s 1065} 1066 1067// SetIconUrl sets the IconUrl field's value. 1068func (s *BundleDetails) SetIconUrl(v string) *BundleDetails { 1069 s.IconUrl = &v 1070 return s 1071} 1072 1073// SetTitle sets the Title field's value. 1074func (s *BundleDetails) SetTitle(v string) *BundleDetails { 1075 s.Title = &v 1076 return s 1077} 1078 1079// SetVersion sets the Version field's value. 1080func (s *BundleDetails) SetVersion(v string) *BundleDetails { 1081 s.Version = &v 1082 return s 1083} 1084 1085// Request structure used to request a project be created. 1086// See also, https://docs.aws.amazon.com/goto/WebAPI/mobile-2017-07-01/CreateProjectRequest 1087type CreateProjectInput struct { 1088 _ struct{} `type:"structure" payload:"Contents"` 1089 1090 // ZIP or YAML file which contains configuration settings to be used when creating 1091 // the project. This may be the contents of the file downloaded from the URL 1092 // provided in an export project operation. 1093 Contents []byte `locationName:"contents" type:"blob"` 1094 1095 // Name of the project. 1096 Name *string `location:"querystring" locationName:"name" type:"string"` 1097 1098 // Default region where project resources should be created. 1099 Region *string `location:"querystring" locationName:"region" type:"string"` 1100 1101 // Unique identifier for an exported snapshot of project configuration. This 1102 // snapshot identifier is included in the share URL when a project is exported. 1103 SnapshotId *string `location:"querystring" locationName:"snapshotId" type:"string"` 1104} 1105 1106// String returns the string representation 1107func (s CreateProjectInput) String() string { 1108 return awsutil.Prettify(s) 1109} 1110 1111// GoString returns the string representation 1112func (s CreateProjectInput) GoString() string { 1113 return s.String() 1114} 1115 1116// SetContents sets the Contents field's value. 1117func (s *CreateProjectInput) SetContents(v []byte) *CreateProjectInput { 1118 s.Contents = v 1119 return s 1120} 1121 1122// SetName sets the Name field's value. 1123func (s *CreateProjectInput) SetName(v string) *CreateProjectInput { 1124 s.Name = &v 1125 return s 1126} 1127 1128// SetRegion sets the Region field's value. 1129func (s *CreateProjectInput) SetRegion(v string) *CreateProjectInput { 1130 s.Region = &v 1131 return s 1132} 1133 1134// SetSnapshotId sets the SnapshotId field's value. 1135func (s *CreateProjectInput) SetSnapshotId(v string) *CreateProjectInput { 1136 s.SnapshotId = &v 1137 return s 1138} 1139 1140// Result structure used in response to a request to create a project. 1141// See also, https://docs.aws.amazon.com/goto/WebAPI/mobile-2017-07-01/CreateProjectResult 1142type CreateProjectOutput struct { 1143 _ struct{} `type:"structure"` 1144 1145 // Detailed information about the created AWS Mobile Hub project. 1146 Details *ProjectDetails `locationName:"details" type:"structure"` 1147} 1148 1149// String returns the string representation 1150func (s CreateProjectOutput) String() string { 1151 return awsutil.Prettify(s) 1152} 1153 1154// GoString returns the string representation 1155func (s CreateProjectOutput) GoString() string { 1156 return s.String() 1157} 1158 1159// SetDetails sets the Details field's value. 1160func (s *CreateProjectOutput) SetDetails(v *ProjectDetails) *CreateProjectOutput { 1161 s.Details = v 1162 return s 1163} 1164 1165// Request structure used to request a project be deleted. 1166// See also, https://docs.aws.amazon.com/goto/WebAPI/mobile-2017-07-01/DeleteProjectRequest 1167type DeleteProjectInput struct { 1168 _ struct{} `type:"structure"` 1169 1170 // Unique project identifier. 1171 // 1172 // ProjectId is a required field 1173 ProjectId *string `location:"uri" locationName:"projectId" type:"string" required:"true"` 1174} 1175 1176// String returns the string representation 1177func (s DeleteProjectInput) String() string { 1178 return awsutil.Prettify(s) 1179} 1180 1181// GoString returns the string representation 1182func (s DeleteProjectInput) GoString() string { 1183 return s.String() 1184} 1185 1186// Validate inspects the fields of the type to determine if they are valid. 1187func (s *DeleteProjectInput) Validate() error { 1188 invalidParams := request.ErrInvalidParams{Context: "DeleteProjectInput"} 1189 if s.ProjectId == nil { 1190 invalidParams.Add(request.NewErrParamRequired("ProjectId")) 1191 } 1192 1193 if invalidParams.Len() > 0 { 1194 return invalidParams 1195 } 1196 return nil 1197} 1198 1199// SetProjectId sets the ProjectId field's value. 1200func (s *DeleteProjectInput) SetProjectId(v string) *DeleteProjectInput { 1201 s.ProjectId = &v 1202 return s 1203} 1204 1205// Result structure used in response to request to delete a project. 1206// See also, https://docs.aws.amazon.com/goto/WebAPI/mobile-2017-07-01/DeleteProjectResult 1207type DeleteProjectOutput struct { 1208 _ struct{} `type:"structure"` 1209 1210 // Resources which were deleted. 1211 DeletedResources []*Resource `locationName:"deletedResources" type:"list"` 1212 1213 // Resources which were not deleted, due to a risk of losing potentially important 1214 // data or files. 1215 OrphanedResources []*Resource `locationName:"orphanedResources" type:"list"` 1216} 1217 1218// String returns the string representation 1219func (s DeleteProjectOutput) String() string { 1220 return awsutil.Prettify(s) 1221} 1222 1223// GoString returns the string representation 1224func (s DeleteProjectOutput) GoString() string { 1225 return s.String() 1226} 1227 1228// SetDeletedResources sets the DeletedResources field's value. 1229func (s *DeleteProjectOutput) SetDeletedResources(v []*Resource) *DeleteProjectOutput { 1230 s.DeletedResources = v 1231 return s 1232} 1233 1234// SetOrphanedResources sets the OrphanedResources field's value. 1235func (s *DeleteProjectOutput) SetOrphanedResources(v []*Resource) *DeleteProjectOutput { 1236 s.OrphanedResources = v 1237 return s 1238} 1239 1240// Request structure to request the details of a specific bundle. 1241// See also, https://docs.aws.amazon.com/goto/WebAPI/mobile-2017-07-01/DescribeBundleRequest 1242type DescribeBundleInput struct { 1243 _ struct{} `type:"structure"` 1244 1245 // Unique bundle identifier. 1246 // 1247 // BundleId is a required field 1248 BundleId *string `location:"uri" locationName:"bundleId" type:"string" required:"true"` 1249} 1250 1251// String returns the string representation 1252func (s DescribeBundleInput) String() string { 1253 return awsutil.Prettify(s) 1254} 1255 1256// GoString returns the string representation 1257func (s DescribeBundleInput) GoString() string { 1258 return s.String() 1259} 1260 1261// Validate inspects the fields of the type to determine if they are valid. 1262func (s *DescribeBundleInput) Validate() error { 1263 invalidParams := request.ErrInvalidParams{Context: "DescribeBundleInput"} 1264 if s.BundleId == nil { 1265 invalidParams.Add(request.NewErrParamRequired("BundleId")) 1266 } 1267 1268 if invalidParams.Len() > 0 { 1269 return invalidParams 1270 } 1271 return nil 1272} 1273 1274// SetBundleId sets the BundleId field's value. 1275func (s *DescribeBundleInput) SetBundleId(v string) *DescribeBundleInput { 1276 s.BundleId = &v 1277 return s 1278} 1279 1280// Result structure contains the details of the bundle. 1281// See also, https://docs.aws.amazon.com/goto/WebAPI/mobile-2017-07-01/DescribeBundleResult 1282type DescribeBundleOutput struct { 1283 _ struct{} `type:"structure"` 1284 1285 // The details of the bundle. 1286 Details *BundleDetails `locationName:"details" type:"structure"` 1287} 1288 1289// String returns the string representation 1290func (s DescribeBundleOutput) String() string { 1291 return awsutil.Prettify(s) 1292} 1293 1294// GoString returns the string representation 1295func (s DescribeBundleOutput) GoString() string { 1296 return s.String() 1297} 1298 1299// SetDetails sets the Details field's value. 1300func (s *DescribeBundleOutput) SetDetails(v *BundleDetails) *DescribeBundleOutput { 1301 s.Details = v 1302 return s 1303} 1304 1305// Request structure used to request details about a project. 1306// See also, https://docs.aws.amazon.com/goto/WebAPI/mobile-2017-07-01/DescribeProjectRequest 1307type DescribeProjectInput struct { 1308 _ struct{} `type:"structure"` 1309 1310 // Unique project identifier. 1311 // 1312 // ProjectId is a required field 1313 ProjectId *string `location:"querystring" locationName:"projectId" type:"string" required:"true"` 1314 1315 // If set to true, causes AWS Mobile Hub to synchronize information from other 1316 // services, e.g., update state of AWS CloudFormation stacks in the AWS Mobile 1317 // Hub project. 1318 SyncFromResources *bool `location:"querystring" locationName:"syncFromResources" type:"boolean"` 1319} 1320 1321// String returns the string representation 1322func (s DescribeProjectInput) String() string { 1323 return awsutil.Prettify(s) 1324} 1325 1326// GoString returns the string representation 1327func (s DescribeProjectInput) GoString() string { 1328 return s.String() 1329} 1330 1331// Validate inspects the fields of the type to determine if they are valid. 1332func (s *DescribeProjectInput) Validate() error { 1333 invalidParams := request.ErrInvalidParams{Context: "DescribeProjectInput"} 1334 if s.ProjectId == nil { 1335 invalidParams.Add(request.NewErrParamRequired("ProjectId")) 1336 } 1337 1338 if invalidParams.Len() > 0 { 1339 return invalidParams 1340 } 1341 return nil 1342} 1343 1344// SetProjectId sets the ProjectId field's value. 1345func (s *DescribeProjectInput) SetProjectId(v string) *DescribeProjectInput { 1346 s.ProjectId = &v 1347 return s 1348} 1349 1350// SetSyncFromResources sets the SyncFromResources field's value. 1351func (s *DescribeProjectInput) SetSyncFromResources(v bool) *DescribeProjectInput { 1352 s.SyncFromResources = &v 1353 return s 1354} 1355 1356// Result structure used for requests of project details. 1357// See also, https://docs.aws.amazon.com/goto/WebAPI/mobile-2017-07-01/DescribeProjectResult 1358type DescribeProjectOutput struct { 1359 _ struct{} `type:"structure"` 1360 1361 // Detailed information about an AWS Mobile Hub project. 1362 Details *ProjectDetails `locationName:"details" type:"structure"` 1363} 1364 1365// String returns the string representation 1366func (s DescribeProjectOutput) String() string { 1367 return awsutil.Prettify(s) 1368} 1369 1370// GoString returns the string representation 1371func (s DescribeProjectOutput) GoString() string { 1372 return s.String() 1373} 1374 1375// SetDetails sets the Details field's value. 1376func (s *DescribeProjectOutput) SetDetails(v *ProjectDetails) *DescribeProjectOutput { 1377 s.Details = v 1378 return s 1379} 1380 1381// Request structure used to request generation of custom SDK and tool packages 1382// required to integrate mobile web or app clients with backed AWS resources. 1383// See also, https://docs.aws.amazon.com/goto/WebAPI/mobile-2017-07-01/ExportBundleRequest 1384type ExportBundleInput struct { 1385 _ struct{} `type:"structure"` 1386 1387 // Unique bundle identifier. 1388 // 1389 // BundleId is a required field 1390 BundleId *string `location:"uri" locationName:"bundleId" type:"string" required:"true"` 1391 1392 // Developer desktop or target application platform. 1393 Platform *string `location:"querystring" locationName:"platform" type:"string" enum:"Platform"` 1394 1395 // Unique project identifier. 1396 ProjectId *string `location:"querystring" locationName:"projectId" type:"string"` 1397} 1398 1399// String returns the string representation 1400func (s ExportBundleInput) String() string { 1401 return awsutil.Prettify(s) 1402} 1403 1404// GoString returns the string representation 1405func (s ExportBundleInput) GoString() string { 1406 return s.String() 1407} 1408 1409// Validate inspects the fields of the type to determine if they are valid. 1410func (s *ExportBundleInput) Validate() error { 1411 invalidParams := request.ErrInvalidParams{Context: "ExportBundleInput"} 1412 if s.BundleId == nil { 1413 invalidParams.Add(request.NewErrParamRequired("BundleId")) 1414 } 1415 1416 if invalidParams.Len() > 0 { 1417 return invalidParams 1418 } 1419 return nil 1420} 1421 1422// SetBundleId sets the BundleId field's value. 1423func (s *ExportBundleInput) SetBundleId(v string) *ExportBundleInput { 1424 s.BundleId = &v 1425 return s 1426} 1427 1428// SetPlatform sets the Platform field's value. 1429func (s *ExportBundleInput) SetPlatform(v string) *ExportBundleInput { 1430 s.Platform = &v 1431 return s 1432} 1433 1434// SetProjectId sets the ProjectId field's value. 1435func (s *ExportBundleInput) SetProjectId(v string) *ExportBundleInput { 1436 s.ProjectId = &v 1437 return s 1438} 1439 1440// Result structure which contains link to download custom-generated SDK and 1441// tool packages used to integrate mobile web or app clients with backed AWS 1442// resources. 1443// See also, https://docs.aws.amazon.com/goto/WebAPI/mobile-2017-07-01/ExportBundleResult 1444type ExportBundleOutput struct { 1445 _ struct{} `type:"structure"` 1446 1447 // URL which contains the custom-generated SDK and tool packages used to integrate 1448 // the client mobile app or web app with the AWS resources created by the AWS 1449 // Mobile Hub project. 1450 DownloadUrl *string `locationName:"downloadUrl" type:"string"` 1451} 1452 1453// String returns the string representation 1454func (s ExportBundleOutput) String() string { 1455 return awsutil.Prettify(s) 1456} 1457 1458// GoString returns the string representation 1459func (s ExportBundleOutput) GoString() string { 1460 return s.String() 1461} 1462 1463// SetDownloadUrl sets the DownloadUrl field's value. 1464func (s *ExportBundleOutput) SetDownloadUrl(v string) *ExportBundleOutput { 1465 s.DownloadUrl = &v 1466 return s 1467} 1468 1469// Request structure used in requests to export project configuration details. 1470// See also, https://docs.aws.amazon.com/goto/WebAPI/mobile-2017-07-01/ExportProjectRequest 1471type ExportProjectInput struct { 1472 _ struct{} `type:"structure"` 1473 1474 // Unique project identifier. 1475 // 1476 // ProjectId is a required field 1477 ProjectId *string `location:"uri" locationName:"projectId" type:"string" required:"true"` 1478} 1479 1480// String returns the string representation 1481func (s ExportProjectInput) String() string { 1482 return awsutil.Prettify(s) 1483} 1484 1485// GoString returns the string representation 1486func (s ExportProjectInput) GoString() string { 1487 return s.String() 1488} 1489 1490// Validate inspects the fields of the type to determine if they are valid. 1491func (s *ExportProjectInput) Validate() error { 1492 invalidParams := request.ErrInvalidParams{Context: "ExportProjectInput"} 1493 if s.ProjectId == nil { 1494 invalidParams.Add(request.NewErrParamRequired("ProjectId")) 1495 } 1496 1497 if invalidParams.Len() > 0 { 1498 return invalidParams 1499 } 1500 return nil 1501} 1502 1503// SetProjectId sets the ProjectId field's value. 1504func (s *ExportProjectInput) SetProjectId(v string) *ExportProjectInput { 1505 s.ProjectId = &v 1506 return s 1507} 1508 1509// Result structure used for requests to export project configuration details. 1510// See also, https://docs.aws.amazon.com/goto/WebAPI/mobile-2017-07-01/ExportProjectResult 1511type ExportProjectOutput struct { 1512 _ struct{} `type:"structure"` 1513 1514 // URL which can be used to download the exported project configuation file(s). 1515 DownloadUrl *string `locationName:"downloadUrl" type:"string"` 1516 1517 // URL which can be shared to allow other AWS users to create their own project 1518 // in AWS Mobile Hub with the same configuration as the specified project. This 1519 // URL pertains to a snapshot in time of the project configuration that is created 1520 // when this API is called. If you want to share additional changes to your 1521 // project configuration, then you will need to create and share a new snapshot 1522 // by calling this method again. 1523 ShareUrl *string `locationName:"shareUrl" type:"string"` 1524 1525 // Unique identifier for the exported snapshot of the project configuration. 1526 // This snapshot identifier is included in the share URL. 1527 SnapshotId *string `locationName:"snapshotId" type:"string"` 1528} 1529 1530// String returns the string representation 1531func (s ExportProjectOutput) String() string { 1532 return awsutil.Prettify(s) 1533} 1534 1535// GoString returns the string representation 1536func (s ExportProjectOutput) GoString() string { 1537 return s.String() 1538} 1539 1540// SetDownloadUrl sets the DownloadUrl field's value. 1541func (s *ExportProjectOutput) SetDownloadUrl(v string) *ExportProjectOutput { 1542 s.DownloadUrl = &v 1543 return s 1544} 1545 1546// SetShareUrl sets the ShareUrl field's value. 1547func (s *ExportProjectOutput) SetShareUrl(v string) *ExportProjectOutput { 1548 s.ShareUrl = &v 1549 return s 1550} 1551 1552// SetSnapshotId sets the SnapshotId field's value. 1553func (s *ExportProjectOutput) SetSnapshotId(v string) *ExportProjectOutput { 1554 s.SnapshotId = &v 1555 return s 1556} 1557 1558// Request structure to request all available bundles. 1559// See also, https://docs.aws.amazon.com/goto/WebAPI/mobile-2017-07-01/ListBundlesRequest 1560type ListBundlesInput struct { 1561 _ struct{} `type:"structure"` 1562 1563 // Maximum number of records to list in a single response. 1564 MaxResults *int64 `location:"querystring" locationName:"maxResults" type:"integer"` 1565 1566 // Pagination token. Set to null to start listing bundles from start. If non-null 1567 // pagination token is returned in a result, then pass its value in here in 1568 // another request to list more bundles. 1569 NextToken *string `location:"querystring" locationName:"nextToken" type:"string"` 1570} 1571 1572// String returns the string representation 1573func (s ListBundlesInput) String() string { 1574 return awsutil.Prettify(s) 1575} 1576 1577// GoString returns the string representation 1578func (s ListBundlesInput) GoString() string { 1579 return s.String() 1580} 1581 1582// SetMaxResults sets the MaxResults field's value. 1583func (s *ListBundlesInput) SetMaxResults(v int64) *ListBundlesInput { 1584 s.MaxResults = &v 1585 return s 1586} 1587 1588// SetNextToken sets the NextToken field's value. 1589func (s *ListBundlesInput) SetNextToken(v string) *ListBundlesInput { 1590 s.NextToken = &v 1591 return s 1592} 1593 1594// Result structure contains a list of all available bundles with details. 1595// See also, https://docs.aws.amazon.com/goto/WebAPI/mobile-2017-07-01/ListBundlesResult 1596type ListBundlesOutput struct { 1597 _ struct{} `type:"structure"` 1598 1599 // A list of bundles. 1600 BundleList []*BundleDetails `locationName:"bundleList" type:"list"` 1601 1602 // Pagination token. If non-null pagination token is returned in a result, then 1603 // pass its value in another request to fetch more entries. 1604 NextToken *string `locationName:"nextToken" type:"string"` 1605} 1606 1607// String returns the string representation 1608func (s ListBundlesOutput) String() string { 1609 return awsutil.Prettify(s) 1610} 1611 1612// GoString returns the string representation 1613func (s ListBundlesOutput) GoString() string { 1614 return s.String() 1615} 1616 1617// SetBundleList sets the BundleList field's value. 1618func (s *ListBundlesOutput) SetBundleList(v []*BundleDetails) *ListBundlesOutput { 1619 s.BundleList = v 1620 return s 1621} 1622 1623// SetNextToken sets the NextToken field's value. 1624func (s *ListBundlesOutput) SetNextToken(v string) *ListBundlesOutput { 1625 s.NextToken = &v 1626 return s 1627} 1628 1629// Request structure used to request projects list in AWS Mobile Hub. 1630// See also, https://docs.aws.amazon.com/goto/WebAPI/mobile-2017-07-01/ListProjectsRequest 1631type ListProjectsInput struct { 1632 _ struct{} `type:"structure"` 1633 1634 // Maximum number of records to list in a single response. 1635 MaxResults *int64 `location:"querystring" locationName:"maxResults" type:"integer"` 1636 1637 // Pagination token. Set to null to start listing projects from start. If non-null 1638 // pagination token is returned in a result, then pass its value in here in 1639 // another request to list more projects. 1640 NextToken *string `location:"querystring" locationName:"nextToken" type:"string"` 1641} 1642 1643// String returns the string representation 1644func (s ListProjectsInput) String() string { 1645 return awsutil.Prettify(s) 1646} 1647 1648// GoString returns the string representation 1649func (s ListProjectsInput) GoString() string { 1650 return s.String() 1651} 1652 1653// SetMaxResults sets the MaxResults field's value. 1654func (s *ListProjectsInput) SetMaxResults(v int64) *ListProjectsInput { 1655 s.MaxResults = &v 1656 return s 1657} 1658 1659// SetNextToken sets the NextToken field's value. 1660func (s *ListProjectsInput) SetNextToken(v string) *ListProjectsInput { 1661 s.NextToken = &v 1662 return s 1663} 1664 1665// Result structure used for requests to list projects in AWS Mobile Hub. 1666// See also, https://docs.aws.amazon.com/goto/WebAPI/mobile-2017-07-01/ListProjectsResult 1667type ListProjectsOutput struct { 1668 _ struct{} `type:"structure"` 1669 1670 // Pagination token. Set to null to start listing records from start. If non-null 1671 // pagination token is returned in a result, then pass its value in here in 1672 // another request to list more entries. 1673 NextToken *string `locationName:"nextToken" type:"string"` 1674 1675 // List of projects. 1676 Projects []*ProjectSummary `locationName:"projects" type:"list"` 1677} 1678 1679// String returns the string representation 1680func (s ListProjectsOutput) String() string { 1681 return awsutil.Prettify(s) 1682} 1683 1684// GoString returns the string representation 1685func (s ListProjectsOutput) GoString() string { 1686 return s.String() 1687} 1688 1689// SetNextToken sets the NextToken field's value. 1690func (s *ListProjectsOutput) SetNextToken(v string) *ListProjectsOutput { 1691 s.NextToken = &v 1692 return s 1693} 1694 1695// SetProjects sets the Projects field's value. 1696func (s *ListProjectsOutput) SetProjects(v []*ProjectSummary) *ListProjectsOutput { 1697 s.Projects = v 1698 return s 1699} 1700 1701// Detailed information about an AWS Mobile Hub project. 1702// See also, https://docs.aws.amazon.com/goto/WebAPI/mobile-2017-07-01/ProjectDetails 1703type ProjectDetails struct { 1704 _ struct{} `type:"structure"` 1705 1706 // Website URL for this project in the AWS Mobile Hub console. 1707 ConsoleUrl *string `locationName:"consoleUrl" type:"string"` 1708 1709 // Date the project was created. 1710 CreatedDate *time.Time `locationName:"createdDate" type:"timestamp" timestampFormat:"unix"` 1711 1712 // Date of the last modification of the project. 1713 LastUpdatedDate *time.Time `locationName:"lastUpdatedDate" type:"timestamp" timestampFormat:"unix"` 1714 1715 // Name of the project. 1716 Name *string `locationName:"name" type:"string"` 1717 1718 // Unique project identifier. 1719 ProjectId *string `locationName:"projectId" type:"string"` 1720 1721 // Default region to use for AWS resource creation in the AWS Mobile Hub project. 1722 Region *string `locationName:"region" type:"string"` 1723 1724 // List of AWS resources associated with a project. 1725 Resources []*Resource `locationName:"resources" type:"list"` 1726 1727 // Synchronization state for a project. 1728 State *string `locationName:"state" type:"string" enum:"ProjectState"` 1729} 1730 1731// String returns the string representation 1732func (s ProjectDetails) String() string { 1733 return awsutil.Prettify(s) 1734} 1735 1736// GoString returns the string representation 1737func (s ProjectDetails) GoString() string { 1738 return s.String() 1739} 1740 1741// SetConsoleUrl sets the ConsoleUrl field's value. 1742func (s *ProjectDetails) SetConsoleUrl(v string) *ProjectDetails { 1743 s.ConsoleUrl = &v 1744 return s 1745} 1746 1747// SetCreatedDate sets the CreatedDate field's value. 1748func (s *ProjectDetails) SetCreatedDate(v time.Time) *ProjectDetails { 1749 s.CreatedDate = &v 1750 return s 1751} 1752 1753// SetLastUpdatedDate sets the LastUpdatedDate field's value. 1754func (s *ProjectDetails) SetLastUpdatedDate(v time.Time) *ProjectDetails { 1755 s.LastUpdatedDate = &v 1756 return s 1757} 1758 1759// SetName sets the Name field's value. 1760func (s *ProjectDetails) SetName(v string) *ProjectDetails { 1761 s.Name = &v 1762 return s 1763} 1764 1765// SetProjectId sets the ProjectId field's value. 1766func (s *ProjectDetails) SetProjectId(v string) *ProjectDetails { 1767 s.ProjectId = &v 1768 return s 1769} 1770 1771// SetRegion sets the Region field's value. 1772func (s *ProjectDetails) SetRegion(v string) *ProjectDetails { 1773 s.Region = &v 1774 return s 1775} 1776 1777// SetResources sets the Resources field's value. 1778func (s *ProjectDetails) SetResources(v []*Resource) *ProjectDetails { 1779 s.Resources = v 1780 return s 1781} 1782 1783// SetState sets the State field's value. 1784func (s *ProjectDetails) SetState(v string) *ProjectDetails { 1785 s.State = &v 1786 return s 1787} 1788 1789// Summary information about an AWS Mobile Hub project. 1790// See also, https://docs.aws.amazon.com/goto/WebAPI/mobile-2017-07-01/ProjectSummary 1791type ProjectSummary struct { 1792 _ struct{} `type:"structure"` 1793 1794 // Name of the project. 1795 Name *string `locationName:"name" type:"string"` 1796 1797 // Unique project identifier. 1798 ProjectId *string `locationName:"projectId" type:"string"` 1799} 1800 1801// String returns the string representation 1802func (s ProjectSummary) String() string { 1803 return awsutil.Prettify(s) 1804} 1805 1806// GoString returns the string representation 1807func (s ProjectSummary) GoString() string { 1808 return s.String() 1809} 1810 1811// SetName sets the Name field's value. 1812func (s *ProjectSummary) SetName(v string) *ProjectSummary { 1813 s.Name = &v 1814 return s 1815} 1816 1817// SetProjectId sets the ProjectId field's value. 1818func (s *ProjectSummary) SetProjectId(v string) *ProjectSummary { 1819 s.ProjectId = &v 1820 return s 1821} 1822 1823// Information about an instance of an AWS resource associated with a project. 1824// See also, https://docs.aws.amazon.com/goto/WebAPI/mobile-2017-07-01/Resource 1825type Resource struct { 1826 _ struct{} `type:"structure"` 1827 1828 // AWS resource name which uniquely identifies the resource in AWS systems. 1829 Arn *string `locationName:"arn" type:"string"` 1830 1831 // Key-value attribute pairs. 1832 Attributes map[string]*string `locationName:"attributes" type:"map"` 1833 1834 // Identifies which feature in AWS Mobile Hub is associated with this AWS resource. 1835 Feature *string `locationName:"feature" type:"string"` 1836 1837 // Name of the AWS resource (e.g., for an Amazon S3 bucket this is the name 1838 // of the bucket). 1839 Name *string `locationName:"name" type:"string"` 1840 1841 // Simplified name for type of AWS resource (e.g., bucket is an Amazon S3 bucket). 1842 Type *string `locationName:"type" type:"string"` 1843} 1844 1845// String returns the string representation 1846func (s Resource) String() string { 1847 return awsutil.Prettify(s) 1848} 1849 1850// GoString returns the string representation 1851func (s Resource) GoString() string { 1852 return s.String() 1853} 1854 1855// SetArn sets the Arn field's value. 1856func (s *Resource) SetArn(v string) *Resource { 1857 s.Arn = &v 1858 return s 1859} 1860 1861// SetAttributes sets the Attributes field's value. 1862func (s *Resource) SetAttributes(v map[string]*string) *Resource { 1863 s.Attributes = v 1864 return s 1865} 1866 1867// SetFeature sets the Feature field's value. 1868func (s *Resource) SetFeature(v string) *Resource { 1869 s.Feature = &v 1870 return s 1871} 1872 1873// SetName sets the Name field's value. 1874func (s *Resource) SetName(v string) *Resource { 1875 s.Name = &v 1876 return s 1877} 1878 1879// SetType sets the Type field's value. 1880func (s *Resource) SetType(v string) *Resource { 1881 s.Type = &v 1882 return s 1883} 1884 1885// Request structure used for requests to update project configuration. 1886// See also, https://docs.aws.amazon.com/goto/WebAPI/mobile-2017-07-01/UpdateProjectRequest 1887type UpdateProjectInput struct { 1888 _ struct{} `type:"structure" payload:"Contents"` 1889 1890 // ZIP or YAML file which contains project configuration to be updated. This 1891 // should be the contents of the file downloaded from the URL provided in an 1892 // export project operation. 1893 Contents []byte `locationName:"contents" type:"blob"` 1894 1895 // Unique project identifier. 1896 // 1897 // ProjectId is a required field 1898 ProjectId *string `location:"querystring" locationName:"projectId" type:"string" required:"true"` 1899} 1900 1901// String returns the string representation 1902func (s UpdateProjectInput) String() string { 1903 return awsutil.Prettify(s) 1904} 1905 1906// GoString returns the string representation 1907func (s UpdateProjectInput) GoString() string { 1908 return s.String() 1909} 1910 1911// Validate inspects the fields of the type to determine if they are valid. 1912func (s *UpdateProjectInput) Validate() error { 1913 invalidParams := request.ErrInvalidParams{Context: "UpdateProjectInput"} 1914 if s.ProjectId == nil { 1915 invalidParams.Add(request.NewErrParamRequired("ProjectId")) 1916 } 1917 1918 if invalidParams.Len() > 0 { 1919 return invalidParams 1920 } 1921 return nil 1922} 1923 1924// SetContents sets the Contents field's value. 1925func (s *UpdateProjectInput) SetContents(v []byte) *UpdateProjectInput { 1926 s.Contents = v 1927 return s 1928} 1929 1930// SetProjectId sets the ProjectId field's value. 1931func (s *UpdateProjectInput) SetProjectId(v string) *UpdateProjectInput { 1932 s.ProjectId = &v 1933 return s 1934} 1935 1936// Result structure used for requests to updated project configuration. 1937// See also, https://docs.aws.amazon.com/goto/WebAPI/mobile-2017-07-01/UpdateProjectResult 1938type UpdateProjectOutput struct { 1939 _ struct{} `type:"structure"` 1940 1941 // Detailed information about the updated AWS Mobile Hub project. 1942 Details *ProjectDetails `locationName:"details" type:"structure"` 1943} 1944 1945// String returns the string representation 1946func (s UpdateProjectOutput) String() string { 1947 return awsutil.Prettify(s) 1948} 1949 1950// GoString returns the string representation 1951func (s UpdateProjectOutput) GoString() string { 1952 return s.String() 1953} 1954 1955// SetDetails sets the Details field's value. 1956func (s *UpdateProjectOutput) SetDetails(v *ProjectDetails) *UpdateProjectOutput { 1957 s.Details = v 1958 return s 1959} 1960 1961// Developer desktop or target mobile app or website platform. 1962const ( 1963 // PlatformOsx is a Platform enum value 1964 PlatformOsx = "OSX" 1965 1966 // PlatformWindows is a Platform enum value 1967 PlatformWindows = "WINDOWS" 1968 1969 // PlatformLinux is a Platform enum value 1970 PlatformLinux = "LINUX" 1971 1972 // PlatformObjc is a Platform enum value 1973 PlatformObjc = "OBJC" 1974 1975 // PlatformSwift is a Platform enum value 1976 PlatformSwift = "SWIFT" 1977 1978 // PlatformAndroid is a Platform enum value 1979 PlatformAndroid = "ANDROID" 1980 1981 // PlatformJavascript is a Platform enum value 1982 PlatformJavascript = "JAVASCRIPT" 1983) 1984 1985// Synchronization state for a project. 1986const ( 1987 // ProjectStateNormal is a ProjectState enum value 1988 ProjectStateNormal = "NORMAL" 1989 1990 // ProjectStateSyncing is a ProjectState enum value 1991 ProjectStateSyncing = "SYNCING" 1992 1993 // ProjectStateImporting is a ProjectState enum value 1994 ProjectStateImporting = "IMPORTING" 1995) 1996