1// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT. 2 3package comprehendmedical 4 5import ( 6 "time" 7 8 "github.com/aws/aws-sdk-go/aws" 9 "github.com/aws/aws-sdk-go/aws/awsutil" 10 "github.com/aws/aws-sdk-go/aws/request" 11) 12 13const opDescribeEntitiesDetectionV2Job = "DescribeEntitiesDetectionV2Job" 14 15// DescribeEntitiesDetectionV2JobRequest generates a "aws/request.Request" representing the 16// client's request for the DescribeEntitiesDetectionV2Job operation. The "output" return 17// value will be populated with the request's response once the request completes 18// successfully. 19// 20// Use "Send" method on the returned Request to send the API call to the service. 21// the "output" return value is not valid until after Send returns without error. 22// 23// See DescribeEntitiesDetectionV2Job for more information on using the DescribeEntitiesDetectionV2Job 24// API call, and error handling. 25// 26// This method is useful when you want to inject custom logic or configuration 27// into the SDK's request lifecycle. Such as custom headers, or retry logic. 28// 29// 30// // Example sending a request using the DescribeEntitiesDetectionV2JobRequest method. 31// req, resp := client.DescribeEntitiesDetectionV2JobRequest(params) 32// 33// err := req.Send() 34// if err == nil { // resp is now filled 35// fmt.Println(resp) 36// } 37// 38// See also, https://docs.aws.amazon.com/goto/WebAPI/comprehendmedical-2018-10-30/DescribeEntitiesDetectionV2Job 39func (c *ComprehendMedical) DescribeEntitiesDetectionV2JobRequest(input *DescribeEntitiesDetectionV2JobInput) (req *request.Request, output *DescribeEntitiesDetectionV2JobOutput) { 40 op := &request.Operation{ 41 Name: opDescribeEntitiesDetectionV2Job, 42 HTTPMethod: "POST", 43 HTTPPath: "/", 44 } 45 46 if input == nil { 47 input = &DescribeEntitiesDetectionV2JobInput{} 48 } 49 50 output = &DescribeEntitiesDetectionV2JobOutput{} 51 req = c.newRequest(op, input, output) 52 return 53} 54 55// DescribeEntitiesDetectionV2Job API operation for AWS Comprehend Medical. 56// 57// Gets the properties associated with a medical entities detection job. Use 58// this operation to get the status of a detection job. 59// 60// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 61// with awserr.Error's Code and Message methods to get detailed information about 62// the error. 63// 64// See the AWS API reference guide for AWS Comprehend Medical's 65// API operation DescribeEntitiesDetectionV2Job for usage and error information. 66// 67// Returned Error Codes: 68// * ErrCodeInvalidRequestException "InvalidRequestException" 69// The request that you made is invalid. Check your request to determine why 70// it's invalid and then retry the request. 71// 72// * ErrCodeTooManyRequestsException "TooManyRequestsException" 73// You have made too many requests within a short period of time. Wait for a 74// short time and then try your request again. Contact customer support for 75// more information about a service limit increase. 76// 77// * ErrCodeResourceNotFoundException "ResourceNotFoundException" 78// The resource identified by the specified Amazon Resource Name (ARN) was not 79// found. Check the ARN and try your request again. 80// 81// * ErrCodeInternalServerException "InternalServerException" 82// An internal server error occurred. Retry your request. 83// 84// See also, https://docs.aws.amazon.com/goto/WebAPI/comprehendmedical-2018-10-30/DescribeEntitiesDetectionV2Job 85func (c *ComprehendMedical) DescribeEntitiesDetectionV2Job(input *DescribeEntitiesDetectionV2JobInput) (*DescribeEntitiesDetectionV2JobOutput, error) { 86 req, out := c.DescribeEntitiesDetectionV2JobRequest(input) 87 return out, req.Send() 88} 89 90// DescribeEntitiesDetectionV2JobWithContext is the same as DescribeEntitiesDetectionV2Job with the addition of 91// the ability to pass a context and additional request options. 92// 93// See DescribeEntitiesDetectionV2Job for details on how to use this API operation. 94// 95// The context must be non-nil and will be used for request cancellation. If 96// the context is nil a panic will occur. In the future the SDK may create 97// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 98// for more information on using Contexts. 99func (c *ComprehendMedical) DescribeEntitiesDetectionV2JobWithContext(ctx aws.Context, input *DescribeEntitiesDetectionV2JobInput, opts ...request.Option) (*DescribeEntitiesDetectionV2JobOutput, error) { 100 req, out := c.DescribeEntitiesDetectionV2JobRequest(input) 101 req.SetContext(ctx) 102 req.ApplyOptions(opts...) 103 return out, req.Send() 104} 105 106const opDescribePHIDetectionJob = "DescribePHIDetectionJob" 107 108// DescribePHIDetectionJobRequest generates a "aws/request.Request" representing the 109// client's request for the DescribePHIDetectionJob operation. The "output" return 110// value will be populated with the request's response once the request completes 111// successfully. 112// 113// Use "Send" method on the returned Request to send the API call to the service. 114// the "output" return value is not valid until after Send returns without error. 115// 116// See DescribePHIDetectionJob for more information on using the DescribePHIDetectionJob 117// API call, and error handling. 118// 119// This method is useful when you want to inject custom logic or configuration 120// into the SDK's request lifecycle. Such as custom headers, or retry logic. 121// 122// 123// // Example sending a request using the DescribePHIDetectionJobRequest method. 124// req, resp := client.DescribePHIDetectionJobRequest(params) 125// 126// err := req.Send() 127// if err == nil { // resp is now filled 128// fmt.Println(resp) 129// } 130// 131// See also, https://docs.aws.amazon.com/goto/WebAPI/comprehendmedical-2018-10-30/DescribePHIDetectionJob 132func (c *ComprehendMedical) DescribePHIDetectionJobRequest(input *DescribePHIDetectionJobInput) (req *request.Request, output *DescribePHIDetectionJobOutput) { 133 op := &request.Operation{ 134 Name: opDescribePHIDetectionJob, 135 HTTPMethod: "POST", 136 HTTPPath: "/", 137 } 138 139 if input == nil { 140 input = &DescribePHIDetectionJobInput{} 141 } 142 143 output = &DescribePHIDetectionJobOutput{} 144 req = c.newRequest(op, input, output) 145 return 146} 147 148// DescribePHIDetectionJob API operation for AWS Comprehend Medical. 149// 150// Gets the properties associated with a protected health information (PHI) 151// detection job. Use this operation to get the status of a detection job. 152// 153// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 154// with awserr.Error's Code and Message methods to get detailed information about 155// the error. 156// 157// See the AWS API reference guide for AWS Comprehend Medical's 158// API operation DescribePHIDetectionJob for usage and error information. 159// 160// Returned Error Codes: 161// * ErrCodeInvalidRequestException "InvalidRequestException" 162// The request that you made is invalid. Check your request to determine why 163// it's invalid and then retry the request. 164// 165// * ErrCodeTooManyRequestsException "TooManyRequestsException" 166// You have made too many requests within a short period of time. Wait for a 167// short time and then try your request again. Contact customer support for 168// more information about a service limit increase. 169// 170// * ErrCodeResourceNotFoundException "ResourceNotFoundException" 171// The resource identified by the specified Amazon Resource Name (ARN) was not 172// found. Check the ARN and try your request again. 173// 174// * ErrCodeInternalServerException "InternalServerException" 175// An internal server error occurred. Retry your request. 176// 177// See also, https://docs.aws.amazon.com/goto/WebAPI/comprehendmedical-2018-10-30/DescribePHIDetectionJob 178func (c *ComprehendMedical) DescribePHIDetectionJob(input *DescribePHIDetectionJobInput) (*DescribePHIDetectionJobOutput, error) { 179 req, out := c.DescribePHIDetectionJobRequest(input) 180 return out, req.Send() 181} 182 183// DescribePHIDetectionJobWithContext is the same as DescribePHIDetectionJob with the addition of 184// the ability to pass a context and additional request options. 185// 186// See DescribePHIDetectionJob for details on how to use this API operation. 187// 188// The context must be non-nil and will be used for request cancellation. If 189// the context is nil a panic will occur. In the future the SDK may create 190// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 191// for more information on using Contexts. 192func (c *ComprehendMedical) DescribePHIDetectionJobWithContext(ctx aws.Context, input *DescribePHIDetectionJobInput, opts ...request.Option) (*DescribePHIDetectionJobOutput, error) { 193 req, out := c.DescribePHIDetectionJobRequest(input) 194 req.SetContext(ctx) 195 req.ApplyOptions(opts...) 196 return out, req.Send() 197} 198 199const opDetectEntities = "DetectEntities" 200 201// DetectEntitiesRequest generates a "aws/request.Request" representing the 202// client's request for the DetectEntities operation. The "output" return 203// value will be populated with the request's response once the request completes 204// successfully. 205// 206// Use "Send" method on the returned Request to send the API call to the service. 207// the "output" return value is not valid until after Send returns without error. 208// 209// See DetectEntities for more information on using the DetectEntities 210// API call, and error handling. 211// 212// This method is useful when you want to inject custom logic or configuration 213// into the SDK's request lifecycle. Such as custom headers, or retry logic. 214// 215// 216// // Example sending a request using the DetectEntitiesRequest method. 217// req, resp := client.DetectEntitiesRequest(params) 218// 219// err := req.Send() 220// if err == nil { // resp is now filled 221// fmt.Println(resp) 222// } 223// 224// See also, https://docs.aws.amazon.com/goto/WebAPI/comprehendmedical-2018-10-30/DetectEntities 225// 226// Deprecated: This operation is deprecated, use DetectEntitiesV2 instead. 227func (c *ComprehendMedical) DetectEntitiesRequest(input *DetectEntitiesInput) (req *request.Request, output *DetectEntitiesOutput) { 228 if c.Client.Config.Logger != nil { 229 c.Client.Config.Logger.Log("This operation, DetectEntities, has been deprecated") 230 } 231 op := &request.Operation{ 232 Name: opDetectEntities, 233 HTTPMethod: "POST", 234 HTTPPath: "/", 235 } 236 237 if input == nil { 238 input = &DetectEntitiesInput{} 239 } 240 241 output = &DetectEntitiesOutput{} 242 req = c.newRequest(op, input, output) 243 return 244} 245 246// DetectEntities API operation for AWS Comprehend Medical. 247// 248// The DetectEntities operation is deprecated. You should use the DetectEntitiesV2 249// operation instead. 250// 251// Inspects the clinical text for a variety of medical entities and returns 252// specific information about them such as entity category, location, and confidence 253// score on that information . 254// 255// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 256// with awserr.Error's Code and Message methods to get detailed information about 257// the error. 258// 259// See the AWS API reference guide for AWS Comprehend Medical's 260// API operation DetectEntities for usage and error information. 261// 262// Returned Error Codes: 263// * ErrCodeInternalServerException "InternalServerException" 264// An internal server error occurred. Retry your request. 265// 266// * ErrCodeServiceUnavailableException "ServiceUnavailableException" 267// The Amazon Comprehend Medical service is temporarily unavailable. Please 268// wait and then retry your request. 269// 270// * ErrCodeTooManyRequestsException "TooManyRequestsException" 271// You have made too many requests within a short period of time. Wait for a 272// short time and then try your request again. Contact customer support for 273// more information about a service limit increase. 274// 275// * ErrCodeInvalidRequestException "InvalidRequestException" 276// The request that you made is invalid. Check your request to determine why 277// it's invalid and then retry the request. 278// 279// * ErrCodeInvalidEncodingException "InvalidEncodingException" 280// The input text was not in valid UTF-8 character encoding. Check your text 281// then retry your request. 282// 283// * ErrCodeTextSizeLimitExceededException "TextSizeLimitExceededException" 284// The size of the text you submitted exceeds the size limit. Reduce the size 285// of the text or use a smaller document and then retry your request. 286// 287// See also, https://docs.aws.amazon.com/goto/WebAPI/comprehendmedical-2018-10-30/DetectEntities 288// 289// Deprecated: This operation is deprecated, use DetectEntitiesV2 instead. 290func (c *ComprehendMedical) DetectEntities(input *DetectEntitiesInput) (*DetectEntitiesOutput, error) { 291 req, out := c.DetectEntitiesRequest(input) 292 return out, req.Send() 293} 294 295// DetectEntitiesWithContext is the same as DetectEntities with the addition of 296// the ability to pass a context and additional request options. 297// 298// See DetectEntities for details on how to use this API operation. 299// 300// The context must be non-nil and will be used for request cancellation. If 301// the context is nil a panic will occur. In the future the SDK may create 302// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 303// for more information on using Contexts. 304// 305// Deprecated: This operation is deprecated, use DetectEntitiesV2 instead. 306func (c *ComprehendMedical) DetectEntitiesWithContext(ctx aws.Context, input *DetectEntitiesInput, opts ...request.Option) (*DetectEntitiesOutput, error) { 307 req, out := c.DetectEntitiesRequest(input) 308 req.SetContext(ctx) 309 req.ApplyOptions(opts...) 310 return out, req.Send() 311} 312 313const opDetectEntitiesV2 = "DetectEntitiesV2" 314 315// DetectEntitiesV2Request generates a "aws/request.Request" representing the 316// client's request for the DetectEntitiesV2 operation. The "output" return 317// value will be populated with the request's response once the request completes 318// successfully. 319// 320// Use "Send" method on the returned Request to send the API call to the service. 321// the "output" return value is not valid until after Send returns without error. 322// 323// See DetectEntitiesV2 for more information on using the DetectEntitiesV2 324// API call, and error handling. 325// 326// This method is useful when you want to inject custom logic or configuration 327// into the SDK's request lifecycle. Such as custom headers, or retry logic. 328// 329// 330// // Example sending a request using the DetectEntitiesV2Request method. 331// req, resp := client.DetectEntitiesV2Request(params) 332// 333// err := req.Send() 334// if err == nil { // resp is now filled 335// fmt.Println(resp) 336// } 337// 338// See also, https://docs.aws.amazon.com/goto/WebAPI/comprehendmedical-2018-10-30/DetectEntitiesV2 339func (c *ComprehendMedical) DetectEntitiesV2Request(input *DetectEntitiesV2Input) (req *request.Request, output *DetectEntitiesV2Output) { 340 op := &request.Operation{ 341 Name: opDetectEntitiesV2, 342 HTTPMethod: "POST", 343 HTTPPath: "/", 344 } 345 346 if input == nil { 347 input = &DetectEntitiesV2Input{} 348 } 349 350 output = &DetectEntitiesV2Output{} 351 req = c.newRequest(op, input, output) 352 return 353} 354 355// DetectEntitiesV2 API operation for AWS Comprehend Medical. 356// 357// Inspects the clinical text for a variety of medical entities and returns 358// specific information about them such as entity category, location, and confidence 359// score on that information. 360// 361// The DetectEntitiesV2 operation replaces the DetectEntities operation. This 362// new action uses a different model for determining the entities in your medical 363// text and changes the way that some entities are returned in the output. You 364// should use the DetectEntitiesV2 operation in all new applications. 365// 366// The DetectEntitiesV2 operation returns the Acuity and Direction entities 367// as attributes instead of types. It does not return the Quality or Quantity 368// entities. 369// 370// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 371// with awserr.Error's Code and Message methods to get detailed information about 372// the error. 373// 374// See the AWS API reference guide for AWS Comprehend Medical's 375// API operation DetectEntitiesV2 for usage and error information. 376// 377// Returned Error Codes: 378// * ErrCodeInternalServerException "InternalServerException" 379// An internal server error occurred. Retry your request. 380// 381// * ErrCodeServiceUnavailableException "ServiceUnavailableException" 382// The Amazon Comprehend Medical service is temporarily unavailable. Please 383// wait and then retry your request. 384// 385// * ErrCodeTooManyRequestsException "TooManyRequestsException" 386// You have made too many requests within a short period of time. Wait for a 387// short time and then try your request again. Contact customer support for 388// more information about a service limit increase. 389// 390// * ErrCodeInvalidRequestException "InvalidRequestException" 391// The request that you made is invalid. Check your request to determine why 392// it's invalid and then retry the request. 393// 394// * ErrCodeInvalidEncodingException "InvalidEncodingException" 395// The input text was not in valid UTF-8 character encoding. Check your text 396// then retry your request. 397// 398// * ErrCodeTextSizeLimitExceededException "TextSizeLimitExceededException" 399// The size of the text you submitted exceeds the size limit. Reduce the size 400// of the text or use a smaller document and then retry your request. 401// 402// See also, https://docs.aws.amazon.com/goto/WebAPI/comprehendmedical-2018-10-30/DetectEntitiesV2 403func (c *ComprehendMedical) DetectEntitiesV2(input *DetectEntitiesV2Input) (*DetectEntitiesV2Output, error) { 404 req, out := c.DetectEntitiesV2Request(input) 405 return out, req.Send() 406} 407 408// DetectEntitiesV2WithContext is the same as DetectEntitiesV2 with the addition of 409// the ability to pass a context and additional request options. 410// 411// See DetectEntitiesV2 for details on how to use this API operation. 412// 413// The context must be non-nil and will be used for request cancellation. If 414// the context is nil a panic will occur. In the future the SDK may create 415// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 416// for more information on using Contexts. 417func (c *ComprehendMedical) DetectEntitiesV2WithContext(ctx aws.Context, input *DetectEntitiesV2Input, opts ...request.Option) (*DetectEntitiesV2Output, error) { 418 req, out := c.DetectEntitiesV2Request(input) 419 req.SetContext(ctx) 420 req.ApplyOptions(opts...) 421 return out, req.Send() 422} 423 424const opDetectPHI = "DetectPHI" 425 426// DetectPHIRequest generates a "aws/request.Request" representing the 427// client's request for the DetectPHI operation. The "output" return 428// value will be populated with the request's response once the request completes 429// successfully. 430// 431// Use "Send" method on the returned Request to send the API call to the service. 432// the "output" return value is not valid until after Send returns without error. 433// 434// See DetectPHI for more information on using the DetectPHI 435// API call, and error handling. 436// 437// This method is useful when you want to inject custom logic or configuration 438// into the SDK's request lifecycle. Such as custom headers, or retry logic. 439// 440// 441// // Example sending a request using the DetectPHIRequest method. 442// req, resp := client.DetectPHIRequest(params) 443// 444// err := req.Send() 445// if err == nil { // resp is now filled 446// fmt.Println(resp) 447// } 448// 449// See also, https://docs.aws.amazon.com/goto/WebAPI/comprehendmedical-2018-10-30/DetectPHI 450func (c *ComprehendMedical) DetectPHIRequest(input *DetectPHIInput) (req *request.Request, output *DetectPHIOutput) { 451 op := &request.Operation{ 452 Name: opDetectPHI, 453 HTTPMethod: "POST", 454 HTTPPath: "/", 455 } 456 457 if input == nil { 458 input = &DetectPHIInput{} 459 } 460 461 output = &DetectPHIOutput{} 462 req = c.newRequest(op, input, output) 463 return 464} 465 466// DetectPHI API operation for AWS Comprehend Medical. 467// 468// Inspects the clinical text for protected health information (PHI) entities 469// and entity category, location, and confidence score on that information. 470// 471// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 472// with awserr.Error's Code and Message methods to get detailed information about 473// the error. 474// 475// See the AWS API reference guide for AWS Comprehend Medical's 476// API operation DetectPHI for usage and error information. 477// 478// Returned Error Codes: 479// * ErrCodeInternalServerException "InternalServerException" 480// An internal server error occurred. Retry your request. 481// 482// * ErrCodeServiceUnavailableException "ServiceUnavailableException" 483// The Amazon Comprehend Medical service is temporarily unavailable. Please 484// wait and then retry your request. 485// 486// * ErrCodeTooManyRequestsException "TooManyRequestsException" 487// You have made too many requests within a short period of time. Wait for a 488// short time and then try your request again. Contact customer support for 489// more information about a service limit increase. 490// 491// * ErrCodeInvalidRequestException "InvalidRequestException" 492// The request that you made is invalid. Check your request to determine why 493// it's invalid and then retry the request. 494// 495// * ErrCodeInvalidEncodingException "InvalidEncodingException" 496// The input text was not in valid UTF-8 character encoding. Check your text 497// then retry your request. 498// 499// * ErrCodeTextSizeLimitExceededException "TextSizeLimitExceededException" 500// The size of the text you submitted exceeds the size limit. Reduce the size 501// of the text or use a smaller document and then retry your request. 502// 503// See also, https://docs.aws.amazon.com/goto/WebAPI/comprehendmedical-2018-10-30/DetectPHI 504func (c *ComprehendMedical) DetectPHI(input *DetectPHIInput) (*DetectPHIOutput, error) { 505 req, out := c.DetectPHIRequest(input) 506 return out, req.Send() 507} 508 509// DetectPHIWithContext is the same as DetectPHI with the addition of 510// the ability to pass a context and additional request options. 511// 512// See DetectPHI for details on how to use this API operation. 513// 514// The context must be non-nil and will be used for request cancellation. If 515// the context is nil a panic will occur. In the future the SDK may create 516// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 517// for more information on using Contexts. 518func (c *ComprehendMedical) DetectPHIWithContext(ctx aws.Context, input *DetectPHIInput, opts ...request.Option) (*DetectPHIOutput, error) { 519 req, out := c.DetectPHIRequest(input) 520 req.SetContext(ctx) 521 req.ApplyOptions(opts...) 522 return out, req.Send() 523} 524 525const opListEntitiesDetectionV2Jobs = "ListEntitiesDetectionV2Jobs" 526 527// ListEntitiesDetectionV2JobsRequest generates a "aws/request.Request" representing the 528// client's request for the ListEntitiesDetectionV2Jobs operation. The "output" return 529// value will be populated with the request's response once the request completes 530// successfully. 531// 532// Use "Send" method on the returned Request to send the API call to the service. 533// the "output" return value is not valid until after Send returns without error. 534// 535// See ListEntitiesDetectionV2Jobs for more information on using the ListEntitiesDetectionV2Jobs 536// API call, and error handling. 537// 538// This method is useful when you want to inject custom logic or configuration 539// into the SDK's request lifecycle. Such as custom headers, or retry logic. 540// 541// 542// // Example sending a request using the ListEntitiesDetectionV2JobsRequest method. 543// req, resp := client.ListEntitiesDetectionV2JobsRequest(params) 544// 545// err := req.Send() 546// if err == nil { // resp is now filled 547// fmt.Println(resp) 548// } 549// 550// See also, https://docs.aws.amazon.com/goto/WebAPI/comprehendmedical-2018-10-30/ListEntitiesDetectionV2Jobs 551func (c *ComprehendMedical) ListEntitiesDetectionV2JobsRequest(input *ListEntitiesDetectionV2JobsInput) (req *request.Request, output *ListEntitiesDetectionV2JobsOutput) { 552 op := &request.Operation{ 553 Name: opListEntitiesDetectionV2Jobs, 554 HTTPMethod: "POST", 555 HTTPPath: "/", 556 } 557 558 if input == nil { 559 input = &ListEntitiesDetectionV2JobsInput{} 560 } 561 562 output = &ListEntitiesDetectionV2JobsOutput{} 563 req = c.newRequest(op, input, output) 564 return 565} 566 567// ListEntitiesDetectionV2Jobs API operation for AWS Comprehend Medical. 568// 569// Gets a list of medical entity detection jobs that you have submitted. 570// 571// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 572// with awserr.Error's Code and Message methods to get detailed information about 573// the error. 574// 575// See the AWS API reference guide for AWS Comprehend Medical's 576// API operation ListEntitiesDetectionV2Jobs for usage and error information. 577// 578// Returned Error Codes: 579// * ErrCodeInvalidRequestException "InvalidRequestException" 580// The request that you made is invalid. Check your request to determine why 581// it's invalid and then retry the request. 582// 583// * ErrCodeValidationException "ValidationException" 584// The filter that you specified for the operation is invalid. Check the filter 585// values that you entered and try your request again. 586// 587// * ErrCodeTooManyRequestsException "TooManyRequestsException" 588// You have made too many requests within a short period of time. Wait for a 589// short time and then try your request again. Contact customer support for 590// more information about a service limit increase. 591// 592// * ErrCodeInternalServerException "InternalServerException" 593// An internal server error occurred. Retry your request. 594// 595// See also, https://docs.aws.amazon.com/goto/WebAPI/comprehendmedical-2018-10-30/ListEntitiesDetectionV2Jobs 596func (c *ComprehendMedical) ListEntitiesDetectionV2Jobs(input *ListEntitiesDetectionV2JobsInput) (*ListEntitiesDetectionV2JobsOutput, error) { 597 req, out := c.ListEntitiesDetectionV2JobsRequest(input) 598 return out, req.Send() 599} 600 601// ListEntitiesDetectionV2JobsWithContext is the same as ListEntitiesDetectionV2Jobs with the addition of 602// the ability to pass a context and additional request options. 603// 604// See ListEntitiesDetectionV2Jobs for details on how to use this API operation. 605// 606// The context must be non-nil and will be used for request cancellation. If 607// the context is nil a panic will occur. In the future the SDK may create 608// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 609// for more information on using Contexts. 610func (c *ComprehendMedical) ListEntitiesDetectionV2JobsWithContext(ctx aws.Context, input *ListEntitiesDetectionV2JobsInput, opts ...request.Option) (*ListEntitiesDetectionV2JobsOutput, error) { 611 req, out := c.ListEntitiesDetectionV2JobsRequest(input) 612 req.SetContext(ctx) 613 req.ApplyOptions(opts...) 614 return out, req.Send() 615} 616 617const opListPHIDetectionJobs = "ListPHIDetectionJobs" 618 619// ListPHIDetectionJobsRequest generates a "aws/request.Request" representing the 620// client's request for the ListPHIDetectionJobs operation. The "output" return 621// value will be populated with the request's response once the request completes 622// successfully. 623// 624// Use "Send" method on the returned Request to send the API call to the service. 625// the "output" return value is not valid until after Send returns without error. 626// 627// See ListPHIDetectionJobs for more information on using the ListPHIDetectionJobs 628// API call, and error handling. 629// 630// This method is useful when you want to inject custom logic or configuration 631// into the SDK's request lifecycle. Such as custom headers, or retry logic. 632// 633// 634// // Example sending a request using the ListPHIDetectionJobsRequest method. 635// req, resp := client.ListPHIDetectionJobsRequest(params) 636// 637// err := req.Send() 638// if err == nil { // resp is now filled 639// fmt.Println(resp) 640// } 641// 642// See also, https://docs.aws.amazon.com/goto/WebAPI/comprehendmedical-2018-10-30/ListPHIDetectionJobs 643func (c *ComprehendMedical) ListPHIDetectionJobsRequest(input *ListPHIDetectionJobsInput) (req *request.Request, output *ListPHIDetectionJobsOutput) { 644 op := &request.Operation{ 645 Name: opListPHIDetectionJobs, 646 HTTPMethod: "POST", 647 HTTPPath: "/", 648 } 649 650 if input == nil { 651 input = &ListPHIDetectionJobsInput{} 652 } 653 654 output = &ListPHIDetectionJobsOutput{} 655 req = c.newRequest(op, input, output) 656 return 657} 658 659// ListPHIDetectionJobs API operation for AWS Comprehend Medical. 660// 661// Gets a list of protected health information (PHI) detection jobs that you 662// have submitted. 663// 664// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 665// with awserr.Error's Code and Message methods to get detailed information about 666// the error. 667// 668// See the AWS API reference guide for AWS Comprehend Medical's 669// API operation ListPHIDetectionJobs for usage and error information. 670// 671// Returned Error Codes: 672// * ErrCodeInvalidRequestException "InvalidRequestException" 673// The request that you made is invalid. Check your request to determine why 674// it's invalid and then retry the request. 675// 676// * ErrCodeValidationException "ValidationException" 677// The filter that you specified for the operation is invalid. Check the filter 678// values that you entered and try your request again. 679// 680// * ErrCodeTooManyRequestsException "TooManyRequestsException" 681// You have made too many requests within a short period of time. Wait for a 682// short time and then try your request again. Contact customer support for 683// more information about a service limit increase. 684// 685// * ErrCodeInternalServerException "InternalServerException" 686// An internal server error occurred. Retry your request. 687// 688// See also, https://docs.aws.amazon.com/goto/WebAPI/comprehendmedical-2018-10-30/ListPHIDetectionJobs 689func (c *ComprehendMedical) ListPHIDetectionJobs(input *ListPHIDetectionJobsInput) (*ListPHIDetectionJobsOutput, error) { 690 req, out := c.ListPHIDetectionJobsRequest(input) 691 return out, req.Send() 692} 693 694// ListPHIDetectionJobsWithContext is the same as ListPHIDetectionJobs with the addition of 695// the ability to pass a context and additional request options. 696// 697// See ListPHIDetectionJobs for details on how to use this API operation. 698// 699// The context must be non-nil and will be used for request cancellation. If 700// the context is nil a panic will occur. In the future the SDK may create 701// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 702// for more information on using Contexts. 703func (c *ComprehendMedical) ListPHIDetectionJobsWithContext(ctx aws.Context, input *ListPHIDetectionJobsInput, opts ...request.Option) (*ListPHIDetectionJobsOutput, error) { 704 req, out := c.ListPHIDetectionJobsRequest(input) 705 req.SetContext(ctx) 706 req.ApplyOptions(opts...) 707 return out, req.Send() 708} 709 710const opStartEntitiesDetectionV2Job = "StartEntitiesDetectionV2Job" 711 712// StartEntitiesDetectionV2JobRequest generates a "aws/request.Request" representing the 713// client's request for the StartEntitiesDetectionV2Job operation. The "output" return 714// value will be populated with the request's response once the request completes 715// successfully. 716// 717// Use "Send" method on the returned Request to send the API call to the service. 718// the "output" return value is not valid until after Send returns without error. 719// 720// See StartEntitiesDetectionV2Job for more information on using the StartEntitiesDetectionV2Job 721// API call, and error handling. 722// 723// This method is useful when you want to inject custom logic or configuration 724// into the SDK's request lifecycle. Such as custom headers, or retry logic. 725// 726// 727// // Example sending a request using the StartEntitiesDetectionV2JobRequest method. 728// req, resp := client.StartEntitiesDetectionV2JobRequest(params) 729// 730// err := req.Send() 731// if err == nil { // resp is now filled 732// fmt.Println(resp) 733// } 734// 735// See also, https://docs.aws.amazon.com/goto/WebAPI/comprehendmedical-2018-10-30/StartEntitiesDetectionV2Job 736func (c *ComprehendMedical) StartEntitiesDetectionV2JobRequest(input *StartEntitiesDetectionV2JobInput) (req *request.Request, output *StartEntitiesDetectionV2JobOutput) { 737 op := &request.Operation{ 738 Name: opStartEntitiesDetectionV2Job, 739 HTTPMethod: "POST", 740 HTTPPath: "/", 741 } 742 743 if input == nil { 744 input = &StartEntitiesDetectionV2JobInput{} 745 } 746 747 output = &StartEntitiesDetectionV2JobOutput{} 748 req = c.newRequest(op, input, output) 749 return 750} 751 752// StartEntitiesDetectionV2Job API operation for AWS Comprehend Medical. 753// 754// Starts an asynchronous medical entity detection job for a collection of documents. 755// Use the DescribeEntitiesDetectionV2Job operation to track the status of a 756// job. 757// 758// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 759// with awserr.Error's Code and Message methods to get detailed information about 760// the error. 761// 762// See the AWS API reference guide for AWS Comprehend Medical's 763// API operation StartEntitiesDetectionV2Job for usage and error information. 764// 765// Returned Error Codes: 766// * ErrCodeInvalidRequestException "InvalidRequestException" 767// The request that you made is invalid. Check your request to determine why 768// it's invalid and then retry the request. 769// 770// * ErrCodeTooManyRequestsException "TooManyRequestsException" 771// You have made too many requests within a short period of time. Wait for a 772// short time and then try your request again. Contact customer support for 773// more information about a service limit increase. 774// 775// * ErrCodeResourceNotFoundException "ResourceNotFoundException" 776// The resource identified by the specified Amazon Resource Name (ARN) was not 777// found. Check the ARN and try your request again. 778// 779// * ErrCodeInternalServerException "InternalServerException" 780// An internal server error occurred. Retry your request. 781// 782// See also, https://docs.aws.amazon.com/goto/WebAPI/comprehendmedical-2018-10-30/StartEntitiesDetectionV2Job 783func (c *ComprehendMedical) StartEntitiesDetectionV2Job(input *StartEntitiesDetectionV2JobInput) (*StartEntitiesDetectionV2JobOutput, error) { 784 req, out := c.StartEntitiesDetectionV2JobRequest(input) 785 return out, req.Send() 786} 787 788// StartEntitiesDetectionV2JobWithContext is the same as StartEntitiesDetectionV2Job with the addition of 789// the ability to pass a context and additional request options. 790// 791// See StartEntitiesDetectionV2Job for details on how to use this API operation. 792// 793// The context must be non-nil and will be used for request cancellation. If 794// the context is nil a panic will occur. In the future the SDK may create 795// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 796// for more information on using Contexts. 797func (c *ComprehendMedical) StartEntitiesDetectionV2JobWithContext(ctx aws.Context, input *StartEntitiesDetectionV2JobInput, opts ...request.Option) (*StartEntitiesDetectionV2JobOutput, error) { 798 req, out := c.StartEntitiesDetectionV2JobRequest(input) 799 req.SetContext(ctx) 800 req.ApplyOptions(opts...) 801 return out, req.Send() 802} 803 804const opStartPHIDetectionJob = "StartPHIDetectionJob" 805 806// StartPHIDetectionJobRequest generates a "aws/request.Request" representing the 807// client's request for the StartPHIDetectionJob operation. The "output" return 808// value will be populated with the request's response once the request completes 809// successfully. 810// 811// Use "Send" method on the returned Request to send the API call to the service. 812// the "output" return value is not valid until after Send returns without error. 813// 814// See StartPHIDetectionJob for more information on using the StartPHIDetectionJob 815// API call, and error handling. 816// 817// This method is useful when you want to inject custom logic or configuration 818// into the SDK's request lifecycle. Such as custom headers, or retry logic. 819// 820// 821// // Example sending a request using the StartPHIDetectionJobRequest method. 822// req, resp := client.StartPHIDetectionJobRequest(params) 823// 824// err := req.Send() 825// if err == nil { // resp is now filled 826// fmt.Println(resp) 827// } 828// 829// See also, https://docs.aws.amazon.com/goto/WebAPI/comprehendmedical-2018-10-30/StartPHIDetectionJob 830func (c *ComprehendMedical) StartPHIDetectionJobRequest(input *StartPHIDetectionJobInput) (req *request.Request, output *StartPHIDetectionJobOutput) { 831 op := &request.Operation{ 832 Name: opStartPHIDetectionJob, 833 HTTPMethod: "POST", 834 HTTPPath: "/", 835 } 836 837 if input == nil { 838 input = &StartPHIDetectionJobInput{} 839 } 840 841 output = &StartPHIDetectionJobOutput{} 842 req = c.newRequest(op, input, output) 843 return 844} 845 846// StartPHIDetectionJob API operation for AWS Comprehend Medical. 847// 848// Starts an asynchronous job to detect protected health information (PHI). 849// Use the DescribePHIDetectionJob operation to track the status of a job. 850// 851// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 852// with awserr.Error's Code and Message methods to get detailed information about 853// the error. 854// 855// See the AWS API reference guide for AWS Comprehend Medical's 856// API operation StartPHIDetectionJob for usage and error information. 857// 858// Returned Error Codes: 859// * ErrCodeInvalidRequestException "InvalidRequestException" 860// The request that you made is invalid. Check your request to determine why 861// it's invalid and then retry the request. 862// 863// * ErrCodeTooManyRequestsException "TooManyRequestsException" 864// You have made too many requests within a short period of time. Wait for a 865// short time and then try your request again. Contact customer support for 866// more information about a service limit increase. 867// 868// * ErrCodeResourceNotFoundException "ResourceNotFoundException" 869// The resource identified by the specified Amazon Resource Name (ARN) was not 870// found. Check the ARN and try your request again. 871// 872// * ErrCodeInternalServerException "InternalServerException" 873// An internal server error occurred. Retry your request. 874// 875// See also, https://docs.aws.amazon.com/goto/WebAPI/comprehendmedical-2018-10-30/StartPHIDetectionJob 876func (c *ComprehendMedical) StartPHIDetectionJob(input *StartPHIDetectionJobInput) (*StartPHIDetectionJobOutput, error) { 877 req, out := c.StartPHIDetectionJobRequest(input) 878 return out, req.Send() 879} 880 881// StartPHIDetectionJobWithContext is the same as StartPHIDetectionJob with the addition of 882// the ability to pass a context and additional request options. 883// 884// See StartPHIDetectionJob for details on how to use this API operation. 885// 886// The context must be non-nil and will be used for request cancellation. If 887// the context is nil a panic will occur. In the future the SDK may create 888// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 889// for more information on using Contexts. 890func (c *ComprehendMedical) StartPHIDetectionJobWithContext(ctx aws.Context, input *StartPHIDetectionJobInput, opts ...request.Option) (*StartPHIDetectionJobOutput, error) { 891 req, out := c.StartPHIDetectionJobRequest(input) 892 req.SetContext(ctx) 893 req.ApplyOptions(opts...) 894 return out, req.Send() 895} 896 897const opStopEntitiesDetectionV2Job = "StopEntitiesDetectionV2Job" 898 899// StopEntitiesDetectionV2JobRequest generates a "aws/request.Request" representing the 900// client's request for the StopEntitiesDetectionV2Job operation. The "output" return 901// value will be populated with the request's response once the request completes 902// successfully. 903// 904// Use "Send" method on the returned Request to send the API call to the service. 905// the "output" return value is not valid until after Send returns without error. 906// 907// See StopEntitiesDetectionV2Job for more information on using the StopEntitiesDetectionV2Job 908// API call, and error handling. 909// 910// This method is useful when you want to inject custom logic or configuration 911// into the SDK's request lifecycle. Such as custom headers, or retry logic. 912// 913// 914// // Example sending a request using the StopEntitiesDetectionV2JobRequest method. 915// req, resp := client.StopEntitiesDetectionV2JobRequest(params) 916// 917// err := req.Send() 918// if err == nil { // resp is now filled 919// fmt.Println(resp) 920// } 921// 922// See also, https://docs.aws.amazon.com/goto/WebAPI/comprehendmedical-2018-10-30/StopEntitiesDetectionV2Job 923func (c *ComprehendMedical) StopEntitiesDetectionV2JobRequest(input *StopEntitiesDetectionV2JobInput) (req *request.Request, output *StopEntitiesDetectionV2JobOutput) { 924 op := &request.Operation{ 925 Name: opStopEntitiesDetectionV2Job, 926 HTTPMethod: "POST", 927 HTTPPath: "/", 928 } 929 930 if input == nil { 931 input = &StopEntitiesDetectionV2JobInput{} 932 } 933 934 output = &StopEntitiesDetectionV2JobOutput{} 935 req = c.newRequest(op, input, output) 936 return 937} 938 939// StopEntitiesDetectionV2Job API operation for AWS Comprehend Medical. 940// 941// Stops a medical entities detection job in progress. 942// 943// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 944// with awserr.Error's Code and Message methods to get detailed information about 945// the error. 946// 947// See the AWS API reference guide for AWS Comprehend Medical's 948// API operation StopEntitiesDetectionV2Job for usage and error information. 949// 950// Returned Error Codes: 951// * ErrCodeInvalidRequestException "InvalidRequestException" 952// The request that you made is invalid. Check your request to determine why 953// it's invalid and then retry the request. 954// 955// * ErrCodeResourceNotFoundException "ResourceNotFoundException" 956// The resource identified by the specified Amazon Resource Name (ARN) was not 957// found. Check the ARN and try your request again. 958// 959// * ErrCodeInternalServerException "InternalServerException" 960// An internal server error occurred. Retry your request. 961// 962// See also, https://docs.aws.amazon.com/goto/WebAPI/comprehendmedical-2018-10-30/StopEntitiesDetectionV2Job 963func (c *ComprehendMedical) StopEntitiesDetectionV2Job(input *StopEntitiesDetectionV2JobInput) (*StopEntitiesDetectionV2JobOutput, error) { 964 req, out := c.StopEntitiesDetectionV2JobRequest(input) 965 return out, req.Send() 966} 967 968// StopEntitiesDetectionV2JobWithContext is the same as StopEntitiesDetectionV2Job with the addition of 969// the ability to pass a context and additional request options. 970// 971// See StopEntitiesDetectionV2Job for details on how to use this API operation. 972// 973// The context must be non-nil and will be used for request cancellation. If 974// the context is nil a panic will occur. In the future the SDK may create 975// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 976// for more information on using Contexts. 977func (c *ComprehendMedical) StopEntitiesDetectionV2JobWithContext(ctx aws.Context, input *StopEntitiesDetectionV2JobInput, opts ...request.Option) (*StopEntitiesDetectionV2JobOutput, error) { 978 req, out := c.StopEntitiesDetectionV2JobRequest(input) 979 req.SetContext(ctx) 980 req.ApplyOptions(opts...) 981 return out, req.Send() 982} 983 984const opStopPHIDetectionJob = "StopPHIDetectionJob" 985 986// StopPHIDetectionJobRequest generates a "aws/request.Request" representing the 987// client's request for the StopPHIDetectionJob operation. The "output" return 988// value will be populated with the request's response once the request completes 989// successfully. 990// 991// Use "Send" method on the returned Request to send the API call to the service. 992// the "output" return value is not valid until after Send returns without error. 993// 994// See StopPHIDetectionJob for more information on using the StopPHIDetectionJob 995// API call, and error handling. 996// 997// This method is useful when you want to inject custom logic or configuration 998// into the SDK's request lifecycle. Such as custom headers, or retry logic. 999// 1000// 1001// // Example sending a request using the StopPHIDetectionJobRequest method. 1002// req, resp := client.StopPHIDetectionJobRequest(params) 1003// 1004// err := req.Send() 1005// if err == nil { // resp is now filled 1006// fmt.Println(resp) 1007// } 1008// 1009// See also, https://docs.aws.amazon.com/goto/WebAPI/comprehendmedical-2018-10-30/StopPHIDetectionJob 1010func (c *ComprehendMedical) StopPHIDetectionJobRequest(input *StopPHIDetectionJobInput) (req *request.Request, output *StopPHIDetectionJobOutput) { 1011 op := &request.Operation{ 1012 Name: opStopPHIDetectionJob, 1013 HTTPMethod: "POST", 1014 HTTPPath: "/", 1015 } 1016 1017 if input == nil { 1018 input = &StopPHIDetectionJobInput{} 1019 } 1020 1021 output = &StopPHIDetectionJobOutput{} 1022 req = c.newRequest(op, input, output) 1023 return 1024} 1025 1026// StopPHIDetectionJob API operation for AWS Comprehend Medical. 1027// 1028// Stops a protected health information (PHI) detection job in progress. 1029// 1030// Returns awserr.Error for service API and SDK errors. Use runtime type assertions 1031// with awserr.Error's Code and Message methods to get detailed information about 1032// the error. 1033// 1034// See the AWS API reference guide for AWS Comprehend Medical's 1035// API operation StopPHIDetectionJob for usage and error information. 1036// 1037// Returned Error Codes: 1038// * ErrCodeInvalidRequestException "InvalidRequestException" 1039// The request that you made is invalid. Check your request to determine why 1040// it's invalid and then retry the request. 1041// 1042// * ErrCodeResourceNotFoundException "ResourceNotFoundException" 1043// The resource identified by the specified Amazon Resource Name (ARN) was not 1044// found. Check the ARN and try your request again. 1045// 1046// * ErrCodeInternalServerException "InternalServerException" 1047// An internal server error occurred. Retry your request. 1048// 1049// See also, https://docs.aws.amazon.com/goto/WebAPI/comprehendmedical-2018-10-30/StopPHIDetectionJob 1050func (c *ComprehendMedical) StopPHIDetectionJob(input *StopPHIDetectionJobInput) (*StopPHIDetectionJobOutput, error) { 1051 req, out := c.StopPHIDetectionJobRequest(input) 1052 return out, req.Send() 1053} 1054 1055// StopPHIDetectionJobWithContext is the same as StopPHIDetectionJob with the addition of 1056// the ability to pass a context and additional request options. 1057// 1058// See StopPHIDetectionJob for details on how to use this API operation. 1059// 1060// The context must be non-nil and will be used for request cancellation. If 1061// the context is nil a panic will occur. In the future the SDK may create 1062// sub-contexts for http.Requests. See https://golang.org/pkg/context/ 1063// for more information on using Contexts. 1064func (c *ComprehendMedical) StopPHIDetectionJobWithContext(ctx aws.Context, input *StopPHIDetectionJobInput, opts ...request.Option) (*StopPHIDetectionJobOutput, error) { 1065 req, out := c.StopPHIDetectionJobRequest(input) 1066 req.SetContext(ctx) 1067 req.ApplyOptions(opts...) 1068 return out, req.Send() 1069} 1070 1071// An extracted segment of the text that is an attribute of an entity, or otherwise 1072// related to an entity, such as the dosage of a medication taken. It contains 1073// information about the attribute such as id, begin and end offset within the 1074// input text, and the segment of the input text. 1075type Attribute struct { 1076 _ struct{} `type:"structure"` 1077 1078 // The 0-based character offset in the input text that shows where the attribute 1079 // begins. The offset returns the UTF-8 code point in the string. 1080 BeginOffset *int64 `type:"integer"` 1081 1082 // The 0-based character offset in the input text that shows where the attribute 1083 // ends. The offset returns the UTF-8 code point in the string. 1084 EndOffset *int64 `type:"integer"` 1085 1086 // The numeric identifier for this attribute. This is a monotonically increasing 1087 // id unique within this response rather than a global unique identifier. 1088 Id *int64 `type:"integer"` 1089 1090 // The level of confidence that Amazon Comprehend Medical has that this attribute 1091 // is correctly related to this entity. 1092 RelationshipScore *float64 `type:"float"` 1093 1094 // The level of confidence that Amazon Comprehend Medical has that the segment 1095 // of text is correctly recognized as an attribute. 1096 Score *float64 `type:"float"` 1097 1098 // The segment of input text extracted as this attribute. 1099 Text *string `min:"1" type:"string"` 1100 1101 // Contextual information for this attribute. 1102 Traits []*Trait `type:"list"` 1103 1104 // The type of attribute. 1105 Type *string `type:"string" enum:"EntitySubType"` 1106} 1107 1108// String returns the string representation 1109func (s Attribute) String() string { 1110 return awsutil.Prettify(s) 1111} 1112 1113// GoString returns the string representation 1114func (s Attribute) GoString() string { 1115 return s.String() 1116} 1117 1118// SetBeginOffset sets the BeginOffset field's value. 1119func (s *Attribute) SetBeginOffset(v int64) *Attribute { 1120 s.BeginOffset = &v 1121 return s 1122} 1123 1124// SetEndOffset sets the EndOffset field's value. 1125func (s *Attribute) SetEndOffset(v int64) *Attribute { 1126 s.EndOffset = &v 1127 return s 1128} 1129 1130// SetId sets the Id field's value. 1131func (s *Attribute) SetId(v int64) *Attribute { 1132 s.Id = &v 1133 return s 1134} 1135 1136// SetRelationshipScore sets the RelationshipScore field's value. 1137func (s *Attribute) SetRelationshipScore(v float64) *Attribute { 1138 s.RelationshipScore = &v 1139 return s 1140} 1141 1142// SetScore sets the Score field's value. 1143func (s *Attribute) SetScore(v float64) *Attribute { 1144 s.Score = &v 1145 return s 1146} 1147 1148// SetText sets the Text field's value. 1149func (s *Attribute) SetText(v string) *Attribute { 1150 s.Text = &v 1151 return s 1152} 1153 1154// SetTraits sets the Traits field's value. 1155func (s *Attribute) SetTraits(v []*Trait) *Attribute { 1156 s.Traits = v 1157 return s 1158} 1159 1160// SetType sets the Type field's value. 1161func (s *Attribute) SetType(v string) *Attribute { 1162 s.Type = &v 1163 return s 1164} 1165 1166// Provides information for filtering a list of detection jobs. 1167type ComprehendMedicalAsyncJobFilter struct { 1168 _ struct{} `type:"structure"` 1169 1170 // Filters on the name of the job. 1171 JobName *string `min:"1" type:"string"` 1172 1173 // Filters the list of jobs based on job status. Returns only jobs with the 1174 // specified status. 1175 JobStatus *string `type:"string" enum:"JobStatus"` 1176 1177 // Filters the list of jobs based on the time that the job was submitted for 1178 // processing. Returns only jobs submitted after the specified time. Jobs are 1179 // returned in descending order, newest to oldest. 1180 SubmitTimeAfter *time.Time `type:"timestamp"` 1181 1182 // Filters the list of jobs based on the time that the job was submitted for 1183 // processing. Returns only jobs submitted before the specified time. Jobs are 1184 // returned in ascending order, oldest to newest. 1185 SubmitTimeBefore *time.Time `type:"timestamp"` 1186} 1187 1188// String returns the string representation 1189func (s ComprehendMedicalAsyncJobFilter) String() string { 1190 return awsutil.Prettify(s) 1191} 1192 1193// GoString returns the string representation 1194func (s ComprehendMedicalAsyncJobFilter) GoString() string { 1195 return s.String() 1196} 1197 1198// Validate inspects the fields of the type to determine if they are valid. 1199func (s *ComprehendMedicalAsyncJobFilter) Validate() error { 1200 invalidParams := request.ErrInvalidParams{Context: "ComprehendMedicalAsyncJobFilter"} 1201 if s.JobName != nil && len(*s.JobName) < 1 { 1202 invalidParams.Add(request.NewErrParamMinLen("JobName", 1)) 1203 } 1204 1205 if invalidParams.Len() > 0 { 1206 return invalidParams 1207 } 1208 return nil 1209} 1210 1211// SetJobName sets the JobName field's value. 1212func (s *ComprehendMedicalAsyncJobFilter) SetJobName(v string) *ComprehendMedicalAsyncJobFilter { 1213 s.JobName = &v 1214 return s 1215} 1216 1217// SetJobStatus sets the JobStatus field's value. 1218func (s *ComprehendMedicalAsyncJobFilter) SetJobStatus(v string) *ComprehendMedicalAsyncJobFilter { 1219 s.JobStatus = &v 1220 return s 1221} 1222 1223// SetSubmitTimeAfter sets the SubmitTimeAfter field's value. 1224func (s *ComprehendMedicalAsyncJobFilter) SetSubmitTimeAfter(v time.Time) *ComprehendMedicalAsyncJobFilter { 1225 s.SubmitTimeAfter = &v 1226 return s 1227} 1228 1229// SetSubmitTimeBefore sets the SubmitTimeBefore field's value. 1230func (s *ComprehendMedicalAsyncJobFilter) SetSubmitTimeBefore(v time.Time) *ComprehendMedicalAsyncJobFilter { 1231 s.SubmitTimeBefore = &v 1232 return s 1233} 1234 1235// Provides information about a detection job. 1236type ComprehendMedicalAsyncJobProperties struct { 1237 _ struct{} `type:"structure"` 1238 1239 // The Amazon Resource Name (ARN) that gives Amazon Comprehend Medical read 1240 // access to your input data. 1241 DataAccessRoleArn *string `min:"20" type:"string"` 1242 1243 // The time that the detection job completed. 1244 EndTime *time.Time `type:"timestamp"` 1245 1246 // The date and time that job metadata is deleted from the server. Output files 1247 // in your S3 bucket will not be deleted. After the metadata is deleted, the 1248 // job will no longer appear in the results of the ListEntitiesDetectionV2Job 1249 // or the ListPHIDetectionJobs operation. 1250 ExpirationTime *time.Time `type:"timestamp"` 1251 1252 // The input data configuration that you supplied when you created the detection 1253 // job. 1254 InputDataConfig *InputDataConfig `type:"structure"` 1255 1256 // The identifier assigned to the detection job. 1257 JobId *string `min:"1" type:"string"` 1258 1259 // The name that you assigned to the detection job. 1260 JobName *string `min:"1" type:"string"` 1261 1262 // The current status of the detection job. If the status is FAILED, the Message 1263 // field shows the reason for the failure. 1264 JobStatus *string `type:"string" enum:"JobStatus"` 1265 1266 // The AWS Key Management Service key, if any, used to encrypt the output files. 1267 KMSKey *string `min:"1" type:"string"` 1268 1269 // The language code of the input documents. 1270 LanguageCode *string `type:"string" enum:"LanguageCode"` 1271 1272 // The path to the file that describes the results of a batch job. 1273 ManifestFilePath *string `min:"1" type:"string"` 1274 1275 // A description of the status of a job. 1276 Message *string `type:"string"` 1277 1278 // The version of the model used to analyze the documents. The version number 1279 // looks like X.X.X. You can use this information to track the model used for 1280 // a particular batch of documents. 1281 ModelVersion *string `type:"string"` 1282 1283 // The output data configuration that you supplied when you created the detection 1284 // job. 1285 OutputDataConfig *OutputDataConfig `type:"structure"` 1286 1287 // The time that the detection job was submitted for processing. 1288 SubmitTime *time.Time `type:"timestamp"` 1289} 1290 1291// String returns the string representation 1292func (s ComprehendMedicalAsyncJobProperties) String() string { 1293 return awsutil.Prettify(s) 1294} 1295 1296// GoString returns the string representation 1297func (s ComprehendMedicalAsyncJobProperties) GoString() string { 1298 return s.String() 1299} 1300 1301// SetDataAccessRoleArn sets the DataAccessRoleArn field's value. 1302func (s *ComprehendMedicalAsyncJobProperties) SetDataAccessRoleArn(v string) *ComprehendMedicalAsyncJobProperties { 1303 s.DataAccessRoleArn = &v 1304 return s 1305} 1306 1307// SetEndTime sets the EndTime field's value. 1308func (s *ComprehendMedicalAsyncJobProperties) SetEndTime(v time.Time) *ComprehendMedicalAsyncJobProperties { 1309 s.EndTime = &v 1310 return s 1311} 1312 1313// SetExpirationTime sets the ExpirationTime field's value. 1314func (s *ComprehendMedicalAsyncJobProperties) SetExpirationTime(v time.Time) *ComprehendMedicalAsyncJobProperties { 1315 s.ExpirationTime = &v 1316 return s 1317} 1318 1319// SetInputDataConfig sets the InputDataConfig field's value. 1320func (s *ComprehendMedicalAsyncJobProperties) SetInputDataConfig(v *InputDataConfig) *ComprehendMedicalAsyncJobProperties { 1321 s.InputDataConfig = v 1322 return s 1323} 1324 1325// SetJobId sets the JobId field's value. 1326func (s *ComprehendMedicalAsyncJobProperties) SetJobId(v string) *ComprehendMedicalAsyncJobProperties { 1327 s.JobId = &v 1328 return s 1329} 1330 1331// SetJobName sets the JobName field's value. 1332func (s *ComprehendMedicalAsyncJobProperties) SetJobName(v string) *ComprehendMedicalAsyncJobProperties { 1333 s.JobName = &v 1334 return s 1335} 1336 1337// SetJobStatus sets the JobStatus field's value. 1338func (s *ComprehendMedicalAsyncJobProperties) SetJobStatus(v string) *ComprehendMedicalAsyncJobProperties { 1339 s.JobStatus = &v 1340 return s 1341} 1342 1343// SetKMSKey sets the KMSKey field's value. 1344func (s *ComprehendMedicalAsyncJobProperties) SetKMSKey(v string) *ComprehendMedicalAsyncJobProperties { 1345 s.KMSKey = &v 1346 return s 1347} 1348 1349// SetLanguageCode sets the LanguageCode field's value. 1350func (s *ComprehendMedicalAsyncJobProperties) SetLanguageCode(v string) *ComprehendMedicalAsyncJobProperties { 1351 s.LanguageCode = &v 1352 return s 1353} 1354 1355// SetManifestFilePath sets the ManifestFilePath field's value. 1356func (s *ComprehendMedicalAsyncJobProperties) SetManifestFilePath(v string) *ComprehendMedicalAsyncJobProperties { 1357 s.ManifestFilePath = &v 1358 return s 1359} 1360 1361// SetMessage sets the Message field's value. 1362func (s *ComprehendMedicalAsyncJobProperties) SetMessage(v string) *ComprehendMedicalAsyncJobProperties { 1363 s.Message = &v 1364 return s 1365} 1366 1367// SetModelVersion sets the ModelVersion field's value. 1368func (s *ComprehendMedicalAsyncJobProperties) SetModelVersion(v string) *ComprehendMedicalAsyncJobProperties { 1369 s.ModelVersion = &v 1370 return s 1371} 1372 1373// SetOutputDataConfig sets the OutputDataConfig field's value. 1374func (s *ComprehendMedicalAsyncJobProperties) SetOutputDataConfig(v *OutputDataConfig) *ComprehendMedicalAsyncJobProperties { 1375 s.OutputDataConfig = v 1376 return s 1377} 1378 1379// SetSubmitTime sets the SubmitTime field's value. 1380func (s *ComprehendMedicalAsyncJobProperties) SetSubmitTime(v time.Time) *ComprehendMedicalAsyncJobProperties { 1381 s.SubmitTime = &v 1382 return s 1383} 1384 1385type DescribeEntitiesDetectionV2JobInput struct { 1386 _ struct{} `type:"structure"` 1387 1388 // The identifier that Amazon Comprehend Medical generated for the job. The 1389 // StartEntitiesDetectionV2Job operation returns this identifier in its response. 1390 // 1391 // JobId is a required field 1392 JobId *string `min:"1" type:"string" required:"true"` 1393} 1394 1395// String returns the string representation 1396func (s DescribeEntitiesDetectionV2JobInput) String() string { 1397 return awsutil.Prettify(s) 1398} 1399 1400// GoString returns the string representation 1401func (s DescribeEntitiesDetectionV2JobInput) GoString() string { 1402 return s.String() 1403} 1404 1405// Validate inspects the fields of the type to determine if they are valid. 1406func (s *DescribeEntitiesDetectionV2JobInput) Validate() error { 1407 invalidParams := request.ErrInvalidParams{Context: "DescribeEntitiesDetectionV2JobInput"} 1408 if s.JobId == nil { 1409 invalidParams.Add(request.NewErrParamRequired("JobId")) 1410 } 1411 if s.JobId != nil && len(*s.JobId) < 1 { 1412 invalidParams.Add(request.NewErrParamMinLen("JobId", 1)) 1413 } 1414 1415 if invalidParams.Len() > 0 { 1416 return invalidParams 1417 } 1418 return nil 1419} 1420 1421// SetJobId sets the JobId field's value. 1422func (s *DescribeEntitiesDetectionV2JobInput) SetJobId(v string) *DescribeEntitiesDetectionV2JobInput { 1423 s.JobId = &v 1424 return s 1425} 1426 1427type DescribeEntitiesDetectionV2JobOutput struct { 1428 _ struct{} `type:"structure"` 1429 1430 // An object that contains the properties associated with a detection job. 1431 ComprehendMedicalAsyncJobProperties *ComprehendMedicalAsyncJobProperties `type:"structure"` 1432} 1433 1434// String returns the string representation 1435func (s DescribeEntitiesDetectionV2JobOutput) String() string { 1436 return awsutil.Prettify(s) 1437} 1438 1439// GoString returns the string representation 1440func (s DescribeEntitiesDetectionV2JobOutput) GoString() string { 1441 return s.String() 1442} 1443 1444// SetComprehendMedicalAsyncJobProperties sets the ComprehendMedicalAsyncJobProperties field's value. 1445func (s *DescribeEntitiesDetectionV2JobOutput) SetComprehendMedicalAsyncJobProperties(v *ComprehendMedicalAsyncJobProperties) *DescribeEntitiesDetectionV2JobOutput { 1446 s.ComprehendMedicalAsyncJobProperties = v 1447 return s 1448} 1449 1450type DescribePHIDetectionJobInput struct { 1451 _ struct{} `type:"structure"` 1452 1453 // The identifier that Amazon Comprehend Medical generated for the job. The 1454 // StartPHIDetectionJob operation returns this identifier in its response. 1455 // 1456 // JobId is a required field 1457 JobId *string `min:"1" type:"string" required:"true"` 1458} 1459 1460// String returns the string representation 1461func (s DescribePHIDetectionJobInput) String() string { 1462 return awsutil.Prettify(s) 1463} 1464 1465// GoString returns the string representation 1466func (s DescribePHIDetectionJobInput) GoString() string { 1467 return s.String() 1468} 1469 1470// Validate inspects the fields of the type to determine if they are valid. 1471func (s *DescribePHIDetectionJobInput) Validate() error { 1472 invalidParams := request.ErrInvalidParams{Context: "DescribePHIDetectionJobInput"} 1473 if s.JobId == nil { 1474 invalidParams.Add(request.NewErrParamRequired("JobId")) 1475 } 1476 if s.JobId != nil && len(*s.JobId) < 1 { 1477 invalidParams.Add(request.NewErrParamMinLen("JobId", 1)) 1478 } 1479 1480 if invalidParams.Len() > 0 { 1481 return invalidParams 1482 } 1483 return nil 1484} 1485 1486// SetJobId sets the JobId field's value. 1487func (s *DescribePHIDetectionJobInput) SetJobId(v string) *DescribePHIDetectionJobInput { 1488 s.JobId = &v 1489 return s 1490} 1491 1492type DescribePHIDetectionJobOutput struct { 1493 _ struct{} `type:"structure"` 1494 1495 // An object that contains the properties associated with a detection job. 1496 ComprehendMedicalAsyncJobProperties *ComprehendMedicalAsyncJobProperties `type:"structure"` 1497} 1498 1499// String returns the string representation 1500func (s DescribePHIDetectionJobOutput) String() string { 1501 return awsutil.Prettify(s) 1502} 1503 1504// GoString returns the string representation 1505func (s DescribePHIDetectionJobOutput) GoString() string { 1506 return s.String() 1507} 1508 1509// SetComprehendMedicalAsyncJobProperties sets the ComprehendMedicalAsyncJobProperties field's value. 1510func (s *DescribePHIDetectionJobOutput) SetComprehendMedicalAsyncJobProperties(v *ComprehendMedicalAsyncJobProperties) *DescribePHIDetectionJobOutput { 1511 s.ComprehendMedicalAsyncJobProperties = v 1512 return s 1513} 1514 1515type DetectEntitiesInput struct { 1516 _ struct{} `type:"structure"` 1517 1518 // A UTF-8 text string containing the clinical content being examined for entities. 1519 // Each string must contain fewer than 20,000 bytes of characters. 1520 // 1521 // Text is a required field 1522 Text *string `min:"1" type:"string" required:"true"` 1523} 1524 1525// String returns the string representation 1526func (s DetectEntitiesInput) String() string { 1527 return awsutil.Prettify(s) 1528} 1529 1530// GoString returns the string representation 1531func (s DetectEntitiesInput) GoString() string { 1532 return s.String() 1533} 1534 1535// Validate inspects the fields of the type to determine if they are valid. 1536func (s *DetectEntitiesInput) Validate() error { 1537 invalidParams := request.ErrInvalidParams{Context: "DetectEntitiesInput"} 1538 if s.Text == nil { 1539 invalidParams.Add(request.NewErrParamRequired("Text")) 1540 } 1541 if s.Text != nil && len(*s.Text) < 1 { 1542 invalidParams.Add(request.NewErrParamMinLen("Text", 1)) 1543 } 1544 1545 if invalidParams.Len() > 0 { 1546 return invalidParams 1547 } 1548 return nil 1549} 1550 1551// SetText sets the Text field's value. 1552func (s *DetectEntitiesInput) SetText(v string) *DetectEntitiesInput { 1553 s.Text = &v 1554 return s 1555} 1556 1557type DetectEntitiesOutput struct { 1558 _ struct{} `type:"structure"` 1559 1560 // The collection of medical entities extracted from the input text and their 1561 // associated information. For each entity, the response provides the entity 1562 // text, the entity category, where the entity text begins and ends, and the 1563 // level of confidence that Amazon Comprehend Medical has in the detection and 1564 // analysis. Attributes and traits of the entity are also returned. 1565 // 1566 // Entities is a required field 1567 Entities []*Entity `type:"list" required:"true"` 1568 1569 // The version of the model used to analyze the documents. The version number 1570 // looks like X.X.X. You can use this information to track the model used for 1571 // a particular batch of documents. 1572 // 1573 // ModelVersion is a required field 1574 ModelVersion *string `min:"1" type:"string" required:"true"` 1575 1576 // If the result of the previous request to DetectEntities was truncated, include 1577 // the PaginationToken to fetch the next page of entities. 1578 PaginationToken *string `min:"1" type:"string"` 1579 1580 // Attributes extracted from the input text that we were unable to relate to 1581 // an entity. 1582 UnmappedAttributes []*UnmappedAttribute `type:"list"` 1583} 1584 1585// String returns the string representation 1586func (s DetectEntitiesOutput) String() string { 1587 return awsutil.Prettify(s) 1588} 1589 1590// GoString returns the string representation 1591func (s DetectEntitiesOutput) GoString() string { 1592 return s.String() 1593} 1594 1595// SetEntities sets the Entities field's value. 1596func (s *DetectEntitiesOutput) SetEntities(v []*Entity) *DetectEntitiesOutput { 1597 s.Entities = v 1598 return s 1599} 1600 1601// SetModelVersion sets the ModelVersion field's value. 1602func (s *DetectEntitiesOutput) SetModelVersion(v string) *DetectEntitiesOutput { 1603 s.ModelVersion = &v 1604 return s 1605} 1606 1607// SetPaginationToken sets the PaginationToken field's value. 1608func (s *DetectEntitiesOutput) SetPaginationToken(v string) *DetectEntitiesOutput { 1609 s.PaginationToken = &v 1610 return s 1611} 1612 1613// SetUnmappedAttributes sets the UnmappedAttributes field's value. 1614func (s *DetectEntitiesOutput) SetUnmappedAttributes(v []*UnmappedAttribute) *DetectEntitiesOutput { 1615 s.UnmappedAttributes = v 1616 return s 1617} 1618 1619type DetectEntitiesV2Input struct { 1620 _ struct{} `type:"structure"` 1621 1622 // A UTF-8 string containing the clinical content being examined for entities. 1623 // Each string must contain fewer than 20,000 bytes of characters. 1624 // 1625 // Text is a required field 1626 Text *string `min:"1" type:"string" required:"true"` 1627} 1628 1629// String returns the string representation 1630func (s DetectEntitiesV2Input) String() string { 1631 return awsutil.Prettify(s) 1632} 1633 1634// GoString returns the string representation 1635func (s DetectEntitiesV2Input) GoString() string { 1636 return s.String() 1637} 1638 1639// Validate inspects the fields of the type to determine if they are valid. 1640func (s *DetectEntitiesV2Input) Validate() error { 1641 invalidParams := request.ErrInvalidParams{Context: "DetectEntitiesV2Input"} 1642 if s.Text == nil { 1643 invalidParams.Add(request.NewErrParamRequired("Text")) 1644 } 1645 if s.Text != nil && len(*s.Text) < 1 { 1646 invalidParams.Add(request.NewErrParamMinLen("Text", 1)) 1647 } 1648 1649 if invalidParams.Len() > 0 { 1650 return invalidParams 1651 } 1652 return nil 1653} 1654 1655// SetText sets the Text field's value. 1656func (s *DetectEntitiesV2Input) SetText(v string) *DetectEntitiesV2Input { 1657 s.Text = &v 1658 return s 1659} 1660 1661type DetectEntitiesV2Output struct { 1662 _ struct{} `type:"structure"` 1663 1664 // The collection of medical entities extracted from the input text and their 1665 // associated information. For each entity, the response provides the entity 1666 // text, the entity category, where the entity text begins and ends, and the 1667 // level of confidence in the detection and analysis. Attributes and traits 1668 // of the entity are also returned. 1669 // 1670 // Entities is a required field 1671 Entities []*Entity `type:"list" required:"true"` 1672 1673 // The version of the model used to analyze the documents. The version number 1674 // looks like X.X.X. You can use this information to track the model used for 1675 // a particular batch of documents. 1676 // 1677 // ModelVersion is a required field 1678 ModelVersion *string `min:"1" type:"string" required:"true"` 1679 1680 // If the result to the DetectEntitiesV2 operation was truncated, include the 1681 // PaginationToken to fetch the next page of entities. 1682 PaginationToken *string `min:"1" type:"string"` 1683 1684 // Attributes extracted from the input text that couldn't be related to an entity. 1685 UnmappedAttributes []*UnmappedAttribute `type:"list"` 1686} 1687 1688// String returns the string representation 1689func (s DetectEntitiesV2Output) String() string { 1690 return awsutil.Prettify(s) 1691} 1692 1693// GoString returns the string representation 1694func (s DetectEntitiesV2Output) GoString() string { 1695 return s.String() 1696} 1697 1698// SetEntities sets the Entities field's value. 1699func (s *DetectEntitiesV2Output) SetEntities(v []*Entity) *DetectEntitiesV2Output { 1700 s.Entities = v 1701 return s 1702} 1703 1704// SetModelVersion sets the ModelVersion field's value. 1705func (s *DetectEntitiesV2Output) SetModelVersion(v string) *DetectEntitiesV2Output { 1706 s.ModelVersion = &v 1707 return s 1708} 1709 1710// SetPaginationToken sets the PaginationToken field's value. 1711func (s *DetectEntitiesV2Output) SetPaginationToken(v string) *DetectEntitiesV2Output { 1712 s.PaginationToken = &v 1713 return s 1714} 1715 1716// SetUnmappedAttributes sets the UnmappedAttributes field's value. 1717func (s *DetectEntitiesV2Output) SetUnmappedAttributes(v []*UnmappedAttribute) *DetectEntitiesV2Output { 1718 s.UnmappedAttributes = v 1719 return s 1720} 1721 1722type DetectPHIInput struct { 1723 _ struct{} `type:"structure"` 1724 1725 // A UTF-8 text string containing the clinical content being examined for PHI 1726 // entities. Each string must contain fewer than 20,000 bytes of characters. 1727 // 1728 // Text is a required field 1729 Text *string `min:"1" type:"string" required:"true"` 1730} 1731 1732// String returns the string representation 1733func (s DetectPHIInput) String() string { 1734 return awsutil.Prettify(s) 1735} 1736 1737// GoString returns the string representation 1738func (s DetectPHIInput) GoString() string { 1739 return s.String() 1740} 1741 1742// Validate inspects the fields of the type to determine if they are valid. 1743func (s *DetectPHIInput) Validate() error { 1744 invalidParams := request.ErrInvalidParams{Context: "DetectPHIInput"} 1745 if s.Text == nil { 1746 invalidParams.Add(request.NewErrParamRequired("Text")) 1747 } 1748 if s.Text != nil && len(*s.Text) < 1 { 1749 invalidParams.Add(request.NewErrParamMinLen("Text", 1)) 1750 } 1751 1752 if invalidParams.Len() > 0 { 1753 return invalidParams 1754 } 1755 return nil 1756} 1757 1758// SetText sets the Text field's value. 1759func (s *DetectPHIInput) SetText(v string) *DetectPHIInput { 1760 s.Text = &v 1761 return s 1762} 1763 1764type DetectPHIOutput struct { 1765 _ struct{} `type:"structure"` 1766 1767 // The collection of PHI entities extracted from the input text and their associated 1768 // information. For each entity, the response provides the entity text, the 1769 // entity category, where the entity text begins and ends, and the level of 1770 // confidence that Amazon Comprehend Medical has in its detection. 1771 // 1772 // Entities is a required field 1773 Entities []*Entity `type:"list" required:"true"` 1774 1775 // The version of the model used to analyze the documents. The version number 1776 // looks like X.X.X. You can use this information to track the model used for 1777 // a particular batch of documents. 1778 // 1779 // ModelVersion is a required field 1780 ModelVersion *string `min:"1" type:"string" required:"true"` 1781 1782 // If the result of the previous request to DetectPHI was truncated, include 1783 // the PaginationToken to fetch the next page of PHI entities. 1784 PaginationToken *string `min:"1" type:"string"` 1785} 1786 1787// String returns the string representation 1788func (s DetectPHIOutput) String() string { 1789 return awsutil.Prettify(s) 1790} 1791 1792// GoString returns the string representation 1793func (s DetectPHIOutput) GoString() string { 1794 return s.String() 1795} 1796 1797// SetEntities sets the Entities field's value. 1798func (s *DetectPHIOutput) SetEntities(v []*Entity) *DetectPHIOutput { 1799 s.Entities = v 1800 return s 1801} 1802 1803// SetModelVersion sets the ModelVersion field's value. 1804func (s *DetectPHIOutput) SetModelVersion(v string) *DetectPHIOutput { 1805 s.ModelVersion = &v 1806 return s 1807} 1808 1809// SetPaginationToken sets the PaginationToken field's value. 1810func (s *DetectPHIOutput) SetPaginationToken(v string) *DetectPHIOutput { 1811 s.PaginationToken = &v 1812 return s 1813} 1814 1815// Provides information about an extracted medical entity. 1816type Entity struct { 1817 _ struct{} `type:"structure"` 1818 1819 // The extracted attributes that relate to this entity. 1820 Attributes []*Attribute `type:"list"` 1821 1822 // The 0-based character offset in the input text that shows where the entity 1823 // begins. The offset returns the UTF-8 code point in the string. 1824 BeginOffset *int64 `type:"integer"` 1825 1826 // The category of the entity. 1827 Category *string `type:"string" enum:"EntityType"` 1828 1829 // The 0-based character offset in the input text that shows where the entity 1830 // ends. The offset returns the UTF-8 code point in the string. 1831 EndOffset *int64 `type:"integer"` 1832 1833 // The numeric identifier for the entity. This is a monotonically increasing 1834 // id unique within this response rather than a global unique identifier. 1835 Id *int64 `type:"integer"` 1836 1837 // The level of confidence that Amazon Comprehend Medical has in the accuracy 1838 // of the detection. 1839 Score *float64 `type:"float"` 1840 1841 // The segment of input text extracted as this entity. 1842 Text *string `min:"1" type:"string"` 1843 1844 // Contextual information for the entity 1845 Traits []*Trait `type:"list"` 1846 1847 // Describes the specific type of entity with category of entities. 1848 Type *string `type:"string" enum:"EntitySubType"` 1849} 1850 1851// String returns the string representation 1852func (s Entity) String() string { 1853 return awsutil.Prettify(s) 1854} 1855 1856// GoString returns the string representation 1857func (s Entity) GoString() string { 1858 return s.String() 1859} 1860 1861// SetAttributes sets the Attributes field's value. 1862func (s *Entity) SetAttributes(v []*Attribute) *Entity { 1863 s.Attributes = v 1864 return s 1865} 1866 1867// SetBeginOffset sets the BeginOffset field's value. 1868func (s *Entity) SetBeginOffset(v int64) *Entity { 1869 s.BeginOffset = &v 1870 return s 1871} 1872 1873// SetCategory sets the Category field's value. 1874func (s *Entity) SetCategory(v string) *Entity { 1875 s.Category = &v 1876 return s 1877} 1878 1879// SetEndOffset sets the EndOffset field's value. 1880func (s *Entity) SetEndOffset(v int64) *Entity { 1881 s.EndOffset = &v 1882 return s 1883} 1884 1885// SetId sets the Id field's value. 1886func (s *Entity) SetId(v int64) *Entity { 1887 s.Id = &v 1888 return s 1889} 1890 1891// SetScore sets the Score field's value. 1892func (s *Entity) SetScore(v float64) *Entity { 1893 s.Score = &v 1894 return s 1895} 1896 1897// SetText sets the Text field's value. 1898func (s *Entity) SetText(v string) *Entity { 1899 s.Text = &v 1900 return s 1901} 1902 1903// SetTraits sets the Traits field's value. 1904func (s *Entity) SetTraits(v []*Trait) *Entity { 1905 s.Traits = v 1906 return s 1907} 1908 1909// SetType sets the Type field's value. 1910func (s *Entity) SetType(v string) *Entity { 1911 s.Type = &v 1912 return s 1913} 1914 1915// The input properties for an entities detection job 1916type InputDataConfig struct { 1917 _ struct{} `type:"structure"` 1918 1919 // The URI of the S3 bucket that contains the input data. The bucket must be 1920 // in the same region as the API endpoint that you are calling. 1921 // 1922 // Each file in the document collection must be less than 40 KB. You can store 1923 // a maximum of 30 GB in the bucket. 1924 // 1925 // S3Bucket is a required field 1926 S3Bucket *string `min:"3" type:"string" required:"true"` 1927 1928 // The path to the input data files in the S3 bucket. 1929 S3Key *string `type:"string"` 1930} 1931 1932// String returns the string representation 1933func (s InputDataConfig) String() string { 1934 return awsutil.Prettify(s) 1935} 1936 1937// GoString returns the string representation 1938func (s InputDataConfig) GoString() string { 1939 return s.String() 1940} 1941 1942// Validate inspects the fields of the type to determine if they are valid. 1943func (s *InputDataConfig) Validate() error { 1944 invalidParams := request.ErrInvalidParams{Context: "InputDataConfig"} 1945 if s.S3Bucket == nil { 1946 invalidParams.Add(request.NewErrParamRequired("S3Bucket")) 1947 } 1948 if s.S3Bucket != nil && len(*s.S3Bucket) < 3 { 1949 invalidParams.Add(request.NewErrParamMinLen("S3Bucket", 3)) 1950 } 1951 1952 if invalidParams.Len() > 0 { 1953 return invalidParams 1954 } 1955 return nil 1956} 1957 1958// SetS3Bucket sets the S3Bucket field's value. 1959func (s *InputDataConfig) SetS3Bucket(v string) *InputDataConfig { 1960 s.S3Bucket = &v 1961 return s 1962} 1963 1964// SetS3Key sets the S3Key field's value. 1965func (s *InputDataConfig) SetS3Key(v string) *InputDataConfig { 1966 s.S3Key = &v 1967 return s 1968} 1969 1970type ListEntitiesDetectionV2JobsInput struct { 1971 _ struct{} `type:"structure"` 1972 1973 // Filters the jobs that are returned. You can filter jobs based on their names, 1974 // status, or the date and time that they were submitted. You can only set one 1975 // filter at a time. 1976 Filter *ComprehendMedicalAsyncJobFilter `type:"structure"` 1977 1978 // The maximum number of results to return in each page. The default is 100. 1979 MaxResults *int64 `min:"1" type:"integer"` 1980 1981 // Identifies the next page of results to return. 1982 NextToken *string `min:"1" type:"string"` 1983} 1984 1985// String returns the string representation 1986func (s ListEntitiesDetectionV2JobsInput) String() string { 1987 return awsutil.Prettify(s) 1988} 1989 1990// GoString returns the string representation 1991func (s ListEntitiesDetectionV2JobsInput) GoString() string { 1992 return s.String() 1993} 1994 1995// Validate inspects the fields of the type to determine if they are valid. 1996func (s *ListEntitiesDetectionV2JobsInput) Validate() error { 1997 invalidParams := request.ErrInvalidParams{Context: "ListEntitiesDetectionV2JobsInput"} 1998 if s.MaxResults != nil && *s.MaxResults < 1 { 1999 invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) 2000 } 2001 if s.NextToken != nil && len(*s.NextToken) < 1 { 2002 invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) 2003 } 2004 if s.Filter != nil { 2005 if err := s.Filter.Validate(); err != nil { 2006 invalidParams.AddNested("Filter", err.(request.ErrInvalidParams)) 2007 } 2008 } 2009 2010 if invalidParams.Len() > 0 { 2011 return invalidParams 2012 } 2013 return nil 2014} 2015 2016// SetFilter sets the Filter field's value. 2017func (s *ListEntitiesDetectionV2JobsInput) SetFilter(v *ComprehendMedicalAsyncJobFilter) *ListEntitiesDetectionV2JobsInput { 2018 s.Filter = v 2019 return s 2020} 2021 2022// SetMaxResults sets the MaxResults field's value. 2023func (s *ListEntitiesDetectionV2JobsInput) SetMaxResults(v int64) *ListEntitiesDetectionV2JobsInput { 2024 s.MaxResults = &v 2025 return s 2026} 2027 2028// SetNextToken sets the NextToken field's value. 2029func (s *ListEntitiesDetectionV2JobsInput) SetNextToken(v string) *ListEntitiesDetectionV2JobsInput { 2030 s.NextToken = &v 2031 return s 2032} 2033 2034type ListEntitiesDetectionV2JobsOutput struct { 2035 _ struct{} `type:"structure"` 2036 2037 // A list containing the properties of each job returned. 2038 ComprehendMedicalAsyncJobPropertiesList []*ComprehendMedicalAsyncJobProperties `type:"list"` 2039 2040 // Identifies the next page of results to return. 2041 NextToken *string `min:"1" type:"string"` 2042} 2043 2044// String returns the string representation 2045func (s ListEntitiesDetectionV2JobsOutput) String() string { 2046 return awsutil.Prettify(s) 2047} 2048 2049// GoString returns the string representation 2050func (s ListEntitiesDetectionV2JobsOutput) GoString() string { 2051 return s.String() 2052} 2053 2054// SetComprehendMedicalAsyncJobPropertiesList sets the ComprehendMedicalAsyncJobPropertiesList field's value. 2055func (s *ListEntitiesDetectionV2JobsOutput) SetComprehendMedicalAsyncJobPropertiesList(v []*ComprehendMedicalAsyncJobProperties) *ListEntitiesDetectionV2JobsOutput { 2056 s.ComprehendMedicalAsyncJobPropertiesList = v 2057 return s 2058} 2059 2060// SetNextToken sets the NextToken field's value. 2061func (s *ListEntitiesDetectionV2JobsOutput) SetNextToken(v string) *ListEntitiesDetectionV2JobsOutput { 2062 s.NextToken = &v 2063 return s 2064} 2065 2066type ListPHIDetectionJobsInput struct { 2067 _ struct{} `type:"structure"` 2068 2069 // Filters the jobs that are returned. You can filter jobs based on their names, 2070 // status, or the date and time that they were submitted. You can only set one 2071 // filter at a time. 2072 Filter *ComprehendMedicalAsyncJobFilter `type:"structure"` 2073 2074 // The maximum number of results to return in each page. The default is 100. 2075 MaxResults *int64 `min:"1" type:"integer"` 2076 2077 // Identifies the next page of results to return. 2078 NextToken *string `min:"1" type:"string"` 2079} 2080 2081// String returns the string representation 2082func (s ListPHIDetectionJobsInput) String() string { 2083 return awsutil.Prettify(s) 2084} 2085 2086// GoString returns the string representation 2087func (s ListPHIDetectionJobsInput) GoString() string { 2088 return s.String() 2089} 2090 2091// Validate inspects the fields of the type to determine if they are valid. 2092func (s *ListPHIDetectionJobsInput) Validate() error { 2093 invalidParams := request.ErrInvalidParams{Context: "ListPHIDetectionJobsInput"} 2094 if s.MaxResults != nil && *s.MaxResults < 1 { 2095 invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) 2096 } 2097 if s.NextToken != nil && len(*s.NextToken) < 1 { 2098 invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) 2099 } 2100 if s.Filter != nil { 2101 if err := s.Filter.Validate(); err != nil { 2102 invalidParams.AddNested("Filter", err.(request.ErrInvalidParams)) 2103 } 2104 } 2105 2106 if invalidParams.Len() > 0 { 2107 return invalidParams 2108 } 2109 return nil 2110} 2111 2112// SetFilter sets the Filter field's value. 2113func (s *ListPHIDetectionJobsInput) SetFilter(v *ComprehendMedicalAsyncJobFilter) *ListPHIDetectionJobsInput { 2114 s.Filter = v 2115 return s 2116} 2117 2118// SetMaxResults sets the MaxResults field's value. 2119func (s *ListPHIDetectionJobsInput) SetMaxResults(v int64) *ListPHIDetectionJobsInput { 2120 s.MaxResults = &v 2121 return s 2122} 2123 2124// SetNextToken sets the NextToken field's value. 2125func (s *ListPHIDetectionJobsInput) SetNextToken(v string) *ListPHIDetectionJobsInput { 2126 s.NextToken = &v 2127 return s 2128} 2129 2130type ListPHIDetectionJobsOutput struct { 2131 _ struct{} `type:"structure"` 2132 2133 // A list containing the properties of each job returned. 2134 ComprehendMedicalAsyncJobPropertiesList []*ComprehendMedicalAsyncJobProperties `type:"list"` 2135 2136 // Identifies the next page of results to return. 2137 NextToken *string `min:"1" type:"string"` 2138} 2139 2140// String returns the string representation 2141func (s ListPHIDetectionJobsOutput) String() string { 2142 return awsutil.Prettify(s) 2143} 2144 2145// GoString returns the string representation 2146func (s ListPHIDetectionJobsOutput) GoString() string { 2147 return s.String() 2148} 2149 2150// SetComprehendMedicalAsyncJobPropertiesList sets the ComprehendMedicalAsyncJobPropertiesList field's value. 2151func (s *ListPHIDetectionJobsOutput) SetComprehendMedicalAsyncJobPropertiesList(v []*ComprehendMedicalAsyncJobProperties) *ListPHIDetectionJobsOutput { 2152 s.ComprehendMedicalAsyncJobPropertiesList = v 2153 return s 2154} 2155 2156// SetNextToken sets the NextToken field's value. 2157func (s *ListPHIDetectionJobsOutput) SetNextToken(v string) *ListPHIDetectionJobsOutput { 2158 s.NextToken = &v 2159 return s 2160} 2161 2162// The output properties for a detection job. 2163type OutputDataConfig struct { 2164 _ struct{} `type:"structure"` 2165 2166 // When you use the OutputDataConfig object with asynchronous operations, you 2167 // specify the Amazon S3 location where you want to write the output data. The 2168 // URI must be in the same region as the API endpoint that you are calling. 2169 // The location is used as the prefix for the actual location of the output. 2170 // 2171 // S3Bucket is a required field 2172 S3Bucket *string `min:"3" type:"string" required:"true"` 2173 2174 // The path to the output data files in the S3 bucket. Amazon Comprehend Medical 2175 // creates an output directory using the job ID so that the output from one 2176 // job does not overwrite the output of another. 2177 S3Key *string `type:"string"` 2178} 2179 2180// String returns the string representation 2181func (s OutputDataConfig) String() string { 2182 return awsutil.Prettify(s) 2183} 2184 2185// GoString returns the string representation 2186func (s OutputDataConfig) GoString() string { 2187 return s.String() 2188} 2189 2190// Validate inspects the fields of the type to determine if they are valid. 2191func (s *OutputDataConfig) Validate() error { 2192 invalidParams := request.ErrInvalidParams{Context: "OutputDataConfig"} 2193 if s.S3Bucket == nil { 2194 invalidParams.Add(request.NewErrParamRequired("S3Bucket")) 2195 } 2196 if s.S3Bucket != nil && len(*s.S3Bucket) < 3 { 2197 invalidParams.Add(request.NewErrParamMinLen("S3Bucket", 3)) 2198 } 2199 2200 if invalidParams.Len() > 0 { 2201 return invalidParams 2202 } 2203 return nil 2204} 2205 2206// SetS3Bucket sets the S3Bucket field's value. 2207func (s *OutputDataConfig) SetS3Bucket(v string) *OutputDataConfig { 2208 s.S3Bucket = &v 2209 return s 2210} 2211 2212// SetS3Key sets the S3Key field's value. 2213func (s *OutputDataConfig) SetS3Key(v string) *OutputDataConfig { 2214 s.S3Key = &v 2215 return s 2216} 2217 2218type StartEntitiesDetectionV2JobInput struct { 2219 _ struct{} `type:"structure"` 2220 2221 // A unique identifier for the request. If you don't set the client request 2222 // token, Amazon Comprehend Medical generates one. 2223 ClientRequestToken *string `min:"1" type:"string" idempotencyToken:"true"` 2224 2225 // The Amazon Resource Name (ARN) of the AWS Identity and Access Management 2226 // (IAM) role that grants Amazon Comprehend Medical read access to your input 2227 // data. For more information, see Role-Based Permissions Required for Asynchronous 2228 // Operations (https://docs.aws.amazon.com/comprehend/latest/dg/access-control-managing-permissions-med.html#auth-role-permissions-med). 2229 // 2230 // DataAccessRoleArn is a required field 2231 DataAccessRoleArn *string `min:"20" type:"string" required:"true"` 2232 2233 // Specifies the format and location of the input data for the job. 2234 // 2235 // InputDataConfig is a required field 2236 InputDataConfig *InputDataConfig `type:"structure" required:"true"` 2237 2238 // The identifier of the job. 2239 JobName *string `min:"1" type:"string"` 2240 2241 // An AWS Key Management Service key to encrypt your output files. If you do 2242 // not specify a key, the files are written in plain text. 2243 KMSKey *string `min:"1" type:"string"` 2244 2245 // The language of the input documents. All documents must be in the same language. 2246 // 2247 // LanguageCode is a required field 2248 LanguageCode *string `type:"string" required:"true" enum:"LanguageCode"` 2249 2250 // Specifies where to send the output files. 2251 // 2252 // OutputDataConfig is a required field 2253 OutputDataConfig *OutputDataConfig `type:"structure" required:"true"` 2254} 2255 2256// String returns the string representation 2257func (s StartEntitiesDetectionV2JobInput) String() string { 2258 return awsutil.Prettify(s) 2259} 2260 2261// GoString returns the string representation 2262func (s StartEntitiesDetectionV2JobInput) GoString() string { 2263 return s.String() 2264} 2265 2266// Validate inspects the fields of the type to determine if they are valid. 2267func (s *StartEntitiesDetectionV2JobInput) Validate() error { 2268 invalidParams := request.ErrInvalidParams{Context: "StartEntitiesDetectionV2JobInput"} 2269 if s.ClientRequestToken != nil && len(*s.ClientRequestToken) < 1 { 2270 invalidParams.Add(request.NewErrParamMinLen("ClientRequestToken", 1)) 2271 } 2272 if s.DataAccessRoleArn == nil { 2273 invalidParams.Add(request.NewErrParamRequired("DataAccessRoleArn")) 2274 } 2275 if s.DataAccessRoleArn != nil && len(*s.DataAccessRoleArn) < 20 { 2276 invalidParams.Add(request.NewErrParamMinLen("DataAccessRoleArn", 20)) 2277 } 2278 if s.InputDataConfig == nil { 2279 invalidParams.Add(request.NewErrParamRequired("InputDataConfig")) 2280 } 2281 if s.JobName != nil && len(*s.JobName) < 1 { 2282 invalidParams.Add(request.NewErrParamMinLen("JobName", 1)) 2283 } 2284 if s.KMSKey != nil && len(*s.KMSKey) < 1 { 2285 invalidParams.Add(request.NewErrParamMinLen("KMSKey", 1)) 2286 } 2287 if s.LanguageCode == nil { 2288 invalidParams.Add(request.NewErrParamRequired("LanguageCode")) 2289 } 2290 if s.OutputDataConfig == nil { 2291 invalidParams.Add(request.NewErrParamRequired("OutputDataConfig")) 2292 } 2293 if s.InputDataConfig != nil { 2294 if err := s.InputDataConfig.Validate(); err != nil { 2295 invalidParams.AddNested("InputDataConfig", err.(request.ErrInvalidParams)) 2296 } 2297 } 2298 if s.OutputDataConfig != nil { 2299 if err := s.OutputDataConfig.Validate(); err != nil { 2300 invalidParams.AddNested("OutputDataConfig", err.(request.ErrInvalidParams)) 2301 } 2302 } 2303 2304 if invalidParams.Len() > 0 { 2305 return invalidParams 2306 } 2307 return nil 2308} 2309 2310// SetClientRequestToken sets the ClientRequestToken field's value. 2311func (s *StartEntitiesDetectionV2JobInput) SetClientRequestToken(v string) *StartEntitiesDetectionV2JobInput { 2312 s.ClientRequestToken = &v 2313 return s 2314} 2315 2316// SetDataAccessRoleArn sets the DataAccessRoleArn field's value. 2317func (s *StartEntitiesDetectionV2JobInput) SetDataAccessRoleArn(v string) *StartEntitiesDetectionV2JobInput { 2318 s.DataAccessRoleArn = &v 2319 return s 2320} 2321 2322// SetInputDataConfig sets the InputDataConfig field's value. 2323func (s *StartEntitiesDetectionV2JobInput) SetInputDataConfig(v *InputDataConfig) *StartEntitiesDetectionV2JobInput { 2324 s.InputDataConfig = v 2325 return s 2326} 2327 2328// SetJobName sets the JobName field's value. 2329func (s *StartEntitiesDetectionV2JobInput) SetJobName(v string) *StartEntitiesDetectionV2JobInput { 2330 s.JobName = &v 2331 return s 2332} 2333 2334// SetKMSKey sets the KMSKey field's value. 2335func (s *StartEntitiesDetectionV2JobInput) SetKMSKey(v string) *StartEntitiesDetectionV2JobInput { 2336 s.KMSKey = &v 2337 return s 2338} 2339 2340// SetLanguageCode sets the LanguageCode field's value. 2341func (s *StartEntitiesDetectionV2JobInput) SetLanguageCode(v string) *StartEntitiesDetectionV2JobInput { 2342 s.LanguageCode = &v 2343 return s 2344} 2345 2346// SetOutputDataConfig sets the OutputDataConfig field's value. 2347func (s *StartEntitiesDetectionV2JobInput) SetOutputDataConfig(v *OutputDataConfig) *StartEntitiesDetectionV2JobInput { 2348 s.OutputDataConfig = v 2349 return s 2350} 2351 2352type StartEntitiesDetectionV2JobOutput struct { 2353 _ struct{} `type:"structure"` 2354 2355 // The identifier generated for the job. To get the status of a job, use this 2356 // identifier with the DescribeEntitiesDetectionV2Job operation. 2357 JobId *string `min:"1" type:"string"` 2358} 2359 2360// String returns the string representation 2361func (s StartEntitiesDetectionV2JobOutput) String() string { 2362 return awsutil.Prettify(s) 2363} 2364 2365// GoString returns the string representation 2366func (s StartEntitiesDetectionV2JobOutput) GoString() string { 2367 return s.String() 2368} 2369 2370// SetJobId sets the JobId field's value. 2371func (s *StartEntitiesDetectionV2JobOutput) SetJobId(v string) *StartEntitiesDetectionV2JobOutput { 2372 s.JobId = &v 2373 return s 2374} 2375 2376type StartPHIDetectionJobInput struct { 2377 _ struct{} `type:"structure"` 2378 2379 // A unique identifier for the request. If you don't set the client request 2380 // token, Amazon Comprehend Medical generates one. 2381 ClientRequestToken *string `min:"1" type:"string" idempotencyToken:"true"` 2382 2383 // The Amazon Resource Name (ARN) of the AWS Identity and Access Management 2384 // (IAM) role that grants Amazon Comprehend Medical read access to your input 2385 // data. For more information, see Role-Based Permissions Required for Asynchronous 2386 // Operations (https://docs.aws.amazon.com/comprehend/latest/dg/access-control-managing-permissions-med.html#auth-role-permissions-med). 2387 // 2388 // DataAccessRoleArn is a required field 2389 DataAccessRoleArn *string `min:"20" type:"string" required:"true"` 2390 2391 // Specifies the format and location of the input data for the job. 2392 // 2393 // InputDataConfig is a required field 2394 InputDataConfig *InputDataConfig `type:"structure" required:"true"` 2395 2396 // The identifier of the job. 2397 JobName *string `min:"1" type:"string"` 2398 2399 // An AWS Key Management Service key to encrypt your output files. If you do 2400 // not specify a key, the files are written in plain text. 2401 KMSKey *string `min:"1" type:"string"` 2402 2403 // The language of the input documents. All documents must be in the same language. 2404 // 2405 // LanguageCode is a required field 2406 LanguageCode *string `type:"string" required:"true" enum:"LanguageCode"` 2407 2408 // Specifies where to send the output files. 2409 // 2410 // OutputDataConfig is a required field 2411 OutputDataConfig *OutputDataConfig `type:"structure" required:"true"` 2412} 2413 2414// String returns the string representation 2415func (s StartPHIDetectionJobInput) String() string { 2416 return awsutil.Prettify(s) 2417} 2418 2419// GoString returns the string representation 2420func (s StartPHIDetectionJobInput) GoString() string { 2421 return s.String() 2422} 2423 2424// Validate inspects the fields of the type to determine if they are valid. 2425func (s *StartPHIDetectionJobInput) Validate() error { 2426 invalidParams := request.ErrInvalidParams{Context: "StartPHIDetectionJobInput"} 2427 if s.ClientRequestToken != nil && len(*s.ClientRequestToken) < 1 { 2428 invalidParams.Add(request.NewErrParamMinLen("ClientRequestToken", 1)) 2429 } 2430 if s.DataAccessRoleArn == nil { 2431 invalidParams.Add(request.NewErrParamRequired("DataAccessRoleArn")) 2432 } 2433 if s.DataAccessRoleArn != nil && len(*s.DataAccessRoleArn) < 20 { 2434 invalidParams.Add(request.NewErrParamMinLen("DataAccessRoleArn", 20)) 2435 } 2436 if s.InputDataConfig == nil { 2437 invalidParams.Add(request.NewErrParamRequired("InputDataConfig")) 2438 } 2439 if s.JobName != nil && len(*s.JobName) < 1 { 2440 invalidParams.Add(request.NewErrParamMinLen("JobName", 1)) 2441 } 2442 if s.KMSKey != nil && len(*s.KMSKey) < 1 { 2443 invalidParams.Add(request.NewErrParamMinLen("KMSKey", 1)) 2444 } 2445 if s.LanguageCode == nil { 2446 invalidParams.Add(request.NewErrParamRequired("LanguageCode")) 2447 } 2448 if s.OutputDataConfig == nil { 2449 invalidParams.Add(request.NewErrParamRequired("OutputDataConfig")) 2450 } 2451 if s.InputDataConfig != nil { 2452 if err := s.InputDataConfig.Validate(); err != nil { 2453 invalidParams.AddNested("InputDataConfig", err.(request.ErrInvalidParams)) 2454 } 2455 } 2456 if s.OutputDataConfig != nil { 2457 if err := s.OutputDataConfig.Validate(); err != nil { 2458 invalidParams.AddNested("OutputDataConfig", err.(request.ErrInvalidParams)) 2459 } 2460 } 2461 2462 if invalidParams.Len() > 0 { 2463 return invalidParams 2464 } 2465 return nil 2466} 2467 2468// SetClientRequestToken sets the ClientRequestToken field's value. 2469func (s *StartPHIDetectionJobInput) SetClientRequestToken(v string) *StartPHIDetectionJobInput { 2470 s.ClientRequestToken = &v 2471 return s 2472} 2473 2474// SetDataAccessRoleArn sets the DataAccessRoleArn field's value. 2475func (s *StartPHIDetectionJobInput) SetDataAccessRoleArn(v string) *StartPHIDetectionJobInput { 2476 s.DataAccessRoleArn = &v 2477 return s 2478} 2479 2480// SetInputDataConfig sets the InputDataConfig field's value. 2481func (s *StartPHIDetectionJobInput) SetInputDataConfig(v *InputDataConfig) *StartPHIDetectionJobInput { 2482 s.InputDataConfig = v 2483 return s 2484} 2485 2486// SetJobName sets the JobName field's value. 2487func (s *StartPHIDetectionJobInput) SetJobName(v string) *StartPHIDetectionJobInput { 2488 s.JobName = &v 2489 return s 2490} 2491 2492// SetKMSKey sets the KMSKey field's value. 2493func (s *StartPHIDetectionJobInput) SetKMSKey(v string) *StartPHIDetectionJobInput { 2494 s.KMSKey = &v 2495 return s 2496} 2497 2498// SetLanguageCode sets the LanguageCode field's value. 2499func (s *StartPHIDetectionJobInput) SetLanguageCode(v string) *StartPHIDetectionJobInput { 2500 s.LanguageCode = &v 2501 return s 2502} 2503 2504// SetOutputDataConfig sets the OutputDataConfig field's value. 2505func (s *StartPHIDetectionJobInput) SetOutputDataConfig(v *OutputDataConfig) *StartPHIDetectionJobInput { 2506 s.OutputDataConfig = v 2507 return s 2508} 2509 2510type StartPHIDetectionJobOutput struct { 2511 _ struct{} `type:"structure"` 2512 2513 // The identifier generated for the job. To get the status of a job, use this 2514 // identifier with the DescribePHIDetectionJob operation. 2515 JobId *string `min:"1" type:"string"` 2516} 2517 2518// String returns the string representation 2519func (s StartPHIDetectionJobOutput) String() string { 2520 return awsutil.Prettify(s) 2521} 2522 2523// GoString returns the string representation 2524func (s StartPHIDetectionJobOutput) GoString() string { 2525 return s.String() 2526} 2527 2528// SetJobId sets the JobId field's value. 2529func (s *StartPHIDetectionJobOutput) SetJobId(v string) *StartPHIDetectionJobOutput { 2530 s.JobId = &v 2531 return s 2532} 2533 2534type StopEntitiesDetectionV2JobInput struct { 2535 _ struct{} `type:"structure"` 2536 2537 // The identifier of the medical entities job to stop. 2538 // 2539 // JobId is a required field 2540 JobId *string `min:"1" type:"string" required:"true"` 2541} 2542 2543// String returns the string representation 2544func (s StopEntitiesDetectionV2JobInput) String() string { 2545 return awsutil.Prettify(s) 2546} 2547 2548// GoString returns the string representation 2549func (s StopEntitiesDetectionV2JobInput) GoString() string { 2550 return s.String() 2551} 2552 2553// Validate inspects the fields of the type to determine if they are valid. 2554func (s *StopEntitiesDetectionV2JobInput) Validate() error { 2555 invalidParams := request.ErrInvalidParams{Context: "StopEntitiesDetectionV2JobInput"} 2556 if s.JobId == nil { 2557 invalidParams.Add(request.NewErrParamRequired("JobId")) 2558 } 2559 if s.JobId != nil && len(*s.JobId) < 1 { 2560 invalidParams.Add(request.NewErrParamMinLen("JobId", 1)) 2561 } 2562 2563 if invalidParams.Len() > 0 { 2564 return invalidParams 2565 } 2566 return nil 2567} 2568 2569// SetJobId sets the JobId field's value. 2570func (s *StopEntitiesDetectionV2JobInput) SetJobId(v string) *StopEntitiesDetectionV2JobInput { 2571 s.JobId = &v 2572 return s 2573} 2574 2575type StopEntitiesDetectionV2JobOutput struct { 2576 _ struct{} `type:"structure"` 2577 2578 // The identifier of the medical entities detection job that was stopped. 2579 JobId *string `min:"1" type:"string"` 2580} 2581 2582// String returns the string representation 2583func (s StopEntitiesDetectionV2JobOutput) String() string { 2584 return awsutil.Prettify(s) 2585} 2586 2587// GoString returns the string representation 2588func (s StopEntitiesDetectionV2JobOutput) GoString() string { 2589 return s.String() 2590} 2591 2592// SetJobId sets the JobId field's value. 2593func (s *StopEntitiesDetectionV2JobOutput) SetJobId(v string) *StopEntitiesDetectionV2JobOutput { 2594 s.JobId = &v 2595 return s 2596} 2597 2598type StopPHIDetectionJobInput struct { 2599 _ struct{} `type:"structure"` 2600 2601 // The identifier of the PHI detection job to stop. 2602 // 2603 // JobId is a required field 2604 JobId *string `min:"1" type:"string" required:"true"` 2605} 2606 2607// String returns the string representation 2608func (s StopPHIDetectionJobInput) String() string { 2609 return awsutil.Prettify(s) 2610} 2611 2612// GoString returns the string representation 2613func (s StopPHIDetectionJobInput) GoString() string { 2614 return s.String() 2615} 2616 2617// Validate inspects the fields of the type to determine if they are valid. 2618func (s *StopPHIDetectionJobInput) Validate() error { 2619 invalidParams := request.ErrInvalidParams{Context: "StopPHIDetectionJobInput"} 2620 if s.JobId == nil { 2621 invalidParams.Add(request.NewErrParamRequired("JobId")) 2622 } 2623 if s.JobId != nil && len(*s.JobId) < 1 { 2624 invalidParams.Add(request.NewErrParamMinLen("JobId", 1)) 2625 } 2626 2627 if invalidParams.Len() > 0 { 2628 return invalidParams 2629 } 2630 return nil 2631} 2632 2633// SetJobId sets the JobId field's value. 2634func (s *StopPHIDetectionJobInput) SetJobId(v string) *StopPHIDetectionJobInput { 2635 s.JobId = &v 2636 return s 2637} 2638 2639type StopPHIDetectionJobOutput struct { 2640 _ struct{} `type:"structure"` 2641 2642 // The identifier of the PHI detection job that was stopped. 2643 JobId *string `min:"1" type:"string"` 2644} 2645 2646// String returns the string representation 2647func (s StopPHIDetectionJobOutput) String() string { 2648 return awsutil.Prettify(s) 2649} 2650 2651// GoString returns the string representation 2652func (s StopPHIDetectionJobOutput) GoString() string { 2653 return s.String() 2654} 2655 2656// SetJobId sets the JobId field's value. 2657func (s *StopPHIDetectionJobOutput) SetJobId(v string) *StopPHIDetectionJobOutput { 2658 s.JobId = &v 2659 return s 2660} 2661 2662// Provides contextual information about the extracted entity. 2663type Trait struct { 2664 _ struct{} `type:"structure"` 2665 2666 // Provides a name or contextual description about the trait. 2667 Name *string `type:"string" enum:"AttributeName"` 2668 2669 // The level of confidence that Amazon Comprehend Medical has in the accuracy 2670 // of this trait. 2671 Score *float64 `type:"float"` 2672} 2673 2674// String returns the string representation 2675func (s Trait) String() string { 2676 return awsutil.Prettify(s) 2677} 2678 2679// GoString returns the string representation 2680func (s Trait) GoString() string { 2681 return s.String() 2682} 2683 2684// SetName sets the Name field's value. 2685func (s *Trait) SetName(v string) *Trait { 2686 s.Name = &v 2687 return s 2688} 2689 2690// SetScore sets the Score field's value. 2691func (s *Trait) SetScore(v float64) *Trait { 2692 s.Score = &v 2693 return s 2694} 2695 2696// An attribute that we extracted, but were unable to relate to an entity. 2697type UnmappedAttribute struct { 2698 _ struct{} `type:"structure"` 2699 2700 // The specific attribute that has been extracted but not mapped to an entity. 2701 Attribute *Attribute `type:"structure"` 2702 2703 // The type of the attribute, could be one of the following values: "MEDICATION", 2704 // "MEDICAL_CONDITION", "ANATOMY", "TEST_AND_TREATMENT_PROCEDURE" or "PROTECTED_HEALTH_INFORMATION". 2705 Type *string `type:"string" enum:"EntityType"` 2706} 2707 2708// String returns the string representation 2709func (s UnmappedAttribute) String() string { 2710 return awsutil.Prettify(s) 2711} 2712 2713// GoString returns the string representation 2714func (s UnmappedAttribute) GoString() string { 2715 return s.String() 2716} 2717 2718// SetAttribute sets the Attribute field's value. 2719func (s *UnmappedAttribute) SetAttribute(v *Attribute) *UnmappedAttribute { 2720 s.Attribute = v 2721 return s 2722} 2723 2724// SetType sets the Type field's value. 2725func (s *UnmappedAttribute) SetType(v string) *UnmappedAttribute { 2726 s.Type = &v 2727 return s 2728} 2729 2730const ( 2731 // AttributeNameSign is a AttributeName enum value 2732 AttributeNameSign = "SIGN" 2733 2734 // AttributeNameSymptom is a AttributeName enum value 2735 AttributeNameSymptom = "SYMPTOM" 2736 2737 // AttributeNameDiagnosis is a AttributeName enum value 2738 AttributeNameDiagnosis = "DIAGNOSIS" 2739 2740 // AttributeNameNegation is a AttributeName enum value 2741 AttributeNameNegation = "NEGATION" 2742) 2743 2744const ( 2745 // EntitySubTypeName is a EntitySubType enum value 2746 EntitySubTypeName = "NAME" 2747 2748 // EntitySubTypeDosage is a EntitySubType enum value 2749 EntitySubTypeDosage = "DOSAGE" 2750 2751 // EntitySubTypeRouteOrMode is a EntitySubType enum value 2752 EntitySubTypeRouteOrMode = "ROUTE_OR_MODE" 2753 2754 // EntitySubTypeForm is a EntitySubType enum value 2755 EntitySubTypeForm = "FORM" 2756 2757 // EntitySubTypeFrequency is a EntitySubType enum value 2758 EntitySubTypeFrequency = "FREQUENCY" 2759 2760 // EntitySubTypeDuration is a EntitySubType enum value 2761 EntitySubTypeDuration = "DURATION" 2762 2763 // EntitySubTypeGenericName is a EntitySubType enum value 2764 EntitySubTypeGenericName = "GENERIC_NAME" 2765 2766 // EntitySubTypeBrandName is a EntitySubType enum value 2767 EntitySubTypeBrandName = "BRAND_NAME" 2768 2769 // EntitySubTypeStrength is a EntitySubType enum value 2770 EntitySubTypeStrength = "STRENGTH" 2771 2772 // EntitySubTypeRate is a EntitySubType enum value 2773 EntitySubTypeRate = "RATE" 2774 2775 // EntitySubTypeAcuity is a EntitySubType enum value 2776 EntitySubTypeAcuity = "ACUITY" 2777 2778 // EntitySubTypeTestName is a EntitySubType enum value 2779 EntitySubTypeTestName = "TEST_NAME" 2780 2781 // EntitySubTypeTestValue is a EntitySubType enum value 2782 EntitySubTypeTestValue = "TEST_VALUE" 2783 2784 // EntitySubTypeTestUnits is a EntitySubType enum value 2785 EntitySubTypeTestUnits = "TEST_UNITS" 2786 2787 // EntitySubTypeProcedureName is a EntitySubType enum value 2788 EntitySubTypeProcedureName = "PROCEDURE_NAME" 2789 2790 // EntitySubTypeTreatmentName is a EntitySubType enum value 2791 EntitySubTypeTreatmentName = "TREATMENT_NAME" 2792 2793 // EntitySubTypeDate is a EntitySubType enum value 2794 EntitySubTypeDate = "DATE" 2795 2796 // EntitySubTypeAge is a EntitySubType enum value 2797 EntitySubTypeAge = "AGE" 2798 2799 // EntitySubTypeContactPoint is a EntitySubType enum value 2800 EntitySubTypeContactPoint = "CONTACT_POINT" 2801 2802 // EntitySubTypeEmail is a EntitySubType enum value 2803 EntitySubTypeEmail = "EMAIL" 2804 2805 // EntitySubTypeIdentifier is a EntitySubType enum value 2806 EntitySubTypeIdentifier = "IDENTIFIER" 2807 2808 // EntitySubTypeUrl is a EntitySubType enum value 2809 EntitySubTypeUrl = "URL" 2810 2811 // EntitySubTypeAddress is a EntitySubType enum value 2812 EntitySubTypeAddress = "ADDRESS" 2813 2814 // EntitySubTypeProfession is a EntitySubType enum value 2815 EntitySubTypeProfession = "PROFESSION" 2816 2817 // EntitySubTypeSystemOrganSite is a EntitySubType enum value 2818 EntitySubTypeSystemOrganSite = "SYSTEM_ORGAN_SITE" 2819 2820 // EntitySubTypeDirection is a EntitySubType enum value 2821 EntitySubTypeDirection = "DIRECTION" 2822 2823 // EntitySubTypeQuality is a EntitySubType enum value 2824 EntitySubTypeQuality = "QUALITY" 2825 2826 // EntitySubTypeQuantity is a EntitySubType enum value 2827 EntitySubTypeQuantity = "QUANTITY" 2828) 2829 2830const ( 2831 // EntityTypeMedication is a EntityType enum value 2832 EntityTypeMedication = "MEDICATION" 2833 2834 // EntityTypeMedicalCondition is a EntityType enum value 2835 EntityTypeMedicalCondition = "MEDICAL_CONDITION" 2836 2837 // EntityTypeProtectedHealthInformation is a EntityType enum value 2838 EntityTypeProtectedHealthInformation = "PROTECTED_HEALTH_INFORMATION" 2839 2840 // EntityTypeTestTreatmentProcedure is a EntityType enum value 2841 EntityTypeTestTreatmentProcedure = "TEST_TREATMENT_PROCEDURE" 2842 2843 // EntityTypeAnatomy is a EntityType enum value 2844 EntityTypeAnatomy = "ANATOMY" 2845) 2846 2847const ( 2848 // JobStatusSubmitted is a JobStatus enum value 2849 JobStatusSubmitted = "SUBMITTED" 2850 2851 // JobStatusInProgress is a JobStatus enum value 2852 JobStatusInProgress = "IN_PROGRESS" 2853 2854 // JobStatusCompleted is a JobStatus enum value 2855 JobStatusCompleted = "COMPLETED" 2856 2857 // JobStatusPartialSuccess is a JobStatus enum value 2858 JobStatusPartialSuccess = "PARTIAL_SUCCESS" 2859 2860 // JobStatusFailed is a JobStatus enum value 2861 JobStatusFailed = "FAILED" 2862 2863 // JobStatusStopRequested is a JobStatus enum value 2864 JobStatusStopRequested = "STOP_REQUESTED" 2865 2866 // JobStatusStopped is a JobStatus enum value 2867 JobStatusStopped = "STOPPED" 2868) 2869 2870const ( 2871 // LanguageCodeEn is a LanguageCode enum value 2872 LanguageCodeEn = "en" 2873) 2874