-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathtranslated_tts.go
More file actions
58 lines (50 loc) · 2.01 KB
/
translated_tts.go
File metadata and controls
58 lines (50 loc) · 2.01 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
// This file was auto-generated by Fern from our API Definition.
package cambai
import (
json "encoding/json"
fmt "fmt"
core "github.com/camb-ai/cambai-go-sdk/core"
)
type CreateTranslatedTtsRequestPayload struct {
Traceparent *string `json:"-" url:"-"`
RunID *int `json:"-" url:"run_id,omitempty"`
ProjectName *string `json:"project_name,omitempty" url:"project_name,omitempty"`
ProjectDescription *string `json:"project_description,omitempty" url:"project_description,omitempty"`
FolderID *int `json:"folder_id,omitempty" url:"folder_id,omitempty"`
Text string `json:"text" url:"text"`
VoiceID int `json:"voice_id" url:"voice_id"`
Age *int `json:"age,omitempty" url:"age,omitempty"`
Formality *Formalities `json:"formality,omitempty" url:"formality,omitempty"`
Gender *Gender `json:"gender,omitempty" url:"gender,omitempty"`
SourceLanguage Languages `json:"source_language" url:"source_language"`
TargetLanguage Languages `json:"target_language" url:"target_language"`
ChosenDictionaries []int `json:"chosen_dictionaries,omitempty" url:"chosen_dictionaries,omitempty"`
}
type GetTranslatedTtsTaskStatusTranslatedTtsTaskIDGetRequest struct {
RunID *int `json:"-" url:"run_id,omitempty"`
}
type CreateTranslatedTtsOut struct {
TaskID string `json:"task_id" url:"task_id"`
_rawJSON json.RawMessage
}
func (c *CreateTranslatedTtsOut) UnmarshalJSON(data []byte) error {
type unmarshaler CreateTranslatedTtsOut
var value unmarshaler
if err := json.Unmarshal(data, &value); err != nil {
return err
}
*c = CreateTranslatedTtsOut(value)
c._rawJSON = json.RawMessage(data)
return nil
}
func (c *CreateTranslatedTtsOut) String() string {
if len(c._rawJSON) > 0 {
if value, err := core.StringifyJSON(c._rawJSON); err == nil {
return value
}
}
if value, err := core.StringifyJSON(c); err == nil {
return value
}
return fmt.Sprintf("%#v", c)
}