version

package
v1.1.4 Latest Latest
Warning

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

Go to latest
Published: Feb 29, 2024 License: MIT Imports: 10 Imported by: 4

Documentation

Overview

This package handles the versioning in the API for prerecorded endpoint

This package handles the versioning in the API for live/streaming websocket

This package handles the versioning in the API for manage endpoints

This package handles the versioning in the API for prerecorded endpoint

Index

Constants

View Source
const (
	// ReadAPIVersion current supported version
	ReadAPIVersion string = "v1"

	// ReadPath is the current path for prerecorded transcription
	ReadPath string = "read"
)
View Source
const (
	// APIProtocol default protocol
	APIProtocol string = "https"

	// WSProtocol default protocol
	WSProtocol string = "wss"
)
View Source
const (
	// LiveAPIVersion current supported version
	LiveAPIVersion string = "v1"

	// LivePath is the current path for live transcription
	LivePath string = "listen"
)
View Source
const (
	// version
	ManageAPIVersion string = "v1"

	// balances
	BalancesURI     string = "projects/%s/balances"
	BalancesByIdURI string = "projects/%s/balances/%s"

	// invitations
	InvitationsURI      string = "projects/%s/invites"
	InvitationsByIdURI  string = "projects/%s/invites/%s"
	InvitationsLeaveURI string = "projects/%s/leave"

	// Keys
	KeysURI     string = "projects/%s/keys"
	KeysByIdURI string = "projects/%s/keys/%s"

	// Members
	MembersURI     string = "projects/%s/members"
	MembersByIdURI string = "projects/%s/members/%s"

	// projects
	ProjectsURI     string = "projects"
	ProjectsByIdURI string = "projects/%s"

	// scopes
	MembersScopeByIdURI string = "projects/%s/members/%s/scopes"

	// usage
	UsageRequestURI     string = "projects/%s/requests"
	UsageRequestByIdURI string = "projects/%s/requests/%s"
	UsageURI            string = "projects/%s/usage"
	UsageFieldsURI      string = "projects/%s/usage/fields"
)
View Source
const (
	// PrerecordedAPIVersion current supported version
	PrerecordedAPIVersion string = "v1"

	// PrerecordedPath is the current path for prerecorded transcription
	PrerecordedPath string = "listen"
)

Variables

View Source
var (
	// ErrInvalidPath invalid path
	ErrInvalidPath = errors.New("invalid path")
)

Functions

func GetAnalyzeAPI added in v1.1.0

func GetAnalyzeAPI(ctx context.Context, host, version, path string, options interfaces.AnalyzeOptions, args ...interface{}) (string, error)

GetAnalyzeAPI is a function which controls the versioning of the live transcription API and provides mechanism for:

- overriding the host endpoint - overriding the version used - overriding the endpoint path - additional arguments to the query string/parameters

The return value is the complete URL endpoint to be used for the live transcription

func GetLiveAPI

func GetLiveAPI(ctx context.Context, host, version, path string, options interfaces.LiveTranscriptionOptions, args ...interface{}) (string, error)

GetLiveAPI is a function which controls the versioning of the live transcription API and provides mechanism for:

- overriding the host endpoint - overriding the version used - overriding the endpoint path - additional arguments to the query string/parameters

The return value is the complete URL endpoint to be used for the live transcription

func GetManageAPI

func GetManageAPI(ctx context.Context, host, version, path string, vals interface{}, args ...interface{}) (string, error)

GetManageAPI is a function which controls the versioning of the manage API and provides mechanism for:

- overriding the host endpoint - overriding the version used - overriding the endpoint path - additional arguments to the query string/parameters

The return value is the complete URL endpoint to be used for manage

func GetPrerecordedAPI

func GetPrerecordedAPI(ctx context.Context, host, version, path string, options interfaces.PreRecordedTranscriptionOptions, args ...interface{}) (string, error)

GetPrerecordedAPI is a function which controls the versioning of the live transcription API and provides mechanism for:

- overriding the host endpoint - overriding the version used - overriding the endpoint path - additional arguments to the query string/parameters

The return value is the complete URL endpoint to be used for the live transcription

Types

This section is empty.

Jump to

Keyboard shortcuts

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