...

Source file src/github.com/Azure/azure-sdk-for-go/services/cognitiveservices/v1.0/contentmoderator/models.go

Documentation: github.com/Azure/azure-sdk-for-go/services/cognitiveservices/v1.0/contentmoderator

     1  package contentmoderator
     2  
     3  // Copyright (c) Microsoft Corporation. All rights reserved.
     4  // Licensed under the MIT License. See License.txt in the project root for license information.
     5  //
     6  // Code generated by Microsoft (R) AutoRest Code Generator.
     7  // Changes may cause incorrect behavior and will be lost if the code is regenerated.
     8  
     9  import (
    10  	"encoding/json"
    11  	"github.com/Azure/go-autorest/autorest"
    12  )
    13  
    14  // The package's fully qualified name.
    15  const fqdn = "github.com/Azure/azure-sdk-for-go/services/cognitiveservices/v1.0/contentmoderator"
    16  
    17  // Address address details.
    18  type Address struct {
    19  	// Text - Detected Address.
    20  	Text *string `json:"Text,omitempty"`
    21  	// Index - Index(Location) of the Address in the input text content.
    22  	Index *int32 `json:"Index,omitempty"`
    23  }
    24  
    25  // APIError error information returned by the API
    26  type APIError struct {
    27  	Error *Error `json:"Error,omitempty"`
    28  }
    29  
    30  // Body ...
    31  type Body struct {
    32  	// Name - Name of the list.
    33  	Name *string `json:"Name,omitempty"`
    34  	// Description - Description of the list.
    35  	Description *string `json:"Description,omitempty"`
    36  	// Metadata - Metadata of the list.
    37  	Metadata map[string]*string `json:"Metadata"`
    38  }
    39  
    40  // MarshalJSON is the custom marshaler for Body.
    41  func (b Body) MarshalJSON() ([]byte, error) {
    42  	objectMap := make(map[string]interface{})
    43  	if b.Name != nil {
    44  		objectMap["Name"] = b.Name
    45  	}
    46  	if b.Description != nil {
    47  		objectMap["Description"] = b.Description
    48  	}
    49  	if b.Metadata != nil {
    50  		objectMap["Metadata"] = b.Metadata
    51  	}
    52  	return json.Marshal(objectMap)
    53  }
    54  
    55  // Candidate OCR candidate text.
    56  type Candidate struct {
    57  	// Text - The text found.
    58  	Text *string `json:"Text,omitempty"`
    59  	// Confidence - The confidence level.
    60  	Confidence *float64 `json:"Confidence,omitempty"`
    61  }
    62  
    63  // Classification the classification details of the text.
    64  type Classification struct {
    65  	// Category1 - The category1 score details of the text. <a href="https://aka.ms/textClassifyCategories">Click here</a> for more details on category classification.
    66  	Category1 *ClassificationCategory1 `json:"Category1,omitempty"`
    67  	// Category2 - The category2 score details of the text. <a href="https://aka.ms/textClassifyCategories">Click here</a> for more details on category classification.
    68  	Category2 *ClassificationCategory2 `json:"Category2,omitempty"`
    69  	// Category3 - The category3 score details of the text. <a href="https://aka.ms/textClassifyCategories">Click here</a> for more details on category classification.
    70  	Category3 *ClassificationCategory3 `json:"Category3,omitempty"`
    71  	// ReviewRecommended - The review recommended flag.
    72  	ReviewRecommended *bool `json:"ReviewRecommended,omitempty"`
    73  }
    74  
    75  // ClassificationCategory1 the category1 score details of the text. <a
    76  // href="https://aka.ms/textClassifyCategories">Click here</a> for more details on category classification.
    77  type ClassificationCategory1 struct {
    78  	// Score - The category1 score.
    79  	Score *float64 `json:"Score,omitempty"`
    80  }
    81  
    82  // ClassificationCategory2 the category2 score details of the text. <a
    83  // href="https://aka.ms/textClassifyCategories">Click here</a> for more details on category classification.
    84  type ClassificationCategory2 struct {
    85  	// Score - The category2 score.
    86  	Score *float64 `json:"Score,omitempty"`
    87  }
    88  
    89  // ClassificationCategory3 the category3 score details of the text. <a
    90  // href="https://aka.ms/textClassifyCategories">Click here</a> for more details on category classification.
    91  type ClassificationCategory3 struct {
    92  	// Score - The category3 score.
    93  	Score *float64 `json:"Score,omitempty"`
    94  }
    95  
    96  // Content ...
    97  type Content struct {
    98  	// ContentValue - Content to evaluate for a job.
    99  	ContentValue *string `json:"ContentValue,omitempty"`
   100  }
   101  
   102  // CreateReviewBodyItem schema items of the body.
   103  type CreateReviewBodyItem struct {
   104  	// Type - Type of the content. Possible values include: 'TypeImage', 'TypeText'
   105  	Type Type `json:"Type,omitempty"`
   106  	// Content - Content to review.
   107  	Content *string `json:"Content,omitempty"`
   108  	// ContentID - Content Identifier.
   109  	ContentID *string `json:"ContentId,omitempty"`
   110  	// CallbackEndpoint - Optional CallbackEndpoint.
   111  	CallbackEndpoint *string `json:"CallbackEndpoint,omitempty"`
   112  	// Metadata - Optional metadata details.
   113  	Metadata *[]CreateReviewBodyItemMetadataItem `json:"Metadata,omitempty"`
   114  }
   115  
   116  // CreateReviewBodyItemMetadataItem ...
   117  type CreateReviewBodyItemMetadataItem struct {
   118  	// Key - Your key parameter.
   119  	Key *string `json:"Key,omitempty"`
   120  	// Value - Your value parameter.
   121  	Value *string `json:"Value,omitempty"`
   122  }
   123  
   124  // CreateVideoReviewsBodyItem schema items of the body.
   125  type CreateVideoReviewsBodyItem struct {
   126  	// VideoFrames - Optional metadata details.
   127  	VideoFrames *[]CreateVideoReviewsBodyItemVideoFramesItem `json:"VideoFrames,omitempty"`
   128  	// Metadata - Optional metadata details.
   129  	Metadata *[]CreateVideoReviewsBodyItemMetadataItem `json:"Metadata,omitempty"`
   130  	// Type - Type of the content.
   131  	Type *string `json:"Type,omitempty"`
   132  	// Content - Video content url to review.
   133  	Content *string `json:"Content,omitempty"`
   134  	// ContentID - Content Identifier.
   135  	ContentID *string `json:"ContentId,omitempty"`
   136  	// Status - Status of the video(Complete,Unpublished,Pending). Possible values include: 'Complete', 'Unpublished', 'Pending'
   137  	Status StatusEnum `json:"Status,omitempty"`
   138  	// Timescale - Timescale of the video.
   139  	Timescale *int32 `json:"Timescale,omitempty"`
   140  	// CallbackEndpoint - Optional CallbackEndpoint.
   141  	CallbackEndpoint *string `json:"CallbackEndpoint,omitempty"`
   142  }
   143  
   144  // CreateVideoReviewsBodyItemMetadataItem ...
   145  type CreateVideoReviewsBodyItemMetadataItem struct {
   146  	// Key - Your key parameter.
   147  	Key *string `json:"Key,omitempty"`
   148  	// Value - Your value parameter.
   149  	Value *string `json:"Value,omitempty"`
   150  }
   151  
   152  // CreateVideoReviewsBodyItemVideoFramesItem ...
   153  type CreateVideoReviewsBodyItemVideoFramesItem struct {
   154  	// ID - Id of the frame.
   155  	ID *string `json:"Id,omitempty"`
   156  	// Timestamp - Timestamp of the frame.
   157  	Timestamp *int32 `json:"Timestamp,omitempty"`
   158  	// FrameImage - Frame image Url.
   159  	FrameImage         *string                                                            `json:"FrameImage,omitempty"`
   160  	ReviewerResultTags *[]CreateVideoReviewsBodyItemVideoFramesItemReviewerResultTagsItem `json:"ReviewerResultTags,omitempty"`
   161  	// Metadata - Optional metadata details.
   162  	Metadata *[]CreateVideoReviewsBodyItemVideoFramesItemMetadataItem `json:"Metadata,omitempty"`
   163  }
   164  
   165  // CreateVideoReviewsBodyItemVideoFramesItemMetadataItem ...
   166  type CreateVideoReviewsBodyItemVideoFramesItemMetadataItem struct {
   167  	// Key - Your key parameter.
   168  	Key *string `json:"Key,omitempty"`
   169  	// Value - Your value parameter.
   170  	Value *string `json:"Value,omitempty"`
   171  }
   172  
   173  // CreateVideoReviewsBodyItemVideoFramesItemReviewerResultTagsItem ...
   174  type CreateVideoReviewsBodyItemVideoFramesItemReviewerResultTagsItem struct {
   175  	// Key - Your key parameter.
   176  	Key *string `json:"Key,omitempty"`
   177  	// Value - Your value parameter.
   178  	Value *string `json:"Value,omitempty"`
   179  }
   180  
   181  // DetectedLanguage detect language result.
   182  type DetectedLanguage struct {
   183  	autorest.Response `json:"-"`
   184  	// DetectedLanguage - The detected language.
   185  	DetectedLanguage *string `json:"DetectedLanguage,omitempty"`
   186  	// Status - The detect language status
   187  	Status *Status `json:"Status,omitempty"`
   188  	// TrackingID - The tracking id.
   189  	TrackingID *string `json:"TrackingId,omitempty"`
   190  }
   191  
   192  // DetectedTerms detected Terms details.
   193  type DetectedTerms struct {
   194  	// Index - Index(Location) of the detected profanity term in the input text content.
   195  	Index *int32 `json:"Index,omitempty"`
   196  	// OriginalIndex - Original Index(Location) of the detected profanity term in the input text content.
   197  	OriginalIndex *int32 `json:"OriginalIndex,omitempty"`
   198  	// ListID - Matched Terms list Id.
   199  	ListID *int32 `json:"ListId,omitempty"`
   200  	// Term - Detected profanity term.
   201  	Term *string `json:"Term,omitempty"`
   202  }
   203  
   204  // Email email Address details.
   205  type Email struct {
   206  	// Detected - Detected Email Address from the input text content.
   207  	Detected *string `json:"Detected,omitempty"`
   208  	// SubType - Subtype of the detected Email Address.
   209  	SubType *string `json:"SubType,omitempty"`
   210  	// Text - Email Address in the input text content.
   211  	Text *string `json:"Text,omitempty"`
   212  	// Index - Index(Location) of the Email address in the input text content.
   213  	Index *int32 `json:"Index,omitempty"`
   214  }
   215  
   216  // Error error body.
   217  type Error struct {
   218  	Code    *string `json:"Code,omitempty"`
   219  	Message *string `json:"Message,omitempty"`
   220  }
   221  
   222  // Evaluate evaluate response object.
   223  type Evaluate struct {
   224  	autorest.Response `json:"-"`
   225  	// CacheID - The cache id.
   226  	CacheID *string `json:"CacheID,omitempty"`
   227  	// Result - Evaluate result.
   228  	Result *bool `json:"Result,omitempty"`
   229  	// TrackingID - The tracking id.
   230  	TrackingID *string `json:"TrackingId,omitempty"`
   231  	// AdultClassificationScore - The adult classification score.
   232  	AdultClassificationScore *float64 `json:"AdultClassificationScore,omitempty"`
   233  	// IsImageAdultClassified - Indicates if an image is classified as adult.
   234  	IsImageAdultClassified *bool `json:"IsImageAdultClassified,omitempty"`
   235  	// RacyClassificationScore - The racy classification score.
   236  	RacyClassificationScore *float64 `json:"RacyClassificationScore,omitempty"`
   237  	// IsImageRacyClassified - Indicates if the image is classified as racy.
   238  	IsImageRacyClassified *bool `json:"IsImageRacyClassified,omitempty"`
   239  	// AdvancedInfo - The advanced info.
   240  	AdvancedInfo *[]KeyValuePair `json:"AdvancedInfo,omitempty"`
   241  	// Status - The evaluate status
   242  	Status *Status `json:"Status,omitempty"`
   243  }
   244  
   245  // Face coordinates to the found face.
   246  type Face struct {
   247  	// Bottom - The bottom coordinate.
   248  	Bottom *int32 `json:"Bottom,omitempty"`
   249  	// Left - The left coordinate.
   250  	Left *int32 `json:"Left,omitempty"`
   251  	// Right - The right coordinate.
   252  	Right *int32 `json:"Right,omitempty"`
   253  	// Top - The top coordinate.
   254  	Top *int32 `json:"Top,omitempty"`
   255  }
   256  
   257  // FoundFaces request object the contains found faces.
   258  type FoundFaces struct {
   259  	autorest.Response `json:"-"`
   260  	// Status - The evaluate status
   261  	Status *Status `json:"Status,omitempty"`
   262  	// TrackingID - The tracking id.
   263  	TrackingID *string `json:"TrackingId,omitempty"`
   264  	// CacheID - The cache id.
   265  	CacheID *string `json:"CacheId,omitempty"`
   266  	// Result - True if result was found.
   267  	Result *bool `json:"Result,omitempty"`
   268  	// Count - Number of faces found.
   269  	Count *int32 `json:"Count,omitempty"`
   270  	// AdvancedInfo - The advanced info.
   271  	AdvancedInfo *[]KeyValuePair `json:"AdvancedInfo,omitempty"`
   272  	// Faces - The list of faces.
   273  	Faces *[]Face `json:"Faces,omitempty"`
   274  }
   275  
   276  // Frame video frame property details.
   277  type Frame struct {
   278  	// Timestamp - Timestamp of the frame.
   279  	Timestamp *string `json:"Timestamp,omitempty"`
   280  	// FrameImage - Frame image.
   281  	FrameImage *string `json:"FrameImage,omitempty"`
   282  	// Metadata - Array of KeyValue.
   283  	Metadata *[]KeyValuePair `json:"Metadata,omitempty"`
   284  	// ReviewerResultTags - Reviewer result tags.
   285  	ReviewerResultTags *[]Tag `json:"ReviewerResultTags,omitempty"`
   286  }
   287  
   288  // Frames the response for a Get Frames request.
   289  type Frames struct {
   290  	autorest.Response `json:"-"`
   291  	// ReviewID - Id of the review.
   292  	ReviewID    *string  `json:"ReviewId,omitempty"`
   293  	VideoFrames *[]Frame `json:"VideoFrames,omitempty"`
   294  }
   295  
   296  // Image image Properties.
   297  type Image struct {
   298  	autorest.Response `json:"-"`
   299  	// ContentID - Content Id.
   300  	ContentID *string `json:"ContentId,omitempty"`
   301  	// AdditionalInfo - Advanced info list.
   302  	AdditionalInfo *[]ImageAdditionalInfoItem `json:"AdditionalInfo,omitempty"`
   303  	// Status - Status details.
   304  	Status *Status `json:"Status,omitempty"`
   305  	// TrackingID - Tracking Id.
   306  	TrackingID *string `json:"TrackingId,omitempty"`
   307  }
   308  
   309  // ImageAdditionalInfoItem ...
   310  type ImageAdditionalInfoItem struct {
   311  	// Key - Key parameter.
   312  	Key *string `json:"Key,omitempty"`
   313  	// Value - Value parameter.
   314  	Value *string `json:"Value,omitempty"`
   315  }
   316  
   317  // ImageIds image Id properties.
   318  type ImageIds struct {
   319  	autorest.Response `json:"-"`
   320  	// ContentSource - Source of the content.
   321  	ContentSource *string `json:"ContentSource,omitempty"`
   322  	// ContentIds - Id of the contents.
   323  	ContentIds *[]int32 `json:"ContentIds,omitempty"`
   324  	// Status - Get Image status.
   325  	Status *Status `json:"Status,omitempty"`
   326  	// TrackingID - Tracking Id.
   327  	TrackingID *string `json:"TrackingId,omitempty"`
   328  }
   329  
   330  // ImageList image List Properties.
   331  type ImageList struct {
   332  	autorest.Response `json:"-"`
   333  	// ID - Image List Id.
   334  	ID *int32 `json:"Id,omitempty"`
   335  	// Name - Image List Name.
   336  	Name *string `json:"Name,omitempty"`
   337  	// Description - Description for image list.
   338  	Description *string `json:"Description,omitempty"`
   339  	// Metadata - Image List Metadata.
   340  	Metadata map[string]*string `json:"Metadata"`
   341  }
   342  
   343  // MarshalJSON is the custom marshaler for ImageList.
   344  func (il ImageList) MarshalJSON() ([]byte, error) {
   345  	objectMap := make(map[string]interface{})
   346  	if il.ID != nil {
   347  		objectMap["Id"] = il.ID
   348  	}
   349  	if il.Name != nil {
   350  		objectMap["Name"] = il.Name
   351  	}
   352  	if il.Description != nil {
   353  		objectMap["Description"] = il.Description
   354  	}
   355  	if il.Metadata != nil {
   356  		objectMap["Metadata"] = il.Metadata
   357  	}
   358  	return json.Marshal(objectMap)
   359  }
   360  
   361  // ImageURL ...
   362  type ImageURL struct {
   363  	DataRepresentation *string `json:"DataRepresentation,omitempty"`
   364  	Value              *string `json:"Value,omitempty"`
   365  }
   366  
   367  // IPA IP Address details.
   368  type IPA struct {
   369  	// SubType - Subtype of the detected IP Address.
   370  	SubType *string `json:"SubType,omitempty"`
   371  	// Text - Detected IP Address.
   372  	Text *string `json:"Text,omitempty"`
   373  	// Index - Index(Location) of the IP Address in the input text content.
   374  	Index *int32 `json:"Index,omitempty"`
   375  }
   376  
   377  // Job the Job object.
   378  type Job struct {
   379  	autorest.Response `json:"-"`
   380  	// ID - The job id.
   381  	ID *string `json:"Id,omitempty"`
   382  	// TeamName - The team name associated with the job.
   383  	TeamName *string `json:"TeamName,omitempty"`
   384  	// Status - The status string (<Pending, Failed, Completed>).
   385  	Status *string `json:"Status,omitempty"`
   386  	// WorkflowID - The Id of the workflow.
   387  	WorkflowID *string `json:"WorkflowId,omitempty"`
   388  	// Type - Type of the content.
   389  	Type *string `json:"Type,omitempty"`
   390  	// CallBackEndpoint - The callback endpoint.
   391  	CallBackEndpoint *string `json:"CallBackEndpoint,omitempty"`
   392  	// ReviewID - Review Id if one is created.
   393  	ReviewID *string `json:"ReviewId,omitempty"`
   394  	// ResultMetaData - Array of KeyValue pairs.
   395  	ResultMetaData *[]KeyValuePair `json:"ResultMetaData,omitempty"`
   396  	// JobExecutionReport - Job execution report- Array of KeyValue pairs object.
   397  	JobExecutionReport *[]JobExecutionReportDetails `json:"JobExecutionReport,omitempty"`
   398  }
   399  
   400  // JobExecutionReportDetails job Execution Report Values.
   401  type JobExecutionReportDetails struct {
   402  	// Ts - Time details.
   403  	Ts *string `json:"Ts,omitempty"`
   404  	// Msg - Message details.
   405  	Msg *string `json:"Msg,omitempty"`
   406  }
   407  
   408  // JobID ...
   409  type JobID struct {
   410  	autorest.Response `json:"-"`
   411  	// JobID - Id of the created job.
   412  	JobID *string `json:"JobId,omitempty"`
   413  }
   414  
   415  // JobListResult the list of job ids.
   416  type JobListResult struct {
   417  	// Value - The job id.
   418  	Value *[]string `json:"Value,omitempty"`
   419  }
   420  
   421  // KeyValuePair the key value pair object properties.
   422  type KeyValuePair struct {
   423  	// Key - The key parameter.
   424  	Key *string `json:"Key,omitempty"`
   425  	// Value - The value parameter.
   426  	Value *string `json:"Value,omitempty"`
   427  }
   428  
   429  // ListImageList ...
   430  type ListImageList struct {
   431  	autorest.Response `json:"-"`
   432  	Value             *[]ImageList `json:"value,omitempty"`
   433  }
   434  
   435  // ListString ...
   436  type ListString struct {
   437  	autorest.Response `json:"-"`
   438  	Value             *[]string `json:"value,omitempty"`
   439  }
   440  
   441  // ListTermList ...
   442  type ListTermList struct {
   443  	autorest.Response `json:"-"`
   444  	Value             *[]TermList `json:"value,omitempty"`
   445  }
   446  
   447  // Match the match details.
   448  type Match struct {
   449  	// Score - Confidence score of the image match.
   450  	Score *float64 `json:"Score,omitempty"`
   451  	// MatchID - The match id.
   452  	MatchID *int32 `json:"MatchId,omitempty"`
   453  	// Source - The source.
   454  	Source *string `json:"Source,omitempty"`
   455  	// Tags - The tags for match details.
   456  	Tags *[]int32 `json:"Tags,omitempty"`
   457  	// Label - The label.
   458  	Label *string `json:"Label,omitempty"`
   459  }
   460  
   461  // MatchResponse the response for a Match request.
   462  type MatchResponse struct {
   463  	autorest.Response `json:"-"`
   464  	// TrackingID - The tracking id.
   465  	TrackingID *string `json:"TrackingId,omitempty"`
   466  	// CacheID - The cache id.
   467  	CacheID *string `json:"CacheID,omitempty"`
   468  	// IsMatch - Indicates if there is a match.
   469  	IsMatch *bool `json:"IsMatch,omitempty"`
   470  	// Matches - The match details.
   471  	Matches *[]Match `json:"Matches,omitempty"`
   472  	// Status - The evaluate status
   473  	Status *Status `json:"Status,omitempty"`
   474  }
   475  
   476  // OCR contains the text found in image for the language specified.
   477  type OCR struct {
   478  	autorest.Response `json:"-"`
   479  	// Status - The evaluate status
   480  	Status *Status `json:"Status,omitempty"`
   481  	// Metadata - Array of KeyValue.
   482  	Metadata *[]KeyValuePair `json:"Metadata,omitempty"`
   483  	// TrackingID - The tracking id.
   484  	TrackingID *string `json:"TrackingId,omitempty"`
   485  	// CacheID - The cache id.
   486  	CacheID *string `json:"CacheId,omitempty"`
   487  	// Language - The ISO 639-3 code.
   488  	Language *string `json:"Language,omitempty"`
   489  	// Text - The found text.
   490  	Text *string `json:"Text,omitempty"`
   491  	// Candidates - The list of candidate text.
   492  	Candidates *[]Candidate `json:"Candidates,omitempty"`
   493  }
   494  
   495  // Phone phone Property details.
   496  type Phone struct {
   497  	// CountryCode - CountryCode of the detected Phone number.
   498  	CountryCode *string `json:"CountryCode,omitempty"`
   499  	// Text - Detected Phone number.
   500  	Text *string `json:"Text,omitempty"`
   501  	// Index - Index(Location) of the Phone number in the input text content.
   502  	Index *int32 `json:"Index,omitempty"`
   503  }
   504  
   505  // PII personal Identifier Information details.
   506  type PII struct {
   507  	Email   *[]Email   `json:"Email,omitempty"`
   508  	SSN     *[]SSN     `json:"SSN,omitempty"`
   509  	IPA     *[]IPA     `json:"IPA,omitempty"`
   510  	Phone   *[]Phone   `json:"Phone,omitempty"`
   511  	Address *[]Address `json:"Address,omitempty"`
   512  }
   513  
   514  // RefreshIndex refresh Index Response.
   515  type RefreshIndex struct {
   516  	autorest.Response `json:"-"`
   517  	// ContentSourceID - Content source Id.
   518  	ContentSourceID *string `json:"ContentSourceId,omitempty"`
   519  	// IsUpdateSuccess - Update success status.
   520  	IsUpdateSuccess *bool `json:"IsUpdateSuccess,omitempty"`
   521  	// AdvancedInfo - Advanced info list.
   522  	AdvancedInfo *[]map[string]*string `json:"AdvancedInfo,omitempty"`
   523  	// Status - Refresh index status.
   524  	Status *Status `json:"Status,omitempty"`
   525  	// TrackingID - Tracking Id.
   526  	TrackingID *string `json:"TrackingId,omitempty"`
   527  }
   528  
   529  // Review the Review object.
   530  type Review struct {
   531  	autorest.Response `json:"-"`
   532  	// ReviewID - Id of the review.
   533  	ReviewID *string `json:"ReviewId,omitempty"`
   534  	// SubTeam - Name of the subteam.
   535  	SubTeam *string `json:"SubTeam,omitempty"`
   536  	// Status - The status string (<Pending, Complete>).
   537  	Status *string `json:"Status,omitempty"`
   538  	// ReviewerResultTags - Array of KeyValue with Reviewer set Tags.
   539  	ReviewerResultTags *[]KeyValuePair `json:"ReviewerResultTags,omitempty"`
   540  	// CreatedBy - The reviewer name.
   541  	CreatedBy *string `json:"CreatedBy,omitempty"`
   542  	// Metadata - Array of KeyValue.
   543  	Metadata *[]KeyValuePair `json:"Metadata,omitempty"`
   544  	// Type - The type of content.
   545  	Type *string `json:"Type,omitempty"`
   546  	// Content - The content value.
   547  	Content *string `json:"Content,omitempty"`
   548  	// ContentID - Id of the content.
   549  	ContentID *string `json:"ContentId,omitempty"`
   550  	// CallbackEndpoint - The callback endpoint.
   551  	CallbackEndpoint *string `json:"CallbackEndpoint,omitempty"`
   552  }
   553  
   554  // Screen the response for a Screen text request.
   555  type Screen struct {
   556  	autorest.Response `json:"-"`
   557  	// OriginalText - The original text.
   558  	OriginalText *string `json:"OriginalText,omitempty"`
   559  	// NormalizedText - The normalized text.
   560  	NormalizedText *string `json:"NormalizedText,omitempty"`
   561  	// AutoCorrectedText - The autocorrected text
   562  	AutoCorrectedText *string `json:"AutoCorrectedText,omitempty"`
   563  	// Misrepresentation - The misrepresentation text.
   564  	Misrepresentation *[]string `json:"Misrepresentation,omitempty"`
   565  	// Classification - The classification details of the text.
   566  	Classification *Classification `json:"Classification,omitempty"`
   567  	// Status - The evaluate status.
   568  	Status *Status `json:"Status,omitempty"`
   569  	// PII - Personal Identifier Information details.
   570  	PII *PII `json:"PII,omitempty"`
   571  	// Language - Language of the input text content.
   572  	Language *string          `json:"Language,omitempty"`
   573  	Terms    *[]DetectedTerms `json:"Terms,omitempty"`
   574  	// TrackingID - Unique Content Moderator transaction Id.
   575  	TrackingID *string `json:"TrackingId,omitempty"`
   576  }
   577  
   578  // SSN detected SSN details.
   579  type SSN struct {
   580  	// Text - Detected SSN in the input text content.
   581  	Text *string `json:"Text,omitempty"`
   582  	// Index - Index(Location) of the SSN in the input text content.
   583  	Index *int32 `json:"Index,omitempty"`
   584  }
   585  
   586  // Status status properties.
   587  type Status struct {
   588  	// Code - Status code.
   589  	Code *int32 `json:"Code,omitempty"`
   590  	// Description - Status description.
   591  	Description *string `json:"Description,omitempty"`
   592  	// Exception - Exception status.
   593  	Exception *string `json:"Exception,omitempty"`
   594  }
   595  
   596  // String ...
   597  type String struct {
   598  	autorest.Response `json:"-"`
   599  	Value             *string `json:"value,omitempty"`
   600  }
   601  
   602  // Tag tag details.
   603  type Tag struct {
   604  	// Key - The key parameter.
   605  	Key *string `json:"Key,omitempty"`
   606  	// Value - The value parameter.
   607  	Value *string `json:"Value,omitempty"`
   608  }
   609  
   610  // TermList term List  Properties.
   611  type TermList struct {
   612  	autorest.Response `json:"-"`
   613  	// ID - Term list Id.
   614  	ID *int32 `json:"Id,omitempty"`
   615  	// Name - Term list name.
   616  	Name *string `json:"Name,omitempty"`
   617  	// Description - Description for term list.
   618  	Description *string `json:"Description,omitempty"`
   619  	// Metadata - Term list metadata.
   620  	Metadata map[string]*string `json:"Metadata"`
   621  }
   622  
   623  // MarshalJSON is the custom marshaler for TermList.
   624  func (tl TermList) MarshalJSON() ([]byte, error) {
   625  	objectMap := make(map[string]interface{})
   626  	if tl.ID != nil {
   627  		objectMap["Id"] = tl.ID
   628  	}
   629  	if tl.Name != nil {
   630  		objectMap["Name"] = tl.Name
   631  	}
   632  	if tl.Description != nil {
   633  		objectMap["Description"] = tl.Description
   634  	}
   635  	if tl.Metadata != nil {
   636  		objectMap["Metadata"] = tl.Metadata
   637  	}
   638  	return json.Marshal(objectMap)
   639  }
   640  
   641  // Terms terms properties.
   642  type Terms struct {
   643  	autorest.Response `json:"-"`
   644  	// Data - Term data details.
   645  	Data *TermsData `json:"Data,omitempty"`
   646  	// Paging - Paging details.
   647  	Paging *TermsPaging `json:"Paging,omitempty"`
   648  }
   649  
   650  // TermsData all term Id response properties.
   651  type TermsData struct {
   652  	// Language - Language of the terms.
   653  	Language *string `json:"Language,omitempty"`
   654  	// Terms - List of terms.
   655  	Terms *[]TermsInList `json:"Terms,omitempty"`
   656  	// Status - Term Status.
   657  	Status *Status `json:"Status,omitempty"`
   658  	// TrackingID - Tracking Id.
   659  	TrackingID *string `json:"TrackingId,omitempty"`
   660  }
   661  
   662  // TermsInList terms in list Id passed.
   663  type TermsInList struct {
   664  	// Term - Added term details.
   665  	Term *string `json:"Term,omitempty"`
   666  }
   667  
   668  // TermsPaging paging details.
   669  type TermsPaging struct {
   670  	// Total - Total details.
   671  	Total *int32 `json:"Total,omitempty"`
   672  	// Limit - Limit details.
   673  	Limit *int32 `json:"Limit,omitempty"`
   674  	// Offset - Offset details.
   675  	Offset *int32 `json:"Offset,omitempty"`
   676  	// Returned - Returned text details.
   677  	Returned *int32 `json:"Returned,omitempty"`
   678  }
   679  
   680  // TranscriptModerationBodyItem schema items of the body.
   681  type TranscriptModerationBodyItem struct {
   682  	// Timestamp - Timestamp of the image.
   683  	Timestamp *string `json:"Timestamp,omitempty"`
   684  	// Terms - Optional metadata details.
   685  	Terms *[]TranscriptModerationBodyItemTermsItem `json:"Terms,omitempty"`
   686  }
   687  
   688  // TranscriptModerationBodyItemTermsItem ...
   689  type TranscriptModerationBodyItemTermsItem struct {
   690  	// Index - Index of the word
   691  	Index *int32 `json:"Index,omitempty"`
   692  	// Term - Detected word.
   693  	Term *string `json:"Term,omitempty"`
   694  }
   695  
   696  // VideoFrameBodyItem schema items of the body.
   697  type VideoFrameBodyItem struct {
   698  	// Timestamp - Timestamp of the frame.
   699  	Timestamp *string `json:"Timestamp,omitempty"`
   700  	// FrameImage - Content to review.
   701  	FrameImage         *string                                     `json:"FrameImage,omitempty"`
   702  	ReviewerResultTags *[]VideoFrameBodyItemReviewerResultTagsItem `json:"ReviewerResultTags,omitempty"`
   703  	// Metadata - Optional metadata details.
   704  	Metadata *[]VideoFrameBodyItemMetadataItem `json:"Metadata,omitempty"`
   705  }
   706  
   707  // VideoFrameBodyItemMetadataItem ...
   708  type VideoFrameBodyItemMetadataItem struct {
   709  	// Key - Your key parameter.
   710  	Key *string `json:"Key,omitempty"`
   711  	// Value - Your value parameter.
   712  	Value *string `json:"Value,omitempty"`
   713  }
   714  
   715  // VideoFrameBodyItemReviewerResultTagsItem ...
   716  type VideoFrameBodyItemReviewerResultTagsItem struct {
   717  	// Key - Your key parameter.
   718  	Key *string `json:"Key,omitempty"`
   719  	// Value - Your value parameter.
   720  	Value *string `json:"Value,omitempty"`
   721  }
   722  

View as plain text