voicebase

package
v2.3.1+incompatible Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 4, 2018 License: MIT Imports: 20 Imported by: 0

README

Go API client for voicebase

APIs for speech recognition and speech analytics, powering insights every business needs.

Overview

This API client was generated by the swagger-codegen project. By using the swagger-spec from a remote server, you can easily generate an API client.

Installation

Put the package under your project folder and add the following in import:

    "./voicebase"

Documentation for API Endpoints

All URIs are relative to https://apis.voicebase.com

Class Method HTTP request Description
DefinitionApi CreateKeywordSpottingGroup Put /v3/definition/spotting/groups/{groupId} Create or update keyword spotting group
DefinitionApi CreateVocabulary Put /v3/definition/vocabularies/{vocabularyId} Create or update a custom vocabulary
DefinitionApi DeleteKeywordSpottingGroupById Delete /v3/definition/spotting/groups/{groupId} Delete keyword spotting group
DefinitionApi DeleteVocabularyById Delete /v3/definition/vocabularies/{vocabularyId} Delete a custom vocabulary
DefinitionApi GetClassifier Get /v3/definition/prediction/classifiers/{classifierId} Retrieve details about a predictive classification model
DefinitionApi GetClassifiers Get /v3/definition/prediction/classifiers List predictive classification models
DefinitionApi GetDetector Get /v3/definition/prediction/detectors/{detectorId} Retrieve details about a detection model
DefinitionApi GetDetectors Get /v3/definition/prediction/detectors List detection models
DefinitionApi GetKeywordSpottingGroupById Get /v3/definition/spotting/groups/{groupId} Retrieve a keyword spotting Group
DefinitionApi GetKeywordSpottingGroups Get /v3/definition/spotting/groups List keyword spotting groups
DefinitionApi GetSearchableFields Get /v3/definition/media/search Retrieve the list of extended metadata searchable fields
DefinitionApi GetVocabularies Get /v3/definition/vocabularies List custom vocabularies
DefinitionApi GetVocabularyById Get /v3/definition/vocabularies/{vocabularyId} Retrieve a custom vocabulary.
DefinitionApi SetSearchableFields Put /v3/definition/media/search Define extended metadata searchable fields
KeyManagementApi CreateKey Post /v3/profile/keys Create API Key
KeyManagementApi DeleteKeyById Delete /v3/profile/keys/{keyId} Delete API key
KeyManagementApi GetKeyById Get /v3/profile/keys/{keyId} Retrieve details about an API key
KeyManagementApi GetKeys Get /v3/profile/keys List API Keys
MediaApi DeleteMediaById Delete /v3/media/{mediaId} Delete a media, transcripts and analytics results
MediaApi GetMediaById Get /v3/media/{mediaId} Retrieve transcript and analytical results from a media record
MediaApi GetMetadataById Get /v3/media/{mediaId}/metadata Retrieve metadata associated with a media record
MediaApi GetProgressById Get /v3/media/{mediaId}/progress Retrieve processing progress
MediaApi GetStreamByMediaIdAndName Get /v3/media/{mediaId}/streams/{streamName} Downloads the media identified by the stream name
MediaApi GetStreamsById Get /v3/media/{mediaId}/streams List streams
MediaApi GetSubtitleDfxpById Get /v3/media/{mediaId}/transcript/dfxp Retrieve DFXP transcript
MediaApi GetSubtitleWebVttById Get /v3/media/{mediaId}/transcript/webvtt Retrieve WEBVTT transcript
MediaApi GetSubtitlesById Get /v3/media/{mediaId}/transcript/srt Retrieve SRT transcript
MediaApi GetTextById Get /v3/media/{mediaId}/transcript/text Retrieve text transcript
MediaApi GetTranscript Get /v3/media/{mediaId}/transcript Retrieve transcript
MediaApi MediaQuery Get /v3/media List media records
MediaApi PostMedia Post /v3/media Upload a media file for transcription and analysis
MediaApi PostMediaById Post /v3/media/{mediaId} Align a transcript and re-run the job
MediaApi SetMetadataById Put /v3/media/{mediaId}/metadata Update media metadata

Documentation For Models

Documentation For Authorization

Authorization

  • Type: API key

Example

	auth := context.WithValue(context.Background(), sw.ContextAPIKey, sw.APIKey{
		Key: "APIKEY",
		Prefix: "Bearer", // Omit if not necessary.
	})
    r, err := client.Service.Operation(auth, args)

Author

support@voicebase.com

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// ContextOAuth2 takes a oauth2.TokenSource as authentication for the request.
	ContextOAuth2 = contextKey("token")

	// ContextBasicAuth takes BasicAuth as authentication for the request.
	ContextBasicAuth = contextKey("basic")

	// ContextAccessToken takes a string oauth2 access token as authentication for the request.
	ContextAccessToken = contextKey("accesstoken")

	// ContextAPIKey takes an APIKey as authentication for the request
	ContextAPIKey = contextKey("apikey")
)

Functions

func CacheExpires

func CacheExpires(r *http.Response) time.Time

CacheExpires helper function to determine remaining time before repeating a request.

Types

type APIClient

type APIClient struct {

	// API Services
	DefinitionApi    *DefinitionApiService
	KeyManagementApi *KeyManagementApiService
	MediaApi         *MediaApiService
	// contains filtered or unexported fields
}

APIClient manages communication with the Voicebase V3 API API v3.0.1 In most cases there should be only one, shared, APIClient.

func NewAPIClient

func NewAPIClient(cfg *Configuration) *APIClient

NewAPIClient creates a new API client. Requires a userAgent string describing your application. optionally a custom http.Client to allow for advanced features such as caching.

func (*APIClient) ChangeBasePath

func (c *APIClient) ChangeBasePath(path string)

Change base path to allow switching to mocks

type APIKey

type APIKey struct {
	Key    string
	Prefix string
}

APIKey provides API key based authentication to a request passed via context using ContextAPIKey

type APIResponse

type APIResponse struct {
	*http.Response `json:"-"`
	Message        string `json:"message,omitempty"`
	// Operation is the name of the swagger operation.
	Operation string `json:"operation,omitempty"`
	// RequestURL is the request URL. This value is always available, even if the
	// embedded *http.Response is nil.
	RequestURL string `json:"url,omitempty"`
	// Method is the HTTP method used for the request.  This value is always
	// available, even if the embedded *http.Response is nil.
	Method string `json:"method,omitempty"`
	// Payload holds the contents of the response body (which may be nil or empty).
	// This is provided here as the raw response.Body() reader will have already
	// been drained.
	Payload []byte `json:"-"`
}

func NewAPIResponse

func NewAPIResponse(r *http.Response) *APIResponse

func NewAPIResponseWithError

func NewAPIResponseWithError(errorMessage string) *APIResponse

type BasicAuth

type BasicAuth struct {
	UserName string `json:"userName,omitempty"`
	Password string `json:"password,omitempty"`
}

BasicAuth provides basic http authentication to a request passed via context using ContextBasicAuth

type Configuration

type Configuration struct {
	BasePath      string            `json:"basePath,omitempty"`
	Host          string            `json:"host,omitempty"`
	Scheme        string            `json:"scheme,omitempty"`
	DefaultHeader map[string]string `json:"defaultHeader,omitempty"`
	UserAgent     string            `json:"userAgent,omitempty"`
	HTTPClient    *http.Client
}

func NewConfiguration

func NewConfiguration() *Configuration

func (*Configuration) AddDefaultHeader

func (c *Configuration) AddDefaultHeader(key string, value string)

type DefinitionApiService

type DefinitionApiService service

func (*DefinitionApiService) CreateKeywordSpottingGroup

func (a *DefinitionApiService) CreateKeywordSpottingGroup(ctx context.Context, groupId string, keywordSpottingGroup VbKeywordGroup) (VbKeywordGroup, *http.Response, error)
DefinitionApiService Create or update keyword spotting group

Create or update a keyword spotting group with a set of keywords * @param ctx context.Context for authentication, logging, tracing, etc. @param groupId The keyword spotting group identifier. @param keywordSpottingGroup Keyword Spotting Group definition @return VbKeywordGroup

func (*DefinitionApiService) CreateVocabulary

func (a *DefinitionApiService) CreateVocabulary(ctx context.Context, vocabularyId string, vocabulary VbVocabulary) (VbVocabulary, *http.Response, error)
DefinitionApiService Create or update a custom vocabulary

Create or update a custom vocabulary. Custom vocabularies are used to improve accurary of transcription * @param ctx context.Context for authentication, logging, tracing, etc. @param vocabularyId The vocabulary identifier (name). @param vocabulary Vocabulary defintion. @return VbVocabulary

func (*DefinitionApiService) DeleteKeywordSpottingGroupById

func (a *DefinitionApiService) DeleteKeywordSpottingGroupById(ctx context.Context, groupId string) (*http.Response, error)
DefinitionApiService Delete keyword spotting group

Delete the keyword spotting group * @param ctx context.Context for authentication, logging, tracing, etc. @param groupId The keyword spotting group identifier. @return

func (*DefinitionApiService) DeleteVocabularyById

func (a *DefinitionApiService) DeleteVocabularyById(ctx context.Context, vocabularyId string) (*http.Response, error)
DefinitionApiService Delete a custom vocabulary

Delete a custom vocabulary * @param ctx context.Context for authentication, logging, tracing, etc. @param vocabularyId The vocabulary identifier (name) @return

func (*DefinitionApiService) GetClassifier

func (a *DefinitionApiService) GetClassifier(ctx context.Context, classifierId string) (VbClassifierModel, *http.Response, error)
DefinitionApiService Retrieve details about a predictive classification model

Get the classifier model * @param ctx context.Context for authentication, logging, tracing, etc. @param classifierId The classifier model identifier. @return VbClassifierModel

func (*DefinitionApiService) GetClassifiers

DefinitionApiService List predictive classification models

List available predictive models for classification * @param ctx context.Context for authentication, logging, tracing, etc. @return VbClassifierModelsResponse

func (*DefinitionApiService) GetDetector

func (a *DefinitionApiService) GetDetector(ctx context.Context, detectorId string) (VbDetectorModel, *http.Response, error)
DefinitionApiService Retrieve details about a detection model

Retrieve details about a detection model * @param ctx context.Context for authentication, logging, tracing, etc. @param detectorId The detector model identifier. @return VbDetectorModel

func (*DefinitionApiService) GetDetectors

DefinitionApiService List detection models

List available detection models * @param ctx context.Context for authentication, logging, tracing, etc. @return VbDetectorModelsResponse

func (*DefinitionApiService) GetKeywordSpottingGroupById

func (a *DefinitionApiService) GetKeywordSpottingGroupById(ctx context.Context, groupId string) (VbKeywordGroup, *http.Response, error)
DefinitionApiService Retrieve a keyword spotting Group

Retrieve a keyword spotting group with its keywords * @param ctx context.Context for authentication, logging, tracing, etc. @param groupId Keyword spotting group identifier @return VbKeywordGroup

func (*DefinitionApiService) GetKeywordSpottingGroups

func (a *DefinitionApiService) GetKeywordSpottingGroups(ctx context.Context) (VbKeywordGroupsResponse, *http.Response, error)
DefinitionApiService List keyword spotting groups

Get all defined keyword spotting groups * @param ctx context.Context for authentication, logging, tracing, etc. @return VbKeywordGroupsResponse

func (*DefinitionApiService) GetSearchableFields

func (a *DefinitionApiService) GetSearchableFields(ctx context.Context) (VbSearchableFields, *http.Response, error)
DefinitionApiService Retrieve the list of extended metadata searchable fields

Get searchable fields * @param ctx context.Context for authentication, logging, tracing, etc. @return VbSearchableFields

func (*DefinitionApiService) GetVocabularies

DefinitionApiService List custom vocabularies

List all defined custom vocabularies. Custom vocabularies are used to improve accurary of transcription * @param ctx context.Context for authentication, logging, tracing, etc. @return VbVocabulariesResponse

func (*DefinitionApiService) GetVocabularyById

func (a *DefinitionApiService) GetVocabularyById(ctx context.Context, vocabularyId string) (VbVocabulary, *http.Response, error)
DefinitionApiService Retrieve a custom vocabulary.

Retrieve a custom vocabulary * @param ctx context.Context for authentication, logging, tracing, etc. @param vocabularyId The vocabulary identifier (name) @return VbVocabulary

func (*DefinitionApiService) SetSearchableFields

func (a *DefinitionApiService) SetSearchableFields(ctx context.Context, searchableFields VbSearchableFields) (VbSearchableFields, *http.Response, error)
DefinitionApiService Define extended metadata searchable fields

Create or update custom parameters of metadata for search * @param ctx context.Context for authentication, logging, tracing, etc. @param searchableFields Key config. @return VbSearchableFields

type KeyManagementApiService

type KeyManagementApiService service

func (*KeyManagementApiService) CreateKey

KeyManagementApiService Create API Key

Create a new API key for the current user * @param ctx context.Context for authentication, logging, tracing, etc. @param key Key config. @return VbKey

func (*KeyManagementApiService) DeleteKeyById

func (a *KeyManagementApiService) DeleteKeyById(ctx context.Context, keyId string) (*http.Response, error)
KeyManagementApiService Delete API key

Delete and revoke this API key * @param ctx context.Context for authentication, logging, tracing, etc. @param keyId The key Id. @return

func (*KeyManagementApiService) GetKeyById

func (a *KeyManagementApiService) GetKeyById(ctx context.Context, keyId string) (VbKey, *http.Response, error)
KeyManagementApiService Retrieve details about an API key

Get information about this API key * @param ctx context.Context for authentication, logging, tracing, etc. @param keyId The key Id. @return VbKey

func (*KeyManagementApiService) GetKeys

KeyManagementApiService List API Keys

Returns all current API keys for current user * @param ctx context.Context for authentication, logging, tracing, etc. @return VbKeysResponse

type MediaApiService

type MediaApiService service

func (*MediaApiService) DeleteMediaById

func (a *MediaApiService) DeleteMediaById(ctx context.Context, mediaId string) (*http.Response, error)
MediaApiService Delete a media, transcripts and analytics results

Delete this media * @param ctx context.Context for authentication, logging, tracing, etc. @param mediaId Media identifier, a UUID. @return

func (*MediaApiService) GetMediaById

func (a *MediaApiService) GetMediaById(ctx context.Context, mediaId string, localVarOptionals map[string]interface{}) (VbMedia, *http.Response, error)
MediaApiService Retrieve transcript and analytical results from a media record

Retrieve analytical results from a previously uploaded media * @param ctx context.Context for authentication, logging, tracing, etc. @param mediaId Media identifier, a UUID. @param optional (nil or map[string]interface{}) with one or more of:

@param "includeAlternateFormat" ([]string) Set of alternate formats to include in the response

@return VbMedia

func (*MediaApiService) GetMetadataById

func (a *MediaApiService) GetMetadataById(ctx context.Context, mediaId string) (VbMetadata, *http.Response, error)
MediaApiService Retrieve metadata associated with a media record

Retrieve the media metadata * @param ctx context.Context for authentication, logging, tracing, etc. @param mediaId Media identifier, a UUID. @return VbMetadata

func (*MediaApiService) GetProgressById

func (a *MediaApiService) GetProgressById(ctx context.Context, mediaId string) (VbJob, *http.Response, error)
MediaApiService Retrieve processing progress

Retrieve processing progress for a given media * @param ctx context.Context for authentication, logging, tracing, etc. @param mediaId Media identifier, a UUID. @return VbJob

func (*MediaApiService) GetStreamByMediaIdAndName

func (a *MediaApiService) GetStreamByMediaIdAndName(ctx context.Context, mediaId string, streamName string) (VbStream, *http.Response, error)
MediaApiService Downloads the media identified by the stream name

Returns a redirect to the named media stream * @param ctx context.Context for authentication, logging, tracing, etc. @param mediaId Media identifier, a UUID. @param streamName A stream name @return VbStream

func (*MediaApiService) GetStreamsById

func (a *MediaApiService) GetStreamsById(ctx context.Context, mediaId string) (VbStreams, *http.Response, error)
MediaApiService List streams

Get list of available media URLs * @param ctx context.Context for authentication, logging, tracing, etc. @param mediaId Media identifier, a UUID. @return VbStreams

func (*MediaApiService) GetSubtitleDfxpById

func (a *MediaApiService) GetSubtitleDfxpById(ctx context.Context, mediaId string) (string, *http.Response, error)
MediaApiService Retrieve DFXP transcript

Retrieve the transcript from a given media in DFXP format * @param ctx context.Context for authentication, logging, tracing, etc. @param mediaId Media identifier, a UUID. @return string

func (*MediaApiService) GetSubtitleWebVttById

func (a *MediaApiService) GetSubtitleWebVttById(ctx context.Context, mediaId string) (string, *http.Response, error)
MediaApiService Retrieve WEBVTT transcript

Retrieve the transcript from a given media in WEBVTT format * @param ctx context.Context for authentication, logging, tracing, etc. @param mediaId Media identifier, a UUID. @return string

func (*MediaApiService) GetSubtitlesById

func (a *MediaApiService) GetSubtitlesById(ctx context.Context, mediaId string) (string, *http.Response, error)
MediaApiService Retrieve SRT transcript

Retrieve the transcript from a given media in SRT (subtitles) format * @param ctx context.Context for authentication, logging, tracing, etc. @param mediaId Media identifier, a UUID. @return string

func (*MediaApiService) GetTextById

func (a *MediaApiService) GetTextById(ctx context.Context, mediaId string) (string, *http.Response, error)
MediaApiService Retrieve text transcript

Retrieve the transcript from a given media in plain text format * @param ctx context.Context for authentication, logging, tracing, etc. @param mediaId Media identifier, a UUID. @return string

func (*MediaApiService) GetTranscript

func (a *MediaApiService) GetTranscript(ctx context.Context, mediaId string, localVarOptionals map[string]interface{}) (VbTranscript, *http.Response, error)
MediaApiService Retrieve transcript

Retrieve the transcript from a given media * @param ctx context.Context for authentication, logging, tracing, etc. @param mediaId Get media by Id. @param optional (nil or map[string]interface{}) with one or more of:

@param "includeAlternateFormat" ([]string) Set of alternate formats to include in the response

@return VbTranscript

func (*MediaApiService) MediaQuery

func (a *MediaApiService) MediaQuery(ctx context.Context, localVarOptionals map[string]interface{}) (VbMediaQueryResponse, *http.Response, error)
MediaApiService List media records

Retrieve a list of media previously uploaded that match a criteria * @param ctx context.Context for authentication, logging, tracing, etc. @param optional (nil or map[string]interface{}) with one or more of:

@param "query" (string) The full text search
@param "externalId" (string) Media tagged with externalId in the metadata.
@param "before" (string) Find media created before this mediaId
@param "after" (string) Find media created after this mediaId
@param "extendedFilter" ([]string) A special filter which is of the form 'extendedFilter=Name;Value' which allows you to filter by extended metadata.
@param "onOrAfterDate" (time.Time) Media created on or after date.
@param "onOrBeforeDate" (time.Time) Media created on or before date.
@param "sortOrder" (string) Sort order.
@param "limit" (int32) Control the number of values returned.

@return VbMediaQueryResponse

func (*MediaApiService) PostMedia

func (a *MediaApiService) PostMedia(ctx context.Context, localVarOptionals map[string]interface{}) (VbMedia, *http.Response, error)
MediaApiService Upload a media file for transcription and analysis

Upload new new media to the service as an attachment or from a url * @param ctx context.Context for authentication, logging, tracing, etc. @param optional (nil or map[string]interface{}) with one or more of:

@param "media" (*os.File) Media file attached to the request.
@param "mediaUrl" (string) URL where media file can be downloaded.
@param "configuration" (string) A JSON object with configuration options.
@param "metadata" (string) Metadata about the file being posted.
@param "transcript" (string) A transcript

@return VbMedia

func (*MediaApiService) PostMediaById

func (a *MediaApiService) PostMediaById(ctx context.Context, mediaId string, localVarOptionals map[string]interface{}) (VbMedia, *http.Response, error)
MediaApiService Align a transcript and re-run the job

Upload a transcript to the service as an attachment for alignment and re-running of the job * @param ctx context.Context for authentication, logging, tracing, etc. @param mediaId A JSON object with configuration options. @param optional (nil or map[string]interface{}) with one or more of:

@param "configuration" (string) A JSON object with configuration options.
@param "metadata" (string) Metadata about the file being posted.
@param "transcript" (string) A transcript

@return VbMedia

func (*MediaApiService) SetMetadataById

func (a *MediaApiService) SetMetadataById(ctx context.Context, mediaId string, metadata VbMetadata) (VbMetadata, *http.Response, error)
MediaApiService Update media metadata

Set or update the media metadata * @param ctx context.Context for authentication, logging, tracing, etc. @param mediaId Get media by Id. @param metadata metadata. @return VbMetadata

type VbAudioRedactorConfiguration

type VbAudioRedactorConfiguration struct {
	Tone int32 `json:"tone,omitempty"`

	Gain float32 `json:"gain,omitempty"`
}

Sound attributes to replace spoken words in the audio when reported by a detector

type VbCallbackConfiguration

type VbCallbackConfiguration struct {
	Url string `json:"url,omitempty"`

	Method *VbHttpMethodEnum `json:"method,omitempty"`

	Type_ *VbCallbackTypeEnum `json:"type,omitempty"`

	Include []VbIncludeTypeEnum `json:"include,omitempty"`

	Stream *VbCallbackStreamEnum `json:"stream,omitempty"`

	Format *VbCallbackFormatEnum `json:"format,omitempty"`
}

type VbCallbackFormatEnum

type VbCallbackFormatEnum string
const (
	JSON   VbCallbackFormatEnum = "json"
	TEXT   VbCallbackFormatEnum = "text"
	SRT    VbCallbackFormatEnum = "srt"
	WEBVTT VbCallbackFormatEnum = "webvtt"
	DFXP   VbCallbackFormatEnum = "dfxp"
)

List of VbCallbackFormatEnum

type VbCallbackStreamEnum

type VbCallbackStreamEnum string
const (
	ORIGINAL       VbCallbackStreamEnum = "original"
	REDACTED_AUDIO VbCallbackStreamEnum = "redacted-audio"
)

List of VbCallbackStreamEnum

type VbCallbackTypeEnum

type VbCallbackTypeEnum string
const (
	ANALYTICS  VbCallbackTypeEnum = "analytics"
	TRANSCRIPT VbCallbackTypeEnum = "transcript"
	MEDIA      VbCallbackTypeEnum = "media"
)

List of VbCallbackTypeEnum

type VbChannelConfiguration

type VbChannelConfiguration struct {

	// Speaker name on this channel. Defaults to \"SpeakerN\" where N is the channel number.
	SpeakerName string `json:"speakerName,omitempty"`

	// A description of the speaker role. Only used as metadata.
	SpeakerRole string `json:"speakerRole,omitempty"`

	// Whether this channel should be ignored for all processing.
	Ignore bool `json:"ignore,omitempty"`
}

type VbClass

type VbClass struct {
	ClassLabel string `json:"classLabel,omitempty"`

	ClassValue int32 `json:"classValue,omitempty"`
}

type VbClassifier

type VbClassifier struct {
	ClassifierId string `json:"classifierId,omitempty"`

	ClassifierName string `json:"classifierName,omitempty"`

	ClassifierDisplayName string `json:"classifierDisplayName,omitempty"`

	ClassifierType string `json:"classifierType,omitempty"`

	PredictedClassLabel string `json:"predictedClassLabel,omitempty"`

	PredictionScore float64 `json:"predictionScore,omitempty"`

	PredictedClass int32 `json:"predictedClass,omitempty"`
}

type VbClassifierConfiguration

type VbClassifierConfiguration struct {

	// Classifier identifier, usually a UUID.
	ClassifierId string `json:"classifierId,omitempty"`

	// A name identifying classifiers offered by Voicebase to all customers
	ClassifierName string `json:"classifierName,omitempty"`

	// Provide a specific version (e.g. \"3.1.3\"), specify a minimum (e.g. \"3.1+\") or get the \"latest\". Defaults to \"latest\" if not specified.
	Version string `json:"version,omitempty"`

	// List of parameter values to the classifier
	Parameters []VbParameter `json:"parameters,omitempty"`
}

type VbClassifierModel

type VbClassifierModel struct {
	ClassifierId string `json:"classifierId,omitempty"`

	// Use this name for referring to the classifier in a configuration provided with the media for processing
	ClassifierName string `json:"classifierName,omitempty"`

	// Use this version in conjuction with the classifier name for referring to this classifier in a configuration provided with the media for processing
	ClassifierVersion string `json:"classifierVersion,omitempty"`

	ClassifierDescription string `json:"classifierDescription,omitempty"`

	ClassifierType string `json:"classifierType,omitempty"`

	// Set of possible classes identified by the classifier
	Classes []VbClass `json:"classes,omitempty"`

	// Set of possible parameters for this classifier
	Parameters []VbParameterDefinition `json:"parameters,omitempty"`
}

type VbClassifierModelsResponse

type VbClassifierModelsResponse struct {
	Classifiers []VbClassifierModel `json:"classifiers,omitempty"`
}

type VbConfiguration

type VbConfiguration struct {
	SpeechModel *VbSpeechModelConfiguration `json:"speechModel,omitempty"`

	// Allows to specify other languages to enable recognition when conversations occur in multiple languages
	AdditionalSpeechModels []VbSpeechModelConfiguration `json:"additionalSpeechModels,omitempty"`

	Priority *VbPriorityEnum `json:"priority,omitempty"`

	Ingest *VbIngestConfiguration `json:"ingest,omitempty"`

	Prediction *VbPredictionConfiguration `json:"prediction,omitempty"`

	Spotting *VbSpottingConfiguration `json:"spotting,omitempty"`

	Knowledge *VbKnowledgeConfiguration `json:"knowledge,omitempty"`

	Transcript *VbTranscriptConfiguration `json:"transcript,omitempty"`

	Vocabularies []VbVocabularyConfiguration `json:"vocabularies,omitempty"`

	Publish *VbPublishConfiguration `json:"publish,omitempty"`
}

type VbContentFilteringConfiguration

type VbContentFilteringConfiguration struct {

	// Whether swear word filtering is enabled or not
	EnableProfanityFiltering bool `json:"enableProfanityFiltering,omitempty"`
}

type VbDetectedSegment

type VbDetectedSegment struct {
	SpeakerName string `json:"speakerName,omitempty"`

	Occurrences []VbOccurrence `json:"occurrences,omitempty"`
}

type VbDetection

type VbDetection struct {
	DetectorClass int32 `json:"detectorClass,omitempty"`

	DetectorClassLabel string `json:"detectorClassLabel,omitempty"`

	DetectedSegments []VbDetectedSegment `json:"detectedSegments,omitempty"`
}

type VbDetector

type VbDetector struct {
	DetectorId string `json:"detectorId,omitempty"`

	DetectorName string `json:"detectorName,omitempty"`

	DetectorDisplayName string `json:"detectorDisplayName,omitempty"`

	DetectorType string `json:"detectorType,omitempty"`

	Detections []VbDetection `json:"detections,omitempty"`
}

type VbDetectorConfiguration

type VbDetectorConfiguration struct {

	// Detector identifier, a UUID
	DetectorId string `json:"detectorId,omitempty"`

	// A name identifying a detector offered by Voicebase to all customers
	DetectorName string `json:"detectorName,omitempty"`

	// Provide a specific version (e.g. \"3.1.3\"), specify a minimum (e.g. \"3.1+\") or get the \"latest\". Defaults to \"latest\" if not specified.
	Version string `json:"version,omitempty"`

	// List of parameter values to the detector
	Parameters []VbParameter `json:"parameters,omitempty"`

	Redactor *VbRedactorConfiguration `json:"redactor,omitempty"`
}

type VbDetectorModel

type VbDetectorModel struct {
	DetectorId string `json:"detectorId,omitempty"`

	// Use this detector name when refering to this detector in a configuration for media processing
	DetectorName string `json:"detectorName,omitempty"`

	// Use this version in conjuction with the detector name for referring to this detector in a configuration provided with the media for processing
	DetectorVersion string `json:"detectorVersion,omitempty"`

	// Describes the function of this detector and its restrictions
	DetectorDescription string `json:"detectorDescription,omitempty"`

	// Detector type, one of ( 'binary', 'multiclass').  Binary detectors only report positive cases.
	DetectorType string `json:"detectorType,omitempty"`

	// Set of possible classes for segments identified by this detector
	Classes []VbClass `json:"classes,omitempty"`

	// Set of possible parameters for this detector
	Parameters []VbParameterDefinition `json:"parameters,omitempty"`
}

type VbDetectorModelsResponse

type VbDetectorModelsResponse struct {
	Detectors []VbDetectorModel `json:"detectors,omitempty"`
}

type VbDiarization

type VbDiarization struct {
	Band string `json:"band,omitempty"`

	Env string `json:"env,omitempty"`

	Gender string `json:"gender,omitempty"`

	Length int64 `json:"length,omitempty"`

	SpeakerLabel string `json:"speakerLabel,omitempty"`

	Start int64 `json:"start,omitempty"`
}

type VbError

type VbError struct {
	Code int32 `json:"code,omitempty"`

	Error_ string `json:"error,omitempty"`
}

type VbErrorResponse

type VbErrorResponse struct {

	// Status Code
	Status int32 `json:"status,omitempty"`

	// The errors
	Errors []VbError `json:"errors,omitempty"`

	// The warnings
	Warnings []VbMessage `json:"warnings,omitempty"`

	// ref.
	Reference string `json:"reference,omitempty"`
}

type VbFormattingConfiguration

type VbFormattingConfiguration struct {

	// Whether number formatting is enabled or not
	EnableNumberFormatting bool `json:"enableNumberFormatting,omitempty"`
}

type VbFrequency

type VbFrequency struct {
	E float64 `json:"e,omitempty"`

	F float64 `json:"f,omitempty"`
}

type VbGroup

type VbGroup struct {
	GroupName string `json:"groupName,omitempty"`

	Spotted bool `json:"spotted,omitempty"`

	Score float64 `json:"score,omitempty"`

	SpottedKeywords []VbKeyword `json:"spottedKeywords,omitempty"`
}

type VbHttpMethodEnum

type VbHttpMethodEnum string
const (
	POST VbHttpMethodEnum = "post"
	PUT  VbHttpMethodEnum = "put"
)

List of VbHttpMethodEnum

type VbIncludeTypeEnum

type VbIncludeTypeEnum string
const (
	INCLUDE_KNOWLEDGE  VbIncludeTypeEnum = "knowledge"
	INCLUDE_METADATA   VbIncludeTypeEnum = "metadata"
	INCLUDE_PREDICTION VbIncludeTypeEnum = "prediction"
	INCLUDE_SPOTTING   VbIncludeTypeEnum = "spotting"
	INCLUDE_STREAMS    VbIncludeTypeEnum = "streams"
	INCLUDE_TRANSCRIPT VbIncludeTypeEnum = "transcript"
)

List of VbIncludeTypeEnum

type VbIngestConfiguration

type VbIngestConfiguration struct {

	// Speaker name. Defaults to \"Speaker\". If this attribute is specified, all channels are mixed into a single one.
	SpeakerName string `json:"speakerName,omitempty"`

	// A description of the speaker role. Only used as metadata.
	SpeakerRole string `json:"speakerRole,omitempty"`

	// List of channels to process, mutually exclusive with \"tracks\", \"stereo\" and \"speakerName\"
	Channels []VbChannelConfiguration `json:"channels,omitempty"`

	// Indicates to process two channels of the media.
	Stereo *VbStereoConfiguration `json:"stereo,omitempty"`

	// List of tracks to process, mutually exclusive with \"channels\", \"stereo\" and \"speakerName\"
	Tracks []VbTrackConfiguration `json:"tracks,omitempty"`
}

type VbJob

type VbJob struct {
	MediaId string `json:"mediaId,omitempty"`

	JobId string `json:"jobId,omitempty"`

	Progress *VbProgress `json:"progress,omitempty"`
}

type VbKey

type VbKey struct {
	Id string `json:"id,omitempty"`

	BearerToken string `json:"bearerToken,omitempty"`

	LastSix string `json:"lastSix,omitempty"`

	Issued time.Time `json:"issued,omitempty"`

	ExpirationDate time.Time `json:"expirationDate,omitempty"`

	Expired bool `json:"expired,omitempty"`

	Scope string `json:"scope,omitempty"`
}

type VbKeyConfiguration

type VbKeyConfiguration struct {

	// Number of milliseconds that the key must be valid for
	TtlMillis int64 `json:"ttlMillis,omitempty"`

	// Expiration date expressed in ISO-8601 format
	ExpirationDate time.Time `json:"expirationDate,omitempty"`

	Ephemeral bool `json:"ephemeral,omitempty"`

	// Restriction of the scope of the token in the form of media:get?extendedFilter=speakers:agent
	Scope string `json:"scope,omitempty"`
}

type VbKeysResponse

type VbKeysResponse struct {
	Keys []VbKey `json:"keys,omitempty"`
}

type VbKeyword

type VbKeyword struct {
	Keyword string `json:"keyword,omitempty"`

	Relevance float64 `json:"relevance,omitempty"`

	Mentions []VbMention `json:"mentions,omitempty"`
}

type VbKeywordGroup

type VbKeywordGroup struct {
	GroupName string `json:"groupName,omitempty"`

	Keywords []string `json:"keywords,omitempty"`
}

type VbKeywordGroupsResponse

type VbKeywordGroupsResponse struct {
	Groups []VbKeywordGroup `json:"groups,omitempty"`
}

type VbKnowledge

type VbKnowledge struct {
	Keywords []VbKeyword `json:"keywords,omitempty"`

	Topics []VbTopic `json:"topics,omitempty"`
}

type VbKnowledgeConfiguration

type VbKnowledgeConfiguration struct {

	// Whether knowledge discovery is enabled or not
	EnableDiscovery bool `json:"enableDiscovery,omitempty"`

	// Whether semantic discovery is allowed to use external data sources or not
	EnableExternalDataSources bool `json:"enableExternalDataSources,omitempty"`
}

type VbMedia

type VbMedia struct {

	// Media format version. E.g. 3.0.1
	FormatVersion string `json:"formatVersion,omitempty"`

	// Media unique identifier.
	MediaId string `json:"mediaId,omitempty"`

	// Processing state.
	Status *VbStatusEnum `json:"status,omitempty"`

	// Creation timestamp
	DateCreated time.Time `json:"dateCreated,omitempty"`

	// User defined data associated with this record.
	Metadata *VbMetadata `json:"metadata,omitempty"`

	// The MIME type of the media submitted for processing. E.g. audio/x-wav, audio/mpeg
	MediaContentType string `json:"mediaContentType,omitempty"`

	// Duration of the audio/video submitted for processing expressed in milliseconds
	Length int64 `json:"length,omitempty"`

	// Semantic knowledge discovery section. If knoweledge discovery was requested, this section contains the results.
	Knowledge *VbKnowledge `json:"knowledge,omitempty"`

	// If kewyword spotting was requested, this section contains the results.
	Spotting *VbSpotting `json:"spotting,omitempty"`

	// If any predictions (classifiers, detectors) were requested, this section contains the results.
	Prediction *VbPrediction `json:"prediction,omitempty"`

	// This section contains the transcript in a variety of formats
	Transcript *VbTranscript `json:"transcript,omitempty"`

	// This section contains warnings about the media
	Warnings []VbMessage `json:"warnings,omitempty"`

	// Theaudio/video streams available.
	Streams []VbStream `json:"streams,omitempty"`

	Job *VbJob `json:"_job,omitempty"`
}

type VbMediaQueryResponse

type VbMediaQueryResponse struct {
	Media []VbMediaSummary `json:"media,omitempty"`
}

type VbMediaSummary

type VbMediaSummary struct {

	// Media format version. E.g. 3.0.1
	FormatVersion string `json:"formatVersion,omitempty"`

	// Media unique identifier.
	MediaId string `json:"mediaId,omitempty"`

	// Processing state.
	Status *VbStatusEnum `json:"status,omitempty"`

	// Creation timestamp
	DateCreated time.Time `json:"dateCreated,omitempty"`

	// User defined data associated with this record.
	Metadata *VbMetadata `json:"metadata,omitempty"`
}

type VbMention

type VbMention struct {
	SpeakerName string `json:"speakerName,omitempty"`

	Occurrences []VbOccurrence `json:"occurrences,omitempty"`
}

type VbMessage

type VbMessage struct {
	Code int32 `json:"code,omitempty"`

	Message string `json:"message,omitempty"`
}

type VbMetadata

type VbMetadata struct {
	Title string `json:"title,omitempty"`

	Description string `json:"description,omitempty"`

	ExternalId string `json:"externalId,omitempty"`

	Extended map[string]interface{} `json:"extended,omitempty"`
}

type VbOccurrence

type VbOccurrence struct {
	S int64 `json:"s,omitempty"`

	E int64 `json:"e,omitempty"`

	Exact string `json:"exact,omitempty"`
}

type VbParameter

type VbParameter struct {

	// Parameter name
	Parameter string `json:"parameter,omitempty"`

	// The value for a parameter.
	Value string `json:"value,omitempty"`
}

type VbParameterDefinition

type VbParameterDefinition struct {
	Name string `json:"name,omitempty"`

	// whether the parameter is optional or not
	Optional bool `json:"optional,omitempty"`

	// Parameter type, one of ( \"String\", \"Integer\", \"Float\", \"Boolean\" )
	Type_ string `json:"type,omitempty"`

	// List of possible values for this parameter, only provided if there is a finite number of values accepted.
	ValueSet []string `json:"valueSet,omitempty"`

	DefaultValue string `json:"defaultValue,omitempty"`
}

type VbPrediction

type VbPrediction struct {
	Classifiers []VbClassifier `json:"classifiers,omitempty"`

	Detectors []VbDetector `json:"detectors,omitempty"`
}

type VbPredictionConfiguration

type VbPredictionConfiguration struct {
	Classifiers []VbClassifierConfiguration `json:"classifiers,omitempty"`

	Detectors []VbDetectorConfiguration `json:"detectors,omitempty"`
}

type VbPriorityEnum

type VbPriorityEnum string
const (
	HIGH   VbPriorityEnum = "high"
	NORMAL VbPriorityEnum = "normal"
	LOW    VbPriorityEnum = "low"
)

List of VbPriorityEnum

type VbProgress

type VbProgress struct {
	Finish string `json:"finish,omitempty"`

	JobId string `json:"jobId,omitempty"`

	Start string `json:"start,omitempty"`

	Status *VbTaskStatusEnum `json:"status,omitempty"`

	Tasks []VbProgressTask `json:"tasks,omitempty"`
}

type VbProgressTask

type VbProgressTask struct {
	TaskId string `json:"taskId,omitempty"`

	Display string `json:"display,omitempty"`

	Phase string `json:"phase,omitempty"`

	Status *VbTaskStatusEnum `json:"status,omitempty"`

	Dependencies []string `json:"dependencies,omitempty"`

	Dependents []string `json:"dependents,omitempty"`
}

type VbPublishConfiguration

type VbPublishConfiguration struct {
	Callbacks []VbCallbackConfiguration `json:"callbacks,omitempty"`
}

type VbRedactorConfiguration

type VbRedactorConfiguration struct {
	Transcript *VbTranscriptRedactorConfiguration `json:"transcript,omitempty"`

	Audio *VbAudioRedactorConfiguration `json:"audio,omitempty"`
}

type VbReference

type VbReference struct {
	Name string `json:"name,omitempty"`

	Score float64 `json:"score,omitempty"`
}

type VbSearchableFields

type VbSearchableFields struct {
	Fields []string `json:"fields,omitempty"`
}

type VbSpeechModelConfiguration

type VbSpeechModelConfiguration struct {

	// Specifies the language using the ISO-639-1 standard two-letter code followed by a dash and a non-standarized region code.
	Language string `json:"language,omitempty"`

	// Allows to turn on additional features of the speech engine
	Features []string `json:"features,omitempty"`

	// This allows to request speech recognition with additional extensions for specific jargon or use cases with the purpose to improve transcription accuracy
	Extensions []string `json:"extensions,omitempty"`
}

type VbSpotting

type VbSpotting struct {
	Groups []VbGroup `json:"groups,omitempty"`
}

type VbSpottingConfiguration

type VbSpottingConfiguration struct {

	// List of keyword spotting groups
	Groups []VbSpottingGroupConfiguration `json:"groups,omitempty"`
}

type VbSpottingGroupConfiguration

type VbSpottingGroupConfiguration struct {

	// Name of a pre-defined keyword spotting group
	GroupName string `json:"groupName,omitempty"`
}

type VbStatusEnum

type VbStatusEnum string
const (
	ACCEPTED  VbStatusEnum = "accepted"
	FAILED    VbStatusEnum = "failed"
	SCHEDULED VbStatusEnum = "scheduled"
	RUNNING   VbStatusEnum = "running"
	FINISHED  VbStatusEnum = "finished"
)

List of VbStatusEnum

type VbStereoConfiguration

type VbStereoConfiguration struct {

	// Description of the speaker on the left channel (Channel 0)
	Left *VbChannelConfiguration `json:"left,omitempty"`

	// Description of the speaker on the right channel (Channel 1)
	Right *VbChannelConfiguration `json:"right,omitempty"`
}

type VbStream

type VbStream struct {
	Status int32 `json:"status,omitempty"`

	StreamName string `json:"streamName,omitempty"`

	StreamLocation string `json:"streamLocation,omitempty"`

	Comment string `json:"comment,omitempty"`
}

type VbStreams

type VbStreams struct {
	Streams []VbStream `json:"streams,omitempty"`
}

type VbTaskStatusEnum

type VbTaskStatusEnum string
const (
	TASK_STATUS_ACCEPTED        VbTaskStatusEnum = "accepted"
	TASK_STATUS_FAILED          VbTaskStatusEnum = "failed"
	TASK_STATUS_EXCEEDEDRETRIES VbTaskStatusEnum = "exceededretries"
	TASK_STATUS_EXPIRED         VbTaskStatusEnum = "expired"
	TASK_STATUS_CANCELLED       VbTaskStatusEnum = "cancelled"
	TASK_STATUS_STORED          VbTaskStatusEnum = "stored"
	TASK_STATUS_LOADED          VbTaskStatusEnum = "loaded"
	TASK_STATUS_STARTED         VbTaskStatusEnum = "started"
	TASK_STATUS_FINISHED        VbTaskStatusEnum = "finished"
	TASK_STATUS_COMPLETED       VbTaskStatusEnum = "completed"
	TASK_STATUS_STOPPED         VbTaskStatusEnum = "stopped"
	TASK_STATUS_SKIPPED         VbTaskStatusEnum = "skipped"
	TASK_STATUS_PENDING         VbTaskStatusEnum = "pending"
)

List of VbTaskStatusEnum

type VbTopic

type VbTopic struct {
	TopicName string `json:"topicName,omitempty"`

	Relevance float64 `json:"relevance,omitempty"`

	SubTopics []VbReference `json:"subTopics,omitempty"`

	Keywords []VbKeyword `json:"keywords,omitempty"`
}

type VbTrackConfiguration

type VbTrackConfiguration struct {

	// Track index.
	TrackIndex int32 `json:"trackIndex,omitempty"`

	// Speaker name. Defaults to \"Speaker\". If this attribute is specified, all channels are mixed into a single one.
	SpeakerName string `json:"speakerName,omitempty"`

	// A description of the speaker role. Only used as metadata.
	SpeakerRole string `json:"speakerRole,omitempty"`

	// List of channels to process, mutually exclusive with \"speakerName\"
	Channels []VbChannelConfiguration `json:"channels,omitempty"`
}

type VbTranscript

type VbTranscript struct {
	Confidence float64 `json:"confidence,omitempty"`

	Words []VbWord `json:"words,omitempty"`

	AlternateFormats []VbTranscriptFormat `json:"alternateFormats,omitempty"`
}

type VbTranscriptConfiguration

type VbTranscriptConfiguration struct {
	Formatting *VbFormattingConfiguration `json:"formatting,omitempty"`

	ContentFiltering *VbContentFilteringConfiguration `json:"contentFiltering,omitempty"`
}

type VbTranscriptFormat

type VbTranscriptFormat struct {
	Format string `json:"format,omitempty"`

	ContentType string `json:"contentType,omitempty"`

	ContentEncoding string `json:"contentEncoding,omitempty"`

	Charset string `json:"charset,omitempty"`

	Data string `json:"data,omitempty"`
}

type VbTranscriptRedactorConfiguration

type VbTranscriptRedactorConfiguration struct {

	// Sequence of characters to replace words within a transcript when reported by a detector
	Replacement string `json:"replacement,omitempty"`
}

type VbVocabulariesResponse

type VbVocabulariesResponse struct {
	Vocabularies []VbVocabulary `json:"vocabularies,omitempty"`
}

type VbVocabulary

type VbVocabulary struct {
	VocabularyName string `json:"vocabularyName,omitempty"`

	VocabularyType VbVocabularyType `json:"vocabularyType,omitempty"`

	Terms []VbVocabularyTerm `json:"terms,omitempty"`

	Scripts []VbVocabularyScript `json:"scripts,omitempty"`
}

type VbVocabularyConfiguration

type VbVocabularyConfiguration struct {
	VocabularyName string `json:"vocabularyName,omitempty"`

	Terms []VbVocabularyTermConfiguration `json:"terms,omitempty"`

	Scripts []VbVocabularyScriptConfiguration `json:"scripts,omitempty"`
}

type VbVocabularyScript

type VbVocabularyScript struct {
	Script string `json:"script,omitempty"`
}

type VbVocabularyScriptConfiguration

type VbVocabularyScriptConfiguration struct {
	Script string `json:"script,omitempty"`
}

type VbVocabularyTerm

type VbVocabularyTerm struct {
	Term string `json:"term,omitempty"`

	SoundsLike []string `json:"soundsLike,omitempty"`

	Weight int32 `json:"weight,omitempty"`
}

type VbVocabularyTermConfiguration

type VbVocabularyTermConfiguration struct {
	Term string `json:"term,omitempty"`

	SoundsLike []string `json:"soundsLike,omitempty"`

	Weight int32 `json:"weight,omitempty"`
}

type VbVocabularyType

type VbVocabularyType string
const (
	SCRIPTS VbVocabularyType = "scripts"
	TERMS   VbVocabularyType = "terms"
)

List of VbVocabularyType

type VbWord

type VbWord struct {
	P int32 `json:"p,omitempty"`

	C float64 `json:"c,omitempty"`

	S int64 `json:"s,omitempty"`

	E int64 `json:"e,omitempty"`

	Frq []VbFrequency `json:"frq,omitempty"`

	M *VbWordTypeEnum `json:"m,omitempty"`

	V float64 `json:"v,omitempty"`

	W string `json:"w,omitempty"`
}

type VbWordTypeEnum

type VbWordTypeEnum string
const (
	PUNC VbWordTypeEnum = "punc"
	TURN VbWordTypeEnum = "turn"
	DTMF VbWordTypeEnum = "dtmf"
)

List of VbWordTypeEnum

Source Files

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL