Documentation ¶
Index ¶
- Constants
- Variables
- func LoadAsset(id string, c common.Cacheable, api synq.ApiV2) (asset synq.Asset, err error)
- func LoadRawVideosByAccount(accountId, name string, c common.Cacheable, api synq.ApiV2) (videos []json.RawMessage, err error)
- func LoadUploadParameters(id string, req upload.UploadRequest, c common.Cacheable, api synq.ApiV2) (up upload.UploadParameters, err error)
- func LoadVideoV2(id string, c common.Cacheable, api synq.ApiV2) (video synq.VideoV2, err error)
- func LoadVideosByAccount(accountId, name string, c common.Cacheable, api synq.ApiV2) (videos []synq.VideoV2, err error)
- func SetupForTestV2() synq.ApiV2
- func SetupSynqApi(setup ...ApiSetup) (api synq.ApiF)
- func SetupSynqV2() synq.ApiV2
- type ApiSet
- type ApiSetting
- type ApiSetup
Constants ¶
View Source
const ( SYNQ_LEGACY_VERSION = "v1" SYNQ_VERSION = "v2" )
Variables ¶
View Source
var DEFAULT_CRED_FILE = os.Getenv("HOME") + "/.synq/credentials.json"
Functions ¶
func LoadRawVideosByAccount ¶
func LoadRawVideosByAccount(accountId, name string, c common.Cacheable, api synq.ApiV2) (videos []json.RawMessage, err error)
fow now, the query will be the account id
func LoadUploadParameters ¶
func LoadUploadParameters(id string, req upload.UploadRequest, c common.Cacheable, api synq.ApiV2) (up upload.UploadParameters, err error)
func LoadVideoV2 ¶
func LoadVideosByAccount ¶
func LoadVideosByAccount(accountId, name string, c common.Cacheable, api synq.ApiV2) (videos []synq.VideoV2, err error)
fow now, the query will be the account id
func SetupForTestV2 ¶
func SetupSynqApi ¶
func SetupSynqV2 ¶
Types ¶
type ApiSet ¶
type ApiSet struct { V2 ApiSetting `json:"v2"` ApiV2 synq.ApiV2 `json:"-"` }
func LoadFromFile ¶
type ApiSetting ¶
type ApiSetting struct { // only api_key is required ApiKey string `json:"api_key"` Url string `json:"api_url,omitempty"` Timeout int `json:"timeout,omitempty"` UploadTimeout int `json:"upload_timeout,omitempty"` User string `json:"user,omitempty"` Password string `json:"password,omitempty"` }
func (ApiSetting) Configure ¶
func (a ApiSetting) Configure(api synq.ApiF)
func (ApiSetting) SetupV2 ¶
func (a ApiSetting) SetupV2() synq.ApiV2
func (ApiSetting) Valid ¶
func (a ApiSetting) Valid() bool
Click to show internal directories.
Click to hide internal directories.