1// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT. 2 3package frauddetector 4 5import ( 6 "fmt" 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 "github.com/aws/aws-sdk-go/private/protocol" 12 "github.com/aws/aws-sdk-go/private/protocol/jsonrpc" 13) 14 15const opBatchCreateVariable = "BatchCreateVariable" 16 17// BatchCreateVariableRequest generates a "aws/request.Request" representing the 18// client's request for the BatchCreateVariable operation. The "output" return 19// value will be populated with the request's response once the request completes 20// successfully. 21// 22// Use "Send" method on the returned Request to send the API call to the service. 23// the "output" return value is not valid until after Send returns without error. 24// 25// See BatchCreateVariable for more information on using the BatchCreateVariable 26// API call, and error handling. 27// 28// This method is useful when you want to inject custom logic or configuration 29// into the SDK's request lifecycle. Such as custom headers, or retry logic. 30// 31// 32// // Example sending a request using the BatchCreateVariableRequest method. 33// req, resp := client.BatchCreateVariableRequest(params) 34// 35// err := req.Send() 36// if err == nil { // resp is now filled 37// fmt.Println(resp) 38// } 39// 40// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/BatchCreateVariable 41func (c *FraudDetector) BatchCreateVariableRequest(input *BatchCreateVariableInput) (req *request.Request, output *BatchCreateVariableOutput) { 42 op := &request.Operation{ 43 Name: opBatchCreateVariable, 44 HTTPMethod: "POST", 45 HTTPPath: "/", 46 } 47 48 if input == nil { 49 input = &BatchCreateVariableInput{} 50 } 51 52 output = &BatchCreateVariableOutput{} 53 req = c.newRequest(op, input, output) 54 return 55} 56 57// BatchCreateVariable API operation for Amazon Fraud Detector. 58// 59// Creates a batch of variables. 60// 61// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 62// with awserr.Error's Code and Message methods to get detailed information about 63// the error. 64// 65// See the AWS API reference guide for Amazon Fraud Detector's 66// API operation BatchCreateVariable for usage and error information. 67// 68// Returned Error Types: 69// * ValidationException 70// An exception indicating a specified value is not allowed. 71// 72// * InternalServerException 73// An exception indicating an internal server error. 74// 75// * ThrottlingException 76// An exception indicating a throttling error. 77// 78// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/BatchCreateVariable 79func (c *FraudDetector) BatchCreateVariable(input *BatchCreateVariableInput) (*BatchCreateVariableOutput, error) { 80 req, out := c.BatchCreateVariableRequest(input) 81 return out, req.Send() 82} 83 84// BatchCreateVariableWithContext is the same as BatchCreateVariable with the addition of 85// the ability to pass a context and additional request options. 86// 87// See BatchCreateVariable for details on how to use this API operation. 88// 89// The context must be non-nil and will be used for request cancellation. If 90// the context is nil a panic will occur. In the future the SDK may create 91// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 92// for more information on using Contexts. 93func (c *FraudDetector) BatchCreateVariableWithContext(ctx aws.Context, input *BatchCreateVariableInput, opts ...request.Option) (*BatchCreateVariableOutput, error) { 94 req, out := c.BatchCreateVariableRequest(input) 95 req.SetContext(ctx) 96 req.ApplyOptions(opts...) 97 return out, req.Send() 98} 99 100const opBatchGetVariable = "BatchGetVariable" 101 102// BatchGetVariableRequest generates a "aws/request.Request" representing the 103// client's request for the BatchGetVariable operation. The "output" return 104// value will be populated with the request's response once the request completes 105// successfully. 106// 107// Use "Send" method on the returned Request to send the API call to the service. 108// the "output" return value is not valid until after Send returns without error. 109// 110// See BatchGetVariable for more information on using the BatchGetVariable 111// API call, and error handling. 112// 113// This method is useful when you want to inject custom logic or configuration 114// into the SDK's request lifecycle. Such as custom headers, or retry logic. 115// 116// 117// // Example sending a request using the BatchGetVariableRequest method. 118// req, resp := client.BatchGetVariableRequest(params) 119// 120// err := req.Send() 121// if err == nil { // resp is now filled 122// fmt.Println(resp) 123// } 124// 125// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/BatchGetVariable 126func (c *FraudDetector) BatchGetVariableRequest(input *BatchGetVariableInput) (req *request.Request, output *BatchGetVariableOutput) { 127 op := &request.Operation{ 128 Name: opBatchGetVariable, 129 HTTPMethod: "POST", 130 HTTPPath: "/", 131 } 132 133 if input == nil { 134 input = &BatchGetVariableInput{} 135 } 136 137 output = &BatchGetVariableOutput{} 138 req = c.newRequest(op, input, output) 139 return 140} 141 142// BatchGetVariable API operation for Amazon Fraud Detector. 143// 144// Gets a batch of variables. 145// 146// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 147// with awserr.Error's Code and Message methods to get detailed information about 148// the error. 149// 150// See the AWS API reference guide for Amazon Fraud Detector's 151// API operation BatchGetVariable for usage and error information. 152// 153// Returned Error Types: 154// * ValidationException 155// An exception indicating a specified value is not allowed. 156// 157// * InternalServerException 158// An exception indicating an internal server error. 159// 160// * ThrottlingException 161// An exception indicating a throttling error. 162// 163// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/BatchGetVariable 164func (c *FraudDetector) BatchGetVariable(input *BatchGetVariableInput) (*BatchGetVariableOutput, error) { 165 req, out := c.BatchGetVariableRequest(input) 166 return out, req.Send() 167} 168 169// BatchGetVariableWithContext is the same as BatchGetVariable with the addition of 170// the ability to pass a context and additional request options. 171// 172// See BatchGetVariable for details on how to use this API operation. 173// 174// The context must be non-nil and will be used for request cancellation. If 175// the context is nil a panic will occur. In the future the SDK may create 176// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 177// for more information on using Contexts. 178func (c *FraudDetector) BatchGetVariableWithContext(ctx aws.Context, input *BatchGetVariableInput, opts ...request.Option) (*BatchGetVariableOutput, error) { 179 req, out := c.BatchGetVariableRequest(input) 180 req.SetContext(ctx) 181 req.ApplyOptions(opts...) 182 return out, req.Send() 183} 184 185const opCreateDetectorVersion = "CreateDetectorVersion" 186 187// CreateDetectorVersionRequest generates a "aws/request.Request" representing the 188// client's request for the CreateDetectorVersion operation. The "output" return 189// value will be populated with the request's response once the request completes 190// successfully. 191// 192// Use "Send" method on the returned Request to send the API call to the service. 193// the "output" return value is not valid until after Send returns without error. 194// 195// See CreateDetectorVersion for more information on using the CreateDetectorVersion 196// API call, and error handling. 197// 198// This method is useful when you want to inject custom logic or configuration 199// into the SDK's request lifecycle. Such as custom headers, or retry logic. 200// 201// 202// // Example sending a request using the CreateDetectorVersionRequest method. 203// req, resp := client.CreateDetectorVersionRequest(params) 204// 205// err := req.Send() 206// if err == nil { // resp is now filled 207// fmt.Println(resp) 208// } 209// 210// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/CreateDetectorVersion 211func (c *FraudDetector) CreateDetectorVersionRequest(input *CreateDetectorVersionInput) (req *request.Request, output *CreateDetectorVersionOutput) { 212 op := &request.Operation{ 213 Name: opCreateDetectorVersion, 214 HTTPMethod: "POST", 215 HTTPPath: "/", 216 } 217 218 if input == nil { 219 input = &CreateDetectorVersionInput{} 220 } 221 222 output = &CreateDetectorVersionOutput{} 223 req = c.newRequest(op, input, output) 224 return 225} 226 227// CreateDetectorVersion API operation for Amazon Fraud Detector. 228// 229// Creates a detector version. The detector version starts in a DRAFT status. 230// 231// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 232// with awserr.Error's Code and Message methods to get detailed information about 233// the error. 234// 235// See the AWS API reference guide for Amazon Fraud Detector's 236// API operation CreateDetectorVersion for usage and error information. 237// 238// Returned Error Types: 239// * ValidationException 240// An exception indicating a specified value is not allowed. 241// 242// * ResourceNotFoundException 243// An exception indicating the specified resource was not found. 244// 245// * InternalServerException 246// An exception indicating an internal server error. 247// 248// * ThrottlingException 249// An exception indicating a throttling error. 250// 251// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/CreateDetectorVersion 252func (c *FraudDetector) CreateDetectorVersion(input *CreateDetectorVersionInput) (*CreateDetectorVersionOutput, error) { 253 req, out := c.CreateDetectorVersionRequest(input) 254 return out, req.Send() 255} 256 257// CreateDetectorVersionWithContext is the same as CreateDetectorVersion with the addition of 258// the ability to pass a context and additional request options. 259// 260// See CreateDetectorVersion for details on how to use this API operation. 261// 262// The context must be non-nil and will be used for request cancellation. If 263// the context is nil a panic will occur. In the future the SDK may create 264// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 265// for more information on using Contexts. 266func (c *FraudDetector) CreateDetectorVersionWithContext(ctx aws.Context, input *CreateDetectorVersionInput, opts ...request.Option) (*CreateDetectorVersionOutput, error) { 267 req, out := c.CreateDetectorVersionRequest(input) 268 req.SetContext(ctx) 269 req.ApplyOptions(opts...) 270 return out, req.Send() 271} 272 273const opCreateModelVersion = "CreateModelVersion" 274 275// CreateModelVersionRequest generates a "aws/request.Request" representing the 276// client's request for the CreateModelVersion operation. The "output" return 277// value will be populated with the request's response once the request completes 278// successfully. 279// 280// Use "Send" method on the returned Request to send the API call to the service. 281// the "output" return value is not valid until after Send returns without error. 282// 283// See CreateModelVersion for more information on using the CreateModelVersion 284// API call, and error handling. 285// 286// This method is useful when you want to inject custom logic or configuration 287// into the SDK's request lifecycle. Such as custom headers, or retry logic. 288// 289// 290// // Example sending a request using the CreateModelVersionRequest method. 291// req, resp := client.CreateModelVersionRequest(params) 292// 293// err := req.Send() 294// if err == nil { // resp is now filled 295// fmt.Println(resp) 296// } 297// 298// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/CreateModelVersion 299func (c *FraudDetector) CreateModelVersionRequest(input *CreateModelVersionInput) (req *request.Request, output *CreateModelVersionOutput) { 300 op := &request.Operation{ 301 Name: opCreateModelVersion, 302 HTTPMethod: "POST", 303 HTTPPath: "/", 304 } 305 306 if input == nil { 307 input = &CreateModelVersionInput{} 308 } 309 310 output = &CreateModelVersionOutput{} 311 req = c.newRequest(op, input, output) 312 return 313} 314 315// CreateModelVersion API operation for Amazon Fraud Detector. 316// 317// Creates a version of the model using the specified model type. 318// 319// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 320// with awserr.Error's Code and Message methods to get detailed information about 321// the error. 322// 323// See the AWS API reference guide for Amazon Fraud Detector's 324// API operation CreateModelVersion for usage and error information. 325// 326// Returned Error Types: 327// * ValidationException 328// An exception indicating a specified value is not allowed. 329// 330// * ResourceNotFoundException 331// An exception indicating the specified resource was not found. 332// 333// * InternalServerException 334// An exception indicating an internal server error. 335// 336// * ThrottlingException 337// An exception indicating a throttling error. 338// 339// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/CreateModelVersion 340func (c *FraudDetector) CreateModelVersion(input *CreateModelVersionInput) (*CreateModelVersionOutput, error) { 341 req, out := c.CreateModelVersionRequest(input) 342 return out, req.Send() 343} 344 345// CreateModelVersionWithContext is the same as CreateModelVersion with the addition of 346// the ability to pass a context and additional request options. 347// 348// See CreateModelVersion for details on how to use this API operation. 349// 350// The context must be non-nil and will be used for request cancellation. If 351// the context is nil a panic will occur. In the future the SDK may create 352// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 353// for more information on using Contexts. 354func (c *FraudDetector) CreateModelVersionWithContext(ctx aws.Context, input *CreateModelVersionInput, opts ...request.Option) (*CreateModelVersionOutput, error) { 355 req, out := c.CreateModelVersionRequest(input) 356 req.SetContext(ctx) 357 req.ApplyOptions(opts...) 358 return out, req.Send() 359} 360 361const opCreateRule = "CreateRule" 362 363// CreateRuleRequest generates a "aws/request.Request" representing the 364// client's request for the CreateRule operation. The "output" return 365// value will be populated with the request's response once the request completes 366// successfully. 367// 368// Use "Send" method on the returned Request to send the API call to the service. 369// the "output" return value is not valid until after Send returns without error. 370// 371// See CreateRule for more information on using the CreateRule 372// API call, and error handling. 373// 374// This method is useful when you want to inject custom logic or configuration 375// into the SDK's request lifecycle. Such as custom headers, or retry logic. 376// 377// 378// // Example sending a request using the CreateRuleRequest method. 379// req, resp := client.CreateRuleRequest(params) 380// 381// err := req.Send() 382// if err == nil { // resp is now filled 383// fmt.Println(resp) 384// } 385// 386// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/CreateRule 387func (c *FraudDetector) CreateRuleRequest(input *CreateRuleInput) (req *request.Request, output *CreateRuleOutput) { 388 op := &request.Operation{ 389 Name: opCreateRule, 390 HTTPMethod: "POST", 391 HTTPPath: "/", 392 } 393 394 if input == nil { 395 input = &CreateRuleInput{} 396 } 397 398 output = &CreateRuleOutput{} 399 req = c.newRequest(op, input, output) 400 return 401} 402 403// CreateRule API operation for Amazon Fraud Detector. 404// 405// Creates a rule for use with the specified detector. 406// 407// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 408// with awserr.Error's Code and Message methods to get detailed information about 409// the error. 410// 411// See the AWS API reference guide for Amazon Fraud Detector's 412// API operation CreateRule for usage and error information. 413// 414// Returned Error Types: 415// * ValidationException 416// An exception indicating a specified value is not allowed. 417// 418// * InternalServerException 419// An exception indicating an internal server error. 420// 421// * ThrottlingException 422// An exception indicating a throttling error. 423// 424// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/CreateRule 425func (c *FraudDetector) CreateRule(input *CreateRuleInput) (*CreateRuleOutput, error) { 426 req, out := c.CreateRuleRequest(input) 427 return out, req.Send() 428} 429 430// CreateRuleWithContext is the same as CreateRule with the addition of 431// the ability to pass a context and additional request options. 432// 433// See CreateRule for details on how to use this API operation. 434// 435// The context must be non-nil and will be used for request cancellation. If 436// the context is nil a panic will occur. In the future the SDK may create 437// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 438// for more information on using Contexts. 439func (c *FraudDetector) CreateRuleWithContext(ctx aws.Context, input *CreateRuleInput, opts ...request.Option) (*CreateRuleOutput, error) { 440 req, out := c.CreateRuleRequest(input) 441 req.SetContext(ctx) 442 req.ApplyOptions(opts...) 443 return out, req.Send() 444} 445 446const opCreateVariable = "CreateVariable" 447 448// CreateVariableRequest generates a "aws/request.Request" representing the 449// client's request for the CreateVariable operation. The "output" return 450// value will be populated with the request's response once the request completes 451// successfully. 452// 453// Use "Send" method on the returned Request to send the API call to the service. 454// the "output" return value is not valid until after Send returns without error. 455// 456// See CreateVariable for more information on using the CreateVariable 457// API call, and error handling. 458// 459// This method is useful when you want to inject custom logic or configuration 460// into the SDK's request lifecycle. Such as custom headers, or retry logic. 461// 462// 463// // Example sending a request using the CreateVariableRequest method. 464// req, resp := client.CreateVariableRequest(params) 465// 466// err := req.Send() 467// if err == nil { // resp is now filled 468// fmt.Println(resp) 469// } 470// 471// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/CreateVariable 472func (c *FraudDetector) CreateVariableRequest(input *CreateVariableInput) (req *request.Request, output *CreateVariableOutput) { 473 op := &request.Operation{ 474 Name: opCreateVariable, 475 HTTPMethod: "POST", 476 HTTPPath: "/", 477 } 478 479 if input == nil { 480 input = &CreateVariableInput{} 481 } 482 483 output = &CreateVariableOutput{} 484 req = c.newRequest(op, input, output) 485 req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 486 return 487} 488 489// CreateVariable API operation for Amazon Fraud Detector. 490// 491// Creates a variable. 492// 493// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 494// with awserr.Error's Code and Message methods to get detailed information about 495// the error. 496// 497// See the AWS API reference guide for Amazon Fraud Detector's 498// API operation CreateVariable for usage and error information. 499// 500// Returned Error Types: 501// * ValidationException 502// An exception indicating a specified value is not allowed. 503// 504// * InternalServerException 505// An exception indicating an internal server error. 506// 507// * ThrottlingException 508// An exception indicating a throttling error. 509// 510// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/CreateVariable 511func (c *FraudDetector) CreateVariable(input *CreateVariableInput) (*CreateVariableOutput, error) { 512 req, out := c.CreateVariableRequest(input) 513 return out, req.Send() 514} 515 516// CreateVariableWithContext is the same as CreateVariable with the addition of 517// the ability to pass a context and additional request options. 518// 519// See CreateVariable for details on how to use this API operation. 520// 521// The context must be non-nil and will be used for request cancellation. If 522// the context is nil a panic will occur. In the future the SDK may create 523// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 524// for more information on using Contexts. 525func (c *FraudDetector) CreateVariableWithContext(ctx aws.Context, input *CreateVariableInput, opts ...request.Option) (*CreateVariableOutput, error) { 526 req, out := c.CreateVariableRequest(input) 527 req.SetContext(ctx) 528 req.ApplyOptions(opts...) 529 return out, req.Send() 530} 531 532const opDeleteDetector = "DeleteDetector" 533 534// DeleteDetectorRequest generates a "aws/request.Request" representing the 535// client's request for the DeleteDetector operation. The "output" return 536// value will be populated with the request's response once the request completes 537// successfully. 538// 539// Use "Send" method on the returned Request to send the API call to the service. 540// the "output" return value is not valid until after Send returns without error. 541// 542// See DeleteDetector for more information on using the DeleteDetector 543// API call, and error handling. 544// 545// This method is useful when you want to inject custom logic or configuration 546// into the SDK's request lifecycle. Such as custom headers, or retry logic. 547// 548// 549// // Example sending a request using the DeleteDetectorRequest method. 550// req, resp := client.DeleteDetectorRequest(params) 551// 552// err := req.Send() 553// if err == nil { // resp is now filled 554// fmt.Println(resp) 555// } 556// 557// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/DeleteDetector 558func (c *FraudDetector) DeleteDetectorRequest(input *DeleteDetectorInput) (req *request.Request, output *DeleteDetectorOutput) { 559 op := &request.Operation{ 560 Name: opDeleteDetector, 561 HTTPMethod: "POST", 562 HTTPPath: "/", 563 } 564 565 if input == nil { 566 input = &DeleteDetectorInput{} 567 } 568 569 output = &DeleteDetectorOutput{} 570 req = c.newRequest(op, input, output) 571 req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 572 return 573} 574 575// DeleteDetector API operation for Amazon Fraud Detector. 576// 577// Deletes the detector. Before deleting a detector, you must first delete all 578// detector versions and rule versions associated with the detector. 579// 580// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 581// with awserr.Error's Code and Message methods to get detailed information about 582// the error. 583// 584// See the AWS API reference guide for Amazon Fraud Detector's 585// API operation DeleteDetector for usage and error information. 586// 587// Returned Error Types: 588// * ConflictException 589// An exception indicating there was a conflict during a delete operation. The 590// following delete operations can cause a conflict exception: 591// 592// * DeleteDetector: A conflict exception will occur if the detector has 593// associated Rules or DetectorVersions. You can only delete a detector if 594// it has no Rules or DetectorVersions. 595// 596// * DeleteDetectorVersion: A conflict exception will occur if the DetectorVersion 597// status is ACTIVE. 598// 599// * DeleteRuleVersion: A conflict exception will occur if the RuleVersion 600// is in use by an associated ACTIVE or INACTIVE DetectorVersion. 601// 602// * ValidationException 603// An exception indicating a specified value is not allowed. 604// 605// * InternalServerException 606// An exception indicating an internal server error. 607// 608// * ThrottlingException 609// An exception indicating a throttling error. 610// 611// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/DeleteDetector 612func (c *FraudDetector) DeleteDetector(input *DeleteDetectorInput) (*DeleteDetectorOutput, error) { 613 req, out := c.DeleteDetectorRequest(input) 614 return out, req.Send() 615} 616 617// DeleteDetectorWithContext is the same as DeleteDetector with the addition of 618// the ability to pass a context and additional request options. 619// 620// See DeleteDetector for details on how to use this API operation. 621// 622// The context must be non-nil and will be used for request cancellation. If 623// the context is nil a panic will occur. In the future the SDK may create 624// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 625// for more information on using Contexts. 626func (c *FraudDetector) DeleteDetectorWithContext(ctx aws.Context, input *DeleteDetectorInput, opts ...request.Option) (*DeleteDetectorOutput, error) { 627 req, out := c.DeleteDetectorRequest(input) 628 req.SetContext(ctx) 629 req.ApplyOptions(opts...) 630 return out, req.Send() 631} 632 633const opDeleteDetectorVersion = "DeleteDetectorVersion" 634 635// DeleteDetectorVersionRequest generates a "aws/request.Request" representing the 636// client's request for the DeleteDetectorVersion operation. The "output" return 637// value will be populated with the request's response once the request completes 638// successfully. 639// 640// Use "Send" method on the returned Request to send the API call to the service. 641// the "output" return value is not valid until after Send returns without error. 642// 643// See DeleteDetectorVersion for more information on using the DeleteDetectorVersion 644// API call, and error handling. 645// 646// This method is useful when you want to inject custom logic or configuration 647// into the SDK's request lifecycle. Such as custom headers, or retry logic. 648// 649// 650// // Example sending a request using the DeleteDetectorVersionRequest method. 651// req, resp := client.DeleteDetectorVersionRequest(params) 652// 653// err := req.Send() 654// if err == nil { // resp is now filled 655// fmt.Println(resp) 656// } 657// 658// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/DeleteDetectorVersion 659func (c *FraudDetector) DeleteDetectorVersionRequest(input *DeleteDetectorVersionInput) (req *request.Request, output *DeleteDetectorVersionOutput) { 660 op := &request.Operation{ 661 Name: opDeleteDetectorVersion, 662 HTTPMethod: "POST", 663 HTTPPath: "/", 664 } 665 666 if input == nil { 667 input = &DeleteDetectorVersionInput{} 668 } 669 670 output = &DeleteDetectorVersionOutput{} 671 req = c.newRequest(op, input, output) 672 req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 673 return 674} 675 676// DeleteDetectorVersion API operation for Amazon Fraud Detector. 677// 678// Deletes the detector version. You cannot delete detector versions that are 679// in ACTIVE status. 680// 681// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 682// with awserr.Error's Code and Message methods to get detailed information about 683// the error. 684// 685// See the AWS API reference guide for Amazon Fraud Detector's 686// API operation DeleteDetectorVersion for usage and error information. 687// 688// Returned Error Types: 689// * ValidationException 690// An exception indicating a specified value is not allowed. 691// 692// * ResourceNotFoundException 693// An exception indicating the specified resource was not found. 694// 695// * InternalServerException 696// An exception indicating an internal server error. 697// 698// * ThrottlingException 699// An exception indicating a throttling error. 700// 701// * ConflictException 702// An exception indicating there was a conflict during a delete operation. The 703// following delete operations can cause a conflict exception: 704// 705// * DeleteDetector: A conflict exception will occur if the detector has 706// associated Rules or DetectorVersions. You can only delete a detector if 707// it has no Rules or DetectorVersions. 708// 709// * DeleteDetectorVersion: A conflict exception will occur if the DetectorVersion 710// status is ACTIVE. 711// 712// * DeleteRuleVersion: A conflict exception will occur if the RuleVersion 713// is in use by an associated ACTIVE or INACTIVE DetectorVersion. 714// 715// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/DeleteDetectorVersion 716func (c *FraudDetector) DeleteDetectorVersion(input *DeleteDetectorVersionInput) (*DeleteDetectorVersionOutput, error) { 717 req, out := c.DeleteDetectorVersionRequest(input) 718 return out, req.Send() 719} 720 721// DeleteDetectorVersionWithContext is the same as DeleteDetectorVersion with the addition of 722// the ability to pass a context and additional request options. 723// 724// See DeleteDetectorVersion for details on how to use this API operation. 725// 726// The context must be non-nil and will be used for request cancellation. If 727// the context is nil a panic will occur. In the future the SDK may create 728// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 729// for more information on using Contexts. 730func (c *FraudDetector) DeleteDetectorVersionWithContext(ctx aws.Context, input *DeleteDetectorVersionInput, opts ...request.Option) (*DeleteDetectorVersionOutput, error) { 731 req, out := c.DeleteDetectorVersionRequest(input) 732 req.SetContext(ctx) 733 req.ApplyOptions(opts...) 734 return out, req.Send() 735} 736 737const opDeleteEvent = "DeleteEvent" 738 739// DeleteEventRequest generates a "aws/request.Request" representing the 740// client's request for the DeleteEvent operation. The "output" return 741// value will be populated with the request's response once the request completes 742// successfully. 743// 744// Use "Send" method on the returned Request to send the API call to the service. 745// the "output" return value is not valid until after Send returns without error. 746// 747// See DeleteEvent for more information on using the DeleteEvent 748// API call, and error handling. 749// 750// This method is useful when you want to inject custom logic or configuration 751// into the SDK's request lifecycle. Such as custom headers, or retry logic. 752// 753// 754// // Example sending a request using the DeleteEventRequest method. 755// req, resp := client.DeleteEventRequest(params) 756// 757// err := req.Send() 758// if err == nil { // resp is now filled 759// fmt.Println(resp) 760// } 761// 762// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/DeleteEvent 763func (c *FraudDetector) DeleteEventRequest(input *DeleteEventInput) (req *request.Request, output *DeleteEventOutput) { 764 op := &request.Operation{ 765 Name: opDeleteEvent, 766 HTTPMethod: "POST", 767 HTTPPath: "/", 768 } 769 770 if input == nil { 771 input = &DeleteEventInput{} 772 } 773 774 output = &DeleteEventOutput{} 775 req = c.newRequest(op, input, output) 776 req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 777 return 778} 779 780// DeleteEvent API operation for Amazon Fraud Detector. 781// 782// Deletes the specified event. 783// 784// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 785// with awserr.Error's Code and Message methods to get detailed information about 786// the error. 787// 788// See the AWS API reference guide for Amazon Fraud Detector's 789// API operation DeleteEvent for usage and error information. 790// 791// Returned Error Types: 792// * InternalServerException 793// An exception indicating an internal server error. 794// 795// * ThrottlingException 796// An exception indicating a throttling error. 797// 798// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/DeleteEvent 799func (c *FraudDetector) DeleteEvent(input *DeleteEventInput) (*DeleteEventOutput, error) { 800 req, out := c.DeleteEventRequest(input) 801 return out, req.Send() 802} 803 804// DeleteEventWithContext is the same as DeleteEvent with the addition of 805// the ability to pass a context and additional request options. 806// 807// See DeleteEvent for details on how to use this API operation. 808// 809// The context must be non-nil and will be used for request cancellation. If 810// the context is nil a panic will occur. In the future the SDK may create 811// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 812// for more information on using Contexts. 813func (c *FraudDetector) DeleteEventWithContext(ctx aws.Context, input *DeleteEventInput, opts ...request.Option) (*DeleteEventOutput, error) { 814 req, out := c.DeleteEventRequest(input) 815 req.SetContext(ctx) 816 req.ApplyOptions(opts...) 817 return out, req.Send() 818} 819 820const opDeleteRuleVersion = "DeleteRuleVersion" 821 822// DeleteRuleVersionRequest generates a "aws/request.Request" representing the 823// client's request for the DeleteRuleVersion operation. The "output" return 824// value will be populated with the request's response once the request completes 825// successfully. 826// 827// Use "Send" method on the returned Request to send the API call to the service. 828// the "output" return value is not valid until after Send returns without error. 829// 830// See DeleteRuleVersion for more information on using the DeleteRuleVersion 831// API call, and error handling. 832// 833// This method is useful when you want to inject custom logic or configuration 834// into the SDK's request lifecycle. Such as custom headers, or retry logic. 835// 836// 837// // Example sending a request using the DeleteRuleVersionRequest method. 838// req, resp := client.DeleteRuleVersionRequest(params) 839// 840// err := req.Send() 841// if err == nil { // resp is now filled 842// fmt.Println(resp) 843// } 844// 845// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/DeleteRuleVersion 846func (c *FraudDetector) DeleteRuleVersionRequest(input *DeleteRuleVersionInput) (req *request.Request, output *DeleteRuleVersionOutput) { 847 op := &request.Operation{ 848 Name: opDeleteRuleVersion, 849 HTTPMethod: "POST", 850 HTTPPath: "/", 851 } 852 853 if input == nil { 854 input = &DeleteRuleVersionInput{} 855 } 856 857 output = &DeleteRuleVersionOutput{} 858 req = c.newRequest(op, input, output) 859 req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 860 return 861} 862 863// DeleteRuleVersion API operation for Amazon Fraud Detector. 864// 865// Deletes the rule version. You cannot delete a rule version if it is used 866// by an ACTIVE or INACTIVE detector version. 867// 868// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 869// with awserr.Error's Code and Message methods to get detailed information about 870// the error. 871// 872// See the AWS API reference guide for Amazon Fraud Detector's 873// API operation DeleteRuleVersion for usage and error information. 874// 875// Returned Error Types: 876// * ConflictException 877// An exception indicating there was a conflict during a delete operation. The 878// following delete operations can cause a conflict exception: 879// 880// * DeleteDetector: A conflict exception will occur if the detector has 881// associated Rules or DetectorVersions. You can only delete a detector if 882// it has no Rules or DetectorVersions. 883// 884// * DeleteDetectorVersion: A conflict exception will occur if the DetectorVersion 885// status is ACTIVE. 886// 887// * DeleteRuleVersion: A conflict exception will occur if the RuleVersion 888// is in use by an associated ACTIVE or INACTIVE DetectorVersion. 889// 890// * ValidationException 891// An exception indicating a specified value is not allowed. 892// 893// * InternalServerException 894// An exception indicating an internal server error. 895// 896// * ThrottlingException 897// An exception indicating a throttling error. 898// 899// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/DeleteRuleVersion 900func (c *FraudDetector) DeleteRuleVersion(input *DeleteRuleVersionInput) (*DeleteRuleVersionOutput, error) { 901 req, out := c.DeleteRuleVersionRequest(input) 902 return out, req.Send() 903} 904 905// DeleteRuleVersionWithContext is the same as DeleteRuleVersion with the addition of 906// the ability to pass a context and additional request options. 907// 908// See DeleteRuleVersion for details on how to use this API operation. 909// 910// The context must be non-nil and will be used for request cancellation. If 911// the context is nil a panic will occur. In the future the SDK may create 912// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 913// for more information on using Contexts. 914func (c *FraudDetector) DeleteRuleVersionWithContext(ctx aws.Context, input *DeleteRuleVersionInput, opts ...request.Option) (*DeleteRuleVersionOutput, error) { 915 req, out := c.DeleteRuleVersionRequest(input) 916 req.SetContext(ctx) 917 req.ApplyOptions(opts...) 918 return out, req.Send() 919} 920 921const opDescribeDetector = "DescribeDetector" 922 923// DescribeDetectorRequest generates a "aws/request.Request" representing the 924// client's request for the DescribeDetector operation. The "output" return 925// value will be populated with the request's response once the request completes 926// successfully. 927// 928// Use "Send" method on the returned Request to send the API call to the service. 929// the "output" return value is not valid until after Send returns without error. 930// 931// See DescribeDetector for more information on using the DescribeDetector 932// API call, and error handling. 933// 934// This method is useful when you want to inject custom logic or configuration 935// into the SDK's request lifecycle. Such as custom headers, or retry logic. 936// 937// 938// // Example sending a request using the DescribeDetectorRequest method. 939// req, resp := client.DescribeDetectorRequest(params) 940// 941// err := req.Send() 942// if err == nil { // resp is now filled 943// fmt.Println(resp) 944// } 945// 946// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/DescribeDetector 947func (c *FraudDetector) DescribeDetectorRequest(input *DescribeDetectorInput) (req *request.Request, output *DescribeDetectorOutput) { 948 op := &request.Operation{ 949 Name: opDescribeDetector, 950 HTTPMethod: "POST", 951 HTTPPath: "/", 952 } 953 954 if input == nil { 955 input = &DescribeDetectorInput{} 956 } 957 958 output = &DescribeDetectorOutput{} 959 req = c.newRequest(op, input, output) 960 return 961} 962 963// DescribeDetector API operation for Amazon Fraud Detector. 964// 965// Gets all versions for a specified detector. 966// 967// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 968// with awserr.Error's Code and Message methods to get detailed information about 969// the error. 970// 971// See the AWS API reference guide for Amazon Fraud Detector's 972// API operation DescribeDetector for usage and error information. 973// 974// Returned Error Types: 975// * ValidationException 976// An exception indicating a specified value is not allowed. 977// 978// * ResourceNotFoundException 979// An exception indicating the specified resource was not found. 980// 981// * InternalServerException 982// An exception indicating an internal server error. 983// 984// * ThrottlingException 985// An exception indicating a throttling error. 986// 987// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/DescribeDetector 988func (c *FraudDetector) DescribeDetector(input *DescribeDetectorInput) (*DescribeDetectorOutput, error) { 989 req, out := c.DescribeDetectorRequest(input) 990 return out, req.Send() 991} 992 993// DescribeDetectorWithContext is the same as DescribeDetector with the addition of 994// the ability to pass a context and additional request options. 995// 996// See DescribeDetector for details on how to use this API operation. 997// 998// The context must be non-nil and will be used for request cancellation. If 999// the context is nil a panic will occur. In the future the SDK may create 1000// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1001// for more information on using Contexts. 1002func (c *FraudDetector) DescribeDetectorWithContext(ctx aws.Context, input *DescribeDetectorInput, opts ...request.Option) (*DescribeDetectorOutput, error) { 1003 req, out := c.DescribeDetectorRequest(input) 1004 req.SetContext(ctx) 1005 req.ApplyOptions(opts...) 1006 return out, req.Send() 1007} 1008 1009const opDescribeModelVersions = "DescribeModelVersions" 1010 1011// DescribeModelVersionsRequest generates a "aws/request.Request" representing the 1012// client's request for the DescribeModelVersions operation. The "output" return 1013// value will be populated with the request's response once the request completes 1014// successfully. 1015// 1016// Use "Send" method on the returned Request to send the API call to the service. 1017// the "output" return value is not valid until after Send returns without error. 1018// 1019// See DescribeModelVersions for more information on using the DescribeModelVersions 1020// API call, and error handling. 1021// 1022// This method is useful when you want to inject custom logic or configuration 1023// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1024// 1025// 1026// // Example sending a request using the DescribeModelVersionsRequest method. 1027// req, resp := client.DescribeModelVersionsRequest(params) 1028// 1029// err := req.Send() 1030// if err == nil { // resp is now filled 1031// fmt.Println(resp) 1032// } 1033// 1034// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/DescribeModelVersions 1035func (c *FraudDetector) DescribeModelVersionsRequest(input *DescribeModelVersionsInput) (req *request.Request, output *DescribeModelVersionsOutput) { 1036 op := &request.Operation{ 1037 Name: opDescribeModelVersions, 1038 HTTPMethod: "POST", 1039 HTTPPath: "/", 1040 Paginator: &request.Paginator{ 1041 InputTokens: []string{"nextToken"}, 1042 OutputTokens: []string{"nextToken"}, 1043 LimitToken: "maxResults", 1044 TruncationToken: "", 1045 }, 1046 } 1047 1048 if input == nil { 1049 input = &DescribeModelVersionsInput{} 1050 } 1051 1052 output = &DescribeModelVersionsOutput{} 1053 req = c.newRequest(op, input, output) 1054 return 1055} 1056 1057// DescribeModelVersions API operation for Amazon Fraud Detector. 1058// 1059// Gets all of the model versions for the specified model type or for the specified 1060// model type and model ID. You can also get details for a single, specified 1061// model version. 1062// 1063// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1064// with awserr.Error's Code and Message methods to get detailed information about 1065// the error. 1066// 1067// See the AWS API reference guide for Amazon Fraud Detector's 1068// API operation DescribeModelVersions for usage and error information. 1069// 1070// Returned Error Types: 1071// * ValidationException 1072// An exception indicating a specified value is not allowed. 1073// 1074// * ResourceNotFoundException 1075// An exception indicating the specified resource was not found. 1076// 1077// * InternalServerException 1078// An exception indicating an internal server error. 1079// 1080// * ThrottlingException 1081// An exception indicating a throttling error. 1082// 1083// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/DescribeModelVersions 1084func (c *FraudDetector) DescribeModelVersions(input *DescribeModelVersionsInput) (*DescribeModelVersionsOutput, error) { 1085 req, out := c.DescribeModelVersionsRequest(input) 1086 return out, req.Send() 1087} 1088 1089// DescribeModelVersionsWithContext is the same as DescribeModelVersions with the addition of 1090// the ability to pass a context and additional request options. 1091// 1092// See DescribeModelVersions for details on how to use this API operation. 1093// 1094// The context must be non-nil and will be used for request cancellation. If 1095// the context is nil a panic will occur. In the future the SDK may create 1096// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1097// for more information on using Contexts. 1098func (c *FraudDetector) DescribeModelVersionsWithContext(ctx aws.Context, input *DescribeModelVersionsInput, opts ...request.Option) (*DescribeModelVersionsOutput, error) { 1099 req, out := c.DescribeModelVersionsRequest(input) 1100 req.SetContext(ctx) 1101 req.ApplyOptions(opts...) 1102 return out, req.Send() 1103} 1104 1105// DescribeModelVersionsPages iterates over the pages of a DescribeModelVersions operation, 1106// calling the "fn" function with the response data for each page. To stop 1107// iterating, return false from the fn function. 1108// 1109// See DescribeModelVersions method for more information on how to use this operation. 1110// 1111// Note: This operation can generate multiple requests to a service. 1112// 1113// // Example iterating over at most 3 pages of a DescribeModelVersions operation. 1114// pageNum := 0 1115// err := client.DescribeModelVersionsPages(params, 1116// func(page *frauddetector.DescribeModelVersionsOutput, lastPage bool) bool { 1117// pageNum++ 1118// fmt.Println(page) 1119// return pageNum <= 3 1120// }) 1121// 1122func (c *FraudDetector) DescribeModelVersionsPages(input *DescribeModelVersionsInput, fn func(*DescribeModelVersionsOutput, bool) bool) error { 1123 return c.DescribeModelVersionsPagesWithContext(aws.BackgroundContext(), input, fn) 1124} 1125 1126// DescribeModelVersionsPagesWithContext same as DescribeModelVersionsPages except 1127// it takes a Context and allows setting request options on the pages. 1128// 1129// The context must be non-nil and will be used for request cancellation. If 1130// the context is nil a panic will occur. In the future the SDK may create 1131// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1132// for more information on using Contexts. 1133func (c *FraudDetector) DescribeModelVersionsPagesWithContext(ctx aws.Context, input *DescribeModelVersionsInput, fn func(*DescribeModelVersionsOutput, bool) bool, opts ...request.Option) error { 1134 p := request.Pagination{ 1135 NewRequest: func() (*request.Request, error) { 1136 var inCpy *DescribeModelVersionsInput 1137 if input != nil { 1138 tmp := *input 1139 inCpy = &tmp 1140 } 1141 req, _ := c.DescribeModelVersionsRequest(inCpy) 1142 req.SetContext(ctx) 1143 req.ApplyOptions(opts...) 1144 return req, nil 1145 }, 1146 } 1147 1148 for p.Next() { 1149 if !fn(p.Page().(*DescribeModelVersionsOutput), !p.HasNextPage()) { 1150 break 1151 } 1152 } 1153 1154 return p.Err() 1155} 1156 1157const opGetDetectorVersion = "GetDetectorVersion" 1158 1159// GetDetectorVersionRequest generates a "aws/request.Request" representing the 1160// client's request for the GetDetectorVersion operation. The "output" return 1161// value will be populated with the request's response once the request completes 1162// successfully. 1163// 1164// Use "Send" method on the returned Request to send the API call to the service. 1165// the "output" return value is not valid until after Send returns without error. 1166// 1167// See GetDetectorVersion for more information on using the GetDetectorVersion 1168// API call, and error handling. 1169// 1170// This method is useful when you want to inject custom logic or configuration 1171// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1172// 1173// 1174// // Example sending a request using the GetDetectorVersionRequest method. 1175// req, resp := client.GetDetectorVersionRequest(params) 1176// 1177// err := req.Send() 1178// if err == nil { // resp is now filled 1179// fmt.Println(resp) 1180// } 1181// 1182// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/GetDetectorVersion 1183func (c *FraudDetector) GetDetectorVersionRequest(input *GetDetectorVersionInput) (req *request.Request, output *GetDetectorVersionOutput) { 1184 op := &request.Operation{ 1185 Name: opGetDetectorVersion, 1186 HTTPMethod: "POST", 1187 HTTPPath: "/", 1188 } 1189 1190 if input == nil { 1191 input = &GetDetectorVersionInput{} 1192 } 1193 1194 output = &GetDetectorVersionOutput{} 1195 req = c.newRequest(op, input, output) 1196 return 1197} 1198 1199// GetDetectorVersion API operation for Amazon Fraud Detector. 1200// 1201// Gets a particular detector version. 1202// 1203// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1204// with awserr.Error's Code and Message methods to get detailed information about 1205// the error. 1206// 1207// See the AWS API reference guide for Amazon Fraud Detector's 1208// API operation GetDetectorVersion for usage and error information. 1209// 1210// Returned Error Types: 1211// * ValidationException 1212// An exception indicating a specified value is not allowed. 1213// 1214// * ResourceNotFoundException 1215// An exception indicating the specified resource was not found. 1216// 1217// * InternalServerException 1218// An exception indicating an internal server error. 1219// 1220// * ThrottlingException 1221// An exception indicating a throttling error. 1222// 1223// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/GetDetectorVersion 1224func (c *FraudDetector) GetDetectorVersion(input *GetDetectorVersionInput) (*GetDetectorVersionOutput, error) { 1225 req, out := c.GetDetectorVersionRequest(input) 1226 return out, req.Send() 1227} 1228 1229// GetDetectorVersionWithContext is the same as GetDetectorVersion with the addition of 1230// the ability to pass a context and additional request options. 1231// 1232// See GetDetectorVersion for details on how to use this API operation. 1233// 1234// The context must be non-nil and will be used for request cancellation. If 1235// the context is nil a panic will occur. In the future the SDK may create 1236// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1237// for more information on using Contexts. 1238func (c *FraudDetector) GetDetectorVersionWithContext(ctx aws.Context, input *GetDetectorVersionInput, opts ...request.Option) (*GetDetectorVersionOutput, error) { 1239 req, out := c.GetDetectorVersionRequest(input) 1240 req.SetContext(ctx) 1241 req.ApplyOptions(opts...) 1242 return out, req.Send() 1243} 1244 1245const opGetDetectors = "GetDetectors" 1246 1247// GetDetectorsRequest generates a "aws/request.Request" representing the 1248// client's request for the GetDetectors operation. The "output" return 1249// value will be populated with the request's response once the request completes 1250// successfully. 1251// 1252// Use "Send" method on the returned Request to send the API call to the service. 1253// the "output" return value is not valid until after Send returns without error. 1254// 1255// See GetDetectors for more information on using the GetDetectors 1256// API call, and error handling. 1257// 1258// This method is useful when you want to inject custom logic or configuration 1259// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1260// 1261// 1262// // Example sending a request using the GetDetectorsRequest method. 1263// req, resp := client.GetDetectorsRequest(params) 1264// 1265// err := req.Send() 1266// if err == nil { // resp is now filled 1267// fmt.Println(resp) 1268// } 1269// 1270// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/GetDetectors 1271func (c *FraudDetector) GetDetectorsRequest(input *GetDetectorsInput) (req *request.Request, output *GetDetectorsOutput) { 1272 op := &request.Operation{ 1273 Name: opGetDetectors, 1274 HTTPMethod: "POST", 1275 HTTPPath: "/", 1276 Paginator: &request.Paginator{ 1277 InputTokens: []string{"nextToken"}, 1278 OutputTokens: []string{"nextToken"}, 1279 LimitToken: "maxResults", 1280 TruncationToken: "", 1281 }, 1282 } 1283 1284 if input == nil { 1285 input = &GetDetectorsInput{} 1286 } 1287 1288 output = &GetDetectorsOutput{} 1289 req = c.newRequest(op, input, output) 1290 return 1291} 1292 1293// GetDetectors API operation for Amazon Fraud Detector. 1294// 1295// Gets all of detectors. This is a paginated API. If you provide a null maxSizePerPage, 1296// this actions retrieves a maximum of 10 records per page. If you provide a 1297// maxSizePerPage, the value must be between 5 and 10. To get the next page 1298// results, provide the pagination token from the GetEventTypesResponse as part 1299// of your request. A null pagination token fetches the records from the beginning. 1300// 1301// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1302// with awserr.Error's Code and Message methods to get detailed information about 1303// the error. 1304// 1305// See the AWS API reference guide for Amazon Fraud Detector's 1306// API operation GetDetectors for usage and error information. 1307// 1308// Returned Error Types: 1309// * ValidationException 1310// An exception indicating a specified value is not allowed. 1311// 1312// * ResourceNotFoundException 1313// An exception indicating the specified resource was not found. 1314// 1315// * InternalServerException 1316// An exception indicating an internal server error. 1317// 1318// * ThrottlingException 1319// An exception indicating a throttling error. 1320// 1321// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/GetDetectors 1322func (c *FraudDetector) GetDetectors(input *GetDetectorsInput) (*GetDetectorsOutput, error) { 1323 req, out := c.GetDetectorsRequest(input) 1324 return out, req.Send() 1325} 1326 1327// GetDetectorsWithContext is the same as GetDetectors with the addition of 1328// the ability to pass a context and additional request options. 1329// 1330// See GetDetectors for details on how to use this API operation. 1331// 1332// The context must be non-nil and will be used for request cancellation. If 1333// the context is nil a panic will occur. In the future the SDK may create 1334// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1335// for more information on using Contexts. 1336func (c *FraudDetector) GetDetectorsWithContext(ctx aws.Context, input *GetDetectorsInput, opts ...request.Option) (*GetDetectorsOutput, error) { 1337 req, out := c.GetDetectorsRequest(input) 1338 req.SetContext(ctx) 1339 req.ApplyOptions(opts...) 1340 return out, req.Send() 1341} 1342 1343// GetDetectorsPages iterates over the pages of a GetDetectors operation, 1344// calling the "fn" function with the response data for each page. To stop 1345// iterating, return false from the fn function. 1346// 1347// See GetDetectors method for more information on how to use this operation. 1348// 1349// Note: This operation can generate multiple requests to a service. 1350// 1351// // Example iterating over at most 3 pages of a GetDetectors operation. 1352// pageNum := 0 1353// err := client.GetDetectorsPages(params, 1354// func(page *frauddetector.GetDetectorsOutput, lastPage bool) bool { 1355// pageNum++ 1356// fmt.Println(page) 1357// return pageNum <= 3 1358// }) 1359// 1360func (c *FraudDetector) GetDetectorsPages(input *GetDetectorsInput, fn func(*GetDetectorsOutput, bool) bool) error { 1361 return c.GetDetectorsPagesWithContext(aws.BackgroundContext(), input, fn) 1362} 1363 1364// GetDetectorsPagesWithContext same as GetDetectorsPages except 1365// it takes a Context and allows setting request options on the pages. 1366// 1367// The context must be non-nil and will be used for request cancellation. If 1368// the context is nil a panic will occur. In the future the SDK may create 1369// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1370// for more information on using Contexts. 1371func (c *FraudDetector) GetDetectorsPagesWithContext(ctx aws.Context, input *GetDetectorsInput, fn func(*GetDetectorsOutput, bool) bool, opts ...request.Option) error { 1372 p := request.Pagination{ 1373 NewRequest: func() (*request.Request, error) { 1374 var inCpy *GetDetectorsInput 1375 if input != nil { 1376 tmp := *input 1377 inCpy = &tmp 1378 } 1379 req, _ := c.GetDetectorsRequest(inCpy) 1380 req.SetContext(ctx) 1381 req.ApplyOptions(opts...) 1382 return req, nil 1383 }, 1384 } 1385 1386 for p.Next() { 1387 if !fn(p.Page().(*GetDetectorsOutput), !p.HasNextPage()) { 1388 break 1389 } 1390 } 1391 1392 return p.Err() 1393} 1394 1395const opGetExternalModels = "GetExternalModels" 1396 1397// GetExternalModelsRequest generates a "aws/request.Request" representing the 1398// client's request for the GetExternalModels operation. The "output" return 1399// value will be populated with the request's response once the request completes 1400// successfully. 1401// 1402// Use "Send" method on the returned Request to send the API call to the service. 1403// the "output" return value is not valid until after Send returns without error. 1404// 1405// See GetExternalModels for more information on using the GetExternalModels 1406// API call, and error handling. 1407// 1408// This method is useful when you want to inject custom logic or configuration 1409// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1410// 1411// 1412// // Example sending a request using the GetExternalModelsRequest method. 1413// req, resp := client.GetExternalModelsRequest(params) 1414// 1415// err := req.Send() 1416// if err == nil { // resp is now filled 1417// fmt.Println(resp) 1418// } 1419// 1420// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/GetExternalModels 1421func (c *FraudDetector) GetExternalModelsRequest(input *GetExternalModelsInput) (req *request.Request, output *GetExternalModelsOutput) { 1422 op := &request.Operation{ 1423 Name: opGetExternalModels, 1424 HTTPMethod: "POST", 1425 HTTPPath: "/", 1426 Paginator: &request.Paginator{ 1427 InputTokens: []string{"nextToken"}, 1428 OutputTokens: []string{"nextToken"}, 1429 LimitToken: "maxResults", 1430 TruncationToken: "", 1431 }, 1432 } 1433 1434 if input == nil { 1435 input = &GetExternalModelsInput{} 1436 } 1437 1438 output = &GetExternalModelsOutput{} 1439 req = c.newRequest(op, input, output) 1440 return 1441} 1442 1443// GetExternalModels API operation for Amazon Fraud Detector. 1444// 1445// Gets the details for one or more Amazon SageMaker models that have been imported 1446// into the service. This is a paginated API. If you provide a null maxSizePerPage, 1447// this actions retrieves a maximum of 10 records per page. If you provide a 1448// maxSizePerPage, the value must be between 5 and 10. To get the next page 1449// results, provide the pagination token from the GetExternalModelsResult as 1450// part of your request. A null pagination token fetches the records from the 1451// beginning. 1452// 1453// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1454// with awserr.Error's Code and Message methods to get detailed information about 1455// the error. 1456// 1457// See the AWS API reference guide for Amazon Fraud Detector's 1458// API operation GetExternalModels for usage and error information. 1459// 1460// Returned Error Types: 1461// * ValidationException 1462// An exception indicating a specified value is not allowed. 1463// 1464// * ResourceNotFoundException 1465// An exception indicating the specified resource was not found. 1466// 1467// * InternalServerException 1468// An exception indicating an internal server error. 1469// 1470// * ThrottlingException 1471// An exception indicating a throttling error. 1472// 1473// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/GetExternalModels 1474func (c *FraudDetector) GetExternalModels(input *GetExternalModelsInput) (*GetExternalModelsOutput, error) { 1475 req, out := c.GetExternalModelsRequest(input) 1476 return out, req.Send() 1477} 1478 1479// GetExternalModelsWithContext is the same as GetExternalModels with the addition of 1480// the ability to pass a context and additional request options. 1481// 1482// See GetExternalModels for details on how to use this API operation. 1483// 1484// The context must be non-nil and will be used for request cancellation. If 1485// the context is nil a panic will occur. In the future the SDK may create 1486// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1487// for more information on using Contexts. 1488func (c *FraudDetector) GetExternalModelsWithContext(ctx aws.Context, input *GetExternalModelsInput, opts ...request.Option) (*GetExternalModelsOutput, error) { 1489 req, out := c.GetExternalModelsRequest(input) 1490 req.SetContext(ctx) 1491 req.ApplyOptions(opts...) 1492 return out, req.Send() 1493} 1494 1495// GetExternalModelsPages iterates over the pages of a GetExternalModels operation, 1496// calling the "fn" function with the response data for each page. To stop 1497// iterating, return false from the fn function. 1498// 1499// See GetExternalModels method for more information on how to use this operation. 1500// 1501// Note: This operation can generate multiple requests to a service. 1502// 1503// // Example iterating over at most 3 pages of a GetExternalModels operation. 1504// pageNum := 0 1505// err := client.GetExternalModelsPages(params, 1506// func(page *frauddetector.GetExternalModelsOutput, lastPage bool) bool { 1507// pageNum++ 1508// fmt.Println(page) 1509// return pageNum <= 3 1510// }) 1511// 1512func (c *FraudDetector) GetExternalModelsPages(input *GetExternalModelsInput, fn func(*GetExternalModelsOutput, bool) bool) error { 1513 return c.GetExternalModelsPagesWithContext(aws.BackgroundContext(), input, fn) 1514} 1515 1516// GetExternalModelsPagesWithContext same as GetExternalModelsPages except 1517// it takes a Context and allows setting request options on the pages. 1518// 1519// The context must be non-nil and will be used for request cancellation. If 1520// the context is nil a panic will occur. In the future the SDK may create 1521// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1522// for more information on using Contexts. 1523func (c *FraudDetector) GetExternalModelsPagesWithContext(ctx aws.Context, input *GetExternalModelsInput, fn func(*GetExternalModelsOutput, bool) bool, opts ...request.Option) error { 1524 p := request.Pagination{ 1525 NewRequest: func() (*request.Request, error) { 1526 var inCpy *GetExternalModelsInput 1527 if input != nil { 1528 tmp := *input 1529 inCpy = &tmp 1530 } 1531 req, _ := c.GetExternalModelsRequest(inCpy) 1532 req.SetContext(ctx) 1533 req.ApplyOptions(opts...) 1534 return req, nil 1535 }, 1536 } 1537 1538 for p.Next() { 1539 if !fn(p.Page().(*GetExternalModelsOutput), !p.HasNextPage()) { 1540 break 1541 } 1542 } 1543 1544 return p.Err() 1545} 1546 1547const opGetModelVersion = "GetModelVersion" 1548 1549// GetModelVersionRequest generates a "aws/request.Request" representing the 1550// client's request for the GetModelVersion operation. The "output" return 1551// value will be populated with the request's response once the request completes 1552// successfully. 1553// 1554// Use "Send" method on the returned Request to send the API call to the service. 1555// the "output" return value is not valid until after Send returns without error. 1556// 1557// See GetModelVersion for more information on using the GetModelVersion 1558// API call, and error handling. 1559// 1560// This method is useful when you want to inject custom logic or configuration 1561// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1562// 1563// 1564// // Example sending a request using the GetModelVersionRequest method. 1565// req, resp := client.GetModelVersionRequest(params) 1566// 1567// err := req.Send() 1568// if err == nil { // resp is now filled 1569// fmt.Println(resp) 1570// } 1571// 1572// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/GetModelVersion 1573func (c *FraudDetector) GetModelVersionRequest(input *GetModelVersionInput) (req *request.Request, output *GetModelVersionOutput) { 1574 op := &request.Operation{ 1575 Name: opGetModelVersion, 1576 HTTPMethod: "POST", 1577 HTTPPath: "/", 1578 } 1579 1580 if input == nil { 1581 input = &GetModelVersionInput{} 1582 } 1583 1584 output = &GetModelVersionOutput{} 1585 req = c.newRequest(op, input, output) 1586 return 1587} 1588 1589// GetModelVersion API operation for Amazon Fraud Detector. 1590// 1591// Gets a model version. 1592// 1593// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1594// with awserr.Error's Code and Message methods to get detailed information about 1595// the error. 1596// 1597// See the AWS API reference guide for Amazon Fraud Detector's 1598// API operation GetModelVersion for usage and error information. 1599// 1600// Returned Error Types: 1601// * ValidationException 1602// An exception indicating a specified value is not allowed. 1603// 1604// * ResourceNotFoundException 1605// An exception indicating the specified resource was not found. 1606// 1607// * InternalServerException 1608// An exception indicating an internal server error. 1609// 1610// * ThrottlingException 1611// An exception indicating a throttling error. 1612// 1613// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/GetModelVersion 1614func (c *FraudDetector) GetModelVersion(input *GetModelVersionInput) (*GetModelVersionOutput, error) { 1615 req, out := c.GetModelVersionRequest(input) 1616 return out, req.Send() 1617} 1618 1619// GetModelVersionWithContext is the same as GetModelVersion with the addition of 1620// the ability to pass a context and additional request options. 1621// 1622// See GetModelVersion for details on how to use this API operation. 1623// 1624// The context must be non-nil and will be used for request cancellation. If 1625// the context is nil a panic will occur. In the future the SDK may create 1626// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1627// for more information on using Contexts. 1628func (c *FraudDetector) GetModelVersionWithContext(ctx aws.Context, input *GetModelVersionInput, opts ...request.Option) (*GetModelVersionOutput, error) { 1629 req, out := c.GetModelVersionRequest(input) 1630 req.SetContext(ctx) 1631 req.ApplyOptions(opts...) 1632 return out, req.Send() 1633} 1634 1635const opGetModels = "GetModels" 1636 1637// GetModelsRequest generates a "aws/request.Request" representing the 1638// client's request for the GetModels operation. The "output" return 1639// value will be populated with the request's response once the request completes 1640// successfully. 1641// 1642// Use "Send" method on the returned Request to send the API call to the service. 1643// the "output" return value is not valid until after Send returns without error. 1644// 1645// See GetModels for more information on using the GetModels 1646// API call, and error handling. 1647// 1648// This method is useful when you want to inject custom logic or configuration 1649// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1650// 1651// 1652// // Example sending a request using the GetModelsRequest method. 1653// req, resp := client.GetModelsRequest(params) 1654// 1655// err := req.Send() 1656// if err == nil { // resp is now filled 1657// fmt.Println(resp) 1658// } 1659// 1660// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/GetModels 1661func (c *FraudDetector) GetModelsRequest(input *GetModelsInput) (req *request.Request, output *GetModelsOutput) { 1662 op := &request.Operation{ 1663 Name: opGetModels, 1664 HTTPMethod: "POST", 1665 HTTPPath: "/", 1666 Paginator: &request.Paginator{ 1667 InputTokens: []string{"nextToken"}, 1668 OutputTokens: []string{"nextToken"}, 1669 LimitToken: "maxResults", 1670 TruncationToken: "", 1671 }, 1672 } 1673 1674 if input == nil { 1675 input = &GetModelsInput{} 1676 } 1677 1678 output = &GetModelsOutput{} 1679 req = c.newRequest(op, input, output) 1680 return 1681} 1682 1683// GetModels API operation for Amazon Fraud Detector. 1684// 1685// Gets all of the models for the AWS account, or the specified model type, 1686// or gets a single model for the specified model type, model ID combination. 1687// 1688// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1689// with awserr.Error's Code and Message methods to get detailed information about 1690// the error. 1691// 1692// See the AWS API reference guide for Amazon Fraud Detector's 1693// API operation GetModels for usage and error information. 1694// 1695// Returned Error Types: 1696// * ValidationException 1697// An exception indicating a specified value is not allowed. 1698// 1699// * ResourceNotFoundException 1700// An exception indicating the specified resource was not found. 1701// 1702// * InternalServerException 1703// An exception indicating an internal server error. 1704// 1705// * ThrottlingException 1706// An exception indicating a throttling error. 1707// 1708// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/GetModels 1709func (c *FraudDetector) GetModels(input *GetModelsInput) (*GetModelsOutput, error) { 1710 req, out := c.GetModelsRequest(input) 1711 return out, req.Send() 1712} 1713 1714// GetModelsWithContext is the same as GetModels with the addition of 1715// the ability to pass a context and additional request options. 1716// 1717// See GetModels for details on how to use this API operation. 1718// 1719// The context must be non-nil and will be used for request cancellation. If 1720// the context is nil a panic will occur. In the future the SDK may create 1721// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1722// for more information on using Contexts. 1723func (c *FraudDetector) GetModelsWithContext(ctx aws.Context, input *GetModelsInput, opts ...request.Option) (*GetModelsOutput, error) { 1724 req, out := c.GetModelsRequest(input) 1725 req.SetContext(ctx) 1726 req.ApplyOptions(opts...) 1727 return out, req.Send() 1728} 1729 1730// GetModelsPages iterates over the pages of a GetModels operation, 1731// calling the "fn" function with the response data for each page. To stop 1732// iterating, return false from the fn function. 1733// 1734// See GetModels method for more information on how to use this operation. 1735// 1736// Note: This operation can generate multiple requests to a service. 1737// 1738// // Example iterating over at most 3 pages of a GetModels operation. 1739// pageNum := 0 1740// err := client.GetModelsPages(params, 1741// func(page *frauddetector.GetModelsOutput, lastPage bool) bool { 1742// pageNum++ 1743// fmt.Println(page) 1744// return pageNum <= 3 1745// }) 1746// 1747func (c *FraudDetector) GetModelsPages(input *GetModelsInput, fn func(*GetModelsOutput, bool) bool) error { 1748 return c.GetModelsPagesWithContext(aws.BackgroundContext(), input, fn) 1749} 1750 1751// GetModelsPagesWithContext same as GetModelsPages except 1752// it takes a Context and allows setting request options on the pages. 1753// 1754// The context must be non-nil and will be used for request cancellation. If 1755// the context is nil a panic will occur. In the future the SDK may create 1756// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1757// for more information on using Contexts. 1758func (c *FraudDetector) GetModelsPagesWithContext(ctx aws.Context, input *GetModelsInput, fn func(*GetModelsOutput, bool) bool, opts ...request.Option) error { 1759 p := request.Pagination{ 1760 NewRequest: func() (*request.Request, error) { 1761 var inCpy *GetModelsInput 1762 if input != nil { 1763 tmp := *input 1764 inCpy = &tmp 1765 } 1766 req, _ := c.GetModelsRequest(inCpy) 1767 req.SetContext(ctx) 1768 req.ApplyOptions(opts...) 1769 return req, nil 1770 }, 1771 } 1772 1773 for p.Next() { 1774 if !fn(p.Page().(*GetModelsOutput), !p.HasNextPage()) { 1775 break 1776 } 1777 } 1778 1779 return p.Err() 1780} 1781 1782const opGetOutcomes = "GetOutcomes" 1783 1784// GetOutcomesRequest generates a "aws/request.Request" representing the 1785// client's request for the GetOutcomes operation. The "output" return 1786// value will be populated with the request's response once the request completes 1787// successfully. 1788// 1789// Use "Send" method on the returned Request to send the API call to the service. 1790// the "output" return value is not valid until after Send returns without error. 1791// 1792// See GetOutcomes for more information on using the GetOutcomes 1793// API call, and error handling. 1794// 1795// This method is useful when you want to inject custom logic or configuration 1796// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1797// 1798// 1799// // Example sending a request using the GetOutcomesRequest method. 1800// req, resp := client.GetOutcomesRequest(params) 1801// 1802// err := req.Send() 1803// if err == nil { // resp is now filled 1804// fmt.Println(resp) 1805// } 1806// 1807// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/GetOutcomes 1808func (c *FraudDetector) GetOutcomesRequest(input *GetOutcomesInput) (req *request.Request, output *GetOutcomesOutput) { 1809 op := &request.Operation{ 1810 Name: opGetOutcomes, 1811 HTTPMethod: "POST", 1812 HTTPPath: "/", 1813 Paginator: &request.Paginator{ 1814 InputTokens: []string{"nextToken"}, 1815 OutputTokens: []string{"nextToken"}, 1816 LimitToken: "maxResults", 1817 TruncationToken: "", 1818 }, 1819 } 1820 1821 if input == nil { 1822 input = &GetOutcomesInput{} 1823 } 1824 1825 output = &GetOutcomesOutput{} 1826 req = c.newRequest(op, input, output) 1827 return 1828} 1829 1830// GetOutcomes API operation for Amazon Fraud Detector. 1831// 1832// Gets one or more outcomes. This is a paginated API. If you provide a null 1833// maxSizePerPage, this actions retrieves a maximum of 10 records per page. 1834// If you provide a maxSizePerPage, the value must be between 50 and 100. To 1835// get the next page results, provide the pagination token from the GetOutcomesResult 1836// as part of your request. A null pagination token fetches the records from 1837// the beginning. 1838// 1839// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1840// with awserr.Error's Code and Message methods to get detailed information about 1841// the error. 1842// 1843// See the AWS API reference guide for Amazon Fraud Detector's 1844// API operation GetOutcomes for usage and error information. 1845// 1846// Returned Error Types: 1847// * ValidationException 1848// An exception indicating a specified value is not allowed. 1849// 1850// * ResourceNotFoundException 1851// An exception indicating the specified resource was not found. 1852// 1853// * InternalServerException 1854// An exception indicating an internal server error. 1855// 1856// * ThrottlingException 1857// An exception indicating a throttling error. 1858// 1859// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/GetOutcomes 1860func (c *FraudDetector) GetOutcomes(input *GetOutcomesInput) (*GetOutcomesOutput, error) { 1861 req, out := c.GetOutcomesRequest(input) 1862 return out, req.Send() 1863} 1864 1865// GetOutcomesWithContext is the same as GetOutcomes with the addition of 1866// the ability to pass a context and additional request options. 1867// 1868// See GetOutcomes for details on how to use this API operation. 1869// 1870// The context must be non-nil and will be used for request cancellation. If 1871// the context is nil a panic will occur. In the future the SDK may create 1872// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1873// for more information on using Contexts. 1874func (c *FraudDetector) GetOutcomesWithContext(ctx aws.Context, input *GetOutcomesInput, opts ...request.Option) (*GetOutcomesOutput, error) { 1875 req, out := c.GetOutcomesRequest(input) 1876 req.SetContext(ctx) 1877 req.ApplyOptions(opts...) 1878 return out, req.Send() 1879} 1880 1881// GetOutcomesPages iterates over the pages of a GetOutcomes operation, 1882// calling the "fn" function with the response data for each page. To stop 1883// iterating, return false from the fn function. 1884// 1885// See GetOutcomes method for more information on how to use this operation. 1886// 1887// Note: This operation can generate multiple requests to a service. 1888// 1889// // Example iterating over at most 3 pages of a GetOutcomes operation. 1890// pageNum := 0 1891// err := client.GetOutcomesPages(params, 1892// func(page *frauddetector.GetOutcomesOutput, lastPage bool) bool { 1893// pageNum++ 1894// fmt.Println(page) 1895// return pageNum <= 3 1896// }) 1897// 1898func (c *FraudDetector) GetOutcomesPages(input *GetOutcomesInput, fn func(*GetOutcomesOutput, bool) bool) error { 1899 return c.GetOutcomesPagesWithContext(aws.BackgroundContext(), input, fn) 1900} 1901 1902// GetOutcomesPagesWithContext same as GetOutcomesPages except 1903// it takes a Context and allows setting request options on the pages. 1904// 1905// The context must be non-nil and will be used for request cancellation. If 1906// the context is nil a panic will occur. In the future the SDK may create 1907// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1908// for more information on using Contexts. 1909func (c *FraudDetector) GetOutcomesPagesWithContext(ctx aws.Context, input *GetOutcomesInput, fn func(*GetOutcomesOutput, bool) bool, opts ...request.Option) error { 1910 p := request.Pagination{ 1911 NewRequest: func() (*request.Request, error) { 1912 var inCpy *GetOutcomesInput 1913 if input != nil { 1914 tmp := *input 1915 inCpy = &tmp 1916 } 1917 req, _ := c.GetOutcomesRequest(inCpy) 1918 req.SetContext(ctx) 1919 req.ApplyOptions(opts...) 1920 return req, nil 1921 }, 1922 } 1923 1924 for p.Next() { 1925 if !fn(p.Page().(*GetOutcomesOutput), !p.HasNextPage()) { 1926 break 1927 } 1928 } 1929 1930 return p.Err() 1931} 1932 1933const opGetPrediction = "GetPrediction" 1934 1935// GetPredictionRequest generates a "aws/request.Request" representing the 1936// client's request for the GetPrediction operation. The "output" return 1937// value will be populated with the request's response once the request completes 1938// successfully. 1939// 1940// Use "Send" method on the returned Request to send the API call to the service. 1941// the "output" return value is not valid until after Send returns without error. 1942// 1943// See GetPrediction for more information on using the GetPrediction 1944// API call, and error handling. 1945// 1946// This method is useful when you want to inject custom logic or configuration 1947// into the SDK's request lifecycle. Such as custom headers, or retry logic. 1948// 1949// 1950// // Example sending a request using the GetPredictionRequest method. 1951// req, resp := client.GetPredictionRequest(params) 1952// 1953// err := req.Send() 1954// if err == nil { // resp is now filled 1955// fmt.Println(resp) 1956// } 1957// 1958// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/GetPrediction 1959func (c *FraudDetector) GetPredictionRequest(input *GetPredictionInput) (req *request.Request, output *GetPredictionOutput) { 1960 op := &request.Operation{ 1961 Name: opGetPrediction, 1962 HTTPMethod: "POST", 1963 HTTPPath: "/", 1964 } 1965 1966 if input == nil { 1967 input = &GetPredictionInput{} 1968 } 1969 1970 output = &GetPredictionOutput{} 1971 req = c.newRequest(op, input, output) 1972 return 1973} 1974 1975// GetPrediction API operation for Amazon Fraud Detector. 1976// 1977// Evaluates an event against a detector version. If a version ID is not provided, 1978// the detector’s (ACTIVE) version is used. 1979// 1980// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1981// with awserr.Error's Code and Message methods to get detailed information about 1982// the error. 1983// 1984// See the AWS API reference guide for Amazon Fraud Detector's 1985// API operation GetPrediction for usage and error information. 1986// 1987// Returned Error Types: 1988// * ValidationException 1989// An exception indicating a specified value is not allowed. 1990// 1991// * ResourceNotFoundException 1992// An exception indicating the specified resource was not found. 1993// 1994// * InternalServerException 1995// An exception indicating an internal server error. 1996// 1997// * ThrottlingException 1998// An exception indicating a throttling error. 1999// 2000// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/GetPrediction 2001func (c *FraudDetector) GetPrediction(input *GetPredictionInput) (*GetPredictionOutput, error) { 2002 req, out := c.GetPredictionRequest(input) 2003 return out, req.Send() 2004} 2005 2006// GetPredictionWithContext is the same as GetPrediction with the addition of 2007// the ability to pass a context and additional request options. 2008// 2009// See GetPrediction for details on how to use this API operation. 2010// 2011// The context must be non-nil and will be used for request cancellation. If 2012// the context is nil a panic will occur. In the future the SDK may create 2013// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2014// for more information on using Contexts. 2015func (c *FraudDetector) GetPredictionWithContext(ctx aws.Context, input *GetPredictionInput, opts ...request.Option) (*GetPredictionOutput, error) { 2016 req, out := c.GetPredictionRequest(input) 2017 req.SetContext(ctx) 2018 req.ApplyOptions(opts...) 2019 return out, req.Send() 2020} 2021 2022const opGetRules = "GetRules" 2023 2024// GetRulesRequest generates a "aws/request.Request" representing the 2025// client's request for the GetRules operation. The "output" return 2026// value will be populated with the request's response once the request completes 2027// successfully. 2028// 2029// Use "Send" method on the returned Request to send the API call to the service. 2030// the "output" return value is not valid until after Send returns without error. 2031// 2032// See GetRules for more information on using the GetRules 2033// API call, and error handling. 2034// 2035// This method is useful when you want to inject custom logic or configuration 2036// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2037// 2038// 2039// // Example sending a request using the GetRulesRequest method. 2040// req, resp := client.GetRulesRequest(params) 2041// 2042// err := req.Send() 2043// if err == nil { // resp is now filled 2044// fmt.Println(resp) 2045// } 2046// 2047// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/GetRules 2048func (c *FraudDetector) GetRulesRequest(input *GetRulesInput) (req *request.Request, output *GetRulesOutput) { 2049 op := &request.Operation{ 2050 Name: opGetRules, 2051 HTTPMethod: "POST", 2052 HTTPPath: "/", 2053 Paginator: &request.Paginator{ 2054 InputTokens: []string{"nextToken"}, 2055 OutputTokens: []string{"nextToken"}, 2056 LimitToken: "maxResults", 2057 TruncationToken: "", 2058 }, 2059 } 2060 2061 if input == nil { 2062 input = &GetRulesInput{} 2063 } 2064 2065 output = &GetRulesOutput{} 2066 req = c.newRequest(op, input, output) 2067 return 2068} 2069 2070// GetRules API operation for Amazon Fraud Detector. 2071// 2072// Gets all rules available for the specified detector. 2073// 2074// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2075// with awserr.Error's Code and Message methods to get detailed information about 2076// the error. 2077// 2078// See the AWS API reference guide for Amazon Fraud Detector's 2079// API operation GetRules for usage and error information. 2080// 2081// Returned Error Types: 2082// * ValidationException 2083// An exception indicating a specified value is not allowed. 2084// 2085// * ResourceNotFoundException 2086// An exception indicating the specified resource was not found. 2087// 2088// * InternalServerException 2089// An exception indicating an internal server error. 2090// 2091// * ThrottlingException 2092// An exception indicating a throttling error. 2093// 2094// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/GetRules 2095func (c *FraudDetector) GetRules(input *GetRulesInput) (*GetRulesOutput, error) { 2096 req, out := c.GetRulesRequest(input) 2097 return out, req.Send() 2098} 2099 2100// GetRulesWithContext is the same as GetRules with the addition of 2101// the ability to pass a context and additional request options. 2102// 2103// See GetRules for details on how to use this API operation. 2104// 2105// The context must be non-nil and will be used for request cancellation. If 2106// the context is nil a panic will occur. In the future the SDK may create 2107// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2108// for more information on using Contexts. 2109func (c *FraudDetector) GetRulesWithContext(ctx aws.Context, input *GetRulesInput, opts ...request.Option) (*GetRulesOutput, error) { 2110 req, out := c.GetRulesRequest(input) 2111 req.SetContext(ctx) 2112 req.ApplyOptions(opts...) 2113 return out, req.Send() 2114} 2115 2116// GetRulesPages iterates over the pages of a GetRules operation, 2117// calling the "fn" function with the response data for each page. To stop 2118// iterating, return false from the fn function. 2119// 2120// See GetRules method for more information on how to use this operation. 2121// 2122// Note: This operation can generate multiple requests to a service. 2123// 2124// // Example iterating over at most 3 pages of a GetRules operation. 2125// pageNum := 0 2126// err := client.GetRulesPages(params, 2127// func(page *frauddetector.GetRulesOutput, lastPage bool) bool { 2128// pageNum++ 2129// fmt.Println(page) 2130// return pageNum <= 3 2131// }) 2132// 2133func (c *FraudDetector) GetRulesPages(input *GetRulesInput, fn func(*GetRulesOutput, bool) bool) error { 2134 return c.GetRulesPagesWithContext(aws.BackgroundContext(), input, fn) 2135} 2136 2137// GetRulesPagesWithContext same as GetRulesPages except 2138// it takes a Context and allows setting request options on the pages. 2139// 2140// The context must be non-nil and will be used for request cancellation. If 2141// the context is nil a panic will occur. In the future the SDK may create 2142// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2143// for more information on using Contexts. 2144func (c *FraudDetector) GetRulesPagesWithContext(ctx aws.Context, input *GetRulesInput, fn func(*GetRulesOutput, bool) bool, opts ...request.Option) error { 2145 p := request.Pagination{ 2146 NewRequest: func() (*request.Request, error) { 2147 var inCpy *GetRulesInput 2148 if input != nil { 2149 tmp := *input 2150 inCpy = &tmp 2151 } 2152 req, _ := c.GetRulesRequest(inCpy) 2153 req.SetContext(ctx) 2154 req.ApplyOptions(opts...) 2155 return req, nil 2156 }, 2157 } 2158 2159 for p.Next() { 2160 if !fn(p.Page().(*GetRulesOutput), !p.HasNextPage()) { 2161 break 2162 } 2163 } 2164 2165 return p.Err() 2166} 2167 2168const opGetVariables = "GetVariables" 2169 2170// GetVariablesRequest generates a "aws/request.Request" representing the 2171// client's request for the GetVariables operation. The "output" return 2172// value will be populated with the request's response once the request completes 2173// successfully. 2174// 2175// Use "Send" method on the returned Request to send the API call to the service. 2176// the "output" return value is not valid until after Send returns without error. 2177// 2178// See GetVariables for more information on using the GetVariables 2179// API call, and error handling. 2180// 2181// This method is useful when you want to inject custom logic or configuration 2182// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2183// 2184// 2185// // Example sending a request using the GetVariablesRequest method. 2186// req, resp := client.GetVariablesRequest(params) 2187// 2188// err := req.Send() 2189// if err == nil { // resp is now filled 2190// fmt.Println(resp) 2191// } 2192// 2193// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/GetVariables 2194func (c *FraudDetector) GetVariablesRequest(input *GetVariablesInput) (req *request.Request, output *GetVariablesOutput) { 2195 op := &request.Operation{ 2196 Name: opGetVariables, 2197 HTTPMethod: "POST", 2198 HTTPPath: "/", 2199 Paginator: &request.Paginator{ 2200 InputTokens: []string{"nextToken"}, 2201 OutputTokens: []string{"nextToken"}, 2202 LimitToken: "maxResults", 2203 TruncationToken: "", 2204 }, 2205 } 2206 2207 if input == nil { 2208 input = &GetVariablesInput{} 2209 } 2210 2211 output = &GetVariablesOutput{} 2212 req = c.newRequest(op, input, output) 2213 return 2214} 2215 2216// GetVariables API operation for Amazon Fraud Detector. 2217// 2218// Gets all of the variables or the specific variable. This is a paginated API. 2219// Providing null maxSizePerPage results in retrieving maximum of 100 records 2220// per page. If you provide maxSizePerPage the value must be between 50 and 2221// 100. To get the next page result, a provide a pagination token from GetVariablesResult 2222// as part of your request. Null pagination token fetches the records from the 2223// beginning. 2224// 2225// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2226// with awserr.Error's Code and Message methods to get detailed information about 2227// the error. 2228// 2229// See the AWS API reference guide for Amazon Fraud Detector's 2230// API operation GetVariables for usage and error information. 2231// 2232// Returned Error Types: 2233// * ValidationException 2234// An exception indicating a specified value is not allowed. 2235// 2236// * ResourceNotFoundException 2237// An exception indicating the specified resource was not found. 2238// 2239// * InternalServerException 2240// An exception indicating an internal server error. 2241// 2242// * ThrottlingException 2243// An exception indicating a throttling error. 2244// 2245// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/GetVariables 2246func (c *FraudDetector) GetVariables(input *GetVariablesInput) (*GetVariablesOutput, error) { 2247 req, out := c.GetVariablesRequest(input) 2248 return out, req.Send() 2249} 2250 2251// GetVariablesWithContext is the same as GetVariables with the addition of 2252// the ability to pass a context and additional request options. 2253// 2254// See GetVariables for details on how to use this API operation. 2255// 2256// The context must be non-nil and will be used for request cancellation. If 2257// the context is nil a panic will occur. In the future the SDK may create 2258// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2259// for more information on using Contexts. 2260func (c *FraudDetector) GetVariablesWithContext(ctx aws.Context, input *GetVariablesInput, opts ...request.Option) (*GetVariablesOutput, error) { 2261 req, out := c.GetVariablesRequest(input) 2262 req.SetContext(ctx) 2263 req.ApplyOptions(opts...) 2264 return out, req.Send() 2265} 2266 2267// GetVariablesPages iterates over the pages of a GetVariables operation, 2268// calling the "fn" function with the response data for each page. To stop 2269// iterating, return false from the fn function. 2270// 2271// See GetVariables method for more information on how to use this operation. 2272// 2273// Note: This operation can generate multiple requests to a service. 2274// 2275// // Example iterating over at most 3 pages of a GetVariables operation. 2276// pageNum := 0 2277// err := client.GetVariablesPages(params, 2278// func(page *frauddetector.GetVariablesOutput, lastPage bool) bool { 2279// pageNum++ 2280// fmt.Println(page) 2281// return pageNum <= 3 2282// }) 2283// 2284func (c *FraudDetector) GetVariablesPages(input *GetVariablesInput, fn func(*GetVariablesOutput, bool) bool) error { 2285 return c.GetVariablesPagesWithContext(aws.BackgroundContext(), input, fn) 2286} 2287 2288// GetVariablesPagesWithContext same as GetVariablesPages except 2289// it takes a Context and allows setting request options on the pages. 2290// 2291// The context must be non-nil and will be used for request cancellation. If 2292// the context is nil a panic will occur. In the future the SDK may create 2293// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2294// for more information on using Contexts. 2295func (c *FraudDetector) GetVariablesPagesWithContext(ctx aws.Context, input *GetVariablesInput, fn func(*GetVariablesOutput, bool) bool, opts ...request.Option) error { 2296 p := request.Pagination{ 2297 NewRequest: func() (*request.Request, error) { 2298 var inCpy *GetVariablesInput 2299 if input != nil { 2300 tmp := *input 2301 inCpy = &tmp 2302 } 2303 req, _ := c.GetVariablesRequest(inCpy) 2304 req.SetContext(ctx) 2305 req.ApplyOptions(opts...) 2306 return req, nil 2307 }, 2308 } 2309 2310 for p.Next() { 2311 if !fn(p.Page().(*GetVariablesOutput), !p.HasNextPage()) { 2312 break 2313 } 2314 } 2315 2316 return p.Err() 2317} 2318 2319const opPutDetector = "PutDetector" 2320 2321// PutDetectorRequest generates a "aws/request.Request" representing the 2322// client's request for the PutDetector operation. The "output" return 2323// value will be populated with the request's response once the request completes 2324// successfully. 2325// 2326// Use "Send" method on the returned Request to send the API call to the service. 2327// the "output" return value is not valid until after Send returns without error. 2328// 2329// See PutDetector for more information on using the PutDetector 2330// API call, and error handling. 2331// 2332// This method is useful when you want to inject custom logic or configuration 2333// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2334// 2335// 2336// // Example sending a request using the PutDetectorRequest method. 2337// req, resp := client.PutDetectorRequest(params) 2338// 2339// err := req.Send() 2340// if err == nil { // resp is now filled 2341// fmt.Println(resp) 2342// } 2343// 2344// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/PutDetector 2345func (c *FraudDetector) PutDetectorRequest(input *PutDetectorInput) (req *request.Request, output *PutDetectorOutput) { 2346 op := &request.Operation{ 2347 Name: opPutDetector, 2348 HTTPMethod: "POST", 2349 HTTPPath: "/", 2350 } 2351 2352 if input == nil { 2353 input = &PutDetectorInput{} 2354 } 2355 2356 output = &PutDetectorOutput{} 2357 req = c.newRequest(op, input, output) 2358 req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 2359 return 2360} 2361 2362// PutDetector API operation for Amazon Fraud Detector. 2363// 2364// Creates or updates a detector. 2365// 2366// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2367// with awserr.Error's Code and Message methods to get detailed information about 2368// the error. 2369// 2370// See the AWS API reference guide for Amazon Fraud Detector's 2371// API operation PutDetector for usage and error information. 2372// 2373// Returned Error Types: 2374// * ValidationException 2375// An exception indicating a specified value is not allowed. 2376// 2377// * InternalServerException 2378// An exception indicating an internal server error. 2379// 2380// * ThrottlingException 2381// An exception indicating a throttling error. 2382// 2383// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/PutDetector 2384func (c *FraudDetector) PutDetector(input *PutDetectorInput) (*PutDetectorOutput, error) { 2385 req, out := c.PutDetectorRequest(input) 2386 return out, req.Send() 2387} 2388 2389// PutDetectorWithContext is the same as PutDetector with the addition of 2390// the ability to pass a context and additional request options. 2391// 2392// See PutDetector for details on how to use this API operation. 2393// 2394// The context must be non-nil and will be used for request cancellation. If 2395// the context is nil a panic will occur. In the future the SDK may create 2396// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2397// for more information on using Contexts. 2398func (c *FraudDetector) PutDetectorWithContext(ctx aws.Context, input *PutDetectorInput, opts ...request.Option) (*PutDetectorOutput, error) { 2399 req, out := c.PutDetectorRequest(input) 2400 req.SetContext(ctx) 2401 req.ApplyOptions(opts...) 2402 return out, req.Send() 2403} 2404 2405const opPutExternalModel = "PutExternalModel" 2406 2407// PutExternalModelRequest generates a "aws/request.Request" representing the 2408// client's request for the PutExternalModel operation. The "output" return 2409// value will be populated with the request's response once the request completes 2410// successfully. 2411// 2412// Use "Send" method on the returned Request to send the API call to the service. 2413// the "output" return value is not valid until after Send returns without error. 2414// 2415// See PutExternalModel for more information on using the PutExternalModel 2416// API call, and error handling. 2417// 2418// This method is useful when you want to inject custom logic or configuration 2419// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2420// 2421// 2422// // Example sending a request using the PutExternalModelRequest method. 2423// req, resp := client.PutExternalModelRequest(params) 2424// 2425// err := req.Send() 2426// if err == nil { // resp is now filled 2427// fmt.Println(resp) 2428// } 2429// 2430// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/PutExternalModel 2431func (c *FraudDetector) PutExternalModelRequest(input *PutExternalModelInput) (req *request.Request, output *PutExternalModelOutput) { 2432 op := &request.Operation{ 2433 Name: opPutExternalModel, 2434 HTTPMethod: "POST", 2435 HTTPPath: "/", 2436 } 2437 2438 if input == nil { 2439 input = &PutExternalModelInput{} 2440 } 2441 2442 output = &PutExternalModelOutput{} 2443 req = c.newRequest(op, input, output) 2444 req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 2445 return 2446} 2447 2448// PutExternalModel API operation for Amazon Fraud Detector. 2449// 2450// Creates or updates an Amazon SageMaker model endpoint. You can also use this 2451// action to update the configuration of the model endpoint, including the IAM 2452// role and/or the mapped variables. 2453// 2454// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2455// with awserr.Error's Code and Message methods to get detailed information about 2456// the error. 2457// 2458// See the AWS API reference guide for Amazon Fraud Detector's 2459// API operation PutExternalModel for usage and error information. 2460// 2461// Returned Error Types: 2462// * ValidationException 2463// An exception indicating a specified value is not allowed. 2464// 2465// * InternalServerException 2466// An exception indicating an internal server error. 2467// 2468// * ThrottlingException 2469// An exception indicating a throttling error. 2470// 2471// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/PutExternalModel 2472func (c *FraudDetector) PutExternalModel(input *PutExternalModelInput) (*PutExternalModelOutput, error) { 2473 req, out := c.PutExternalModelRequest(input) 2474 return out, req.Send() 2475} 2476 2477// PutExternalModelWithContext is the same as PutExternalModel with the addition of 2478// the ability to pass a context and additional request options. 2479// 2480// See PutExternalModel for details on how to use this API operation. 2481// 2482// The context must be non-nil and will be used for request cancellation. If 2483// the context is nil a panic will occur. In the future the SDK may create 2484// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2485// for more information on using Contexts. 2486func (c *FraudDetector) PutExternalModelWithContext(ctx aws.Context, input *PutExternalModelInput, opts ...request.Option) (*PutExternalModelOutput, error) { 2487 req, out := c.PutExternalModelRequest(input) 2488 req.SetContext(ctx) 2489 req.ApplyOptions(opts...) 2490 return out, req.Send() 2491} 2492 2493const opPutModel = "PutModel" 2494 2495// PutModelRequest generates a "aws/request.Request" representing the 2496// client's request for the PutModel operation. The "output" return 2497// value will be populated with the request's response once the request completes 2498// successfully. 2499// 2500// Use "Send" method on the returned Request to send the API call to the service. 2501// the "output" return value is not valid until after Send returns without error. 2502// 2503// See PutModel for more information on using the PutModel 2504// API call, and error handling. 2505// 2506// This method is useful when you want to inject custom logic or configuration 2507// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2508// 2509// 2510// // Example sending a request using the PutModelRequest method. 2511// req, resp := client.PutModelRequest(params) 2512// 2513// err := req.Send() 2514// if err == nil { // resp is now filled 2515// fmt.Println(resp) 2516// } 2517// 2518// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/PutModel 2519func (c *FraudDetector) PutModelRequest(input *PutModelInput) (req *request.Request, output *PutModelOutput) { 2520 op := &request.Operation{ 2521 Name: opPutModel, 2522 HTTPMethod: "POST", 2523 HTTPPath: "/", 2524 } 2525 2526 if input == nil { 2527 input = &PutModelInput{} 2528 } 2529 2530 output = &PutModelOutput{} 2531 req = c.newRequest(op, input, output) 2532 req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 2533 return 2534} 2535 2536// PutModel API operation for Amazon Fraud Detector. 2537// 2538// Creates or updates a model. 2539// 2540// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2541// with awserr.Error's Code and Message methods to get detailed information about 2542// the error. 2543// 2544// See the AWS API reference guide for Amazon Fraud Detector's 2545// API operation PutModel for usage and error information. 2546// 2547// Returned Error Types: 2548// * ValidationException 2549// An exception indicating a specified value is not allowed. 2550// 2551// * InternalServerException 2552// An exception indicating an internal server error. 2553// 2554// * ThrottlingException 2555// An exception indicating a throttling error. 2556// 2557// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/PutModel 2558func (c *FraudDetector) PutModel(input *PutModelInput) (*PutModelOutput, error) { 2559 req, out := c.PutModelRequest(input) 2560 return out, req.Send() 2561} 2562 2563// PutModelWithContext is the same as PutModel with the addition of 2564// the ability to pass a context and additional request options. 2565// 2566// See PutModel for details on how to use this API operation. 2567// 2568// The context must be non-nil and will be used for request cancellation. If 2569// the context is nil a panic will occur. In the future the SDK may create 2570// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2571// for more information on using Contexts. 2572func (c *FraudDetector) PutModelWithContext(ctx aws.Context, input *PutModelInput, opts ...request.Option) (*PutModelOutput, error) { 2573 req, out := c.PutModelRequest(input) 2574 req.SetContext(ctx) 2575 req.ApplyOptions(opts...) 2576 return out, req.Send() 2577} 2578 2579const opPutOutcome = "PutOutcome" 2580 2581// PutOutcomeRequest generates a "aws/request.Request" representing the 2582// client's request for the PutOutcome operation. The "output" return 2583// value will be populated with the request's response once the request completes 2584// successfully. 2585// 2586// Use "Send" method on the returned Request to send the API call to the service. 2587// the "output" return value is not valid until after Send returns without error. 2588// 2589// See PutOutcome for more information on using the PutOutcome 2590// API call, and error handling. 2591// 2592// This method is useful when you want to inject custom logic or configuration 2593// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2594// 2595// 2596// // Example sending a request using the PutOutcomeRequest method. 2597// req, resp := client.PutOutcomeRequest(params) 2598// 2599// err := req.Send() 2600// if err == nil { // resp is now filled 2601// fmt.Println(resp) 2602// } 2603// 2604// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/PutOutcome 2605func (c *FraudDetector) PutOutcomeRequest(input *PutOutcomeInput) (req *request.Request, output *PutOutcomeOutput) { 2606 op := &request.Operation{ 2607 Name: opPutOutcome, 2608 HTTPMethod: "POST", 2609 HTTPPath: "/", 2610 } 2611 2612 if input == nil { 2613 input = &PutOutcomeInput{} 2614 } 2615 2616 output = &PutOutcomeOutput{} 2617 req = c.newRequest(op, input, output) 2618 req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 2619 return 2620} 2621 2622// PutOutcome API operation for Amazon Fraud Detector. 2623// 2624// Creates or updates an outcome. 2625// 2626// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2627// with awserr.Error's Code and Message methods to get detailed information about 2628// the error. 2629// 2630// See the AWS API reference guide for Amazon Fraud Detector's 2631// API operation PutOutcome for usage and error information. 2632// 2633// Returned Error Types: 2634// * ValidationException 2635// An exception indicating a specified value is not allowed. 2636// 2637// * InternalServerException 2638// An exception indicating an internal server error. 2639// 2640// * ThrottlingException 2641// An exception indicating a throttling error. 2642// 2643// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/PutOutcome 2644func (c *FraudDetector) PutOutcome(input *PutOutcomeInput) (*PutOutcomeOutput, error) { 2645 req, out := c.PutOutcomeRequest(input) 2646 return out, req.Send() 2647} 2648 2649// PutOutcomeWithContext is the same as PutOutcome with the addition of 2650// the ability to pass a context and additional request options. 2651// 2652// See PutOutcome for details on how to use this API operation. 2653// 2654// The context must be non-nil and will be used for request cancellation. If 2655// the context is nil a panic will occur. In the future the SDK may create 2656// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2657// for more information on using Contexts. 2658func (c *FraudDetector) PutOutcomeWithContext(ctx aws.Context, input *PutOutcomeInput, opts ...request.Option) (*PutOutcomeOutput, error) { 2659 req, out := c.PutOutcomeRequest(input) 2660 req.SetContext(ctx) 2661 req.ApplyOptions(opts...) 2662 return out, req.Send() 2663} 2664 2665const opUpdateDetectorVersion = "UpdateDetectorVersion" 2666 2667// UpdateDetectorVersionRequest generates a "aws/request.Request" representing the 2668// client's request for the UpdateDetectorVersion operation. The "output" return 2669// value will be populated with the request's response once the request completes 2670// successfully. 2671// 2672// Use "Send" method on the returned Request to send the API call to the service. 2673// the "output" return value is not valid until after Send returns without error. 2674// 2675// See UpdateDetectorVersion for more information on using the UpdateDetectorVersion 2676// API call, and error handling. 2677// 2678// This method is useful when you want to inject custom logic or configuration 2679// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2680// 2681// 2682// // Example sending a request using the UpdateDetectorVersionRequest method. 2683// req, resp := client.UpdateDetectorVersionRequest(params) 2684// 2685// err := req.Send() 2686// if err == nil { // resp is now filled 2687// fmt.Println(resp) 2688// } 2689// 2690// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/UpdateDetectorVersion 2691func (c *FraudDetector) UpdateDetectorVersionRequest(input *UpdateDetectorVersionInput) (req *request.Request, output *UpdateDetectorVersionOutput) { 2692 op := &request.Operation{ 2693 Name: opUpdateDetectorVersion, 2694 HTTPMethod: "POST", 2695 HTTPPath: "/", 2696 } 2697 2698 if input == nil { 2699 input = &UpdateDetectorVersionInput{} 2700 } 2701 2702 output = &UpdateDetectorVersionOutput{} 2703 req = c.newRequest(op, input, output) 2704 req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 2705 return 2706} 2707 2708// UpdateDetectorVersion API operation for Amazon Fraud Detector. 2709// 2710// Updates a detector version. The detector version attributes that you can 2711// update include models, external model endpoints, rules, and description. 2712// You can only update a DRAFT detector version. 2713// 2714// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2715// with awserr.Error's Code and Message methods to get detailed information about 2716// the error. 2717// 2718// See the AWS API reference guide for Amazon Fraud Detector's 2719// API operation UpdateDetectorVersion for usage and error information. 2720// 2721// Returned Error Types: 2722// * ValidationException 2723// An exception indicating a specified value is not allowed. 2724// 2725// * ResourceNotFoundException 2726// An exception indicating the specified resource was not found. 2727// 2728// * InternalServerException 2729// An exception indicating an internal server error. 2730// 2731// * ThrottlingException 2732// An exception indicating a throttling error. 2733// 2734// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/UpdateDetectorVersion 2735func (c *FraudDetector) UpdateDetectorVersion(input *UpdateDetectorVersionInput) (*UpdateDetectorVersionOutput, error) { 2736 req, out := c.UpdateDetectorVersionRequest(input) 2737 return out, req.Send() 2738} 2739 2740// UpdateDetectorVersionWithContext is the same as UpdateDetectorVersion with the addition of 2741// the ability to pass a context and additional request options. 2742// 2743// See UpdateDetectorVersion for details on how to use this API operation. 2744// 2745// The context must be non-nil and will be used for request cancellation. If 2746// the context is nil a panic will occur. In the future the SDK may create 2747// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2748// for more information on using Contexts. 2749func (c *FraudDetector) UpdateDetectorVersionWithContext(ctx aws.Context, input *UpdateDetectorVersionInput, opts ...request.Option) (*UpdateDetectorVersionOutput, error) { 2750 req, out := c.UpdateDetectorVersionRequest(input) 2751 req.SetContext(ctx) 2752 req.ApplyOptions(opts...) 2753 return out, req.Send() 2754} 2755 2756const opUpdateDetectorVersionMetadata = "UpdateDetectorVersionMetadata" 2757 2758// UpdateDetectorVersionMetadataRequest generates a "aws/request.Request" representing the 2759// client's request for the UpdateDetectorVersionMetadata operation. The "output" return 2760// value will be populated with the request's response once the request completes 2761// successfully. 2762// 2763// Use "Send" method on the returned Request to send the API call to the service. 2764// the "output" return value is not valid until after Send returns without error. 2765// 2766// See UpdateDetectorVersionMetadata for more information on using the UpdateDetectorVersionMetadata 2767// API call, and error handling. 2768// 2769// This method is useful when you want to inject custom logic or configuration 2770// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2771// 2772// 2773// // Example sending a request using the UpdateDetectorVersionMetadataRequest method. 2774// req, resp := client.UpdateDetectorVersionMetadataRequest(params) 2775// 2776// err := req.Send() 2777// if err == nil { // resp is now filled 2778// fmt.Println(resp) 2779// } 2780// 2781// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/UpdateDetectorVersionMetadata 2782func (c *FraudDetector) UpdateDetectorVersionMetadataRequest(input *UpdateDetectorVersionMetadataInput) (req *request.Request, output *UpdateDetectorVersionMetadataOutput) { 2783 op := &request.Operation{ 2784 Name: opUpdateDetectorVersionMetadata, 2785 HTTPMethod: "POST", 2786 HTTPPath: "/", 2787 } 2788 2789 if input == nil { 2790 input = &UpdateDetectorVersionMetadataInput{} 2791 } 2792 2793 output = &UpdateDetectorVersionMetadataOutput{} 2794 req = c.newRequest(op, input, output) 2795 req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 2796 return 2797} 2798 2799// UpdateDetectorVersionMetadata API operation for Amazon Fraud Detector. 2800// 2801// Updates the detector version's description. You can update the metadata for 2802// any detector version (DRAFT, ACTIVE, or INACTIVE). 2803// 2804// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2805// with awserr.Error's Code and Message methods to get detailed information about 2806// the error. 2807// 2808// See the AWS API reference guide for Amazon Fraud Detector's 2809// API operation UpdateDetectorVersionMetadata for usage and error information. 2810// 2811// Returned Error Types: 2812// * ValidationException 2813// An exception indicating a specified value is not allowed. 2814// 2815// * InternalServerException 2816// An exception indicating an internal server error. 2817// 2818// * ThrottlingException 2819// An exception indicating a throttling error. 2820// 2821// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/UpdateDetectorVersionMetadata 2822func (c *FraudDetector) UpdateDetectorVersionMetadata(input *UpdateDetectorVersionMetadataInput) (*UpdateDetectorVersionMetadataOutput, error) { 2823 req, out := c.UpdateDetectorVersionMetadataRequest(input) 2824 return out, req.Send() 2825} 2826 2827// UpdateDetectorVersionMetadataWithContext is the same as UpdateDetectorVersionMetadata with the addition of 2828// the ability to pass a context and additional request options. 2829// 2830// See UpdateDetectorVersionMetadata for details on how to use this API operation. 2831// 2832// The context must be non-nil and will be used for request cancellation. If 2833// the context is nil a panic will occur. In the future the SDK may create 2834// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2835// for more information on using Contexts. 2836func (c *FraudDetector) UpdateDetectorVersionMetadataWithContext(ctx aws.Context, input *UpdateDetectorVersionMetadataInput, opts ...request.Option) (*UpdateDetectorVersionMetadataOutput, error) { 2837 req, out := c.UpdateDetectorVersionMetadataRequest(input) 2838 req.SetContext(ctx) 2839 req.ApplyOptions(opts...) 2840 return out, req.Send() 2841} 2842 2843const opUpdateDetectorVersionStatus = "UpdateDetectorVersionStatus" 2844 2845// UpdateDetectorVersionStatusRequest generates a "aws/request.Request" representing the 2846// client's request for the UpdateDetectorVersionStatus operation. The "output" return 2847// value will be populated with the request's response once the request completes 2848// successfully. 2849// 2850// Use "Send" method on the returned Request to send the API call to the service. 2851// the "output" return value is not valid until after Send returns without error. 2852// 2853// See UpdateDetectorVersionStatus for more information on using the UpdateDetectorVersionStatus 2854// API call, and error handling. 2855// 2856// This method is useful when you want to inject custom logic or configuration 2857// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2858// 2859// 2860// // Example sending a request using the UpdateDetectorVersionStatusRequest method. 2861// req, resp := client.UpdateDetectorVersionStatusRequest(params) 2862// 2863// err := req.Send() 2864// if err == nil { // resp is now filled 2865// fmt.Println(resp) 2866// } 2867// 2868// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/UpdateDetectorVersionStatus 2869func (c *FraudDetector) UpdateDetectorVersionStatusRequest(input *UpdateDetectorVersionStatusInput) (req *request.Request, output *UpdateDetectorVersionStatusOutput) { 2870 op := &request.Operation{ 2871 Name: opUpdateDetectorVersionStatus, 2872 HTTPMethod: "POST", 2873 HTTPPath: "/", 2874 } 2875 2876 if input == nil { 2877 input = &UpdateDetectorVersionStatusInput{} 2878 } 2879 2880 output = &UpdateDetectorVersionStatusOutput{} 2881 req = c.newRequest(op, input, output) 2882 req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 2883 return 2884} 2885 2886// UpdateDetectorVersionStatus API operation for Amazon Fraud Detector. 2887// 2888// Updates the detector version’s status. You can perform the following promotions 2889// or demotions using UpdateDetectorVersionStatus: DRAFT to ACTIVE, ACTIVE to 2890// INACTIVE, and INACTIVE to ACTIVE. 2891// 2892// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2893// with awserr.Error's Code and Message methods to get detailed information about 2894// the error. 2895// 2896// See the AWS API reference guide for Amazon Fraud Detector's 2897// API operation UpdateDetectorVersionStatus for usage and error information. 2898// 2899// Returned Error Types: 2900// * ValidationException 2901// An exception indicating a specified value is not allowed. 2902// 2903// * ResourceNotFoundException 2904// An exception indicating the specified resource was not found. 2905// 2906// * InternalServerException 2907// An exception indicating an internal server error. 2908// 2909// * ThrottlingException 2910// An exception indicating a throttling error. 2911// 2912// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/UpdateDetectorVersionStatus 2913func (c *FraudDetector) UpdateDetectorVersionStatus(input *UpdateDetectorVersionStatusInput) (*UpdateDetectorVersionStatusOutput, error) { 2914 req, out := c.UpdateDetectorVersionStatusRequest(input) 2915 return out, req.Send() 2916} 2917 2918// UpdateDetectorVersionStatusWithContext is the same as UpdateDetectorVersionStatus with the addition of 2919// the ability to pass a context and additional request options. 2920// 2921// See UpdateDetectorVersionStatus for details on how to use this API operation. 2922// 2923// The context must be non-nil and will be used for request cancellation. If 2924// the context is nil a panic will occur. In the future the SDK may create 2925// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 2926// for more information on using Contexts. 2927func (c *FraudDetector) UpdateDetectorVersionStatusWithContext(ctx aws.Context, input *UpdateDetectorVersionStatusInput, opts ...request.Option) (*UpdateDetectorVersionStatusOutput, error) { 2928 req, out := c.UpdateDetectorVersionStatusRequest(input) 2929 req.SetContext(ctx) 2930 req.ApplyOptions(opts...) 2931 return out, req.Send() 2932} 2933 2934const opUpdateModelVersion = "UpdateModelVersion" 2935 2936// UpdateModelVersionRequest generates a "aws/request.Request" representing the 2937// client's request for the UpdateModelVersion operation. The "output" return 2938// value will be populated with the request's response once the request completes 2939// successfully. 2940// 2941// Use "Send" method on the returned Request to send the API call to the service. 2942// the "output" return value is not valid until after Send returns without error. 2943// 2944// See UpdateModelVersion for more information on using the UpdateModelVersion 2945// API call, and error handling. 2946// 2947// This method is useful when you want to inject custom logic or configuration 2948// into the SDK's request lifecycle. Such as custom headers, or retry logic. 2949// 2950// 2951// // Example sending a request using the UpdateModelVersionRequest method. 2952// req, resp := client.UpdateModelVersionRequest(params) 2953// 2954// err := req.Send() 2955// if err == nil { // resp is now filled 2956// fmt.Println(resp) 2957// } 2958// 2959// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/UpdateModelVersion 2960func (c *FraudDetector) UpdateModelVersionRequest(input *UpdateModelVersionInput) (req *request.Request, output *UpdateModelVersionOutput) { 2961 op := &request.Operation{ 2962 Name: opUpdateModelVersion, 2963 HTTPMethod: "POST", 2964 HTTPPath: "/", 2965 } 2966 2967 if input == nil { 2968 input = &UpdateModelVersionInput{} 2969 } 2970 2971 output = &UpdateModelVersionOutput{} 2972 req = c.newRequest(op, input, output) 2973 req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 2974 return 2975} 2976 2977// UpdateModelVersion API operation for Amazon Fraud Detector. 2978// 2979// Updates a model version. You can update the description and status attributes 2980// using this action. You can perform the following status updates: 2981// 2982// Change the TRAINING_COMPLETE status to ACTIVE 2983// 2984// Change ACTIVE back to TRAINING_COMPLETE 2985// 2986// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 2987// with awserr.Error's Code and Message methods to get detailed information about 2988// the error. 2989// 2990// See the AWS API reference guide for Amazon Fraud Detector's 2991// API operation UpdateModelVersion for usage and error information. 2992// 2993// Returned Error Types: 2994// * ValidationException 2995// An exception indicating a specified value is not allowed. 2996// 2997// * ResourceNotFoundException 2998// An exception indicating the specified resource was not found. 2999// 3000// * InternalServerException 3001// An exception indicating an internal server error. 3002// 3003// * ThrottlingException 3004// An exception indicating a throttling error. 3005// 3006// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/UpdateModelVersion 3007func (c *FraudDetector) UpdateModelVersion(input *UpdateModelVersionInput) (*UpdateModelVersionOutput, error) { 3008 req, out := c.UpdateModelVersionRequest(input) 3009 return out, req.Send() 3010} 3011 3012// UpdateModelVersionWithContext is the same as UpdateModelVersion with the addition of 3013// the ability to pass a context and additional request options. 3014// 3015// See UpdateModelVersion for details on how to use this API operation. 3016// 3017// The context must be non-nil and will be used for request cancellation. If 3018// the context is nil a panic will occur. In the future the SDK may create 3019// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 3020// for more information on using Contexts. 3021func (c *FraudDetector) UpdateModelVersionWithContext(ctx aws.Context, input *UpdateModelVersionInput, opts ...request.Option) (*UpdateModelVersionOutput, error) { 3022 req, out := c.UpdateModelVersionRequest(input) 3023 req.SetContext(ctx) 3024 req.ApplyOptions(opts...) 3025 return out, req.Send() 3026} 3027 3028const opUpdateRuleMetadata = "UpdateRuleMetadata" 3029 3030// UpdateRuleMetadataRequest generates a "aws/request.Request" representing the 3031// client's request for the UpdateRuleMetadata operation. The "output" return 3032// value will be populated with the request's response once the request completes 3033// successfully. 3034// 3035// Use "Send" method on the returned Request to send the API call to the service. 3036// the "output" return value is not valid until after Send returns without error. 3037// 3038// See UpdateRuleMetadata for more information on using the UpdateRuleMetadata 3039// API call, and error handling. 3040// 3041// This method is useful when you want to inject custom logic or configuration 3042// into the SDK's request lifecycle. Such as custom headers, or retry logic. 3043// 3044// 3045// // Example sending a request using the UpdateRuleMetadataRequest method. 3046// req, resp := client.UpdateRuleMetadataRequest(params) 3047// 3048// err := req.Send() 3049// if err == nil { // resp is now filled 3050// fmt.Println(resp) 3051// } 3052// 3053// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/UpdateRuleMetadata 3054func (c *FraudDetector) UpdateRuleMetadataRequest(input *UpdateRuleMetadataInput) (req *request.Request, output *UpdateRuleMetadataOutput) { 3055 op := &request.Operation{ 3056 Name: opUpdateRuleMetadata, 3057 HTTPMethod: "POST", 3058 HTTPPath: "/", 3059 } 3060 3061 if input == nil { 3062 input = &UpdateRuleMetadataInput{} 3063 } 3064 3065 output = &UpdateRuleMetadataOutput{} 3066 req = c.newRequest(op, input, output) 3067 req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 3068 return 3069} 3070 3071// UpdateRuleMetadata API operation for Amazon Fraud Detector. 3072// 3073// Updates a rule's metadata. 3074// 3075// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 3076// with awserr.Error's Code and Message methods to get detailed information about 3077// the error. 3078// 3079// See the AWS API reference guide for Amazon Fraud Detector's 3080// API operation UpdateRuleMetadata for usage and error information. 3081// 3082// Returned Error Types: 3083// * ValidationException 3084// An exception indicating a specified value is not allowed. 3085// 3086// * ResourceNotFoundException 3087// An exception indicating the specified resource was not found. 3088// 3089// * InternalServerException 3090// An exception indicating an internal server error. 3091// 3092// * ThrottlingException 3093// An exception indicating a throttling error. 3094// 3095// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/UpdateRuleMetadata 3096func (c *FraudDetector) UpdateRuleMetadata(input *UpdateRuleMetadataInput) (*UpdateRuleMetadataOutput, error) { 3097 req, out := c.UpdateRuleMetadataRequest(input) 3098 return out, req.Send() 3099} 3100 3101// UpdateRuleMetadataWithContext is the same as UpdateRuleMetadata with the addition of 3102// the ability to pass a context and additional request options. 3103// 3104// See UpdateRuleMetadata for details on how to use this API operation. 3105// 3106// The context must be non-nil and will be used for request cancellation. If 3107// the context is nil a panic will occur. In the future the SDK may create 3108// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 3109// for more information on using Contexts. 3110func (c *FraudDetector) UpdateRuleMetadataWithContext(ctx aws.Context, input *UpdateRuleMetadataInput, opts ...request.Option) (*UpdateRuleMetadataOutput, error) { 3111 req, out := c.UpdateRuleMetadataRequest(input) 3112 req.SetContext(ctx) 3113 req.ApplyOptions(opts...) 3114 return out, req.Send() 3115} 3116 3117const opUpdateRuleVersion = "UpdateRuleVersion" 3118 3119// UpdateRuleVersionRequest generates a "aws/request.Request" representing the 3120// client's request for the UpdateRuleVersion operation. The "output" return 3121// value will be populated with the request's response once the request completes 3122// successfully. 3123// 3124// Use "Send" method on the returned Request to send the API call to the service. 3125// the "output" return value is not valid until after Send returns without error. 3126// 3127// See UpdateRuleVersion for more information on using the UpdateRuleVersion 3128// API call, and error handling. 3129// 3130// This method is useful when you want to inject custom logic or configuration 3131// into the SDK's request lifecycle. Such as custom headers, or retry logic. 3132// 3133// 3134// // Example sending a request using the UpdateRuleVersionRequest method. 3135// req, resp := client.UpdateRuleVersionRequest(params) 3136// 3137// err := req.Send() 3138// if err == nil { // resp is now filled 3139// fmt.Println(resp) 3140// } 3141// 3142// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/UpdateRuleVersion 3143func (c *FraudDetector) UpdateRuleVersionRequest(input *UpdateRuleVersionInput) (req *request.Request, output *UpdateRuleVersionOutput) { 3144 op := &request.Operation{ 3145 Name: opUpdateRuleVersion, 3146 HTTPMethod: "POST", 3147 HTTPPath: "/", 3148 } 3149 3150 if input == nil { 3151 input = &UpdateRuleVersionInput{} 3152 } 3153 3154 output = &UpdateRuleVersionOutput{} 3155 req = c.newRequest(op, input, output) 3156 return 3157} 3158 3159// UpdateRuleVersion API operation for Amazon Fraud Detector. 3160// 3161// Updates a rule version resulting in a new rule version. 3162// 3163// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 3164// with awserr.Error's Code and Message methods to get detailed information about 3165// the error. 3166// 3167// See the AWS API reference guide for Amazon Fraud Detector's 3168// API operation UpdateRuleVersion for usage and error information. 3169// 3170// Returned Error Types: 3171// * ValidationException 3172// An exception indicating a specified value is not allowed. 3173// 3174// * ResourceNotFoundException 3175// An exception indicating the specified resource was not found. 3176// 3177// * InternalServerException 3178// An exception indicating an internal server error. 3179// 3180// * ThrottlingException 3181// An exception indicating a throttling error. 3182// 3183// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/UpdateRuleVersion 3184func (c *FraudDetector) UpdateRuleVersion(input *UpdateRuleVersionInput) (*UpdateRuleVersionOutput, error) { 3185 req, out := c.UpdateRuleVersionRequest(input) 3186 return out, req.Send() 3187} 3188 3189// UpdateRuleVersionWithContext is the same as UpdateRuleVersion with the addition of 3190// the ability to pass a context and additional request options. 3191// 3192// See UpdateRuleVersion for details on how to use this API operation. 3193// 3194// The context must be non-nil and will be used for request cancellation. If 3195// the context is nil a panic will occur. In the future the SDK may create 3196// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 3197// for more information on using Contexts. 3198func (c *FraudDetector) UpdateRuleVersionWithContext(ctx aws.Context, input *UpdateRuleVersionInput, opts ...request.Option) (*UpdateRuleVersionOutput, error) { 3199 req, out := c.UpdateRuleVersionRequest(input) 3200 req.SetContext(ctx) 3201 req.ApplyOptions(opts...) 3202 return out, req.Send() 3203} 3204 3205const opUpdateVariable = "UpdateVariable" 3206 3207// UpdateVariableRequest generates a "aws/request.Request" representing the 3208// client's request for the UpdateVariable operation. The "output" return 3209// value will be populated with the request's response once the request completes 3210// successfully. 3211// 3212// Use "Send" method on the returned Request to send the API call to the service. 3213// the "output" return value is not valid until after Send returns without error. 3214// 3215// See UpdateVariable for more information on using the UpdateVariable 3216// API call, and error handling. 3217// 3218// This method is useful when you want to inject custom logic or configuration 3219// into the SDK's request lifecycle. Such as custom headers, or retry logic. 3220// 3221// 3222// // Example sending a request using the UpdateVariableRequest method. 3223// req, resp := client.UpdateVariableRequest(params) 3224// 3225// err := req.Send() 3226// if err == nil { // resp is now filled 3227// fmt.Println(resp) 3228// } 3229// 3230// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/UpdateVariable 3231func (c *FraudDetector) UpdateVariableRequest(input *UpdateVariableInput) (req *request.Request, output *UpdateVariableOutput) { 3232 op := &request.Operation{ 3233 Name: opUpdateVariable, 3234 HTTPMethod: "POST", 3235 HTTPPath: "/", 3236 } 3237 3238 if input == nil { 3239 input = &UpdateVariableInput{} 3240 } 3241 3242 output = &UpdateVariableOutput{} 3243 req = c.newRequest(op, input, output) 3244 req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) 3245 return 3246} 3247 3248// UpdateVariable API operation for Amazon Fraud Detector. 3249// 3250// Updates a variable. 3251// 3252// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 3253// with awserr.Error's Code and Message methods to get detailed information about 3254// the error. 3255// 3256// See the AWS API reference guide for Amazon Fraud Detector's 3257// API operation UpdateVariable for usage and error information. 3258// 3259// Returned Error Types: 3260// * ValidationException 3261// An exception indicating a specified value is not allowed. 3262// 3263// * ResourceNotFoundException 3264// An exception indicating the specified resource was not found. 3265// 3266// * InternalServerException 3267// An exception indicating an internal server error. 3268// 3269// * ThrottlingException 3270// An exception indicating a throttling error. 3271// 3272// See also, https://docs.aws.amazon.com/goto/WebAPI/frauddetector-2019-11-15/UpdateVariable 3273func (c *FraudDetector) UpdateVariable(input *UpdateVariableInput) (*UpdateVariableOutput, error) { 3274 req, out := c.UpdateVariableRequest(input) 3275 return out, req.Send() 3276} 3277 3278// UpdateVariableWithContext is the same as UpdateVariable with the addition of 3279// the ability to pass a context and additional request options. 3280// 3281// See UpdateVariable for details on how to use this API operation. 3282// 3283// The context must be non-nil and will be used for request cancellation. If 3284// the context is nil a panic will occur. In the future the SDK may create 3285// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 3286// for more information on using Contexts. 3287func (c *FraudDetector) UpdateVariableWithContext(ctx aws.Context, input *UpdateVariableInput, opts ...request.Option) (*UpdateVariableOutput, error) { 3288 req, out := c.UpdateVariableRequest(input) 3289 req.SetContext(ctx) 3290 req.ApplyOptions(opts...) 3291 return out, req.Send() 3292} 3293 3294// Provides the error of the batch create variable API. 3295type BatchCreateVariableError struct { 3296 _ struct{} `type:"structure"` 3297 3298 // The error code. 3299 Code *int64 `locationName:"code" type:"integer"` 3300 3301 // The error message. 3302 Message *string `locationName:"message" type:"string"` 3303 3304 // The name. 3305 Name *string `locationName:"name" type:"string"` 3306} 3307 3308// String returns the string representation 3309func (s BatchCreateVariableError) String() string { 3310 return awsutil.Prettify(s) 3311} 3312 3313// GoString returns the string representation 3314func (s BatchCreateVariableError) GoString() string { 3315 return s.String() 3316} 3317 3318// SetCode sets the Code field's value. 3319func (s *BatchCreateVariableError) SetCode(v int64) *BatchCreateVariableError { 3320 s.Code = &v 3321 return s 3322} 3323 3324// SetMessage sets the Message field's value. 3325func (s *BatchCreateVariableError) SetMessage(v string) *BatchCreateVariableError { 3326 s.Message = &v 3327 return s 3328} 3329 3330// SetName sets the Name field's value. 3331func (s *BatchCreateVariableError) SetName(v string) *BatchCreateVariableError { 3332 s.Name = &v 3333 return s 3334} 3335 3336type BatchCreateVariableInput struct { 3337 _ struct{} `type:"structure"` 3338 3339 // The list of variables for the batch create variable request. 3340 // 3341 // VariableEntries is a required field 3342 VariableEntries []*VariableEntry `locationName:"variableEntries" min:"1" type:"list" required:"true"` 3343} 3344 3345// String returns the string representation 3346func (s BatchCreateVariableInput) String() string { 3347 return awsutil.Prettify(s) 3348} 3349 3350// GoString returns the string representation 3351func (s BatchCreateVariableInput) GoString() string { 3352 return s.String() 3353} 3354 3355// Validate inspects the fields of the type to determine if they are valid. 3356func (s *BatchCreateVariableInput) Validate() error { 3357 invalidParams := request.ErrInvalidParams{Context: "BatchCreateVariableInput"} 3358 if s.VariableEntries == nil { 3359 invalidParams.Add(request.NewErrParamRequired("VariableEntries")) 3360 } 3361 if s.VariableEntries != nil && len(s.VariableEntries) < 1 { 3362 invalidParams.Add(request.NewErrParamMinLen("VariableEntries", 1)) 3363 } 3364 3365 if invalidParams.Len() > 0 { 3366 return invalidParams 3367 } 3368 return nil 3369} 3370 3371// SetVariableEntries sets the VariableEntries field's value. 3372func (s *BatchCreateVariableInput) SetVariableEntries(v []*VariableEntry) *BatchCreateVariableInput { 3373 s.VariableEntries = v 3374 return s 3375} 3376 3377type BatchCreateVariableOutput struct { 3378 _ struct{} `type:"structure"` 3379 3380 // Provides the errors for the BatchCreateVariable request. 3381 Errors []*BatchCreateVariableError `locationName:"errors" type:"list"` 3382} 3383 3384// String returns the string representation 3385func (s BatchCreateVariableOutput) String() string { 3386 return awsutil.Prettify(s) 3387} 3388 3389// GoString returns the string representation 3390func (s BatchCreateVariableOutput) GoString() string { 3391 return s.String() 3392} 3393 3394// SetErrors sets the Errors field's value. 3395func (s *BatchCreateVariableOutput) SetErrors(v []*BatchCreateVariableError) *BatchCreateVariableOutput { 3396 s.Errors = v 3397 return s 3398} 3399 3400// Provides the error of the batch get variable API. 3401type BatchGetVariableError struct { 3402 _ struct{} `type:"structure"` 3403 3404 // The error code. 3405 Code *int64 `locationName:"code" type:"integer"` 3406 3407 // The error message. 3408 Message *string `locationName:"message" type:"string"` 3409 3410 // The error name. 3411 Name *string `locationName:"name" type:"string"` 3412} 3413 3414// String returns the string representation 3415func (s BatchGetVariableError) String() string { 3416 return awsutil.Prettify(s) 3417} 3418 3419// GoString returns the string representation 3420func (s BatchGetVariableError) GoString() string { 3421 return s.String() 3422} 3423 3424// SetCode sets the Code field's value. 3425func (s *BatchGetVariableError) SetCode(v int64) *BatchGetVariableError { 3426 s.Code = &v 3427 return s 3428} 3429 3430// SetMessage sets the Message field's value. 3431func (s *BatchGetVariableError) SetMessage(v string) *BatchGetVariableError { 3432 s.Message = &v 3433 return s 3434} 3435 3436// SetName sets the Name field's value. 3437func (s *BatchGetVariableError) SetName(v string) *BatchGetVariableError { 3438 s.Name = &v 3439 return s 3440} 3441 3442type BatchGetVariableInput struct { 3443 _ struct{} `type:"structure"` 3444 3445 // The list of variable names to get. 3446 // 3447 // Names is a required field 3448 Names []*string `locationName:"names" min:"1" type:"list" required:"true"` 3449} 3450 3451// String returns the string representation 3452func (s BatchGetVariableInput) String() string { 3453 return awsutil.Prettify(s) 3454} 3455 3456// GoString returns the string representation 3457func (s BatchGetVariableInput) GoString() string { 3458 return s.String() 3459} 3460 3461// Validate inspects the fields of the type to determine if they are valid. 3462func (s *BatchGetVariableInput) Validate() error { 3463 invalidParams := request.ErrInvalidParams{Context: "BatchGetVariableInput"} 3464 if s.Names == nil { 3465 invalidParams.Add(request.NewErrParamRequired("Names")) 3466 } 3467 if s.Names != nil && len(s.Names) < 1 { 3468 invalidParams.Add(request.NewErrParamMinLen("Names", 1)) 3469 } 3470 3471 if invalidParams.Len() > 0 { 3472 return invalidParams 3473 } 3474 return nil 3475} 3476 3477// SetNames sets the Names field's value. 3478func (s *BatchGetVariableInput) SetNames(v []*string) *BatchGetVariableInput { 3479 s.Names = v 3480 return s 3481} 3482 3483type BatchGetVariableOutput struct { 3484 _ struct{} `type:"structure"` 3485 3486 // The errors from the request. 3487 Errors []*BatchGetVariableError `locationName:"errors" type:"list"` 3488 3489 // The returned variables. 3490 Variables []*Variable `locationName:"variables" type:"list"` 3491} 3492 3493// String returns the string representation 3494func (s BatchGetVariableOutput) String() string { 3495 return awsutil.Prettify(s) 3496} 3497 3498// GoString returns the string representation 3499func (s BatchGetVariableOutput) GoString() string { 3500 return s.String() 3501} 3502 3503// SetErrors sets the Errors field's value. 3504func (s *BatchGetVariableOutput) SetErrors(v []*BatchGetVariableError) *BatchGetVariableOutput { 3505 s.Errors = v 3506 return s 3507} 3508 3509// SetVariables sets the Variables field's value. 3510func (s *BatchGetVariableOutput) SetVariables(v []*Variable) *BatchGetVariableOutput { 3511 s.Variables = v 3512 return s 3513} 3514 3515// An exception indicating there was a conflict during a delete operation. The 3516// following delete operations can cause a conflict exception: 3517// 3518// * DeleteDetector: A conflict exception will occur if the detector has 3519// associated Rules or DetectorVersions. You can only delete a detector if 3520// it has no Rules or DetectorVersions. 3521// 3522// * DeleteDetectorVersion: A conflict exception will occur if the DetectorVersion 3523// status is ACTIVE. 3524// 3525// * DeleteRuleVersion: A conflict exception will occur if the RuleVersion 3526// is in use by an associated ACTIVE or INACTIVE DetectorVersion. 3527type ConflictException struct { 3528 _ struct{} `type:"structure"` 3529 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 3530 3531 Message_ *string `locationName:"message" type:"string"` 3532} 3533 3534// String returns the string representation 3535func (s ConflictException) String() string { 3536 return awsutil.Prettify(s) 3537} 3538 3539// GoString returns the string representation 3540func (s ConflictException) GoString() string { 3541 return s.String() 3542} 3543 3544func newErrorConflictException(v protocol.ResponseMetadata) error { 3545 return &ConflictException{ 3546 RespMetadata: v, 3547 } 3548} 3549 3550// Code returns the exception type name. 3551func (s *ConflictException) Code() string { 3552 return "ConflictException" 3553} 3554 3555// Message returns the exception's message. 3556func (s *ConflictException) Message() string { 3557 if s.Message_ != nil { 3558 return *s.Message_ 3559 } 3560 return "" 3561} 3562 3563// OrigErr always returns nil, satisfies awserr.Error interface. 3564func (s *ConflictException) OrigErr() error { 3565 return nil 3566} 3567 3568func (s *ConflictException) Error() string { 3569 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 3570} 3571 3572// Status code returns the HTTP status code for the request's response error. 3573func (s *ConflictException) StatusCode() int { 3574 return s.RespMetadata.StatusCode 3575} 3576 3577// RequestID returns the service's response RequestID for request. 3578func (s *ConflictException) RequestID() string { 3579 return s.RespMetadata.RequestID 3580} 3581 3582type CreateDetectorVersionInput struct { 3583 _ struct{} `type:"structure"` 3584 3585 // The description of the detector version. 3586 Description *string `locationName:"description" min:"1" type:"string"` 3587 3588 // The ID of the detector under which you want to create a new version. 3589 // 3590 // DetectorId is a required field 3591 DetectorId *string `locationName:"detectorId" min:"1" type:"string" required:"true"` 3592 3593 // The Amazon Sagemaker model endpoints to include in the detector version. 3594 ExternalModelEndpoints []*string `locationName:"externalModelEndpoints" type:"list"` 3595 3596 // The model versions to include in the detector version. 3597 ModelVersions []*ModelVersion `locationName:"modelVersions" type:"list"` 3598 3599 // The rule execution mode for the rules included in the detector version. 3600 // 3601 // You can define and edit the rule mode at the detector version level, when 3602 // it is in draft status. 3603 // 3604 // If you specify FIRST_MATCHED, Amazon Fraud Detector evaluates rules sequentially, 3605 // first to last, stopping at the first matched rule. Amazon Fraud dectector 3606 // then provides the outcomes for that single rule. 3607 // 3608 // If you specifiy ALL_MATCHED, Amazon Fraud Detector evaluates all rules and 3609 // returns the outcomes for all matched rules. 3610 // 3611 // The default behavior is FIRST_MATCHED. 3612 RuleExecutionMode *string `locationName:"ruleExecutionMode" type:"string" enum:"RuleExecutionMode"` 3613 3614 // The rules to include in the detector version. 3615 // 3616 // Rules is a required field 3617 Rules []*Rule `locationName:"rules" type:"list" required:"true"` 3618} 3619 3620// String returns the string representation 3621func (s CreateDetectorVersionInput) String() string { 3622 return awsutil.Prettify(s) 3623} 3624 3625// GoString returns the string representation 3626func (s CreateDetectorVersionInput) GoString() string { 3627 return s.String() 3628} 3629 3630// Validate inspects the fields of the type to determine if they are valid. 3631func (s *CreateDetectorVersionInput) Validate() error { 3632 invalidParams := request.ErrInvalidParams{Context: "CreateDetectorVersionInput"} 3633 if s.Description != nil && len(*s.Description) < 1 { 3634 invalidParams.Add(request.NewErrParamMinLen("Description", 1)) 3635 } 3636 if s.DetectorId == nil { 3637 invalidParams.Add(request.NewErrParamRequired("DetectorId")) 3638 } 3639 if s.DetectorId != nil && len(*s.DetectorId) < 1 { 3640 invalidParams.Add(request.NewErrParamMinLen("DetectorId", 1)) 3641 } 3642 if s.Rules == nil { 3643 invalidParams.Add(request.NewErrParamRequired("Rules")) 3644 } 3645 if s.ModelVersions != nil { 3646 for i, v := range s.ModelVersions { 3647 if v == nil { 3648 continue 3649 } 3650 if err := v.Validate(); err != nil { 3651 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "ModelVersions", i), err.(request.ErrInvalidParams)) 3652 } 3653 } 3654 } 3655 if s.Rules != nil { 3656 for i, v := range s.Rules { 3657 if v == nil { 3658 continue 3659 } 3660 if err := v.Validate(); err != nil { 3661 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Rules", i), err.(request.ErrInvalidParams)) 3662 } 3663 } 3664 } 3665 3666 if invalidParams.Len() > 0 { 3667 return invalidParams 3668 } 3669 return nil 3670} 3671 3672// SetDescription sets the Description field's value. 3673func (s *CreateDetectorVersionInput) SetDescription(v string) *CreateDetectorVersionInput { 3674 s.Description = &v 3675 return s 3676} 3677 3678// SetDetectorId sets the DetectorId field's value. 3679func (s *CreateDetectorVersionInput) SetDetectorId(v string) *CreateDetectorVersionInput { 3680 s.DetectorId = &v 3681 return s 3682} 3683 3684// SetExternalModelEndpoints sets the ExternalModelEndpoints field's value. 3685func (s *CreateDetectorVersionInput) SetExternalModelEndpoints(v []*string) *CreateDetectorVersionInput { 3686 s.ExternalModelEndpoints = v 3687 return s 3688} 3689 3690// SetModelVersions sets the ModelVersions field's value. 3691func (s *CreateDetectorVersionInput) SetModelVersions(v []*ModelVersion) *CreateDetectorVersionInput { 3692 s.ModelVersions = v 3693 return s 3694} 3695 3696// SetRuleExecutionMode sets the RuleExecutionMode field's value. 3697func (s *CreateDetectorVersionInput) SetRuleExecutionMode(v string) *CreateDetectorVersionInput { 3698 s.RuleExecutionMode = &v 3699 return s 3700} 3701 3702// SetRules sets the Rules field's value. 3703func (s *CreateDetectorVersionInput) SetRules(v []*Rule) *CreateDetectorVersionInput { 3704 s.Rules = v 3705 return s 3706} 3707 3708type CreateDetectorVersionOutput struct { 3709 _ struct{} `type:"structure"` 3710 3711 // The ID for the created version's parent detector. 3712 DetectorId *string `locationName:"detectorId" min:"1" type:"string"` 3713 3714 // The ID for the created detector. 3715 DetectorVersionId *string `locationName:"detectorVersionId" min:"1" type:"string"` 3716 3717 // The status of the detector version. 3718 Status *string `locationName:"status" type:"string" enum:"DetectorVersionStatus"` 3719} 3720 3721// String returns the string representation 3722func (s CreateDetectorVersionOutput) String() string { 3723 return awsutil.Prettify(s) 3724} 3725 3726// GoString returns the string representation 3727func (s CreateDetectorVersionOutput) GoString() string { 3728 return s.String() 3729} 3730 3731// SetDetectorId sets the DetectorId field's value. 3732func (s *CreateDetectorVersionOutput) SetDetectorId(v string) *CreateDetectorVersionOutput { 3733 s.DetectorId = &v 3734 return s 3735} 3736 3737// SetDetectorVersionId sets the DetectorVersionId field's value. 3738func (s *CreateDetectorVersionOutput) SetDetectorVersionId(v string) *CreateDetectorVersionOutput { 3739 s.DetectorVersionId = &v 3740 return s 3741} 3742 3743// SetStatus sets the Status field's value. 3744func (s *CreateDetectorVersionOutput) SetStatus(v string) *CreateDetectorVersionOutput { 3745 s.Status = &v 3746 return s 3747} 3748 3749type CreateModelVersionInput struct { 3750 _ struct{} `type:"structure"` 3751 3752 // The model version description. 3753 Description *string `locationName:"description" min:"1" type:"string"` 3754 3755 // The model ID. 3756 // 3757 // ModelId is a required field 3758 ModelId *string `locationName:"modelId" min:"1" type:"string" required:"true"` 3759 3760 // The model type. 3761 // 3762 // ModelType is a required field 3763 ModelType *string `locationName:"modelType" type:"string" required:"true" enum:"ModelTypeEnum"` 3764} 3765 3766// String returns the string representation 3767func (s CreateModelVersionInput) String() string { 3768 return awsutil.Prettify(s) 3769} 3770 3771// GoString returns the string representation 3772func (s CreateModelVersionInput) GoString() string { 3773 return s.String() 3774} 3775 3776// Validate inspects the fields of the type to determine if they are valid. 3777func (s *CreateModelVersionInput) Validate() error { 3778 invalidParams := request.ErrInvalidParams{Context: "CreateModelVersionInput"} 3779 if s.Description != nil && len(*s.Description) < 1 { 3780 invalidParams.Add(request.NewErrParamMinLen("Description", 1)) 3781 } 3782 if s.ModelId == nil { 3783 invalidParams.Add(request.NewErrParamRequired("ModelId")) 3784 } 3785 if s.ModelId != nil && len(*s.ModelId) < 1 { 3786 invalidParams.Add(request.NewErrParamMinLen("ModelId", 1)) 3787 } 3788 if s.ModelType == nil { 3789 invalidParams.Add(request.NewErrParamRequired("ModelType")) 3790 } 3791 3792 if invalidParams.Len() > 0 { 3793 return invalidParams 3794 } 3795 return nil 3796} 3797 3798// SetDescription sets the Description field's value. 3799func (s *CreateModelVersionInput) SetDescription(v string) *CreateModelVersionInput { 3800 s.Description = &v 3801 return s 3802} 3803 3804// SetModelId sets the ModelId field's value. 3805func (s *CreateModelVersionInput) SetModelId(v string) *CreateModelVersionInput { 3806 s.ModelId = &v 3807 return s 3808} 3809 3810// SetModelType sets the ModelType field's value. 3811func (s *CreateModelVersionInput) SetModelType(v string) *CreateModelVersionInput { 3812 s.ModelType = &v 3813 return s 3814} 3815 3816type CreateModelVersionOutput struct { 3817 _ struct{} `type:"structure"` 3818 3819 // The model ID. 3820 ModelId *string `locationName:"modelId" min:"1" type:"string"` 3821 3822 // The model type. 3823 ModelType *string `locationName:"modelType" type:"string" enum:"ModelTypeEnum"` 3824 3825 // The version of the model. 3826 ModelVersionNumber *string `locationName:"modelVersionNumber" min:"1" type:"string"` 3827 3828 // The model version status. 3829 Status *string `locationName:"status" type:"string"` 3830} 3831 3832// String returns the string representation 3833func (s CreateModelVersionOutput) String() string { 3834 return awsutil.Prettify(s) 3835} 3836 3837// GoString returns the string representation 3838func (s CreateModelVersionOutput) GoString() string { 3839 return s.String() 3840} 3841 3842// SetModelId sets the ModelId field's value. 3843func (s *CreateModelVersionOutput) SetModelId(v string) *CreateModelVersionOutput { 3844 s.ModelId = &v 3845 return s 3846} 3847 3848// SetModelType sets the ModelType field's value. 3849func (s *CreateModelVersionOutput) SetModelType(v string) *CreateModelVersionOutput { 3850 s.ModelType = &v 3851 return s 3852} 3853 3854// SetModelVersionNumber sets the ModelVersionNumber field's value. 3855func (s *CreateModelVersionOutput) SetModelVersionNumber(v string) *CreateModelVersionOutput { 3856 s.ModelVersionNumber = &v 3857 return s 3858} 3859 3860// SetStatus sets the Status field's value. 3861func (s *CreateModelVersionOutput) SetStatus(v string) *CreateModelVersionOutput { 3862 s.Status = &v 3863 return s 3864} 3865 3866type CreateRuleInput struct { 3867 _ struct{} `type:"structure"` 3868 3869 // The rule description. 3870 Description *string `locationName:"description" min:"1" type:"string"` 3871 3872 // The detector ID for the rule's parent detector. 3873 // 3874 // DetectorId is a required field 3875 DetectorId *string `locationName:"detectorId" min:"1" type:"string" required:"true"` 3876 3877 // The rule expression. 3878 // 3879 // Expression is a required field 3880 Expression *string `locationName:"expression" min:"1" type:"string" required:"true"` 3881 3882 // The language of the rule. 3883 // 3884 // Language is a required field 3885 Language *string `locationName:"language" type:"string" required:"true" enum:"Language"` 3886 3887 // The outcome or outcomes returned when the rule expression matches. 3888 // 3889 // Outcomes is a required field 3890 Outcomes []*string `locationName:"outcomes" min:"1" type:"list" required:"true"` 3891 3892 // The rule ID. 3893 // 3894 // RuleId is a required field 3895 RuleId *string `locationName:"ruleId" min:"1" type:"string" required:"true"` 3896} 3897 3898// String returns the string representation 3899func (s CreateRuleInput) String() string { 3900 return awsutil.Prettify(s) 3901} 3902 3903// GoString returns the string representation 3904func (s CreateRuleInput) GoString() string { 3905 return s.String() 3906} 3907 3908// Validate inspects the fields of the type to determine if they are valid. 3909func (s *CreateRuleInput) Validate() error { 3910 invalidParams := request.ErrInvalidParams{Context: "CreateRuleInput"} 3911 if s.Description != nil && len(*s.Description) < 1 { 3912 invalidParams.Add(request.NewErrParamMinLen("Description", 1)) 3913 } 3914 if s.DetectorId == nil { 3915 invalidParams.Add(request.NewErrParamRequired("DetectorId")) 3916 } 3917 if s.DetectorId != nil && len(*s.DetectorId) < 1 { 3918 invalidParams.Add(request.NewErrParamMinLen("DetectorId", 1)) 3919 } 3920 if s.Expression == nil { 3921 invalidParams.Add(request.NewErrParamRequired("Expression")) 3922 } 3923 if s.Expression != nil && len(*s.Expression) < 1 { 3924 invalidParams.Add(request.NewErrParamMinLen("Expression", 1)) 3925 } 3926 if s.Language == nil { 3927 invalidParams.Add(request.NewErrParamRequired("Language")) 3928 } 3929 if s.Outcomes == nil { 3930 invalidParams.Add(request.NewErrParamRequired("Outcomes")) 3931 } 3932 if s.Outcomes != nil && len(s.Outcomes) < 1 { 3933 invalidParams.Add(request.NewErrParamMinLen("Outcomes", 1)) 3934 } 3935 if s.RuleId == nil { 3936 invalidParams.Add(request.NewErrParamRequired("RuleId")) 3937 } 3938 if s.RuleId != nil && len(*s.RuleId) < 1 { 3939 invalidParams.Add(request.NewErrParamMinLen("RuleId", 1)) 3940 } 3941 3942 if invalidParams.Len() > 0 { 3943 return invalidParams 3944 } 3945 return nil 3946} 3947 3948// SetDescription sets the Description field's value. 3949func (s *CreateRuleInput) SetDescription(v string) *CreateRuleInput { 3950 s.Description = &v 3951 return s 3952} 3953 3954// SetDetectorId sets the DetectorId field's value. 3955func (s *CreateRuleInput) SetDetectorId(v string) *CreateRuleInput { 3956 s.DetectorId = &v 3957 return s 3958} 3959 3960// SetExpression sets the Expression field's value. 3961func (s *CreateRuleInput) SetExpression(v string) *CreateRuleInput { 3962 s.Expression = &v 3963 return s 3964} 3965 3966// SetLanguage sets the Language field's value. 3967func (s *CreateRuleInput) SetLanguage(v string) *CreateRuleInput { 3968 s.Language = &v 3969 return s 3970} 3971 3972// SetOutcomes sets the Outcomes field's value. 3973func (s *CreateRuleInput) SetOutcomes(v []*string) *CreateRuleInput { 3974 s.Outcomes = v 3975 return s 3976} 3977 3978// SetRuleId sets the RuleId field's value. 3979func (s *CreateRuleInput) SetRuleId(v string) *CreateRuleInput { 3980 s.RuleId = &v 3981 return s 3982} 3983 3984type CreateRuleOutput struct { 3985 _ struct{} `type:"structure"` 3986 3987 // The created rule. 3988 Rule *Rule `locationName:"rule" type:"structure"` 3989} 3990 3991// String returns the string representation 3992func (s CreateRuleOutput) String() string { 3993 return awsutil.Prettify(s) 3994} 3995 3996// GoString returns the string representation 3997func (s CreateRuleOutput) GoString() string { 3998 return s.String() 3999} 4000 4001// SetRule sets the Rule field's value. 4002func (s *CreateRuleOutput) SetRule(v *Rule) *CreateRuleOutput { 4003 s.Rule = v 4004 return s 4005} 4006 4007type CreateVariableInput struct { 4008 _ struct{} `type:"structure"` 4009 4010 // The source of the data. 4011 // 4012 // DataSource is a required field 4013 DataSource *string `locationName:"dataSource" type:"string" required:"true" enum:"DataSource"` 4014 4015 // The data type. 4016 // 4017 // DataType is a required field 4018 DataType *string `locationName:"dataType" type:"string" required:"true" enum:"DataType"` 4019 4020 // The default value for the variable when no value is received. 4021 // 4022 // DefaultValue is a required field 4023 DefaultValue *string `locationName:"defaultValue" type:"string" required:"true"` 4024 4025 // The description. 4026 Description *string `locationName:"description" type:"string"` 4027 4028 // The name of the variable. 4029 // 4030 // Name is a required field 4031 Name *string `locationName:"name" type:"string" required:"true"` 4032 4033 // The variable type. 4034 VariableType *string `locationName:"variableType" type:"string"` 4035} 4036 4037// String returns the string representation 4038func (s CreateVariableInput) String() string { 4039 return awsutil.Prettify(s) 4040} 4041 4042// GoString returns the string representation 4043func (s CreateVariableInput) GoString() string { 4044 return s.String() 4045} 4046 4047// Validate inspects the fields of the type to determine if they are valid. 4048func (s *CreateVariableInput) Validate() error { 4049 invalidParams := request.ErrInvalidParams{Context: "CreateVariableInput"} 4050 if s.DataSource == nil { 4051 invalidParams.Add(request.NewErrParamRequired("DataSource")) 4052 } 4053 if s.DataType == nil { 4054 invalidParams.Add(request.NewErrParamRequired("DataType")) 4055 } 4056 if s.DefaultValue == nil { 4057 invalidParams.Add(request.NewErrParamRequired("DefaultValue")) 4058 } 4059 if s.Name == nil { 4060 invalidParams.Add(request.NewErrParamRequired("Name")) 4061 } 4062 4063 if invalidParams.Len() > 0 { 4064 return invalidParams 4065 } 4066 return nil 4067} 4068 4069// SetDataSource sets the DataSource field's value. 4070func (s *CreateVariableInput) SetDataSource(v string) *CreateVariableInput { 4071 s.DataSource = &v 4072 return s 4073} 4074 4075// SetDataType sets the DataType field's value. 4076func (s *CreateVariableInput) SetDataType(v string) *CreateVariableInput { 4077 s.DataType = &v 4078 return s 4079} 4080 4081// SetDefaultValue sets the DefaultValue field's value. 4082func (s *CreateVariableInput) SetDefaultValue(v string) *CreateVariableInput { 4083 s.DefaultValue = &v 4084 return s 4085} 4086 4087// SetDescription sets the Description field's value. 4088func (s *CreateVariableInput) SetDescription(v string) *CreateVariableInput { 4089 s.Description = &v 4090 return s 4091} 4092 4093// SetName sets the Name field's value. 4094func (s *CreateVariableInput) SetName(v string) *CreateVariableInput { 4095 s.Name = &v 4096 return s 4097} 4098 4099// SetVariableType sets the VariableType field's value. 4100func (s *CreateVariableInput) SetVariableType(v string) *CreateVariableInput { 4101 s.VariableType = &v 4102 return s 4103} 4104 4105type CreateVariableOutput struct { 4106 _ struct{} `type:"structure"` 4107} 4108 4109// String returns the string representation 4110func (s CreateVariableOutput) String() string { 4111 return awsutil.Prettify(s) 4112} 4113 4114// GoString returns the string representation 4115func (s CreateVariableOutput) GoString() string { 4116 return s.String() 4117} 4118 4119type DeleteDetectorInput struct { 4120 _ struct{} `type:"structure"` 4121 4122 // The ID of the detector to delete. 4123 // 4124 // DetectorId is a required field 4125 DetectorId *string `locationName:"detectorId" min:"1" type:"string" required:"true"` 4126} 4127 4128// String returns the string representation 4129func (s DeleteDetectorInput) String() string { 4130 return awsutil.Prettify(s) 4131} 4132 4133// GoString returns the string representation 4134func (s DeleteDetectorInput) GoString() string { 4135 return s.String() 4136} 4137 4138// Validate inspects the fields of the type to determine if they are valid. 4139func (s *DeleteDetectorInput) Validate() error { 4140 invalidParams := request.ErrInvalidParams{Context: "DeleteDetectorInput"} 4141 if s.DetectorId == nil { 4142 invalidParams.Add(request.NewErrParamRequired("DetectorId")) 4143 } 4144 if s.DetectorId != nil && len(*s.DetectorId) < 1 { 4145 invalidParams.Add(request.NewErrParamMinLen("DetectorId", 1)) 4146 } 4147 4148 if invalidParams.Len() > 0 { 4149 return invalidParams 4150 } 4151 return nil 4152} 4153 4154// SetDetectorId sets the DetectorId field's value. 4155func (s *DeleteDetectorInput) SetDetectorId(v string) *DeleteDetectorInput { 4156 s.DetectorId = &v 4157 return s 4158} 4159 4160type DeleteDetectorOutput struct { 4161 _ struct{} `type:"structure"` 4162} 4163 4164// String returns the string representation 4165func (s DeleteDetectorOutput) String() string { 4166 return awsutil.Prettify(s) 4167} 4168 4169// GoString returns the string representation 4170func (s DeleteDetectorOutput) GoString() string { 4171 return s.String() 4172} 4173 4174type DeleteDetectorVersionInput struct { 4175 _ struct{} `type:"structure"` 4176 4177 // The ID of the parent detector for the detector version to delete. 4178 // 4179 // DetectorId is a required field 4180 DetectorId *string `locationName:"detectorId" min:"1" type:"string" required:"true"` 4181 4182 // The ID of the detector version to delete. 4183 // 4184 // DetectorVersionId is a required field 4185 DetectorVersionId *string `locationName:"detectorVersionId" min:"1" type:"string" required:"true"` 4186} 4187 4188// String returns the string representation 4189func (s DeleteDetectorVersionInput) String() string { 4190 return awsutil.Prettify(s) 4191} 4192 4193// GoString returns the string representation 4194func (s DeleteDetectorVersionInput) GoString() string { 4195 return s.String() 4196} 4197 4198// Validate inspects the fields of the type to determine if they are valid. 4199func (s *DeleteDetectorVersionInput) Validate() error { 4200 invalidParams := request.ErrInvalidParams{Context: "DeleteDetectorVersionInput"} 4201 if s.DetectorId == nil { 4202 invalidParams.Add(request.NewErrParamRequired("DetectorId")) 4203 } 4204 if s.DetectorId != nil && len(*s.DetectorId) < 1 { 4205 invalidParams.Add(request.NewErrParamMinLen("DetectorId", 1)) 4206 } 4207 if s.DetectorVersionId == nil { 4208 invalidParams.Add(request.NewErrParamRequired("DetectorVersionId")) 4209 } 4210 if s.DetectorVersionId != nil && len(*s.DetectorVersionId) < 1 { 4211 invalidParams.Add(request.NewErrParamMinLen("DetectorVersionId", 1)) 4212 } 4213 4214 if invalidParams.Len() > 0 { 4215 return invalidParams 4216 } 4217 return nil 4218} 4219 4220// SetDetectorId sets the DetectorId field's value. 4221func (s *DeleteDetectorVersionInput) SetDetectorId(v string) *DeleteDetectorVersionInput { 4222 s.DetectorId = &v 4223 return s 4224} 4225 4226// SetDetectorVersionId sets the DetectorVersionId field's value. 4227func (s *DeleteDetectorVersionInput) SetDetectorVersionId(v string) *DeleteDetectorVersionInput { 4228 s.DetectorVersionId = &v 4229 return s 4230} 4231 4232type DeleteDetectorVersionOutput struct { 4233 _ struct{} `type:"structure"` 4234} 4235 4236// String returns the string representation 4237func (s DeleteDetectorVersionOutput) String() string { 4238 return awsutil.Prettify(s) 4239} 4240 4241// GoString returns the string representation 4242func (s DeleteDetectorVersionOutput) GoString() string { 4243 return s.String() 4244} 4245 4246type DeleteEventInput struct { 4247 _ struct{} `type:"structure"` 4248 4249 // The ID of the event to delete. 4250 // 4251 // EventId is a required field 4252 EventId *string `locationName:"eventId" type:"string" required:"true"` 4253} 4254 4255// String returns the string representation 4256func (s DeleteEventInput) String() string { 4257 return awsutil.Prettify(s) 4258} 4259 4260// GoString returns the string representation 4261func (s DeleteEventInput) GoString() string { 4262 return s.String() 4263} 4264 4265// Validate inspects the fields of the type to determine if they are valid. 4266func (s *DeleteEventInput) Validate() error { 4267 invalidParams := request.ErrInvalidParams{Context: "DeleteEventInput"} 4268 if s.EventId == nil { 4269 invalidParams.Add(request.NewErrParamRequired("EventId")) 4270 } 4271 4272 if invalidParams.Len() > 0 { 4273 return invalidParams 4274 } 4275 return nil 4276} 4277 4278// SetEventId sets the EventId field's value. 4279func (s *DeleteEventInput) SetEventId(v string) *DeleteEventInput { 4280 s.EventId = &v 4281 return s 4282} 4283 4284type DeleteEventOutput struct { 4285 _ struct{} `type:"structure"` 4286} 4287 4288// String returns the string representation 4289func (s DeleteEventOutput) String() string { 4290 return awsutil.Prettify(s) 4291} 4292 4293// GoString returns the string representation 4294func (s DeleteEventOutput) GoString() string { 4295 return s.String() 4296} 4297 4298type DeleteRuleVersionInput struct { 4299 _ struct{} `type:"structure"` 4300 4301 // The ID of the detector that includes the rule version to delete. 4302 // 4303 // DetectorId is a required field 4304 DetectorId *string `locationName:"detectorId" min:"1" type:"string" required:"true"` 4305 4306 // The rule ID of the rule version to delete. 4307 // 4308 // RuleId is a required field 4309 RuleId *string `locationName:"ruleId" min:"1" type:"string" required:"true"` 4310 4311 // The rule version to delete. 4312 // 4313 // RuleVersion is a required field 4314 RuleVersion *string `locationName:"ruleVersion" min:"1" type:"string" required:"true"` 4315} 4316 4317// String returns the string representation 4318func (s DeleteRuleVersionInput) String() string { 4319 return awsutil.Prettify(s) 4320} 4321 4322// GoString returns the string representation 4323func (s DeleteRuleVersionInput) GoString() string { 4324 return s.String() 4325} 4326 4327// Validate inspects the fields of the type to determine if they are valid. 4328func (s *DeleteRuleVersionInput) Validate() error { 4329 invalidParams := request.ErrInvalidParams{Context: "DeleteRuleVersionInput"} 4330 if s.DetectorId == nil { 4331 invalidParams.Add(request.NewErrParamRequired("DetectorId")) 4332 } 4333 if s.DetectorId != nil && len(*s.DetectorId) < 1 { 4334 invalidParams.Add(request.NewErrParamMinLen("DetectorId", 1)) 4335 } 4336 if s.RuleId == nil { 4337 invalidParams.Add(request.NewErrParamRequired("RuleId")) 4338 } 4339 if s.RuleId != nil && len(*s.RuleId) < 1 { 4340 invalidParams.Add(request.NewErrParamMinLen("RuleId", 1)) 4341 } 4342 if s.RuleVersion == nil { 4343 invalidParams.Add(request.NewErrParamRequired("RuleVersion")) 4344 } 4345 if s.RuleVersion != nil && len(*s.RuleVersion) < 1 { 4346 invalidParams.Add(request.NewErrParamMinLen("RuleVersion", 1)) 4347 } 4348 4349 if invalidParams.Len() > 0 { 4350 return invalidParams 4351 } 4352 return nil 4353} 4354 4355// SetDetectorId sets the DetectorId field's value. 4356func (s *DeleteRuleVersionInput) SetDetectorId(v string) *DeleteRuleVersionInput { 4357 s.DetectorId = &v 4358 return s 4359} 4360 4361// SetRuleId sets the RuleId field's value. 4362func (s *DeleteRuleVersionInput) SetRuleId(v string) *DeleteRuleVersionInput { 4363 s.RuleId = &v 4364 return s 4365} 4366 4367// SetRuleVersion sets the RuleVersion field's value. 4368func (s *DeleteRuleVersionInput) SetRuleVersion(v string) *DeleteRuleVersionInput { 4369 s.RuleVersion = &v 4370 return s 4371} 4372 4373type DeleteRuleVersionOutput struct { 4374 _ struct{} `type:"structure"` 4375} 4376 4377// String returns the string representation 4378func (s DeleteRuleVersionOutput) String() string { 4379 return awsutil.Prettify(s) 4380} 4381 4382// GoString returns the string representation 4383func (s DeleteRuleVersionOutput) GoString() string { 4384 return s.String() 4385} 4386 4387type DescribeDetectorInput struct { 4388 _ struct{} `type:"structure"` 4389 4390 // The detector ID. 4391 // 4392 // DetectorId is a required field 4393 DetectorId *string `locationName:"detectorId" min:"1" type:"string" required:"true"` 4394 4395 // The maximum number of results to return for the request. 4396 MaxResults *int64 `locationName:"maxResults" min:"1000" type:"integer"` 4397 4398 // The next token from the previous response. 4399 NextToken *string `locationName:"nextToken" type:"string"` 4400} 4401 4402// String returns the string representation 4403func (s DescribeDetectorInput) String() string { 4404 return awsutil.Prettify(s) 4405} 4406 4407// GoString returns the string representation 4408func (s DescribeDetectorInput) GoString() string { 4409 return s.String() 4410} 4411 4412// Validate inspects the fields of the type to determine if they are valid. 4413func (s *DescribeDetectorInput) Validate() error { 4414 invalidParams := request.ErrInvalidParams{Context: "DescribeDetectorInput"} 4415 if s.DetectorId == nil { 4416 invalidParams.Add(request.NewErrParamRequired("DetectorId")) 4417 } 4418 if s.DetectorId != nil && len(*s.DetectorId) < 1 { 4419 invalidParams.Add(request.NewErrParamMinLen("DetectorId", 1)) 4420 } 4421 if s.MaxResults != nil && *s.MaxResults < 1000 { 4422 invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1000)) 4423 } 4424 4425 if invalidParams.Len() > 0 { 4426 return invalidParams 4427 } 4428 return nil 4429} 4430 4431// SetDetectorId sets the DetectorId field's value. 4432func (s *DescribeDetectorInput) SetDetectorId(v string) *DescribeDetectorInput { 4433 s.DetectorId = &v 4434 return s 4435} 4436 4437// SetMaxResults sets the MaxResults field's value. 4438func (s *DescribeDetectorInput) SetMaxResults(v int64) *DescribeDetectorInput { 4439 s.MaxResults = &v 4440 return s 4441} 4442 4443// SetNextToken sets the NextToken field's value. 4444func (s *DescribeDetectorInput) SetNextToken(v string) *DescribeDetectorInput { 4445 s.NextToken = &v 4446 return s 4447} 4448 4449type DescribeDetectorOutput struct { 4450 _ struct{} `type:"structure"` 4451 4452 // The detector ID. 4453 DetectorId *string `locationName:"detectorId" min:"1" type:"string"` 4454 4455 // The status and description for each detector version. 4456 DetectorVersionSummaries []*DetectorVersionSummary `locationName:"detectorVersionSummaries" type:"list"` 4457 4458 // The next token to be used for subsequent requests. 4459 NextToken *string `locationName:"nextToken" type:"string"` 4460} 4461 4462// String returns the string representation 4463func (s DescribeDetectorOutput) String() string { 4464 return awsutil.Prettify(s) 4465} 4466 4467// GoString returns the string representation 4468func (s DescribeDetectorOutput) GoString() string { 4469 return s.String() 4470} 4471 4472// SetDetectorId sets the DetectorId field's value. 4473func (s *DescribeDetectorOutput) SetDetectorId(v string) *DescribeDetectorOutput { 4474 s.DetectorId = &v 4475 return s 4476} 4477 4478// SetDetectorVersionSummaries sets the DetectorVersionSummaries field's value. 4479func (s *DescribeDetectorOutput) SetDetectorVersionSummaries(v []*DetectorVersionSummary) *DescribeDetectorOutput { 4480 s.DetectorVersionSummaries = v 4481 return s 4482} 4483 4484// SetNextToken sets the NextToken field's value. 4485func (s *DescribeDetectorOutput) SetNextToken(v string) *DescribeDetectorOutput { 4486 s.NextToken = &v 4487 return s 4488} 4489 4490type DescribeModelVersionsInput struct { 4491 _ struct{} `type:"structure"` 4492 4493 // The maximum number of results to return. 4494 MaxResults *int64 `locationName:"maxResults" min:"1" type:"integer"` 4495 4496 // The model ID. 4497 ModelId *string `locationName:"modelId" min:"1" type:"string"` 4498 4499 // The model type. 4500 ModelType *string `locationName:"modelType" type:"string" enum:"ModelTypeEnum"` 4501 4502 // The model version. 4503 ModelVersionNumber *string `locationName:"modelVersionNumber" min:"1" type:"string"` 4504 4505 // The next token from the previous results. 4506 NextToken *string `locationName:"nextToken" type:"string"` 4507} 4508 4509// String returns the string representation 4510func (s DescribeModelVersionsInput) String() string { 4511 return awsutil.Prettify(s) 4512} 4513 4514// GoString returns the string representation 4515func (s DescribeModelVersionsInput) GoString() string { 4516 return s.String() 4517} 4518 4519// Validate inspects the fields of the type to determine if they are valid. 4520func (s *DescribeModelVersionsInput) Validate() error { 4521 invalidParams := request.ErrInvalidParams{Context: "DescribeModelVersionsInput"} 4522 if s.MaxResults != nil && *s.MaxResults < 1 { 4523 invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) 4524 } 4525 if s.ModelId != nil && len(*s.ModelId) < 1 { 4526 invalidParams.Add(request.NewErrParamMinLen("ModelId", 1)) 4527 } 4528 if s.ModelVersionNumber != nil && len(*s.ModelVersionNumber) < 1 { 4529 invalidParams.Add(request.NewErrParamMinLen("ModelVersionNumber", 1)) 4530 } 4531 4532 if invalidParams.Len() > 0 { 4533 return invalidParams 4534 } 4535 return nil 4536} 4537 4538// SetMaxResults sets the MaxResults field's value. 4539func (s *DescribeModelVersionsInput) SetMaxResults(v int64) *DescribeModelVersionsInput { 4540 s.MaxResults = &v 4541 return s 4542} 4543 4544// SetModelId sets the ModelId field's value. 4545func (s *DescribeModelVersionsInput) SetModelId(v string) *DescribeModelVersionsInput { 4546 s.ModelId = &v 4547 return s 4548} 4549 4550// SetModelType sets the ModelType field's value. 4551func (s *DescribeModelVersionsInput) SetModelType(v string) *DescribeModelVersionsInput { 4552 s.ModelType = &v 4553 return s 4554} 4555 4556// SetModelVersionNumber sets the ModelVersionNumber field's value. 4557func (s *DescribeModelVersionsInput) SetModelVersionNumber(v string) *DescribeModelVersionsInput { 4558 s.ModelVersionNumber = &v 4559 return s 4560} 4561 4562// SetNextToken sets the NextToken field's value. 4563func (s *DescribeModelVersionsInput) SetNextToken(v string) *DescribeModelVersionsInput { 4564 s.NextToken = &v 4565 return s 4566} 4567 4568type DescribeModelVersionsOutput struct { 4569 _ struct{} `type:"structure"` 4570 4571 // The model version details. 4572 ModelVersionDetails []*ModelVersionDetail `locationName:"modelVersionDetails" type:"list"` 4573 4574 // The next token. 4575 NextToken *string `locationName:"nextToken" type:"string"` 4576} 4577 4578// String returns the string representation 4579func (s DescribeModelVersionsOutput) String() string { 4580 return awsutil.Prettify(s) 4581} 4582 4583// GoString returns the string representation 4584func (s DescribeModelVersionsOutput) GoString() string { 4585 return s.String() 4586} 4587 4588// SetModelVersionDetails sets the ModelVersionDetails field's value. 4589func (s *DescribeModelVersionsOutput) SetModelVersionDetails(v []*ModelVersionDetail) *DescribeModelVersionsOutput { 4590 s.ModelVersionDetails = v 4591 return s 4592} 4593 4594// SetNextToken sets the NextToken field's value. 4595func (s *DescribeModelVersionsOutput) SetNextToken(v string) *DescribeModelVersionsOutput { 4596 s.NextToken = &v 4597 return s 4598} 4599 4600// The detector. 4601type Detector struct { 4602 _ struct{} `type:"structure"` 4603 4604 // Timestamp of when the detector was created. 4605 CreatedTime *string `locationName:"createdTime" type:"string"` 4606 4607 // The detector description. 4608 Description *string `locationName:"description" min:"1" type:"string"` 4609 4610 // The detector ID. 4611 DetectorId *string `locationName:"detectorId" min:"1" type:"string"` 4612 4613 // Timestamp of when the detector was last updated. 4614 LastUpdatedTime *string `locationName:"lastUpdatedTime" type:"string"` 4615} 4616 4617// String returns the string representation 4618func (s Detector) String() string { 4619 return awsutil.Prettify(s) 4620} 4621 4622// GoString returns the string representation 4623func (s Detector) GoString() string { 4624 return s.String() 4625} 4626 4627// SetCreatedTime sets the CreatedTime field's value. 4628func (s *Detector) SetCreatedTime(v string) *Detector { 4629 s.CreatedTime = &v 4630 return s 4631} 4632 4633// SetDescription sets the Description field's value. 4634func (s *Detector) SetDescription(v string) *Detector { 4635 s.Description = &v 4636 return s 4637} 4638 4639// SetDetectorId sets the DetectorId field's value. 4640func (s *Detector) SetDetectorId(v string) *Detector { 4641 s.DetectorId = &v 4642 return s 4643} 4644 4645// SetLastUpdatedTime sets the LastUpdatedTime field's value. 4646func (s *Detector) SetLastUpdatedTime(v string) *Detector { 4647 s.LastUpdatedTime = &v 4648 return s 4649} 4650 4651// The summary of the detector version. 4652type DetectorVersionSummary struct { 4653 _ struct{} `type:"structure"` 4654 4655 // The detector version description. 4656 Description *string `locationName:"description" min:"1" type:"string"` 4657 4658 // The detector version ID. 4659 DetectorVersionId *string `locationName:"detectorVersionId" min:"1" type:"string"` 4660 4661 // Timestamp of when the detector version was last updated. 4662 LastUpdatedTime *string `locationName:"lastUpdatedTime" type:"string"` 4663 4664 // The detector version status. 4665 Status *string `locationName:"status" type:"string" enum:"DetectorVersionStatus"` 4666} 4667 4668// String returns the string representation 4669func (s DetectorVersionSummary) String() string { 4670 return awsutil.Prettify(s) 4671} 4672 4673// GoString returns the string representation 4674func (s DetectorVersionSummary) GoString() string { 4675 return s.String() 4676} 4677 4678// SetDescription sets the Description field's value. 4679func (s *DetectorVersionSummary) SetDescription(v string) *DetectorVersionSummary { 4680 s.Description = &v 4681 return s 4682} 4683 4684// SetDetectorVersionId sets the DetectorVersionId field's value. 4685func (s *DetectorVersionSummary) SetDetectorVersionId(v string) *DetectorVersionSummary { 4686 s.DetectorVersionId = &v 4687 return s 4688} 4689 4690// SetLastUpdatedTime sets the LastUpdatedTime field's value. 4691func (s *DetectorVersionSummary) SetLastUpdatedTime(v string) *DetectorVersionSummary { 4692 s.LastUpdatedTime = &v 4693 return s 4694} 4695 4696// SetStatus sets the Status field's value. 4697func (s *DetectorVersionSummary) SetStatus(v string) *DetectorVersionSummary { 4698 s.Status = &v 4699 return s 4700} 4701 4702// The Amazon SageMaker model. 4703type ExternalModel struct { 4704 _ struct{} `type:"structure"` 4705 4706 // Timestamp of when the model was last created. 4707 CreatedTime *string `locationName:"createdTime" type:"string"` 4708 4709 // The input configuration. 4710 InputConfiguration *ModelInputConfiguration `locationName:"inputConfiguration" type:"structure"` 4711 4712 // Timestamp of when the model was last updated. 4713 LastUpdatedTime *string `locationName:"lastUpdatedTime" type:"string"` 4714 4715 // The Amazon SageMaker model endpoints. 4716 ModelEndpoint *string `locationName:"modelEndpoint" type:"string"` 4717 4718 // The Amazon Fraud Detector status for the external model endpoint 4719 ModelEndpointStatus *string `locationName:"modelEndpointStatus" type:"string" enum:"ModelEndpointStatus"` 4720 4721 // The source of the model. 4722 ModelSource *string `locationName:"modelSource" type:"string" enum:"ModelSource"` 4723 4724 // The output configuration. 4725 OutputConfiguration *ModelOutputConfiguration `locationName:"outputConfiguration" type:"structure"` 4726 4727 // The role used to invoke the model. 4728 Role *Role `locationName:"role" type:"structure"` 4729} 4730 4731// String returns the string representation 4732func (s ExternalModel) String() string { 4733 return awsutil.Prettify(s) 4734} 4735 4736// GoString returns the string representation 4737func (s ExternalModel) GoString() string { 4738 return s.String() 4739} 4740 4741// SetCreatedTime sets the CreatedTime field's value. 4742func (s *ExternalModel) SetCreatedTime(v string) *ExternalModel { 4743 s.CreatedTime = &v 4744 return s 4745} 4746 4747// SetInputConfiguration sets the InputConfiguration field's value. 4748func (s *ExternalModel) SetInputConfiguration(v *ModelInputConfiguration) *ExternalModel { 4749 s.InputConfiguration = v 4750 return s 4751} 4752 4753// SetLastUpdatedTime sets the LastUpdatedTime field's value. 4754func (s *ExternalModel) SetLastUpdatedTime(v string) *ExternalModel { 4755 s.LastUpdatedTime = &v 4756 return s 4757} 4758 4759// SetModelEndpoint sets the ModelEndpoint field's value. 4760func (s *ExternalModel) SetModelEndpoint(v string) *ExternalModel { 4761 s.ModelEndpoint = &v 4762 return s 4763} 4764 4765// SetModelEndpointStatus sets the ModelEndpointStatus field's value. 4766func (s *ExternalModel) SetModelEndpointStatus(v string) *ExternalModel { 4767 s.ModelEndpointStatus = &v 4768 return s 4769} 4770 4771// SetModelSource sets the ModelSource field's value. 4772func (s *ExternalModel) SetModelSource(v string) *ExternalModel { 4773 s.ModelSource = &v 4774 return s 4775} 4776 4777// SetOutputConfiguration sets the OutputConfiguration field's value. 4778func (s *ExternalModel) SetOutputConfiguration(v *ModelOutputConfiguration) *ExternalModel { 4779 s.OutputConfiguration = v 4780 return s 4781} 4782 4783// SetRole sets the Role field's value. 4784func (s *ExternalModel) SetRole(v *Role) *ExternalModel { 4785 s.Role = v 4786 return s 4787} 4788 4789type GetDetectorVersionInput struct { 4790 _ struct{} `type:"structure"` 4791 4792 // The detector ID. 4793 // 4794 // DetectorId is a required field 4795 DetectorId *string `locationName:"detectorId" min:"1" type:"string" required:"true"` 4796 4797 // The detector version ID. 4798 // 4799 // DetectorVersionId is a required field 4800 DetectorVersionId *string `locationName:"detectorVersionId" min:"1" type:"string" required:"true"` 4801} 4802 4803// String returns the string representation 4804func (s GetDetectorVersionInput) String() string { 4805 return awsutil.Prettify(s) 4806} 4807 4808// GoString returns the string representation 4809func (s GetDetectorVersionInput) GoString() string { 4810 return s.String() 4811} 4812 4813// Validate inspects the fields of the type to determine if they are valid. 4814func (s *GetDetectorVersionInput) Validate() error { 4815 invalidParams := request.ErrInvalidParams{Context: "GetDetectorVersionInput"} 4816 if s.DetectorId == nil { 4817 invalidParams.Add(request.NewErrParamRequired("DetectorId")) 4818 } 4819 if s.DetectorId != nil && len(*s.DetectorId) < 1 { 4820 invalidParams.Add(request.NewErrParamMinLen("DetectorId", 1)) 4821 } 4822 if s.DetectorVersionId == nil { 4823 invalidParams.Add(request.NewErrParamRequired("DetectorVersionId")) 4824 } 4825 if s.DetectorVersionId != nil && len(*s.DetectorVersionId) < 1 { 4826 invalidParams.Add(request.NewErrParamMinLen("DetectorVersionId", 1)) 4827 } 4828 4829 if invalidParams.Len() > 0 { 4830 return invalidParams 4831 } 4832 return nil 4833} 4834 4835// SetDetectorId sets the DetectorId field's value. 4836func (s *GetDetectorVersionInput) SetDetectorId(v string) *GetDetectorVersionInput { 4837 s.DetectorId = &v 4838 return s 4839} 4840 4841// SetDetectorVersionId sets the DetectorVersionId field's value. 4842func (s *GetDetectorVersionInput) SetDetectorVersionId(v string) *GetDetectorVersionInput { 4843 s.DetectorVersionId = &v 4844 return s 4845} 4846 4847type GetDetectorVersionOutput struct { 4848 _ struct{} `type:"structure"` 4849 4850 // The timestamp when the detector version was created. 4851 CreatedTime *string `locationName:"createdTime" type:"string"` 4852 4853 // The detector version description. 4854 Description *string `locationName:"description" min:"1" type:"string"` 4855 4856 // The detector ID. 4857 DetectorId *string `locationName:"detectorId" min:"1" type:"string"` 4858 4859 // The detector version ID. 4860 DetectorVersionId *string `locationName:"detectorVersionId" min:"1" type:"string"` 4861 4862 // The Amazon SageMaker model endpoints included in the detector version. 4863 ExternalModelEndpoints []*string `locationName:"externalModelEndpoints" type:"list"` 4864 4865 // The timestamp when the detector version was last updated. 4866 LastUpdatedTime *string `locationName:"lastUpdatedTime" type:"string"` 4867 4868 // The model versions included in the detector version. 4869 ModelVersions []*ModelVersion `locationName:"modelVersions" type:"list"` 4870 4871 // The execution mode of the rule in the dectector 4872 // 4873 // FIRST_MATCHED indicates that Amazon Fraud Detector evaluates rules sequentially, 4874 // first to last, stopping at the first matched rule. Amazon Fraud dectector 4875 // then provides the outcomes for that single rule. 4876 // 4877 // ALL_MATCHED indicates that Amazon Fraud Detector evaluates all rules and 4878 // returns the outcomes for all matched rules. You can define and edit the rule 4879 // mode at the detector version level, when it is in draft status. 4880 RuleExecutionMode *string `locationName:"ruleExecutionMode" type:"string" enum:"RuleExecutionMode"` 4881 4882 // The rules included in the detector version. 4883 Rules []*Rule `locationName:"rules" type:"list"` 4884 4885 // The status of the detector version. 4886 Status *string `locationName:"status" type:"string" enum:"DetectorVersionStatus"` 4887} 4888 4889// String returns the string representation 4890func (s GetDetectorVersionOutput) String() string { 4891 return awsutil.Prettify(s) 4892} 4893 4894// GoString returns the string representation 4895func (s GetDetectorVersionOutput) GoString() string { 4896 return s.String() 4897} 4898 4899// SetCreatedTime sets the CreatedTime field's value. 4900func (s *GetDetectorVersionOutput) SetCreatedTime(v string) *GetDetectorVersionOutput { 4901 s.CreatedTime = &v 4902 return s 4903} 4904 4905// SetDescription sets the Description field's value. 4906func (s *GetDetectorVersionOutput) SetDescription(v string) *GetDetectorVersionOutput { 4907 s.Description = &v 4908 return s 4909} 4910 4911// SetDetectorId sets the DetectorId field's value. 4912func (s *GetDetectorVersionOutput) SetDetectorId(v string) *GetDetectorVersionOutput { 4913 s.DetectorId = &v 4914 return s 4915} 4916 4917// SetDetectorVersionId sets the DetectorVersionId field's value. 4918func (s *GetDetectorVersionOutput) SetDetectorVersionId(v string) *GetDetectorVersionOutput { 4919 s.DetectorVersionId = &v 4920 return s 4921} 4922 4923// SetExternalModelEndpoints sets the ExternalModelEndpoints field's value. 4924func (s *GetDetectorVersionOutput) SetExternalModelEndpoints(v []*string) *GetDetectorVersionOutput { 4925 s.ExternalModelEndpoints = v 4926 return s 4927} 4928 4929// SetLastUpdatedTime sets the LastUpdatedTime field's value. 4930func (s *GetDetectorVersionOutput) SetLastUpdatedTime(v string) *GetDetectorVersionOutput { 4931 s.LastUpdatedTime = &v 4932 return s 4933} 4934 4935// SetModelVersions sets the ModelVersions field's value. 4936func (s *GetDetectorVersionOutput) SetModelVersions(v []*ModelVersion) *GetDetectorVersionOutput { 4937 s.ModelVersions = v 4938 return s 4939} 4940 4941// SetRuleExecutionMode sets the RuleExecutionMode field's value. 4942func (s *GetDetectorVersionOutput) SetRuleExecutionMode(v string) *GetDetectorVersionOutput { 4943 s.RuleExecutionMode = &v 4944 return s 4945} 4946 4947// SetRules sets the Rules field's value. 4948func (s *GetDetectorVersionOutput) SetRules(v []*Rule) *GetDetectorVersionOutput { 4949 s.Rules = v 4950 return s 4951} 4952 4953// SetStatus sets the Status field's value. 4954func (s *GetDetectorVersionOutput) SetStatus(v string) *GetDetectorVersionOutput { 4955 s.Status = &v 4956 return s 4957} 4958 4959type GetDetectorsInput struct { 4960 _ struct{} `type:"structure"` 4961 4962 // The detector ID. 4963 DetectorId *string `locationName:"detectorId" min:"1" type:"string"` 4964 4965 // The maximum number of objects to return for the request. 4966 MaxResults *int64 `locationName:"maxResults" min:"5" type:"integer"` 4967 4968 // The next token for the subsequent request. 4969 NextToken *string `locationName:"nextToken" type:"string"` 4970} 4971 4972// String returns the string representation 4973func (s GetDetectorsInput) String() string { 4974 return awsutil.Prettify(s) 4975} 4976 4977// GoString returns the string representation 4978func (s GetDetectorsInput) GoString() string { 4979 return s.String() 4980} 4981 4982// Validate inspects the fields of the type to determine if they are valid. 4983func (s *GetDetectorsInput) Validate() error { 4984 invalidParams := request.ErrInvalidParams{Context: "GetDetectorsInput"} 4985 if s.DetectorId != nil && len(*s.DetectorId) < 1 { 4986 invalidParams.Add(request.NewErrParamMinLen("DetectorId", 1)) 4987 } 4988 if s.MaxResults != nil && *s.MaxResults < 5 { 4989 invalidParams.Add(request.NewErrParamMinValue("MaxResults", 5)) 4990 } 4991 4992 if invalidParams.Len() > 0 { 4993 return invalidParams 4994 } 4995 return nil 4996} 4997 4998// SetDetectorId sets the DetectorId field's value. 4999func (s *GetDetectorsInput) SetDetectorId(v string) *GetDetectorsInput { 5000 s.DetectorId = &v 5001 return s 5002} 5003 5004// SetMaxResults sets the MaxResults field's value. 5005func (s *GetDetectorsInput) SetMaxResults(v int64) *GetDetectorsInput { 5006 s.MaxResults = &v 5007 return s 5008} 5009 5010// SetNextToken sets the NextToken field's value. 5011func (s *GetDetectorsInput) SetNextToken(v string) *GetDetectorsInput { 5012 s.NextToken = &v 5013 return s 5014} 5015 5016type GetDetectorsOutput struct { 5017 _ struct{} `type:"structure"` 5018 5019 // The detectors. 5020 Detectors []*Detector `locationName:"detectors" type:"list"` 5021 5022 // The next page token. 5023 NextToken *string `locationName:"nextToken" type:"string"` 5024} 5025 5026// String returns the string representation 5027func (s GetDetectorsOutput) String() string { 5028 return awsutil.Prettify(s) 5029} 5030 5031// GoString returns the string representation 5032func (s GetDetectorsOutput) GoString() string { 5033 return s.String() 5034} 5035 5036// SetDetectors sets the Detectors field's value. 5037func (s *GetDetectorsOutput) SetDetectors(v []*Detector) *GetDetectorsOutput { 5038 s.Detectors = v 5039 return s 5040} 5041 5042// SetNextToken sets the NextToken field's value. 5043func (s *GetDetectorsOutput) SetNextToken(v string) *GetDetectorsOutput { 5044 s.NextToken = &v 5045 return s 5046} 5047 5048type GetExternalModelsInput struct { 5049 _ struct{} `type:"structure"` 5050 5051 // The maximum number of objects to return for the request. 5052 MaxResults *int64 `locationName:"maxResults" min:"5" type:"integer"` 5053 5054 // The Amazon SageMaker model endpoint. 5055 ModelEndpoint *string `locationName:"modelEndpoint" type:"string"` 5056 5057 // The next page token for the request. 5058 NextToken *string `locationName:"nextToken" type:"string"` 5059} 5060 5061// String returns the string representation 5062func (s GetExternalModelsInput) String() string { 5063 return awsutil.Prettify(s) 5064} 5065 5066// GoString returns the string representation 5067func (s GetExternalModelsInput) GoString() string { 5068 return s.String() 5069} 5070 5071// Validate inspects the fields of the type to determine if they are valid. 5072func (s *GetExternalModelsInput) Validate() error { 5073 invalidParams := request.ErrInvalidParams{Context: "GetExternalModelsInput"} 5074 if s.MaxResults != nil && *s.MaxResults < 5 { 5075 invalidParams.Add(request.NewErrParamMinValue("MaxResults", 5)) 5076 } 5077 5078 if invalidParams.Len() > 0 { 5079 return invalidParams 5080 } 5081 return nil 5082} 5083 5084// SetMaxResults sets the MaxResults field's value. 5085func (s *GetExternalModelsInput) SetMaxResults(v int64) *GetExternalModelsInput { 5086 s.MaxResults = &v 5087 return s 5088} 5089 5090// SetModelEndpoint sets the ModelEndpoint field's value. 5091func (s *GetExternalModelsInput) SetModelEndpoint(v string) *GetExternalModelsInput { 5092 s.ModelEndpoint = &v 5093 return s 5094} 5095 5096// SetNextToken sets the NextToken field's value. 5097func (s *GetExternalModelsInput) SetNextToken(v string) *GetExternalModelsInput { 5098 s.NextToken = &v 5099 return s 5100} 5101 5102type GetExternalModelsOutput struct { 5103 _ struct{} `type:"structure"` 5104 5105 // Gets the Amazon SageMaker models. 5106 ExternalModels []*ExternalModel `locationName:"externalModels" type:"list"` 5107 5108 // The next page token to be used in subsequent requests. 5109 NextToken *string `locationName:"nextToken" type:"string"` 5110} 5111 5112// String returns the string representation 5113func (s GetExternalModelsOutput) String() string { 5114 return awsutil.Prettify(s) 5115} 5116 5117// GoString returns the string representation 5118func (s GetExternalModelsOutput) GoString() string { 5119 return s.String() 5120} 5121 5122// SetExternalModels sets the ExternalModels field's value. 5123func (s *GetExternalModelsOutput) SetExternalModels(v []*ExternalModel) *GetExternalModelsOutput { 5124 s.ExternalModels = v 5125 return s 5126} 5127 5128// SetNextToken sets the NextToken field's value. 5129func (s *GetExternalModelsOutput) SetNextToken(v string) *GetExternalModelsOutput { 5130 s.NextToken = &v 5131 return s 5132} 5133 5134type GetModelVersionInput struct { 5135 _ struct{} `type:"structure"` 5136 5137 // The model ID. 5138 // 5139 // ModelId is a required field 5140 ModelId *string `locationName:"modelId" min:"1" type:"string" required:"true"` 5141 5142 // The model type. 5143 // 5144 // ModelType is a required field 5145 ModelType *string `locationName:"modelType" type:"string" required:"true" enum:"ModelTypeEnum"` 5146 5147 // The model version. 5148 // 5149 // ModelVersionNumber is a required field 5150 ModelVersionNumber *string `locationName:"modelVersionNumber" min:"1" type:"string" required:"true"` 5151} 5152 5153// String returns the string representation 5154func (s GetModelVersionInput) String() string { 5155 return awsutil.Prettify(s) 5156} 5157 5158// GoString returns the string representation 5159func (s GetModelVersionInput) GoString() string { 5160 return s.String() 5161} 5162 5163// Validate inspects the fields of the type to determine if they are valid. 5164func (s *GetModelVersionInput) Validate() error { 5165 invalidParams := request.ErrInvalidParams{Context: "GetModelVersionInput"} 5166 if s.ModelId == nil { 5167 invalidParams.Add(request.NewErrParamRequired("ModelId")) 5168 } 5169 if s.ModelId != nil && len(*s.ModelId) < 1 { 5170 invalidParams.Add(request.NewErrParamMinLen("ModelId", 1)) 5171 } 5172 if s.ModelType == nil { 5173 invalidParams.Add(request.NewErrParamRequired("ModelType")) 5174 } 5175 if s.ModelVersionNumber == nil { 5176 invalidParams.Add(request.NewErrParamRequired("ModelVersionNumber")) 5177 } 5178 if s.ModelVersionNumber != nil && len(*s.ModelVersionNumber) < 1 { 5179 invalidParams.Add(request.NewErrParamMinLen("ModelVersionNumber", 1)) 5180 } 5181 5182 if invalidParams.Len() > 0 { 5183 return invalidParams 5184 } 5185 return nil 5186} 5187 5188// SetModelId sets the ModelId field's value. 5189func (s *GetModelVersionInput) SetModelId(v string) *GetModelVersionInput { 5190 s.ModelId = &v 5191 return s 5192} 5193 5194// SetModelType sets the ModelType field's value. 5195func (s *GetModelVersionInput) SetModelType(v string) *GetModelVersionInput { 5196 s.ModelType = &v 5197 return s 5198} 5199 5200// SetModelVersionNumber sets the ModelVersionNumber field's value. 5201func (s *GetModelVersionInput) SetModelVersionNumber(v string) *GetModelVersionInput { 5202 s.ModelVersionNumber = &v 5203 return s 5204} 5205 5206type GetModelVersionOutput struct { 5207 _ struct{} `type:"structure"` 5208 5209 // The model version description. 5210 Description *string `locationName:"description" min:"1" type:"string"` 5211 5212 // The model ID. 5213 ModelId *string `locationName:"modelId" min:"1" type:"string"` 5214 5215 // The model type. 5216 ModelType *string `locationName:"modelType" type:"string" enum:"ModelTypeEnum"` 5217 5218 // The model version. 5219 ModelVersionNumber *string `locationName:"modelVersionNumber" min:"1" type:"string"` 5220 5221 // The model version status. 5222 Status *string `locationName:"status" type:"string"` 5223} 5224 5225// String returns the string representation 5226func (s GetModelVersionOutput) String() string { 5227 return awsutil.Prettify(s) 5228} 5229 5230// GoString returns the string representation 5231func (s GetModelVersionOutput) GoString() string { 5232 return s.String() 5233} 5234 5235// SetDescription sets the Description field's value. 5236func (s *GetModelVersionOutput) SetDescription(v string) *GetModelVersionOutput { 5237 s.Description = &v 5238 return s 5239} 5240 5241// SetModelId sets the ModelId field's value. 5242func (s *GetModelVersionOutput) SetModelId(v string) *GetModelVersionOutput { 5243 s.ModelId = &v 5244 return s 5245} 5246 5247// SetModelType sets the ModelType field's value. 5248func (s *GetModelVersionOutput) SetModelType(v string) *GetModelVersionOutput { 5249 s.ModelType = &v 5250 return s 5251} 5252 5253// SetModelVersionNumber sets the ModelVersionNumber field's value. 5254func (s *GetModelVersionOutput) SetModelVersionNumber(v string) *GetModelVersionOutput { 5255 s.ModelVersionNumber = &v 5256 return s 5257} 5258 5259// SetStatus sets the Status field's value. 5260func (s *GetModelVersionOutput) SetStatus(v string) *GetModelVersionOutput { 5261 s.Status = &v 5262 return s 5263} 5264 5265type GetModelsInput struct { 5266 _ struct{} `type:"structure"` 5267 5268 // The maximum results to return for the request. 5269 MaxResults *int64 `locationName:"maxResults" min:"1" type:"integer"` 5270 5271 // The model ID. 5272 ModelId *string `locationName:"modelId" min:"1" type:"string"` 5273 5274 // The model type. 5275 ModelType *string `locationName:"modelType" type:"string" enum:"ModelTypeEnum"` 5276 5277 // The next token for the request. 5278 NextToken *string `locationName:"nextToken" type:"string"` 5279} 5280 5281// String returns the string representation 5282func (s GetModelsInput) String() string { 5283 return awsutil.Prettify(s) 5284} 5285 5286// GoString returns the string representation 5287func (s GetModelsInput) GoString() string { 5288 return s.String() 5289} 5290 5291// Validate inspects the fields of the type to determine if they are valid. 5292func (s *GetModelsInput) Validate() error { 5293 invalidParams := request.ErrInvalidParams{Context: "GetModelsInput"} 5294 if s.MaxResults != nil && *s.MaxResults < 1 { 5295 invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) 5296 } 5297 if s.ModelId != nil && len(*s.ModelId) < 1 { 5298 invalidParams.Add(request.NewErrParamMinLen("ModelId", 1)) 5299 } 5300 5301 if invalidParams.Len() > 0 { 5302 return invalidParams 5303 } 5304 return nil 5305} 5306 5307// SetMaxResults sets the MaxResults field's value. 5308func (s *GetModelsInput) SetMaxResults(v int64) *GetModelsInput { 5309 s.MaxResults = &v 5310 return s 5311} 5312 5313// SetModelId sets the ModelId field's value. 5314func (s *GetModelsInput) SetModelId(v string) *GetModelsInput { 5315 s.ModelId = &v 5316 return s 5317} 5318 5319// SetModelType sets the ModelType field's value. 5320func (s *GetModelsInput) SetModelType(v string) *GetModelsInput { 5321 s.ModelType = &v 5322 return s 5323} 5324 5325// SetNextToken sets the NextToken field's value. 5326func (s *GetModelsInput) SetNextToken(v string) *GetModelsInput { 5327 s.NextToken = &v 5328 return s 5329} 5330 5331type GetModelsOutput struct { 5332 _ struct{} `type:"structure"` 5333 5334 // The returned models. 5335 Models []*Model `locationName:"models" type:"list"` 5336 5337 // The next token for subsequent requests. 5338 NextToken *string `locationName:"nextToken" type:"string"` 5339} 5340 5341// String returns the string representation 5342func (s GetModelsOutput) String() string { 5343 return awsutil.Prettify(s) 5344} 5345 5346// GoString returns the string representation 5347func (s GetModelsOutput) GoString() string { 5348 return s.String() 5349} 5350 5351// SetModels sets the Models field's value. 5352func (s *GetModelsOutput) SetModels(v []*Model) *GetModelsOutput { 5353 s.Models = v 5354 return s 5355} 5356 5357// SetNextToken sets the NextToken field's value. 5358func (s *GetModelsOutput) SetNextToken(v string) *GetModelsOutput { 5359 s.NextToken = &v 5360 return s 5361} 5362 5363type GetOutcomesInput struct { 5364 _ struct{} `type:"structure"` 5365 5366 // The maximum number of objects to return for the request. 5367 MaxResults *int64 `locationName:"maxResults" min:"50" type:"integer"` 5368 5369 // The name of the outcome or outcomes to get. 5370 Name *string `locationName:"name" min:"1" type:"string"` 5371 5372 // The next page token for the request. 5373 NextToken *string `locationName:"nextToken" type:"string"` 5374} 5375 5376// String returns the string representation 5377func (s GetOutcomesInput) String() string { 5378 return awsutil.Prettify(s) 5379} 5380 5381// GoString returns the string representation 5382func (s GetOutcomesInput) GoString() string { 5383 return s.String() 5384} 5385 5386// Validate inspects the fields of the type to determine if they are valid. 5387func (s *GetOutcomesInput) Validate() error { 5388 invalidParams := request.ErrInvalidParams{Context: "GetOutcomesInput"} 5389 if s.MaxResults != nil && *s.MaxResults < 50 { 5390 invalidParams.Add(request.NewErrParamMinValue("MaxResults", 50)) 5391 } 5392 if s.Name != nil && len(*s.Name) < 1 { 5393 invalidParams.Add(request.NewErrParamMinLen("Name", 1)) 5394 } 5395 5396 if invalidParams.Len() > 0 { 5397 return invalidParams 5398 } 5399 return nil 5400} 5401 5402// SetMaxResults sets the MaxResults field's value. 5403func (s *GetOutcomesInput) SetMaxResults(v int64) *GetOutcomesInput { 5404 s.MaxResults = &v 5405 return s 5406} 5407 5408// SetName sets the Name field's value. 5409func (s *GetOutcomesInput) SetName(v string) *GetOutcomesInput { 5410 s.Name = &v 5411 return s 5412} 5413 5414// SetNextToken sets the NextToken field's value. 5415func (s *GetOutcomesInput) SetNextToken(v string) *GetOutcomesInput { 5416 s.NextToken = &v 5417 return s 5418} 5419 5420type GetOutcomesOutput struct { 5421 _ struct{} `type:"structure"` 5422 5423 // The next page token for subsequent requests. 5424 NextToken *string `locationName:"nextToken" type:"string"` 5425 5426 // The outcomes. 5427 Outcomes []*Outcome `locationName:"outcomes" type:"list"` 5428} 5429 5430// String returns the string representation 5431func (s GetOutcomesOutput) String() string { 5432 return awsutil.Prettify(s) 5433} 5434 5435// GoString returns the string representation 5436func (s GetOutcomesOutput) GoString() string { 5437 return s.String() 5438} 5439 5440// SetNextToken sets the NextToken field's value. 5441func (s *GetOutcomesOutput) SetNextToken(v string) *GetOutcomesOutput { 5442 s.NextToken = &v 5443 return s 5444} 5445 5446// SetOutcomes sets the Outcomes field's value. 5447func (s *GetOutcomesOutput) SetOutcomes(v []*Outcome) *GetOutcomesOutput { 5448 s.Outcomes = v 5449 return s 5450} 5451 5452type GetPredictionInput struct { 5453 _ struct{} `type:"structure"` 5454 5455 // The detector ID. 5456 // 5457 // DetectorId is a required field 5458 DetectorId *string `locationName:"detectorId" type:"string" required:"true"` 5459 5460 // The detector version ID. 5461 DetectorVersionId *string `locationName:"detectorVersionId" type:"string"` 5462 5463 // Names of variables you defined in Amazon Fraud Detector to represent event 5464 // data elements and their corresponding values for the event you are sending 5465 // for evaluation. 5466 EventAttributes map[string]*string `locationName:"eventAttributes" type:"map"` 5467 5468 // The unique ID used to identify the event. 5469 // 5470 // EventId is a required field 5471 EventId *string `locationName:"eventId" type:"string" required:"true"` 5472 5473 // The Amazon SageMaker model endpoint input data blobs. 5474 ExternalModelEndpointDataBlobs map[string]*ModelEndpointDataBlob `locationName:"externalModelEndpointDataBlobs" type:"map" sensitive:"true"` 5475} 5476 5477// String returns the string representation 5478func (s GetPredictionInput) String() string { 5479 return awsutil.Prettify(s) 5480} 5481 5482// GoString returns the string representation 5483func (s GetPredictionInput) GoString() string { 5484 return s.String() 5485} 5486 5487// Validate inspects the fields of the type to determine if they are valid. 5488func (s *GetPredictionInput) Validate() error { 5489 invalidParams := request.ErrInvalidParams{Context: "GetPredictionInput"} 5490 if s.DetectorId == nil { 5491 invalidParams.Add(request.NewErrParamRequired("DetectorId")) 5492 } 5493 if s.EventId == nil { 5494 invalidParams.Add(request.NewErrParamRequired("EventId")) 5495 } 5496 if s.ExternalModelEndpointDataBlobs != nil { 5497 for i, v := range s.ExternalModelEndpointDataBlobs { 5498 if v == nil { 5499 continue 5500 } 5501 if err := v.Validate(); err != nil { 5502 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "ExternalModelEndpointDataBlobs", i), err.(request.ErrInvalidParams)) 5503 } 5504 } 5505 } 5506 5507 if invalidParams.Len() > 0 { 5508 return invalidParams 5509 } 5510 return nil 5511} 5512 5513// SetDetectorId sets the DetectorId field's value. 5514func (s *GetPredictionInput) SetDetectorId(v string) *GetPredictionInput { 5515 s.DetectorId = &v 5516 return s 5517} 5518 5519// SetDetectorVersionId sets the DetectorVersionId field's value. 5520func (s *GetPredictionInput) SetDetectorVersionId(v string) *GetPredictionInput { 5521 s.DetectorVersionId = &v 5522 return s 5523} 5524 5525// SetEventAttributes sets the EventAttributes field's value. 5526func (s *GetPredictionInput) SetEventAttributes(v map[string]*string) *GetPredictionInput { 5527 s.EventAttributes = v 5528 return s 5529} 5530 5531// SetEventId sets the EventId field's value. 5532func (s *GetPredictionInput) SetEventId(v string) *GetPredictionInput { 5533 s.EventId = &v 5534 return s 5535} 5536 5537// SetExternalModelEndpointDataBlobs sets the ExternalModelEndpointDataBlobs field's value. 5538func (s *GetPredictionInput) SetExternalModelEndpointDataBlobs(v map[string]*ModelEndpointDataBlob) *GetPredictionInput { 5539 s.ExternalModelEndpointDataBlobs = v 5540 return s 5541} 5542 5543type GetPredictionOutput struct { 5544 _ struct{} `type:"structure"` 5545 5546 // The model scores for models used in the detector version. 5547 ModelScores []*ModelScores `locationName:"modelScores" type:"list"` 5548 5549 // The prediction outcomes. 5550 Outcomes []*string `locationName:"outcomes" type:"list"` 5551 5552 // The rule results in the prediction. 5553 RuleResults []*RuleResult `locationName:"ruleResults" type:"list"` 5554} 5555 5556// String returns the string representation 5557func (s GetPredictionOutput) String() string { 5558 return awsutil.Prettify(s) 5559} 5560 5561// GoString returns the string representation 5562func (s GetPredictionOutput) GoString() string { 5563 return s.String() 5564} 5565 5566// SetModelScores sets the ModelScores field's value. 5567func (s *GetPredictionOutput) SetModelScores(v []*ModelScores) *GetPredictionOutput { 5568 s.ModelScores = v 5569 return s 5570} 5571 5572// SetOutcomes sets the Outcomes field's value. 5573func (s *GetPredictionOutput) SetOutcomes(v []*string) *GetPredictionOutput { 5574 s.Outcomes = v 5575 return s 5576} 5577 5578// SetRuleResults sets the RuleResults field's value. 5579func (s *GetPredictionOutput) SetRuleResults(v []*RuleResult) *GetPredictionOutput { 5580 s.RuleResults = v 5581 return s 5582} 5583 5584type GetRulesInput struct { 5585 _ struct{} `type:"structure"` 5586 5587 // The detector ID. 5588 // 5589 // DetectorId is a required field 5590 DetectorId *string `locationName:"detectorId" min:"1" type:"string" required:"true"` 5591 5592 // The maximum number of rules to return for the request. 5593 MaxResults *int64 `locationName:"maxResults" min:"50" type:"integer"` 5594 5595 // The next page token. 5596 NextToken *string `locationName:"nextToken" type:"string"` 5597 5598 // The rule ID. 5599 RuleId *string `locationName:"ruleId" min:"1" type:"string"` 5600 5601 // The rule version. 5602 RuleVersion *string `locationName:"ruleVersion" min:"1" type:"string"` 5603} 5604 5605// String returns the string representation 5606func (s GetRulesInput) String() string { 5607 return awsutil.Prettify(s) 5608} 5609 5610// GoString returns the string representation 5611func (s GetRulesInput) GoString() string { 5612 return s.String() 5613} 5614 5615// Validate inspects the fields of the type to determine if they are valid. 5616func (s *GetRulesInput) Validate() error { 5617 invalidParams := request.ErrInvalidParams{Context: "GetRulesInput"} 5618 if s.DetectorId == nil { 5619 invalidParams.Add(request.NewErrParamRequired("DetectorId")) 5620 } 5621 if s.DetectorId != nil && len(*s.DetectorId) < 1 { 5622 invalidParams.Add(request.NewErrParamMinLen("DetectorId", 1)) 5623 } 5624 if s.MaxResults != nil && *s.MaxResults < 50 { 5625 invalidParams.Add(request.NewErrParamMinValue("MaxResults", 50)) 5626 } 5627 if s.RuleId != nil && len(*s.RuleId) < 1 { 5628 invalidParams.Add(request.NewErrParamMinLen("RuleId", 1)) 5629 } 5630 if s.RuleVersion != nil && len(*s.RuleVersion) < 1 { 5631 invalidParams.Add(request.NewErrParamMinLen("RuleVersion", 1)) 5632 } 5633 5634 if invalidParams.Len() > 0 { 5635 return invalidParams 5636 } 5637 return nil 5638} 5639 5640// SetDetectorId sets the DetectorId field's value. 5641func (s *GetRulesInput) SetDetectorId(v string) *GetRulesInput { 5642 s.DetectorId = &v 5643 return s 5644} 5645 5646// SetMaxResults sets the MaxResults field's value. 5647func (s *GetRulesInput) SetMaxResults(v int64) *GetRulesInput { 5648 s.MaxResults = &v 5649 return s 5650} 5651 5652// SetNextToken sets the NextToken field's value. 5653func (s *GetRulesInput) SetNextToken(v string) *GetRulesInput { 5654 s.NextToken = &v 5655 return s 5656} 5657 5658// SetRuleId sets the RuleId field's value. 5659func (s *GetRulesInput) SetRuleId(v string) *GetRulesInput { 5660 s.RuleId = &v 5661 return s 5662} 5663 5664// SetRuleVersion sets the RuleVersion field's value. 5665func (s *GetRulesInput) SetRuleVersion(v string) *GetRulesInput { 5666 s.RuleVersion = &v 5667 return s 5668} 5669 5670type GetRulesOutput struct { 5671 _ struct{} `type:"structure"` 5672 5673 // The next page token to be used in subsequent requests. 5674 NextToken *string `locationName:"nextToken" type:"string"` 5675 5676 // The details of the requested rule. 5677 RuleDetails []*RuleDetail `locationName:"ruleDetails" type:"list"` 5678} 5679 5680// String returns the string representation 5681func (s GetRulesOutput) String() string { 5682 return awsutil.Prettify(s) 5683} 5684 5685// GoString returns the string representation 5686func (s GetRulesOutput) GoString() string { 5687 return s.String() 5688} 5689 5690// SetNextToken sets the NextToken field's value. 5691func (s *GetRulesOutput) SetNextToken(v string) *GetRulesOutput { 5692 s.NextToken = &v 5693 return s 5694} 5695 5696// SetRuleDetails sets the RuleDetails field's value. 5697func (s *GetRulesOutput) SetRuleDetails(v []*RuleDetail) *GetRulesOutput { 5698 s.RuleDetails = v 5699 return s 5700} 5701 5702type GetVariablesInput struct { 5703 _ struct{} `type:"structure"` 5704 5705 // The max size per page determined for the get variable request. 5706 MaxResults *int64 `locationName:"maxResults" min:"50" type:"integer"` 5707 5708 // The name of the variable. 5709 Name *string `locationName:"name" type:"string"` 5710 5711 // The next page token of the get variable request. 5712 NextToken *string `locationName:"nextToken" type:"string"` 5713} 5714 5715// String returns the string representation 5716func (s GetVariablesInput) String() string { 5717 return awsutil.Prettify(s) 5718} 5719 5720// GoString returns the string representation 5721func (s GetVariablesInput) GoString() string { 5722 return s.String() 5723} 5724 5725// Validate inspects the fields of the type to determine if they are valid. 5726func (s *GetVariablesInput) Validate() error { 5727 invalidParams := request.ErrInvalidParams{Context: "GetVariablesInput"} 5728 if s.MaxResults != nil && *s.MaxResults < 50 { 5729 invalidParams.Add(request.NewErrParamMinValue("MaxResults", 50)) 5730 } 5731 5732 if invalidParams.Len() > 0 { 5733 return invalidParams 5734 } 5735 return nil 5736} 5737 5738// SetMaxResults sets the MaxResults field's value. 5739func (s *GetVariablesInput) SetMaxResults(v int64) *GetVariablesInput { 5740 s.MaxResults = &v 5741 return s 5742} 5743 5744// SetName sets the Name field's value. 5745func (s *GetVariablesInput) SetName(v string) *GetVariablesInput { 5746 s.Name = &v 5747 return s 5748} 5749 5750// SetNextToken sets the NextToken field's value. 5751func (s *GetVariablesInput) SetNextToken(v string) *GetVariablesInput { 5752 s.NextToken = &v 5753 return s 5754} 5755 5756type GetVariablesOutput struct { 5757 _ struct{} `type:"structure"` 5758 5759 // The next page token to be used in subsequent requests. 5760 NextToken *string `locationName:"nextToken" type:"string"` 5761 5762 // The names of the variables returned. 5763 Variables []*Variable `locationName:"variables" type:"list"` 5764} 5765 5766// String returns the string representation 5767func (s GetVariablesOutput) String() string { 5768 return awsutil.Prettify(s) 5769} 5770 5771// GoString returns the string representation 5772func (s GetVariablesOutput) GoString() string { 5773 return s.String() 5774} 5775 5776// SetNextToken sets the NextToken field's value. 5777func (s *GetVariablesOutput) SetNextToken(v string) *GetVariablesOutput { 5778 s.NextToken = &v 5779 return s 5780} 5781 5782// SetVariables sets the Variables field's value. 5783func (s *GetVariablesOutput) SetVariables(v []*Variable) *GetVariablesOutput { 5784 s.Variables = v 5785 return s 5786} 5787 5788// An exception indicating an internal server error. 5789type InternalServerException struct { 5790 _ struct{} `type:"structure"` 5791 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 5792 5793 Message_ *string `locationName:"message" type:"string"` 5794} 5795 5796// String returns the string representation 5797func (s InternalServerException) String() string { 5798 return awsutil.Prettify(s) 5799} 5800 5801// GoString returns the string representation 5802func (s InternalServerException) GoString() string { 5803 return s.String() 5804} 5805 5806func newErrorInternalServerException(v protocol.ResponseMetadata) error { 5807 return &InternalServerException{ 5808 RespMetadata: v, 5809 } 5810} 5811 5812// Code returns the exception type name. 5813func (s *InternalServerException) Code() string { 5814 return "InternalServerException" 5815} 5816 5817// Message returns the exception's message. 5818func (s *InternalServerException) Message() string { 5819 if s.Message_ != nil { 5820 return *s.Message_ 5821 } 5822 return "" 5823} 5824 5825// OrigErr always returns nil, satisfies awserr.Error interface. 5826func (s *InternalServerException) OrigErr() error { 5827 return nil 5828} 5829 5830func (s *InternalServerException) Error() string { 5831 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 5832} 5833 5834// Status code returns the HTTP status code for the request's response error. 5835func (s *InternalServerException) StatusCode() int { 5836 return s.RespMetadata.StatusCode 5837} 5838 5839// RequestID returns the service's response RequestID for request. 5840func (s *InternalServerException) RequestID() string { 5841 return s.RespMetadata.RequestID 5842} 5843 5844// The label schema. 5845type LabelSchema struct { 5846 _ struct{} `type:"structure"` 5847 5848 // The label key. 5849 // 5850 // LabelKey is a required field 5851 LabelKey *string `locationName:"labelKey" type:"string" required:"true"` 5852 5853 // The label mapper maps the Amazon Fraud Detector supported label to the appropriate 5854 // source labels. For example, if "FRAUD" and "LEGIT" are Amazon Fraud Detector 5855 // supported labels, this mapper could be: {"FRAUD" => ["0"], "LEGIT" => ["1"]} 5856 // or {"FRAUD" => ["false"], "LEGIT" => ["true"]} or {"FRAUD" => ["fraud", "abuse"], 5857 // "LEGIT" => ["legit", "safe"]}. The value part of the mapper is a list, because 5858 // you may have multiple variants for a single Amazon Fraud Detector label. 5859 // 5860 // LabelMapper is a required field 5861 LabelMapper map[string][]*string `locationName:"labelMapper" type:"map" required:"true"` 5862} 5863 5864// String returns the string representation 5865func (s LabelSchema) String() string { 5866 return awsutil.Prettify(s) 5867} 5868 5869// GoString returns the string representation 5870func (s LabelSchema) GoString() string { 5871 return s.String() 5872} 5873 5874// Validate inspects the fields of the type to determine if they are valid. 5875func (s *LabelSchema) Validate() error { 5876 invalidParams := request.ErrInvalidParams{Context: "LabelSchema"} 5877 if s.LabelKey == nil { 5878 invalidParams.Add(request.NewErrParamRequired("LabelKey")) 5879 } 5880 if s.LabelMapper == nil { 5881 invalidParams.Add(request.NewErrParamRequired("LabelMapper")) 5882 } 5883 5884 if invalidParams.Len() > 0 { 5885 return invalidParams 5886 } 5887 return nil 5888} 5889 5890// SetLabelKey sets the LabelKey field's value. 5891func (s *LabelSchema) SetLabelKey(v string) *LabelSchema { 5892 s.LabelKey = &v 5893 return s 5894} 5895 5896// SetLabelMapper sets the LabelMapper field's value. 5897func (s *LabelSchema) SetLabelMapper(v map[string][]*string) *LabelSchema { 5898 s.LabelMapper = v 5899 return s 5900} 5901 5902// The model. 5903type Model struct { 5904 _ struct{} `type:"structure"` 5905 5906 // Timestamp of when the model was created. 5907 CreatedTime *string `locationName:"createdTime" type:"string"` 5908 5909 // The model description. 5910 Description *string `locationName:"description" min:"1" type:"string"` 5911 5912 // The model label schema. 5913 LabelSchema *LabelSchema `locationName:"labelSchema" type:"structure"` 5914 5915 // Timestamp of last time the model was updated. 5916 LastUpdatedTime *string `locationName:"lastUpdatedTime" type:"string"` 5917 5918 // The model ID. 5919 ModelId *string `locationName:"modelId" min:"1" type:"string"` 5920 5921 // The model type. 5922 ModelType *string `locationName:"modelType" type:"string" enum:"ModelTypeEnum"` 5923 5924 // The model input variables. 5925 ModelVariables []*ModelVariable `locationName:"modelVariables" type:"list"` 5926 5927 // The model training data source in Amazon S3. 5928 TrainingDataSource *TrainingDataSource `locationName:"trainingDataSource" type:"structure"` 5929} 5930 5931// String returns the string representation 5932func (s Model) String() string { 5933 return awsutil.Prettify(s) 5934} 5935 5936// GoString returns the string representation 5937func (s Model) GoString() string { 5938 return s.String() 5939} 5940 5941// SetCreatedTime sets the CreatedTime field's value. 5942func (s *Model) SetCreatedTime(v string) *Model { 5943 s.CreatedTime = &v 5944 return s 5945} 5946 5947// SetDescription sets the Description field's value. 5948func (s *Model) SetDescription(v string) *Model { 5949 s.Description = &v 5950 return s 5951} 5952 5953// SetLabelSchema sets the LabelSchema field's value. 5954func (s *Model) SetLabelSchema(v *LabelSchema) *Model { 5955 s.LabelSchema = v 5956 return s 5957} 5958 5959// SetLastUpdatedTime sets the LastUpdatedTime field's value. 5960func (s *Model) SetLastUpdatedTime(v string) *Model { 5961 s.LastUpdatedTime = &v 5962 return s 5963} 5964 5965// SetModelId sets the ModelId field's value. 5966func (s *Model) SetModelId(v string) *Model { 5967 s.ModelId = &v 5968 return s 5969} 5970 5971// SetModelType sets the ModelType field's value. 5972func (s *Model) SetModelType(v string) *Model { 5973 s.ModelType = &v 5974 return s 5975} 5976 5977// SetModelVariables sets the ModelVariables field's value. 5978func (s *Model) SetModelVariables(v []*ModelVariable) *Model { 5979 s.ModelVariables = v 5980 return s 5981} 5982 5983// SetTrainingDataSource sets the TrainingDataSource field's value. 5984func (s *Model) SetTrainingDataSource(v *TrainingDataSource) *Model { 5985 s.TrainingDataSource = v 5986 return s 5987} 5988 5989// A pre-formed Amazon SageMaker model input you can include if your detector 5990// version includes an imported Amazon SageMaker model endpoint with pass-through 5991// input configuration. 5992type ModelEndpointDataBlob struct { 5993 _ struct{} `type:"structure"` 5994 5995 // The byte buffer of the Amazon SageMaker model endpoint input data blob. 5996 // 5997 // ByteBuffer is automatically base64 encoded/decoded by the SDK. 5998 ByteBuffer []byte `locationName:"byteBuffer" type:"blob"` 5999 6000 // The content type of the Amazon SageMaker model endpoint input data blob. 6001 ContentType *string `locationName:"contentType" min:"1" type:"string"` 6002} 6003 6004// String returns the string representation 6005func (s ModelEndpointDataBlob) String() string { 6006 return awsutil.Prettify(s) 6007} 6008 6009// GoString returns the string representation 6010func (s ModelEndpointDataBlob) GoString() string { 6011 return s.String() 6012} 6013 6014// Validate inspects the fields of the type to determine if they are valid. 6015func (s *ModelEndpointDataBlob) Validate() error { 6016 invalidParams := request.ErrInvalidParams{Context: "ModelEndpointDataBlob"} 6017 if s.ContentType != nil && len(*s.ContentType) < 1 { 6018 invalidParams.Add(request.NewErrParamMinLen("ContentType", 1)) 6019 } 6020 6021 if invalidParams.Len() > 0 { 6022 return invalidParams 6023 } 6024 return nil 6025} 6026 6027// SetByteBuffer sets the ByteBuffer field's value. 6028func (s *ModelEndpointDataBlob) SetByteBuffer(v []byte) *ModelEndpointDataBlob { 6029 s.ByteBuffer = v 6030 return s 6031} 6032 6033// SetContentType sets the ContentType field's value. 6034func (s *ModelEndpointDataBlob) SetContentType(v string) *ModelEndpointDataBlob { 6035 s.ContentType = &v 6036 return s 6037} 6038 6039// The model input configuration. 6040type ModelInputConfiguration struct { 6041 _ struct{} `type:"structure"` 6042 6043 // Template for constructing the CSV input-data sent to SageMaker. At event-evaluation, 6044 // the placeholders for variable-names in the template will be replaced with 6045 // the variable values before being sent to SageMaker. 6046 CsvInputTemplate *string `locationName:"csvInputTemplate" type:"string"` 6047 6048 // The format of the model input configuration. The format differs depending 6049 // on if it is passed through to SageMaker or constructed by Amazon Fraud Detector. 6050 Format *string `locationName:"format" type:"string" enum:"ModelInputDataFormat"` 6051 6052 // For an opaque-model, the input to the model will be a ByteBuffer blob provided 6053 // in the getPrediction request, and will be passed to SageMaker as-is. For 6054 // non-opaque models, the input will be constructed by Amazon Fraud Detector 6055 // based on the model-configuration. 6056 // 6057 // IsOpaque is a required field 6058 IsOpaque *bool `locationName:"isOpaque" type:"boolean" required:"true"` 6059 6060 // Template for constructing the JSON input-data sent to SageMaker. At event-evaluation, 6061 // the placeholders for variable names in the template will be replaced with 6062 // the variable values before being sent to SageMaker. 6063 JsonInputTemplate *string `locationName:"jsonInputTemplate" type:"string"` 6064} 6065 6066// String returns the string representation 6067func (s ModelInputConfiguration) String() string { 6068 return awsutil.Prettify(s) 6069} 6070 6071// GoString returns the string representation 6072func (s ModelInputConfiguration) GoString() string { 6073 return s.String() 6074} 6075 6076// Validate inspects the fields of the type to determine if they are valid. 6077func (s *ModelInputConfiguration) Validate() error { 6078 invalidParams := request.ErrInvalidParams{Context: "ModelInputConfiguration"} 6079 if s.IsOpaque == nil { 6080 invalidParams.Add(request.NewErrParamRequired("IsOpaque")) 6081 } 6082 6083 if invalidParams.Len() > 0 { 6084 return invalidParams 6085 } 6086 return nil 6087} 6088 6089// SetCsvInputTemplate sets the CsvInputTemplate field's value. 6090func (s *ModelInputConfiguration) SetCsvInputTemplate(v string) *ModelInputConfiguration { 6091 s.CsvInputTemplate = &v 6092 return s 6093} 6094 6095// SetFormat sets the Format field's value. 6096func (s *ModelInputConfiguration) SetFormat(v string) *ModelInputConfiguration { 6097 s.Format = &v 6098 return s 6099} 6100 6101// SetIsOpaque sets the IsOpaque field's value. 6102func (s *ModelInputConfiguration) SetIsOpaque(v bool) *ModelInputConfiguration { 6103 s.IsOpaque = &v 6104 return s 6105} 6106 6107// SetJsonInputTemplate sets the JsonInputTemplate field's value. 6108func (s *ModelInputConfiguration) SetJsonInputTemplate(v string) *ModelInputConfiguration { 6109 s.JsonInputTemplate = &v 6110 return s 6111} 6112 6113// Provides the model output configuration. 6114type ModelOutputConfiguration struct { 6115 _ struct{} `type:"structure"` 6116 6117 // A map of CSV index values in the SageMaker response to the Amazon Fraud Detector 6118 // variables. 6119 CsvIndexToVariableMap map[string]*string `locationName:"csvIndexToVariableMap" type:"map"` 6120 6121 // The format of the model output configuration. 6122 // 6123 // Format is a required field 6124 Format *string `locationName:"format" type:"string" required:"true" enum:"ModelOutputDataFormat"` 6125 6126 // A map of JSON keys in response from SageMaker to the Amazon Fraud Detector 6127 // variables. 6128 JsonKeyToVariableMap map[string]*string `locationName:"jsonKeyToVariableMap" type:"map"` 6129} 6130 6131// String returns the string representation 6132func (s ModelOutputConfiguration) String() string { 6133 return awsutil.Prettify(s) 6134} 6135 6136// GoString returns the string representation 6137func (s ModelOutputConfiguration) GoString() string { 6138 return s.String() 6139} 6140 6141// Validate inspects the fields of the type to determine if they are valid. 6142func (s *ModelOutputConfiguration) Validate() error { 6143 invalidParams := request.ErrInvalidParams{Context: "ModelOutputConfiguration"} 6144 if s.Format == nil { 6145 invalidParams.Add(request.NewErrParamRequired("Format")) 6146 } 6147 6148 if invalidParams.Len() > 0 { 6149 return invalidParams 6150 } 6151 return nil 6152} 6153 6154// SetCsvIndexToVariableMap sets the CsvIndexToVariableMap field's value. 6155func (s *ModelOutputConfiguration) SetCsvIndexToVariableMap(v map[string]*string) *ModelOutputConfiguration { 6156 s.CsvIndexToVariableMap = v 6157 return s 6158} 6159 6160// SetFormat sets the Format field's value. 6161func (s *ModelOutputConfiguration) SetFormat(v string) *ModelOutputConfiguration { 6162 s.Format = &v 6163 return s 6164} 6165 6166// SetJsonKeyToVariableMap sets the JsonKeyToVariableMap field's value. 6167func (s *ModelOutputConfiguration) SetJsonKeyToVariableMap(v map[string]*string) *ModelOutputConfiguration { 6168 s.JsonKeyToVariableMap = v 6169 return s 6170} 6171 6172// The fraud prediction scores. 6173type ModelScores struct { 6174 _ struct{} `type:"structure"` 6175 6176 // The model version. 6177 ModelVersion *ModelVersion `locationName:"modelVersion" type:"structure"` 6178 6179 // The model's fraud prediction scores. 6180 Scores map[string]*float64 `locationName:"scores" type:"map"` 6181} 6182 6183// String returns the string representation 6184func (s ModelScores) String() string { 6185 return awsutil.Prettify(s) 6186} 6187 6188// GoString returns the string representation 6189func (s ModelScores) GoString() string { 6190 return s.String() 6191} 6192 6193// SetModelVersion sets the ModelVersion field's value. 6194func (s *ModelScores) SetModelVersion(v *ModelVersion) *ModelScores { 6195 s.ModelVersion = v 6196 return s 6197} 6198 6199// SetScores sets the Scores field's value. 6200func (s *ModelScores) SetScores(v map[string]*float64) *ModelScores { 6201 s.Scores = v 6202 return s 6203} 6204 6205// The model variable.> 6206type ModelVariable struct { 6207 _ struct{} `type:"structure"` 6208 6209 // The model variable's index.> 6210 Index *int64 `locationName:"index" type:"integer"` 6211 6212 // The model variable's name.> 6213 // 6214 // Name is a required field 6215 Name *string `locationName:"name" type:"string" required:"true"` 6216} 6217 6218// String returns the string representation 6219func (s ModelVariable) String() string { 6220 return awsutil.Prettify(s) 6221} 6222 6223// GoString returns the string representation 6224func (s ModelVariable) GoString() string { 6225 return s.String() 6226} 6227 6228// Validate inspects the fields of the type to determine if they are valid. 6229func (s *ModelVariable) Validate() error { 6230 invalidParams := request.ErrInvalidParams{Context: "ModelVariable"} 6231 if s.Name == nil { 6232 invalidParams.Add(request.NewErrParamRequired("Name")) 6233 } 6234 6235 if invalidParams.Len() > 0 { 6236 return invalidParams 6237 } 6238 return nil 6239} 6240 6241// SetIndex sets the Index field's value. 6242func (s *ModelVariable) SetIndex(v int64) *ModelVariable { 6243 s.Index = &v 6244 return s 6245} 6246 6247// SetName sets the Name field's value. 6248func (s *ModelVariable) SetName(v string) *ModelVariable { 6249 s.Name = &v 6250 return s 6251} 6252 6253// The model version. 6254type ModelVersion struct { 6255 _ struct{} `type:"structure"` 6256 6257 // The parent model ID. 6258 // 6259 // ModelId is a required field 6260 ModelId *string `locationName:"modelId" min:"1" type:"string" required:"true"` 6261 6262 // The model type. 6263 // 6264 // ModelType is a required field 6265 ModelType *string `locationName:"modelType" type:"string" required:"true" enum:"ModelTypeEnum"` 6266 6267 // The model version. 6268 // 6269 // ModelVersionNumber is a required field 6270 ModelVersionNumber *string `locationName:"modelVersionNumber" min:"1" type:"string" required:"true"` 6271} 6272 6273// String returns the string representation 6274func (s ModelVersion) String() string { 6275 return awsutil.Prettify(s) 6276} 6277 6278// GoString returns the string representation 6279func (s ModelVersion) GoString() string { 6280 return s.String() 6281} 6282 6283// Validate inspects the fields of the type to determine if they are valid. 6284func (s *ModelVersion) Validate() error { 6285 invalidParams := request.ErrInvalidParams{Context: "ModelVersion"} 6286 if s.ModelId == nil { 6287 invalidParams.Add(request.NewErrParamRequired("ModelId")) 6288 } 6289 if s.ModelId != nil && len(*s.ModelId) < 1 { 6290 invalidParams.Add(request.NewErrParamMinLen("ModelId", 1)) 6291 } 6292 if s.ModelType == nil { 6293 invalidParams.Add(request.NewErrParamRequired("ModelType")) 6294 } 6295 if s.ModelVersionNumber == nil { 6296 invalidParams.Add(request.NewErrParamRequired("ModelVersionNumber")) 6297 } 6298 if s.ModelVersionNumber != nil && len(*s.ModelVersionNumber) < 1 { 6299 invalidParams.Add(request.NewErrParamMinLen("ModelVersionNumber", 1)) 6300 } 6301 6302 if invalidParams.Len() > 0 { 6303 return invalidParams 6304 } 6305 return nil 6306} 6307 6308// SetModelId sets the ModelId field's value. 6309func (s *ModelVersion) SetModelId(v string) *ModelVersion { 6310 s.ModelId = &v 6311 return s 6312} 6313 6314// SetModelType sets the ModelType field's value. 6315func (s *ModelVersion) SetModelType(v string) *ModelVersion { 6316 s.ModelType = &v 6317 return s 6318} 6319 6320// SetModelVersionNumber sets the ModelVersionNumber field's value. 6321func (s *ModelVersion) SetModelVersionNumber(v string) *ModelVersion { 6322 s.ModelVersionNumber = &v 6323 return s 6324} 6325 6326// Provides the model version details. 6327type ModelVersionDetail struct { 6328 _ struct{} `type:"structure"` 6329 6330 // The timestamp when the model was created. 6331 CreatedTime *string `locationName:"createdTime" type:"string"` 6332 6333 // The model description. 6334 Description *string `locationName:"description" min:"1" type:"string"` 6335 6336 // The model label schema. 6337 LabelSchema *LabelSchema `locationName:"labelSchema" type:"structure"` 6338 6339 // The timestamp when the model was last updated. 6340 LastUpdatedTime *string `locationName:"lastUpdatedTime" type:"string"` 6341 6342 // The model ID. 6343 ModelId *string `locationName:"modelId" min:"1" type:"string"` 6344 6345 // The model type. 6346 ModelType *string `locationName:"modelType" type:"string" enum:"ModelTypeEnum"` 6347 6348 // The model variables. 6349 ModelVariables []*ModelVariable `locationName:"modelVariables" type:"list"` 6350 6351 // The model version. 6352 ModelVersionNumber *string `locationName:"modelVersionNumber" min:"1" type:"string"` 6353 6354 // The model status. 6355 Status *string `locationName:"status" type:"string"` 6356 6357 // The model training data source. 6358 TrainingDataSource *TrainingDataSource `locationName:"trainingDataSource" type:"structure"` 6359 6360 // The model training metrics. 6361 TrainingMetrics map[string]*string `locationName:"trainingMetrics" type:"map"` 6362 6363 // The model validation metrics. 6364 ValidationMetrics map[string]*string `locationName:"validationMetrics" type:"map"` 6365} 6366 6367// String returns the string representation 6368func (s ModelVersionDetail) String() string { 6369 return awsutil.Prettify(s) 6370} 6371 6372// GoString returns the string representation 6373func (s ModelVersionDetail) GoString() string { 6374 return s.String() 6375} 6376 6377// SetCreatedTime sets the CreatedTime field's value. 6378func (s *ModelVersionDetail) SetCreatedTime(v string) *ModelVersionDetail { 6379 s.CreatedTime = &v 6380 return s 6381} 6382 6383// SetDescription sets the Description field's value. 6384func (s *ModelVersionDetail) SetDescription(v string) *ModelVersionDetail { 6385 s.Description = &v 6386 return s 6387} 6388 6389// SetLabelSchema sets the LabelSchema field's value. 6390func (s *ModelVersionDetail) SetLabelSchema(v *LabelSchema) *ModelVersionDetail { 6391 s.LabelSchema = v 6392 return s 6393} 6394 6395// SetLastUpdatedTime sets the LastUpdatedTime field's value. 6396func (s *ModelVersionDetail) SetLastUpdatedTime(v string) *ModelVersionDetail { 6397 s.LastUpdatedTime = &v 6398 return s 6399} 6400 6401// SetModelId sets the ModelId field's value. 6402func (s *ModelVersionDetail) SetModelId(v string) *ModelVersionDetail { 6403 s.ModelId = &v 6404 return s 6405} 6406 6407// SetModelType sets the ModelType field's value. 6408func (s *ModelVersionDetail) SetModelType(v string) *ModelVersionDetail { 6409 s.ModelType = &v 6410 return s 6411} 6412 6413// SetModelVariables sets the ModelVariables field's value. 6414func (s *ModelVersionDetail) SetModelVariables(v []*ModelVariable) *ModelVersionDetail { 6415 s.ModelVariables = v 6416 return s 6417} 6418 6419// SetModelVersionNumber sets the ModelVersionNumber field's value. 6420func (s *ModelVersionDetail) SetModelVersionNumber(v string) *ModelVersionDetail { 6421 s.ModelVersionNumber = &v 6422 return s 6423} 6424 6425// SetStatus sets the Status field's value. 6426func (s *ModelVersionDetail) SetStatus(v string) *ModelVersionDetail { 6427 s.Status = &v 6428 return s 6429} 6430 6431// SetTrainingDataSource sets the TrainingDataSource field's value. 6432func (s *ModelVersionDetail) SetTrainingDataSource(v *TrainingDataSource) *ModelVersionDetail { 6433 s.TrainingDataSource = v 6434 return s 6435} 6436 6437// SetTrainingMetrics sets the TrainingMetrics field's value. 6438func (s *ModelVersionDetail) SetTrainingMetrics(v map[string]*string) *ModelVersionDetail { 6439 s.TrainingMetrics = v 6440 return s 6441} 6442 6443// SetValidationMetrics sets the ValidationMetrics field's value. 6444func (s *ModelVersionDetail) SetValidationMetrics(v map[string]*string) *ModelVersionDetail { 6445 s.ValidationMetrics = v 6446 return s 6447} 6448 6449// The outcome. 6450type Outcome struct { 6451 _ struct{} `type:"structure"` 6452 6453 // The timestamp when the outcome was created. 6454 CreatedTime *string `locationName:"createdTime" type:"string"` 6455 6456 // The outcome description. 6457 Description *string `locationName:"description" min:"1" type:"string"` 6458 6459 // The timestamp when the outcome was last updated. 6460 LastUpdatedTime *string `locationName:"lastUpdatedTime" type:"string"` 6461 6462 // The outcome name. 6463 Name *string `locationName:"name" min:"1" type:"string"` 6464} 6465 6466// String returns the string representation 6467func (s Outcome) String() string { 6468 return awsutil.Prettify(s) 6469} 6470 6471// GoString returns the string representation 6472func (s Outcome) GoString() string { 6473 return s.String() 6474} 6475 6476// SetCreatedTime sets the CreatedTime field's value. 6477func (s *Outcome) SetCreatedTime(v string) *Outcome { 6478 s.CreatedTime = &v 6479 return s 6480} 6481 6482// SetDescription sets the Description field's value. 6483func (s *Outcome) SetDescription(v string) *Outcome { 6484 s.Description = &v 6485 return s 6486} 6487 6488// SetLastUpdatedTime sets the LastUpdatedTime field's value. 6489func (s *Outcome) SetLastUpdatedTime(v string) *Outcome { 6490 s.LastUpdatedTime = &v 6491 return s 6492} 6493 6494// SetName sets the Name field's value. 6495func (s *Outcome) SetName(v string) *Outcome { 6496 s.Name = &v 6497 return s 6498} 6499 6500type PutDetectorInput struct { 6501 _ struct{} `type:"structure"` 6502 6503 // The description of the detector. 6504 Description *string `locationName:"description" min:"1" type:"string"` 6505 6506 // The detector ID. 6507 // 6508 // DetectorId is a required field 6509 DetectorId *string `locationName:"detectorId" min:"1" type:"string" required:"true"` 6510} 6511 6512// String returns the string representation 6513func (s PutDetectorInput) String() string { 6514 return awsutil.Prettify(s) 6515} 6516 6517// GoString returns the string representation 6518func (s PutDetectorInput) GoString() string { 6519 return s.String() 6520} 6521 6522// Validate inspects the fields of the type to determine if they are valid. 6523func (s *PutDetectorInput) Validate() error { 6524 invalidParams := request.ErrInvalidParams{Context: "PutDetectorInput"} 6525 if s.Description != nil && len(*s.Description) < 1 { 6526 invalidParams.Add(request.NewErrParamMinLen("Description", 1)) 6527 } 6528 if s.DetectorId == nil { 6529 invalidParams.Add(request.NewErrParamRequired("DetectorId")) 6530 } 6531 if s.DetectorId != nil && len(*s.DetectorId) < 1 { 6532 invalidParams.Add(request.NewErrParamMinLen("DetectorId", 1)) 6533 } 6534 6535 if invalidParams.Len() > 0 { 6536 return invalidParams 6537 } 6538 return nil 6539} 6540 6541// SetDescription sets the Description field's value. 6542func (s *PutDetectorInput) SetDescription(v string) *PutDetectorInput { 6543 s.Description = &v 6544 return s 6545} 6546 6547// SetDetectorId sets the DetectorId field's value. 6548func (s *PutDetectorInput) SetDetectorId(v string) *PutDetectorInput { 6549 s.DetectorId = &v 6550 return s 6551} 6552 6553type PutDetectorOutput struct { 6554 _ struct{} `type:"structure"` 6555} 6556 6557// String returns the string representation 6558func (s PutDetectorOutput) String() string { 6559 return awsutil.Prettify(s) 6560} 6561 6562// GoString returns the string representation 6563func (s PutDetectorOutput) GoString() string { 6564 return s.String() 6565} 6566 6567type PutExternalModelInput struct { 6568 _ struct{} `type:"structure"` 6569 6570 // The model endpoint input configuration. 6571 // 6572 // InputConfiguration is a required field 6573 InputConfiguration *ModelInputConfiguration `locationName:"inputConfiguration" type:"structure" required:"true"` 6574 6575 // The model endpoints name. 6576 // 6577 // ModelEndpoint is a required field 6578 ModelEndpoint *string `locationName:"modelEndpoint" type:"string" required:"true"` 6579 6580 // The model endpoint’s status in Amazon Fraud Detector. 6581 // 6582 // ModelEndpointStatus is a required field 6583 ModelEndpointStatus *string `locationName:"modelEndpointStatus" type:"string" required:"true" enum:"ModelEndpointStatus"` 6584 6585 // The source of the model. 6586 // 6587 // ModelSource is a required field 6588 ModelSource *string `locationName:"modelSource" type:"string" required:"true" enum:"ModelSource"` 6589 6590 // The model endpoint output configuration. 6591 // 6592 // OutputConfiguration is a required field 6593 OutputConfiguration *ModelOutputConfiguration `locationName:"outputConfiguration" type:"structure" required:"true"` 6594 6595 // The IAM role used to invoke the model endpoint. 6596 // 6597 // Role is a required field 6598 Role *Role `locationName:"role" type:"structure" required:"true"` 6599} 6600 6601// String returns the string representation 6602func (s PutExternalModelInput) String() string { 6603 return awsutil.Prettify(s) 6604} 6605 6606// GoString returns the string representation 6607func (s PutExternalModelInput) GoString() string { 6608 return s.String() 6609} 6610 6611// Validate inspects the fields of the type to determine if they are valid. 6612func (s *PutExternalModelInput) Validate() error { 6613 invalidParams := request.ErrInvalidParams{Context: "PutExternalModelInput"} 6614 if s.InputConfiguration == nil { 6615 invalidParams.Add(request.NewErrParamRequired("InputConfiguration")) 6616 } 6617 if s.ModelEndpoint == nil { 6618 invalidParams.Add(request.NewErrParamRequired("ModelEndpoint")) 6619 } 6620 if s.ModelEndpointStatus == nil { 6621 invalidParams.Add(request.NewErrParamRequired("ModelEndpointStatus")) 6622 } 6623 if s.ModelSource == nil { 6624 invalidParams.Add(request.NewErrParamRequired("ModelSource")) 6625 } 6626 if s.OutputConfiguration == nil { 6627 invalidParams.Add(request.NewErrParamRequired("OutputConfiguration")) 6628 } 6629 if s.Role == nil { 6630 invalidParams.Add(request.NewErrParamRequired("Role")) 6631 } 6632 if s.InputConfiguration != nil { 6633 if err := s.InputConfiguration.Validate(); err != nil { 6634 invalidParams.AddNested("InputConfiguration", err.(request.ErrInvalidParams)) 6635 } 6636 } 6637 if s.OutputConfiguration != nil { 6638 if err := s.OutputConfiguration.Validate(); err != nil { 6639 invalidParams.AddNested("OutputConfiguration", err.(request.ErrInvalidParams)) 6640 } 6641 } 6642 if s.Role != nil { 6643 if err := s.Role.Validate(); err != nil { 6644 invalidParams.AddNested("Role", err.(request.ErrInvalidParams)) 6645 } 6646 } 6647 6648 if invalidParams.Len() > 0 { 6649 return invalidParams 6650 } 6651 return nil 6652} 6653 6654// SetInputConfiguration sets the InputConfiguration field's value. 6655func (s *PutExternalModelInput) SetInputConfiguration(v *ModelInputConfiguration) *PutExternalModelInput { 6656 s.InputConfiguration = v 6657 return s 6658} 6659 6660// SetModelEndpoint sets the ModelEndpoint field's value. 6661func (s *PutExternalModelInput) SetModelEndpoint(v string) *PutExternalModelInput { 6662 s.ModelEndpoint = &v 6663 return s 6664} 6665 6666// SetModelEndpointStatus sets the ModelEndpointStatus field's value. 6667func (s *PutExternalModelInput) SetModelEndpointStatus(v string) *PutExternalModelInput { 6668 s.ModelEndpointStatus = &v 6669 return s 6670} 6671 6672// SetModelSource sets the ModelSource field's value. 6673func (s *PutExternalModelInput) SetModelSource(v string) *PutExternalModelInput { 6674 s.ModelSource = &v 6675 return s 6676} 6677 6678// SetOutputConfiguration sets the OutputConfiguration field's value. 6679func (s *PutExternalModelInput) SetOutputConfiguration(v *ModelOutputConfiguration) *PutExternalModelInput { 6680 s.OutputConfiguration = v 6681 return s 6682} 6683 6684// SetRole sets the Role field's value. 6685func (s *PutExternalModelInput) SetRole(v *Role) *PutExternalModelInput { 6686 s.Role = v 6687 return s 6688} 6689 6690type PutExternalModelOutput struct { 6691 _ struct{} `type:"structure"` 6692} 6693 6694// String returns the string representation 6695func (s PutExternalModelOutput) String() string { 6696 return awsutil.Prettify(s) 6697} 6698 6699// GoString returns the string representation 6700func (s PutExternalModelOutput) GoString() string { 6701 return s.String() 6702} 6703 6704type PutModelInput struct { 6705 _ struct{} `type:"structure"` 6706 6707 // The model description. 6708 Description *string `locationName:"description" min:"1" type:"string"` 6709 6710 // The label schema. 6711 // 6712 // LabelSchema is a required field 6713 LabelSchema *LabelSchema `locationName:"labelSchema" type:"structure" required:"true"` 6714 6715 // The model ID. 6716 // 6717 // ModelId is a required field 6718 ModelId *string `locationName:"modelId" min:"1" type:"string" required:"true"` 6719 6720 // The model type. 6721 // 6722 // ModelType is a required field 6723 ModelType *string `locationName:"modelType" type:"string" required:"true" enum:"ModelTypeEnum"` 6724 6725 // The model input variables. 6726 // 6727 // ModelVariables is a required field 6728 ModelVariables []*ModelVariable `locationName:"modelVariables" type:"list" required:"true"` 6729 6730 // The training data source location in Amazon S3. 6731 // 6732 // TrainingDataSource is a required field 6733 TrainingDataSource *TrainingDataSource `locationName:"trainingDataSource" type:"structure" required:"true"` 6734} 6735 6736// String returns the string representation 6737func (s PutModelInput) String() string { 6738 return awsutil.Prettify(s) 6739} 6740 6741// GoString returns the string representation 6742func (s PutModelInput) GoString() string { 6743 return s.String() 6744} 6745 6746// Validate inspects the fields of the type to determine if they are valid. 6747func (s *PutModelInput) Validate() error { 6748 invalidParams := request.ErrInvalidParams{Context: "PutModelInput"} 6749 if s.Description != nil && len(*s.Description) < 1 { 6750 invalidParams.Add(request.NewErrParamMinLen("Description", 1)) 6751 } 6752 if s.LabelSchema == nil { 6753 invalidParams.Add(request.NewErrParamRequired("LabelSchema")) 6754 } 6755 if s.ModelId == nil { 6756 invalidParams.Add(request.NewErrParamRequired("ModelId")) 6757 } 6758 if s.ModelId != nil && len(*s.ModelId) < 1 { 6759 invalidParams.Add(request.NewErrParamMinLen("ModelId", 1)) 6760 } 6761 if s.ModelType == nil { 6762 invalidParams.Add(request.NewErrParamRequired("ModelType")) 6763 } 6764 if s.ModelVariables == nil { 6765 invalidParams.Add(request.NewErrParamRequired("ModelVariables")) 6766 } 6767 if s.TrainingDataSource == nil { 6768 invalidParams.Add(request.NewErrParamRequired("TrainingDataSource")) 6769 } 6770 if s.LabelSchema != nil { 6771 if err := s.LabelSchema.Validate(); err != nil { 6772 invalidParams.AddNested("LabelSchema", err.(request.ErrInvalidParams)) 6773 } 6774 } 6775 if s.ModelVariables != nil { 6776 for i, v := range s.ModelVariables { 6777 if v == nil { 6778 continue 6779 } 6780 if err := v.Validate(); err != nil { 6781 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "ModelVariables", i), err.(request.ErrInvalidParams)) 6782 } 6783 } 6784 } 6785 if s.TrainingDataSource != nil { 6786 if err := s.TrainingDataSource.Validate(); err != nil { 6787 invalidParams.AddNested("TrainingDataSource", err.(request.ErrInvalidParams)) 6788 } 6789 } 6790 6791 if invalidParams.Len() > 0 { 6792 return invalidParams 6793 } 6794 return nil 6795} 6796 6797// SetDescription sets the Description field's value. 6798func (s *PutModelInput) SetDescription(v string) *PutModelInput { 6799 s.Description = &v 6800 return s 6801} 6802 6803// SetLabelSchema sets the LabelSchema field's value. 6804func (s *PutModelInput) SetLabelSchema(v *LabelSchema) *PutModelInput { 6805 s.LabelSchema = v 6806 return s 6807} 6808 6809// SetModelId sets the ModelId field's value. 6810func (s *PutModelInput) SetModelId(v string) *PutModelInput { 6811 s.ModelId = &v 6812 return s 6813} 6814 6815// SetModelType sets the ModelType field's value. 6816func (s *PutModelInput) SetModelType(v string) *PutModelInput { 6817 s.ModelType = &v 6818 return s 6819} 6820 6821// SetModelVariables sets the ModelVariables field's value. 6822func (s *PutModelInput) SetModelVariables(v []*ModelVariable) *PutModelInput { 6823 s.ModelVariables = v 6824 return s 6825} 6826 6827// SetTrainingDataSource sets the TrainingDataSource field's value. 6828func (s *PutModelInput) SetTrainingDataSource(v *TrainingDataSource) *PutModelInput { 6829 s.TrainingDataSource = v 6830 return s 6831} 6832 6833type PutModelOutput struct { 6834 _ struct{} `type:"structure"` 6835} 6836 6837// String returns the string representation 6838func (s PutModelOutput) String() string { 6839 return awsutil.Prettify(s) 6840} 6841 6842// GoString returns the string representation 6843func (s PutModelOutput) GoString() string { 6844 return s.String() 6845} 6846 6847type PutOutcomeInput struct { 6848 _ struct{} `type:"structure"` 6849 6850 // The outcome description. 6851 Description *string `locationName:"description" min:"1" type:"string"` 6852 6853 // The name of the outcome. 6854 // 6855 // Name is a required field 6856 Name *string `locationName:"name" min:"1" type:"string" required:"true"` 6857} 6858 6859// String returns the string representation 6860func (s PutOutcomeInput) String() string { 6861 return awsutil.Prettify(s) 6862} 6863 6864// GoString returns the string representation 6865func (s PutOutcomeInput) GoString() string { 6866 return s.String() 6867} 6868 6869// Validate inspects the fields of the type to determine if they are valid. 6870func (s *PutOutcomeInput) Validate() error { 6871 invalidParams := request.ErrInvalidParams{Context: "PutOutcomeInput"} 6872 if s.Description != nil && len(*s.Description) < 1 { 6873 invalidParams.Add(request.NewErrParamMinLen("Description", 1)) 6874 } 6875 if s.Name == nil { 6876 invalidParams.Add(request.NewErrParamRequired("Name")) 6877 } 6878 if s.Name != nil && len(*s.Name) < 1 { 6879 invalidParams.Add(request.NewErrParamMinLen("Name", 1)) 6880 } 6881 6882 if invalidParams.Len() > 0 { 6883 return invalidParams 6884 } 6885 return nil 6886} 6887 6888// SetDescription sets the Description field's value. 6889func (s *PutOutcomeInput) SetDescription(v string) *PutOutcomeInput { 6890 s.Description = &v 6891 return s 6892} 6893 6894// SetName sets the Name field's value. 6895func (s *PutOutcomeInput) SetName(v string) *PutOutcomeInput { 6896 s.Name = &v 6897 return s 6898} 6899 6900type PutOutcomeOutput struct { 6901 _ struct{} `type:"structure"` 6902} 6903 6904// String returns the string representation 6905func (s PutOutcomeOutput) String() string { 6906 return awsutil.Prettify(s) 6907} 6908 6909// GoString returns the string representation 6910func (s PutOutcomeOutput) GoString() string { 6911 return s.String() 6912} 6913 6914// An exception indicating the specified resource was not found. 6915type ResourceNotFoundException struct { 6916 _ struct{} `type:"structure"` 6917 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 6918 6919 Message_ *string `locationName:"message" type:"string"` 6920} 6921 6922// String returns the string representation 6923func (s ResourceNotFoundException) String() string { 6924 return awsutil.Prettify(s) 6925} 6926 6927// GoString returns the string representation 6928func (s ResourceNotFoundException) GoString() string { 6929 return s.String() 6930} 6931 6932func newErrorResourceNotFoundException(v protocol.ResponseMetadata) error { 6933 return &ResourceNotFoundException{ 6934 RespMetadata: v, 6935 } 6936} 6937 6938// Code returns the exception type name. 6939func (s *ResourceNotFoundException) Code() string { 6940 return "ResourceNotFoundException" 6941} 6942 6943// Message returns the exception's message. 6944func (s *ResourceNotFoundException) Message() string { 6945 if s.Message_ != nil { 6946 return *s.Message_ 6947 } 6948 return "" 6949} 6950 6951// OrigErr always returns nil, satisfies awserr.Error interface. 6952func (s *ResourceNotFoundException) OrigErr() error { 6953 return nil 6954} 6955 6956func (s *ResourceNotFoundException) Error() string { 6957 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 6958} 6959 6960// Status code returns the HTTP status code for the request's response error. 6961func (s *ResourceNotFoundException) StatusCode() int { 6962 return s.RespMetadata.StatusCode 6963} 6964 6965// RequestID returns the service's response RequestID for request. 6966func (s *ResourceNotFoundException) RequestID() string { 6967 return s.RespMetadata.RequestID 6968} 6969 6970// The role used to invoke external model endpoints. 6971type Role struct { 6972 _ struct{} `type:"structure"` 6973 6974 // The role ARN. 6975 // 6976 // Arn is a required field 6977 Arn *string `locationName:"arn" type:"string" required:"true"` 6978 6979 // The role name. 6980 // 6981 // Name is a required field 6982 Name *string `locationName:"name" type:"string" required:"true"` 6983} 6984 6985// String returns the string representation 6986func (s Role) String() string { 6987 return awsutil.Prettify(s) 6988} 6989 6990// GoString returns the string representation 6991func (s Role) GoString() string { 6992 return s.String() 6993} 6994 6995// Validate inspects the fields of the type to determine if they are valid. 6996func (s *Role) Validate() error { 6997 invalidParams := request.ErrInvalidParams{Context: "Role"} 6998 if s.Arn == nil { 6999 invalidParams.Add(request.NewErrParamRequired("Arn")) 7000 } 7001 if s.Name == nil { 7002 invalidParams.Add(request.NewErrParamRequired("Name")) 7003 } 7004 7005 if invalidParams.Len() > 0 { 7006 return invalidParams 7007 } 7008 return nil 7009} 7010 7011// SetArn sets the Arn field's value. 7012func (s *Role) SetArn(v string) *Role { 7013 s.Arn = &v 7014 return s 7015} 7016 7017// SetName sets the Name field's value. 7018func (s *Role) SetName(v string) *Role { 7019 s.Name = &v 7020 return s 7021} 7022 7023// A rule. 7024type Rule struct { 7025 _ struct{} `type:"structure"` 7026 7027 // The detector for which the rule is associated. 7028 // 7029 // DetectorId is a required field 7030 DetectorId *string `locationName:"detectorId" min:"1" type:"string" required:"true"` 7031 7032 // The rule ID. 7033 // 7034 // RuleId is a required field 7035 RuleId *string `locationName:"ruleId" min:"1" type:"string" required:"true"` 7036 7037 // The rule version. 7038 // 7039 // RuleVersion is a required field 7040 RuleVersion *string `locationName:"ruleVersion" min:"1" type:"string" required:"true"` 7041} 7042 7043// String returns the string representation 7044func (s Rule) String() string { 7045 return awsutil.Prettify(s) 7046} 7047 7048// GoString returns the string representation 7049func (s Rule) GoString() string { 7050 return s.String() 7051} 7052 7053// Validate inspects the fields of the type to determine if they are valid. 7054func (s *Rule) Validate() error { 7055 invalidParams := request.ErrInvalidParams{Context: "Rule"} 7056 if s.DetectorId == nil { 7057 invalidParams.Add(request.NewErrParamRequired("DetectorId")) 7058 } 7059 if s.DetectorId != nil && len(*s.DetectorId) < 1 { 7060 invalidParams.Add(request.NewErrParamMinLen("DetectorId", 1)) 7061 } 7062 if s.RuleId == nil { 7063 invalidParams.Add(request.NewErrParamRequired("RuleId")) 7064 } 7065 if s.RuleId != nil && len(*s.RuleId) < 1 { 7066 invalidParams.Add(request.NewErrParamMinLen("RuleId", 1)) 7067 } 7068 if s.RuleVersion == nil { 7069 invalidParams.Add(request.NewErrParamRequired("RuleVersion")) 7070 } 7071 if s.RuleVersion != nil && len(*s.RuleVersion) < 1 { 7072 invalidParams.Add(request.NewErrParamMinLen("RuleVersion", 1)) 7073 } 7074 7075 if invalidParams.Len() > 0 { 7076 return invalidParams 7077 } 7078 return nil 7079} 7080 7081// SetDetectorId sets the DetectorId field's value. 7082func (s *Rule) SetDetectorId(v string) *Rule { 7083 s.DetectorId = &v 7084 return s 7085} 7086 7087// SetRuleId sets the RuleId field's value. 7088func (s *Rule) SetRuleId(v string) *Rule { 7089 s.RuleId = &v 7090 return s 7091} 7092 7093// SetRuleVersion sets the RuleVersion field's value. 7094func (s *Rule) SetRuleVersion(v string) *Rule { 7095 s.RuleVersion = &v 7096 return s 7097} 7098 7099// The details of the rule. 7100type RuleDetail struct { 7101 _ struct{} `type:"structure"` 7102 7103 // The timestamp of when the rule was created. 7104 CreatedTime *string `locationName:"createdTime" type:"string"` 7105 7106 // The rule description. 7107 Description *string `locationName:"description" min:"1" type:"string"` 7108 7109 // The detector for which the rule is associated. 7110 DetectorId *string `locationName:"detectorId" min:"1" type:"string"` 7111 7112 // The rule expression. 7113 Expression *string `locationName:"expression" min:"1" type:"string"` 7114 7115 // The rule language. 7116 Language *string `locationName:"language" type:"string" enum:"Language"` 7117 7118 // Timestamp of the last time the rule was updated. 7119 LastUpdatedTime *string `locationName:"lastUpdatedTime" type:"string"` 7120 7121 // The rule outcomes. 7122 Outcomes []*string `locationName:"outcomes" min:"1" type:"list"` 7123 7124 // The rule ID. 7125 RuleId *string `locationName:"ruleId" min:"1" type:"string"` 7126 7127 // The rule version. 7128 RuleVersion *string `locationName:"ruleVersion" min:"1" type:"string"` 7129} 7130 7131// String returns the string representation 7132func (s RuleDetail) String() string { 7133 return awsutil.Prettify(s) 7134} 7135 7136// GoString returns the string representation 7137func (s RuleDetail) GoString() string { 7138 return s.String() 7139} 7140 7141// SetCreatedTime sets the CreatedTime field's value. 7142func (s *RuleDetail) SetCreatedTime(v string) *RuleDetail { 7143 s.CreatedTime = &v 7144 return s 7145} 7146 7147// SetDescription sets the Description field's value. 7148func (s *RuleDetail) SetDescription(v string) *RuleDetail { 7149 s.Description = &v 7150 return s 7151} 7152 7153// SetDetectorId sets the DetectorId field's value. 7154func (s *RuleDetail) SetDetectorId(v string) *RuleDetail { 7155 s.DetectorId = &v 7156 return s 7157} 7158 7159// SetExpression sets the Expression field's value. 7160func (s *RuleDetail) SetExpression(v string) *RuleDetail { 7161 s.Expression = &v 7162 return s 7163} 7164 7165// SetLanguage sets the Language field's value. 7166func (s *RuleDetail) SetLanguage(v string) *RuleDetail { 7167 s.Language = &v 7168 return s 7169} 7170 7171// SetLastUpdatedTime sets the LastUpdatedTime field's value. 7172func (s *RuleDetail) SetLastUpdatedTime(v string) *RuleDetail { 7173 s.LastUpdatedTime = &v 7174 return s 7175} 7176 7177// SetOutcomes sets the Outcomes field's value. 7178func (s *RuleDetail) SetOutcomes(v []*string) *RuleDetail { 7179 s.Outcomes = v 7180 return s 7181} 7182 7183// SetRuleId sets the RuleId field's value. 7184func (s *RuleDetail) SetRuleId(v string) *RuleDetail { 7185 s.RuleId = &v 7186 return s 7187} 7188 7189// SetRuleVersion sets the RuleVersion field's value. 7190func (s *RuleDetail) SetRuleVersion(v string) *RuleDetail { 7191 s.RuleVersion = &v 7192 return s 7193} 7194 7195// The rule results. 7196type RuleResult struct { 7197 _ struct{} `type:"structure"` 7198 7199 // The outcomes of the matched rule, based on the rule execution mode. 7200 Outcomes []*string `locationName:"outcomes" type:"list"` 7201 7202 // The rule ID that was matched, based on the rule execution mode. 7203 RuleId *string `locationName:"ruleId" type:"string"` 7204} 7205 7206// String returns the string representation 7207func (s RuleResult) String() string { 7208 return awsutil.Prettify(s) 7209} 7210 7211// GoString returns the string representation 7212func (s RuleResult) GoString() string { 7213 return s.String() 7214} 7215 7216// SetOutcomes sets the Outcomes field's value. 7217func (s *RuleResult) SetOutcomes(v []*string) *RuleResult { 7218 s.Outcomes = v 7219 return s 7220} 7221 7222// SetRuleId sets the RuleId field's value. 7223func (s *RuleResult) SetRuleId(v string) *RuleResult { 7224 s.RuleId = &v 7225 return s 7226} 7227 7228// An exception indicating a throttling error. 7229type ThrottlingException struct { 7230 _ struct{} `type:"structure"` 7231 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 7232 7233 Message_ *string `locationName:"message" type:"string"` 7234} 7235 7236// String returns the string representation 7237func (s ThrottlingException) String() string { 7238 return awsutil.Prettify(s) 7239} 7240 7241// GoString returns the string representation 7242func (s ThrottlingException) GoString() string { 7243 return s.String() 7244} 7245 7246func newErrorThrottlingException(v protocol.ResponseMetadata) error { 7247 return &ThrottlingException{ 7248 RespMetadata: v, 7249 } 7250} 7251 7252// Code returns the exception type name. 7253func (s *ThrottlingException) Code() string { 7254 return "ThrottlingException" 7255} 7256 7257// Message returns the exception's message. 7258func (s *ThrottlingException) Message() string { 7259 if s.Message_ != nil { 7260 return *s.Message_ 7261 } 7262 return "" 7263} 7264 7265// OrigErr always returns nil, satisfies awserr.Error interface. 7266func (s *ThrottlingException) OrigErr() error { 7267 return nil 7268} 7269 7270func (s *ThrottlingException) Error() string { 7271 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 7272} 7273 7274// Status code returns the HTTP status code for the request's response error. 7275func (s *ThrottlingException) StatusCode() int { 7276 return s.RespMetadata.StatusCode 7277} 7278 7279// RequestID returns the service's response RequestID for request. 7280func (s *ThrottlingException) RequestID() string { 7281 return s.RespMetadata.RequestID 7282} 7283 7284// The training data source. 7285type TrainingDataSource struct { 7286 _ struct{} `type:"structure"` 7287 7288 // The data access role ARN for the training data source. 7289 // 7290 // DataAccessRoleArn is a required field 7291 DataAccessRoleArn *string `locationName:"dataAccessRoleArn" min:"1" type:"string" required:"true"` 7292 7293 // The data location of the training data source. 7294 // 7295 // DataLocation is a required field 7296 DataLocation *string `locationName:"dataLocation" min:"1" type:"string" required:"true"` 7297} 7298 7299// String returns the string representation 7300func (s TrainingDataSource) String() string { 7301 return awsutil.Prettify(s) 7302} 7303 7304// GoString returns the string representation 7305func (s TrainingDataSource) GoString() string { 7306 return s.String() 7307} 7308 7309// Validate inspects the fields of the type to determine if they are valid. 7310func (s *TrainingDataSource) Validate() error { 7311 invalidParams := request.ErrInvalidParams{Context: "TrainingDataSource"} 7312 if s.DataAccessRoleArn == nil { 7313 invalidParams.Add(request.NewErrParamRequired("DataAccessRoleArn")) 7314 } 7315 if s.DataAccessRoleArn != nil && len(*s.DataAccessRoleArn) < 1 { 7316 invalidParams.Add(request.NewErrParamMinLen("DataAccessRoleArn", 1)) 7317 } 7318 if s.DataLocation == nil { 7319 invalidParams.Add(request.NewErrParamRequired("DataLocation")) 7320 } 7321 if s.DataLocation != nil && len(*s.DataLocation) < 1 { 7322 invalidParams.Add(request.NewErrParamMinLen("DataLocation", 1)) 7323 } 7324 7325 if invalidParams.Len() > 0 { 7326 return invalidParams 7327 } 7328 return nil 7329} 7330 7331// SetDataAccessRoleArn sets the DataAccessRoleArn field's value. 7332func (s *TrainingDataSource) SetDataAccessRoleArn(v string) *TrainingDataSource { 7333 s.DataAccessRoleArn = &v 7334 return s 7335} 7336 7337// SetDataLocation sets the DataLocation field's value. 7338func (s *TrainingDataSource) SetDataLocation(v string) *TrainingDataSource { 7339 s.DataLocation = &v 7340 return s 7341} 7342 7343type UpdateDetectorVersionInput struct { 7344 _ struct{} `type:"structure"` 7345 7346 // The detector version description. 7347 Description *string `locationName:"description" min:"1" type:"string"` 7348 7349 // The parent detector ID for the detector version you want to update. 7350 // 7351 // DetectorId is a required field 7352 DetectorId *string `locationName:"detectorId" min:"1" type:"string" required:"true"` 7353 7354 // The detector version ID. 7355 // 7356 // DetectorVersionId is a required field 7357 DetectorVersionId *string `locationName:"detectorVersionId" min:"1" type:"string" required:"true"` 7358 7359 // The Amazon SageMaker model endpoints to include in the detector version. 7360 // 7361 // ExternalModelEndpoints is a required field 7362 ExternalModelEndpoints []*string `locationName:"externalModelEndpoints" type:"list" required:"true"` 7363 7364 // The model versions to include in the detector version. 7365 ModelVersions []*ModelVersion `locationName:"modelVersions" type:"list"` 7366 7367 // The rule execution mode to add to the detector. 7368 // 7369 // If you specify FIRST_MATCHED, Amazon Fraud Detector evaluates rules sequentially, 7370 // first to last, stopping at the first matched rule. Amazon Fraud dectector 7371 // then provides the outcomes for that single rule. 7372 // 7373 // If you specifiy ALL_MATCHED, Amazon Fraud Detector evaluates all rules and 7374 // returns the outcomes for all matched rules. You can define and edit the rule 7375 // mode at the detector version level, when it is in draft status. 7376 // 7377 // The default behavior is FIRST_MATCHED. 7378 RuleExecutionMode *string `locationName:"ruleExecutionMode" type:"string" enum:"RuleExecutionMode"` 7379 7380 // The rules to include in the detector version. 7381 // 7382 // Rules is a required field 7383 Rules []*Rule `locationName:"rules" type:"list" required:"true"` 7384} 7385 7386// String returns the string representation 7387func (s UpdateDetectorVersionInput) String() string { 7388 return awsutil.Prettify(s) 7389} 7390 7391// GoString returns the string representation 7392func (s UpdateDetectorVersionInput) GoString() string { 7393 return s.String() 7394} 7395 7396// Validate inspects the fields of the type to determine if they are valid. 7397func (s *UpdateDetectorVersionInput) Validate() error { 7398 invalidParams := request.ErrInvalidParams{Context: "UpdateDetectorVersionInput"} 7399 if s.Description != nil && len(*s.Description) < 1 { 7400 invalidParams.Add(request.NewErrParamMinLen("Description", 1)) 7401 } 7402 if s.DetectorId == nil { 7403 invalidParams.Add(request.NewErrParamRequired("DetectorId")) 7404 } 7405 if s.DetectorId != nil && len(*s.DetectorId) < 1 { 7406 invalidParams.Add(request.NewErrParamMinLen("DetectorId", 1)) 7407 } 7408 if s.DetectorVersionId == nil { 7409 invalidParams.Add(request.NewErrParamRequired("DetectorVersionId")) 7410 } 7411 if s.DetectorVersionId != nil && len(*s.DetectorVersionId) < 1 { 7412 invalidParams.Add(request.NewErrParamMinLen("DetectorVersionId", 1)) 7413 } 7414 if s.ExternalModelEndpoints == nil { 7415 invalidParams.Add(request.NewErrParamRequired("ExternalModelEndpoints")) 7416 } 7417 if s.Rules == nil { 7418 invalidParams.Add(request.NewErrParamRequired("Rules")) 7419 } 7420 if s.ModelVersions != nil { 7421 for i, v := range s.ModelVersions { 7422 if v == nil { 7423 continue 7424 } 7425 if err := v.Validate(); err != nil { 7426 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "ModelVersions", i), err.(request.ErrInvalidParams)) 7427 } 7428 } 7429 } 7430 if s.Rules != nil { 7431 for i, v := range s.Rules { 7432 if v == nil { 7433 continue 7434 } 7435 if err := v.Validate(); err != nil { 7436 invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Rules", i), err.(request.ErrInvalidParams)) 7437 } 7438 } 7439 } 7440 7441 if invalidParams.Len() > 0 { 7442 return invalidParams 7443 } 7444 return nil 7445} 7446 7447// SetDescription sets the Description field's value. 7448func (s *UpdateDetectorVersionInput) SetDescription(v string) *UpdateDetectorVersionInput { 7449 s.Description = &v 7450 return s 7451} 7452 7453// SetDetectorId sets the DetectorId field's value. 7454func (s *UpdateDetectorVersionInput) SetDetectorId(v string) *UpdateDetectorVersionInput { 7455 s.DetectorId = &v 7456 return s 7457} 7458 7459// SetDetectorVersionId sets the DetectorVersionId field's value. 7460func (s *UpdateDetectorVersionInput) SetDetectorVersionId(v string) *UpdateDetectorVersionInput { 7461 s.DetectorVersionId = &v 7462 return s 7463} 7464 7465// SetExternalModelEndpoints sets the ExternalModelEndpoints field's value. 7466func (s *UpdateDetectorVersionInput) SetExternalModelEndpoints(v []*string) *UpdateDetectorVersionInput { 7467 s.ExternalModelEndpoints = v 7468 return s 7469} 7470 7471// SetModelVersions sets the ModelVersions field's value. 7472func (s *UpdateDetectorVersionInput) SetModelVersions(v []*ModelVersion) *UpdateDetectorVersionInput { 7473 s.ModelVersions = v 7474 return s 7475} 7476 7477// SetRuleExecutionMode sets the RuleExecutionMode field's value. 7478func (s *UpdateDetectorVersionInput) SetRuleExecutionMode(v string) *UpdateDetectorVersionInput { 7479 s.RuleExecutionMode = &v 7480 return s 7481} 7482 7483// SetRules sets the Rules field's value. 7484func (s *UpdateDetectorVersionInput) SetRules(v []*Rule) *UpdateDetectorVersionInput { 7485 s.Rules = v 7486 return s 7487} 7488 7489type UpdateDetectorVersionMetadataInput struct { 7490 _ struct{} `type:"structure"` 7491 7492 // The description. 7493 // 7494 // Description is a required field 7495 Description *string `locationName:"description" min:"1" type:"string" required:"true"` 7496 7497 // The detector ID. 7498 // 7499 // DetectorId is a required field 7500 DetectorId *string `locationName:"detectorId" min:"1" type:"string" required:"true"` 7501 7502 // The detector version ID. 7503 // 7504 // DetectorVersionId is a required field 7505 DetectorVersionId *string `locationName:"detectorVersionId" min:"1" type:"string" required:"true"` 7506} 7507 7508// String returns the string representation 7509func (s UpdateDetectorVersionMetadataInput) String() string { 7510 return awsutil.Prettify(s) 7511} 7512 7513// GoString returns the string representation 7514func (s UpdateDetectorVersionMetadataInput) GoString() string { 7515 return s.String() 7516} 7517 7518// Validate inspects the fields of the type to determine if they are valid. 7519func (s *UpdateDetectorVersionMetadataInput) Validate() error { 7520 invalidParams := request.ErrInvalidParams{Context: "UpdateDetectorVersionMetadataInput"} 7521 if s.Description == nil { 7522 invalidParams.Add(request.NewErrParamRequired("Description")) 7523 } 7524 if s.Description != nil && len(*s.Description) < 1 { 7525 invalidParams.Add(request.NewErrParamMinLen("Description", 1)) 7526 } 7527 if s.DetectorId == nil { 7528 invalidParams.Add(request.NewErrParamRequired("DetectorId")) 7529 } 7530 if s.DetectorId != nil && len(*s.DetectorId) < 1 { 7531 invalidParams.Add(request.NewErrParamMinLen("DetectorId", 1)) 7532 } 7533 if s.DetectorVersionId == nil { 7534 invalidParams.Add(request.NewErrParamRequired("DetectorVersionId")) 7535 } 7536 if s.DetectorVersionId != nil && len(*s.DetectorVersionId) < 1 { 7537 invalidParams.Add(request.NewErrParamMinLen("DetectorVersionId", 1)) 7538 } 7539 7540 if invalidParams.Len() > 0 { 7541 return invalidParams 7542 } 7543 return nil 7544} 7545 7546// SetDescription sets the Description field's value. 7547func (s *UpdateDetectorVersionMetadataInput) SetDescription(v string) *UpdateDetectorVersionMetadataInput { 7548 s.Description = &v 7549 return s 7550} 7551 7552// SetDetectorId sets the DetectorId field's value. 7553func (s *UpdateDetectorVersionMetadataInput) SetDetectorId(v string) *UpdateDetectorVersionMetadataInput { 7554 s.DetectorId = &v 7555 return s 7556} 7557 7558// SetDetectorVersionId sets the DetectorVersionId field's value. 7559func (s *UpdateDetectorVersionMetadataInput) SetDetectorVersionId(v string) *UpdateDetectorVersionMetadataInput { 7560 s.DetectorVersionId = &v 7561 return s 7562} 7563 7564type UpdateDetectorVersionMetadataOutput struct { 7565 _ struct{} `type:"structure"` 7566} 7567 7568// String returns the string representation 7569func (s UpdateDetectorVersionMetadataOutput) String() string { 7570 return awsutil.Prettify(s) 7571} 7572 7573// GoString returns the string representation 7574func (s UpdateDetectorVersionMetadataOutput) GoString() string { 7575 return s.String() 7576} 7577 7578type UpdateDetectorVersionOutput struct { 7579 _ struct{} `type:"structure"` 7580} 7581 7582// String returns the string representation 7583func (s UpdateDetectorVersionOutput) String() string { 7584 return awsutil.Prettify(s) 7585} 7586 7587// GoString returns the string representation 7588func (s UpdateDetectorVersionOutput) GoString() string { 7589 return s.String() 7590} 7591 7592type UpdateDetectorVersionStatusInput struct { 7593 _ struct{} `type:"structure"` 7594 7595 // The detector ID. 7596 // 7597 // DetectorId is a required field 7598 DetectorId *string `locationName:"detectorId" min:"1" type:"string" required:"true"` 7599 7600 // The detector version ID. 7601 // 7602 // DetectorVersionId is a required field 7603 DetectorVersionId *string `locationName:"detectorVersionId" min:"1" type:"string" required:"true"` 7604 7605 // The new status. 7606 // 7607 // Status is a required field 7608 Status *string `locationName:"status" type:"string" required:"true" enum:"DetectorVersionStatus"` 7609} 7610 7611// String returns the string representation 7612func (s UpdateDetectorVersionStatusInput) String() string { 7613 return awsutil.Prettify(s) 7614} 7615 7616// GoString returns the string representation 7617func (s UpdateDetectorVersionStatusInput) GoString() string { 7618 return s.String() 7619} 7620 7621// Validate inspects the fields of the type to determine if they are valid. 7622func (s *UpdateDetectorVersionStatusInput) Validate() error { 7623 invalidParams := request.ErrInvalidParams{Context: "UpdateDetectorVersionStatusInput"} 7624 if s.DetectorId == nil { 7625 invalidParams.Add(request.NewErrParamRequired("DetectorId")) 7626 } 7627 if s.DetectorId != nil && len(*s.DetectorId) < 1 { 7628 invalidParams.Add(request.NewErrParamMinLen("DetectorId", 1)) 7629 } 7630 if s.DetectorVersionId == nil { 7631 invalidParams.Add(request.NewErrParamRequired("DetectorVersionId")) 7632 } 7633 if s.DetectorVersionId != nil && len(*s.DetectorVersionId) < 1 { 7634 invalidParams.Add(request.NewErrParamMinLen("DetectorVersionId", 1)) 7635 } 7636 if s.Status == nil { 7637 invalidParams.Add(request.NewErrParamRequired("Status")) 7638 } 7639 7640 if invalidParams.Len() > 0 { 7641 return invalidParams 7642 } 7643 return nil 7644} 7645 7646// SetDetectorId sets the DetectorId field's value. 7647func (s *UpdateDetectorVersionStatusInput) SetDetectorId(v string) *UpdateDetectorVersionStatusInput { 7648 s.DetectorId = &v 7649 return s 7650} 7651 7652// SetDetectorVersionId sets the DetectorVersionId field's value. 7653func (s *UpdateDetectorVersionStatusInput) SetDetectorVersionId(v string) *UpdateDetectorVersionStatusInput { 7654 s.DetectorVersionId = &v 7655 return s 7656} 7657 7658// SetStatus sets the Status field's value. 7659func (s *UpdateDetectorVersionStatusInput) SetStatus(v string) *UpdateDetectorVersionStatusInput { 7660 s.Status = &v 7661 return s 7662} 7663 7664type UpdateDetectorVersionStatusOutput struct { 7665 _ struct{} `type:"structure"` 7666} 7667 7668// String returns the string representation 7669func (s UpdateDetectorVersionStatusOutput) String() string { 7670 return awsutil.Prettify(s) 7671} 7672 7673// GoString returns the string representation 7674func (s UpdateDetectorVersionStatusOutput) GoString() string { 7675 return s.String() 7676} 7677 7678type UpdateModelVersionInput struct { 7679 _ struct{} `type:"structure"` 7680 7681 // The model description. 7682 // 7683 // Description is a required field 7684 Description *string `locationName:"description" min:"1" type:"string" required:"true"` 7685 7686 // The model ID. 7687 // 7688 // ModelId is a required field 7689 ModelId *string `locationName:"modelId" min:"1" type:"string" required:"true"` 7690 7691 // The model type. 7692 // 7693 // ModelType is a required field 7694 ModelType *string `locationName:"modelType" type:"string" required:"true" enum:"ModelTypeEnum"` 7695 7696 // The model version. 7697 // 7698 // ModelVersionNumber is a required field 7699 ModelVersionNumber *string `locationName:"modelVersionNumber" min:"1" type:"string" required:"true"` 7700 7701 // The new model status. 7702 // 7703 // Status is a required field 7704 Status *string `locationName:"status" type:"string" required:"true" enum:"ModelVersionStatus"` 7705} 7706 7707// String returns the string representation 7708func (s UpdateModelVersionInput) String() string { 7709 return awsutil.Prettify(s) 7710} 7711 7712// GoString returns the string representation 7713func (s UpdateModelVersionInput) GoString() string { 7714 return s.String() 7715} 7716 7717// Validate inspects the fields of the type to determine if they are valid. 7718func (s *UpdateModelVersionInput) Validate() error { 7719 invalidParams := request.ErrInvalidParams{Context: "UpdateModelVersionInput"} 7720 if s.Description == nil { 7721 invalidParams.Add(request.NewErrParamRequired("Description")) 7722 } 7723 if s.Description != nil && len(*s.Description) < 1 { 7724 invalidParams.Add(request.NewErrParamMinLen("Description", 1)) 7725 } 7726 if s.ModelId == nil { 7727 invalidParams.Add(request.NewErrParamRequired("ModelId")) 7728 } 7729 if s.ModelId != nil && len(*s.ModelId) < 1 { 7730 invalidParams.Add(request.NewErrParamMinLen("ModelId", 1)) 7731 } 7732 if s.ModelType == nil { 7733 invalidParams.Add(request.NewErrParamRequired("ModelType")) 7734 } 7735 if s.ModelVersionNumber == nil { 7736 invalidParams.Add(request.NewErrParamRequired("ModelVersionNumber")) 7737 } 7738 if s.ModelVersionNumber != nil && len(*s.ModelVersionNumber) < 1 { 7739 invalidParams.Add(request.NewErrParamMinLen("ModelVersionNumber", 1)) 7740 } 7741 if s.Status == nil { 7742 invalidParams.Add(request.NewErrParamRequired("Status")) 7743 } 7744 7745 if invalidParams.Len() > 0 { 7746 return invalidParams 7747 } 7748 return nil 7749} 7750 7751// SetDescription sets the Description field's value. 7752func (s *UpdateModelVersionInput) SetDescription(v string) *UpdateModelVersionInput { 7753 s.Description = &v 7754 return s 7755} 7756 7757// SetModelId sets the ModelId field's value. 7758func (s *UpdateModelVersionInput) SetModelId(v string) *UpdateModelVersionInput { 7759 s.ModelId = &v 7760 return s 7761} 7762 7763// SetModelType sets the ModelType field's value. 7764func (s *UpdateModelVersionInput) SetModelType(v string) *UpdateModelVersionInput { 7765 s.ModelType = &v 7766 return s 7767} 7768 7769// SetModelVersionNumber sets the ModelVersionNumber field's value. 7770func (s *UpdateModelVersionInput) SetModelVersionNumber(v string) *UpdateModelVersionInput { 7771 s.ModelVersionNumber = &v 7772 return s 7773} 7774 7775// SetStatus sets the Status field's value. 7776func (s *UpdateModelVersionInput) SetStatus(v string) *UpdateModelVersionInput { 7777 s.Status = &v 7778 return s 7779} 7780 7781type UpdateModelVersionOutput struct { 7782 _ struct{} `type:"structure"` 7783} 7784 7785// String returns the string representation 7786func (s UpdateModelVersionOutput) String() string { 7787 return awsutil.Prettify(s) 7788} 7789 7790// GoString returns the string representation 7791func (s UpdateModelVersionOutput) GoString() string { 7792 return s.String() 7793} 7794 7795type UpdateRuleMetadataInput struct { 7796 _ struct{} `type:"structure"` 7797 7798 // The rule description. 7799 // 7800 // Description is a required field 7801 Description *string `locationName:"description" min:"1" type:"string" required:"true"` 7802 7803 // The rule to update. 7804 // 7805 // Rule is a required field 7806 Rule *Rule `locationName:"rule" type:"structure" required:"true"` 7807} 7808 7809// String returns the string representation 7810func (s UpdateRuleMetadataInput) String() string { 7811 return awsutil.Prettify(s) 7812} 7813 7814// GoString returns the string representation 7815func (s UpdateRuleMetadataInput) GoString() string { 7816 return s.String() 7817} 7818 7819// Validate inspects the fields of the type to determine if they are valid. 7820func (s *UpdateRuleMetadataInput) Validate() error { 7821 invalidParams := request.ErrInvalidParams{Context: "UpdateRuleMetadataInput"} 7822 if s.Description == nil { 7823 invalidParams.Add(request.NewErrParamRequired("Description")) 7824 } 7825 if s.Description != nil && len(*s.Description) < 1 { 7826 invalidParams.Add(request.NewErrParamMinLen("Description", 1)) 7827 } 7828 if s.Rule == nil { 7829 invalidParams.Add(request.NewErrParamRequired("Rule")) 7830 } 7831 if s.Rule != nil { 7832 if err := s.Rule.Validate(); err != nil { 7833 invalidParams.AddNested("Rule", err.(request.ErrInvalidParams)) 7834 } 7835 } 7836 7837 if invalidParams.Len() > 0 { 7838 return invalidParams 7839 } 7840 return nil 7841} 7842 7843// SetDescription sets the Description field's value. 7844func (s *UpdateRuleMetadataInput) SetDescription(v string) *UpdateRuleMetadataInput { 7845 s.Description = &v 7846 return s 7847} 7848 7849// SetRule sets the Rule field's value. 7850func (s *UpdateRuleMetadataInput) SetRule(v *Rule) *UpdateRuleMetadataInput { 7851 s.Rule = v 7852 return s 7853} 7854 7855type UpdateRuleMetadataOutput struct { 7856 _ struct{} `type:"structure"` 7857} 7858 7859// String returns the string representation 7860func (s UpdateRuleMetadataOutput) String() string { 7861 return awsutil.Prettify(s) 7862} 7863 7864// GoString returns the string representation 7865func (s UpdateRuleMetadataOutput) GoString() string { 7866 return s.String() 7867} 7868 7869type UpdateRuleVersionInput struct { 7870 _ struct{} `type:"structure"` 7871 7872 // The description. 7873 Description *string `locationName:"description" min:"1" type:"string"` 7874 7875 // The rule expression. 7876 // 7877 // Expression is a required field 7878 Expression *string `locationName:"expression" min:"1" type:"string" required:"true"` 7879 7880 // The language. 7881 // 7882 // Language is a required field 7883 Language *string `locationName:"language" type:"string" required:"true" enum:"Language"` 7884 7885 // The outcomes. 7886 // 7887 // Outcomes is a required field 7888 Outcomes []*string `locationName:"outcomes" min:"1" type:"list" required:"true"` 7889 7890 // The rule to update. 7891 // 7892 // Rule is a required field 7893 Rule *Rule `locationName:"rule" type:"structure" required:"true"` 7894} 7895 7896// String returns the string representation 7897func (s UpdateRuleVersionInput) String() string { 7898 return awsutil.Prettify(s) 7899} 7900 7901// GoString returns the string representation 7902func (s UpdateRuleVersionInput) GoString() string { 7903 return s.String() 7904} 7905 7906// Validate inspects the fields of the type to determine if they are valid. 7907func (s *UpdateRuleVersionInput) Validate() error { 7908 invalidParams := request.ErrInvalidParams{Context: "UpdateRuleVersionInput"} 7909 if s.Description != nil && len(*s.Description) < 1 { 7910 invalidParams.Add(request.NewErrParamMinLen("Description", 1)) 7911 } 7912 if s.Expression == nil { 7913 invalidParams.Add(request.NewErrParamRequired("Expression")) 7914 } 7915 if s.Expression != nil && len(*s.Expression) < 1 { 7916 invalidParams.Add(request.NewErrParamMinLen("Expression", 1)) 7917 } 7918 if s.Language == nil { 7919 invalidParams.Add(request.NewErrParamRequired("Language")) 7920 } 7921 if s.Outcomes == nil { 7922 invalidParams.Add(request.NewErrParamRequired("Outcomes")) 7923 } 7924 if s.Outcomes != nil && len(s.Outcomes) < 1 { 7925 invalidParams.Add(request.NewErrParamMinLen("Outcomes", 1)) 7926 } 7927 if s.Rule == nil { 7928 invalidParams.Add(request.NewErrParamRequired("Rule")) 7929 } 7930 if s.Rule != nil { 7931 if err := s.Rule.Validate(); err != nil { 7932 invalidParams.AddNested("Rule", err.(request.ErrInvalidParams)) 7933 } 7934 } 7935 7936 if invalidParams.Len() > 0 { 7937 return invalidParams 7938 } 7939 return nil 7940} 7941 7942// SetDescription sets the Description field's value. 7943func (s *UpdateRuleVersionInput) SetDescription(v string) *UpdateRuleVersionInput { 7944 s.Description = &v 7945 return s 7946} 7947 7948// SetExpression sets the Expression field's value. 7949func (s *UpdateRuleVersionInput) SetExpression(v string) *UpdateRuleVersionInput { 7950 s.Expression = &v 7951 return s 7952} 7953 7954// SetLanguage sets the Language field's value. 7955func (s *UpdateRuleVersionInput) SetLanguage(v string) *UpdateRuleVersionInput { 7956 s.Language = &v 7957 return s 7958} 7959 7960// SetOutcomes sets the Outcomes field's value. 7961func (s *UpdateRuleVersionInput) SetOutcomes(v []*string) *UpdateRuleVersionInput { 7962 s.Outcomes = v 7963 return s 7964} 7965 7966// SetRule sets the Rule field's value. 7967func (s *UpdateRuleVersionInput) SetRule(v *Rule) *UpdateRuleVersionInput { 7968 s.Rule = v 7969 return s 7970} 7971 7972type UpdateRuleVersionOutput struct { 7973 _ struct{} `type:"structure"` 7974 7975 // The new rule version that was created. 7976 Rule *Rule `locationName:"rule" type:"structure"` 7977} 7978 7979// String returns the string representation 7980func (s UpdateRuleVersionOutput) String() string { 7981 return awsutil.Prettify(s) 7982} 7983 7984// GoString returns the string representation 7985func (s UpdateRuleVersionOutput) GoString() string { 7986 return s.String() 7987} 7988 7989// SetRule sets the Rule field's value. 7990func (s *UpdateRuleVersionOutput) SetRule(v *Rule) *UpdateRuleVersionOutput { 7991 s.Rule = v 7992 return s 7993} 7994 7995type UpdateVariableInput struct { 7996 _ struct{} `type:"structure"` 7997 7998 // The new default value of the variable. 7999 DefaultValue *string `locationName:"defaultValue" type:"string"` 8000 8001 // The new description. 8002 Description *string `locationName:"description" type:"string"` 8003 8004 // The name of the variable. 8005 // 8006 // Name is a required field 8007 Name *string `locationName:"name" type:"string" required:"true"` 8008 8009 // The variable type. 8010 VariableType *string `locationName:"variableType" type:"string"` 8011} 8012 8013// String returns the string representation 8014func (s UpdateVariableInput) String() string { 8015 return awsutil.Prettify(s) 8016} 8017 8018// GoString returns the string representation 8019func (s UpdateVariableInput) GoString() string { 8020 return s.String() 8021} 8022 8023// Validate inspects the fields of the type to determine if they are valid. 8024func (s *UpdateVariableInput) Validate() error { 8025 invalidParams := request.ErrInvalidParams{Context: "UpdateVariableInput"} 8026 if s.Name == nil { 8027 invalidParams.Add(request.NewErrParamRequired("Name")) 8028 } 8029 8030 if invalidParams.Len() > 0 { 8031 return invalidParams 8032 } 8033 return nil 8034} 8035 8036// SetDefaultValue sets the DefaultValue field's value. 8037func (s *UpdateVariableInput) SetDefaultValue(v string) *UpdateVariableInput { 8038 s.DefaultValue = &v 8039 return s 8040} 8041 8042// SetDescription sets the Description field's value. 8043func (s *UpdateVariableInput) SetDescription(v string) *UpdateVariableInput { 8044 s.Description = &v 8045 return s 8046} 8047 8048// SetName sets the Name field's value. 8049func (s *UpdateVariableInput) SetName(v string) *UpdateVariableInput { 8050 s.Name = &v 8051 return s 8052} 8053 8054// SetVariableType sets the VariableType field's value. 8055func (s *UpdateVariableInput) SetVariableType(v string) *UpdateVariableInput { 8056 s.VariableType = &v 8057 return s 8058} 8059 8060type UpdateVariableOutput struct { 8061 _ struct{} `type:"structure"` 8062} 8063 8064// String returns the string representation 8065func (s UpdateVariableOutput) String() string { 8066 return awsutil.Prettify(s) 8067} 8068 8069// GoString returns the string representation 8070func (s UpdateVariableOutput) GoString() string { 8071 return s.String() 8072} 8073 8074// An exception indicating a specified value is not allowed. 8075type ValidationException struct { 8076 _ struct{} `type:"structure"` 8077 RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` 8078 8079 Message_ *string `locationName:"message" type:"string"` 8080} 8081 8082// String returns the string representation 8083func (s ValidationException) String() string { 8084 return awsutil.Prettify(s) 8085} 8086 8087// GoString returns the string representation 8088func (s ValidationException) GoString() string { 8089 return s.String() 8090} 8091 8092func newErrorValidationException(v protocol.ResponseMetadata) error { 8093 return &ValidationException{ 8094 RespMetadata: v, 8095 } 8096} 8097 8098// Code returns the exception type name. 8099func (s *ValidationException) Code() string { 8100 return "ValidationException" 8101} 8102 8103// Message returns the exception's message. 8104func (s *ValidationException) Message() string { 8105 if s.Message_ != nil { 8106 return *s.Message_ 8107 } 8108 return "" 8109} 8110 8111// OrigErr always returns nil, satisfies awserr.Error interface. 8112func (s *ValidationException) OrigErr() error { 8113 return nil 8114} 8115 8116func (s *ValidationException) Error() string { 8117 return fmt.Sprintf("%s: %s", s.Code(), s.Message()) 8118} 8119 8120// Status code returns the HTTP status code for the request's response error. 8121func (s *ValidationException) StatusCode() int { 8122 return s.RespMetadata.StatusCode 8123} 8124 8125// RequestID returns the service's response RequestID for request. 8126func (s *ValidationException) RequestID() string { 8127 return s.RespMetadata.RequestID 8128} 8129 8130// The variable. 8131type Variable struct { 8132 _ struct{} `type:"structure"` 8133 8134 // The time when the variable was created. 8135 CreatedTime *string `locationName:"createdTime" type:"string"` 8136 8137 // The data source of the variable. 8138 DataSource *string `locationName:"dataSource" type:"string" enum:"DataSource"` 8139 8140 // The data type of the variable. 8141 DataType *string `locationName:"dataType" type:"string" enum:"DataType"` 8142 8143 // The default value of the variable. 8144 DefaultValue *string `locationName:"defaultValue" type:"string"` 8145 8146 // The description of the variable. 8147 Description *string `locationName:"description" type:"string"` 8148 8149 // The time when variable was last updated. 8150 LastUpdatedTime *string `locationName:"lastUpdatedTime" type:"string"` 8151 8152 // The name of the variable. 8153 Name *string `locationName:"name" type:"string"` 8154 8155 // The variable type of the variable. 8156 VariableType *string `locationName:"variableType" type:"string"` 8157} 8158 8159// String returns the string representation 8160func (s Variable) String() string { 8161 return awsutil.Prettify(s) 8162} 8163 8164// GoString returns the string representation 8165func (s Variable) GoString() string { 8166 return s.String() 8167} 8168 8169// SetCreatedTime sets the CreatedTime field's value. 8170func (s *Variable) SetCreatedTime(v string) *Variable { 8171 s.CreatedTime = &v 8172 return s 8173} 8174 8175// SetDataSource sets the DataSource field's value. 8176func (s *Variable) SetDataSource(v string) *Variable { 8177 s.DataSource = &v 8178 return s 8179} 8180 8181// SetDataType sets the DataType field's value. 8182func (s *Variable) SetDataType(v string) *Variable { 8183 s.DataType = &v 8184 return s 8185} 8186 8187// SetDefaultValue sets the DefaultValue field's value. 8188func (s *Variable) SetDefaultValue(v string) *Variable { 8189 s.DefaultValue = &v 8190 return s 8191} 8192 8193// SetDescription sets the Description field's value. 8194func (s *Variable) SetDescription(v string) *Variable { 8195 s.Description = &v 8196 return s 8197} 8198 8199// SetLastUpdatedTime sets the LastUpdatedTime field's value. 8200func (s *Variable) SetLastUpdatedTime(v string) *Variable { 8201 s.LastUpdatedTime = &v 8202 return s 8203} 8204 8205// SetName sets the Name field's value. 8206func (s *Variable) SetName(v string) *Variable { 8207 s.Name = &v 8208 return s 8209} 8210 8211// SetVariableType sets the VariableType field's value. 8212func (s *Variable) SetVariableType(v string) *Variable { 8213 s.VariableType = &v 8214 return s 8215} 8216 8217// The variable entry in a list. 8218type VariableEntry struct { 8219 _ struct{} `type:"structure"` 8220 8221 // The data source of the variable entry. 8222 DataSource *string `locationName:"dataSource" type:"string"` 8223 8224 // The data type of the variable entry. 8225 DataType *string `locationName:"dataType" type:"string"` 8226 8227 // The default value of the variable entry. 8228 DefaultValue *string `locationName:"defaultValue" type:"string"` 8229 8230 // The description of the variable entry. 8231 Description *string `locationName:"description" type:"string"` 8232 8233 // The name of the variable entry. 8234 Name *string `locationName:"name" type:"string"` 8235 8236 // The type of the variable entry. 8237 VariableType *string `locationName:"variableType" type:"string"` 8238} 8239 8240// String returns the string representation 8241func (s VariableEntry) String() string { 8242 return awsutil.Prettify(s) 8243} 8244 8245// GoString returns the string representation 8246func (s VariableEntry) GoString() string { 8247 return s.String() 8248} 8249 8250// SetDataSource sets the DataSource field's value. 8251func (s *VariableEntry) SetDataSource(v string) *VariableEntry { 8252 s.DataSource = &v 8253 return s 8254} 8255 8256// SetDataType sets the DataType field's value. 8257func (s *VariableEntry) SetDataType(v string) *VariableEntry { 8258 s.DataType = &v 8259 return s 8260} 8261 8262// SetDefaultValue sets the DefaultValue field's value. 8263func (s *VariableEntry) SetDefaultValue(v string) *VariableEntry { 8264 s.DefaultValue = &v 8265 return s 8266} 8267 8268// SetDescription sets the Description field's value. 8269func (s *VariableEntry) SetDescription(v string) *VariableEntry { 8270 s.Description = &v 8271 return s 8272} 8273 8274// SetName sets the Name field's value. 8275func (s *VariableEntry) SetName(v string) *VariableEntry { 8276 s.Name = &v 8277 return s 8278} 8279 8280// SetVariableType sets the VariableType field's value. 8281func (s *VariableEntry) SetVariableType(v string) *VariableEntry { 8282 s.VariableType = &v 8283 return s 8284} 8285 8286const ( 8287 // DataSourceEvent is a DataSource enum value 8288 DataSourceEvent = "EVENT" 8289 8290 // DataSourceModelScore is a DataSource enum value 8291 DataSourceModelScore = "MODEL_SCORE" 8292 8293 // DataSourceExternalModelScore is a DataSource enum value 8294 DataSourceExternalModelScore = "EXTERNAL_MODEL_SCORE" 8295) 8296 8297const ( 8298 // DataTypeString is a DataType enum value 8299 DataTypeString = "STRING" 8300 8301 // DataTypeInteger is a DataType enum value 8302 DataTypeInteger = "INTEGER" 8303 8304 // DataTypeFloat is a DataType enum value 8305 DataTypeFloat = "FLOAT" 8306 8307 // DataTypeBoolean is a DataType enum value 8308 DataTypeBoolean = "BOOLEAN" 8309) 8310 8311const ( 8312 // DetectorVersionStatusDraft is a DetectorVersionStatus enum value 8313 DetectorVersionStatusDraft = "DRAFT" 8314 8315 // DetectorVersionStatusActive is a DetectorVersionStatus enum value 8316 DetectorVersionStatusActive = "ACTIVE" 8317 8318 // DetectorVersionStatusInactive is a DetectorVersionStatus enum value 8319 DetectorVersionStatusInactive = "INACTIVE" 8320) 8321 8322const ( 8323 // LanguageDetectorpl is a Language enum value 8324 LanguageDetectorpl = "DETECTORPL" 8325) 8326 8327const ( 8328 // ModelEndpointStatusAssociated is a ModelEndpointStatus enum value 8329 ModelEndpointStatusAssociated = "ASSOCIATED" 8330 8331 // ModelEndpointStatusDissociated is a ModelEndpointStatus enum value 8332 ModelEndpointStatusDissociated = "DISSOCIATED" 8333) 8334 8335const ( 8336 // ModelInputDataFormatTextCsv is a ModelInputDataFormat enum value 8337 ModelInputDataFormatTextCsv = "TEXT_CSV" 8338 8339 // ModelInputDataFormatApplicationJson is a ModelInputDataFormat enum value 8340 ModelInputDataFormatApplicationJson = "APPLICATION_JSON" 8341) 8342 8343const ( 8344 // ModelOutputDataFormatTextCsv is a ModelOutputDataFormat enum value 8345 ModelOutputDataFormatTextCsv = "TEXT_CSV" 8346 8347 // ModelOutputDataFormatApplicationJsonlines is a ModelOutputDataFormat enum value 8348 ModelOutputDataFormatApplicationJsonlines = "APPLICATION_JSONLINES" 8349) 8350 8351const ( 8352 // ModelSourceSagemaker is a ModelSource enum value 8353 ModelSourceSagemaker = "SAGEMAKER" 8354) 8355 8356const ( 8357 // ModelTypeEnumOnlineFraudInsights is a ModelTypeEnum enum value 8358 ModelTypeEnumOnlineFraudInsights = "ONLINE_FRAUD_INSIGHTS" 8359) 8360 8361const ( 8362 // ModelVersionStatusTrainingInProgress is a ModelVersionStatus enum value 8363 ModelVersionStatusTrainingInProgress = "TRAINING_IN_PROGRESS" 8364 8365 // ModelVersionStatusTrainingComplete is a ModelVersionStatus enum value 8366 ModelVersionStatusTrainingComplete = "TRAINING_COMPLETE" 8367 8368 // ModelVersionStatusActivateRequested is a ModelVersionStatus enum value 8369 ModelVersionStatusActivateRequested = "ACTIVATE_REQUESTED" 8370 8371 // ModelVersionStatusActivateInProgress is a ModelVersionStatus enum value 8372 ModelVersionStatusActivateInProgress = "ACTIVATE_IN_PROGRESS" 8373 8374 // ModelVersionStatusActive is a ModelVersionStatus enum value 8375 ModelVersionStatusActive = "ACTIVE" 8376 8377 // ModelVersionStatusInactivateInProgress is a ModelVersionStatus enum value 8378 ModelVersionStatusInactivateInProgress = "INACTIVATE_IN_PROGRESS" 8379 8380 // ModelVersionStatusInactive is a ModelVersionStatus enum value 8381 ModelVersionStatusInactive = "INACTIVE" 8382 8383 // ModelVersionStatusError is a ModelVersionStatus enum value 8384 ModelVersionStatusError = "ERROR" 8385) 8386 8387const ( 8388 // RuleExecutionModeAllMatched is a RuleExecutionMode enum value 8389 RuleExecutionModeAllMatched = "ALL_MATCHED" 8390 8391 // RuleExecutionModeFirstMatched is a RuleExecutionMode enum value 8392 RuleExecutionModeFirstMatched = "FIRST_MATCHED" 8393) 8394