6969 lines
203 KiB
Go
Generated
6969 lines
203 KiB
Go
Generated
// Package api provides primitives to interact with the openapi HTTP API.
|
|
//
|
|
// Code generated by github.com/deepmap/oapi-codegen version v1.9.0 DO NOT EDIT.
|
|
package api
|
|
|
|
import (
|
|
"bytes"
|
|
"context"
|
|
"encoding/json"
|
|
"fmt"
|
|
"io"
|
|
"io/ioutil"
|
|
"net/http"
|
|
"net/url"
|
|
"strings"
|
|
|
|
"gopkg.in/yaml.v2"
|
|
|
|
"github.com/deepmap/oapi-codegen/pkg/runtime"
|
|
)
|
|
|
|
// RequestEditorFn is the function signature for the RequestEditor callback function
|
|
type RequestEditorFn func(ctx context.Context, req *http.Request) error
|
|
|
|
// Doer performs HTTP requests.
|
|
//
|
|
// The standard http.Client implements this interface.
|
|
type HttpRequestDoer interface {
|
|
Do(req *http.Request) (*http.Response, error)
|
|
}
|
|
|
|
// Client which conforms to the OpenAPI3 specification for this service.
|
|
type Client struct {
|
|
// The endpoint of the server conforming to this interface, with scheme,
|
|
// https://api.deepmap.com for example. This can contain a path relative
|
|
// to the server, such as https://api.deepmap.com/dev-test, and all the
|
|
// paths in the swagger spec will be appended to the server.
|
|
Server string
|
|
|
|
// Doer for performing requests, typically a *http.Client with any
|
|
// customized settings, such as certificate chains.
|
|
Client HttpRequestDoer
|
|
|
|
// A list of callbacks for modifying requests which are generated before sending over
|
|
// the network.
|
|
RequestEditors []RequestEditorFn
|
|
}
|
|
|
|
// ClientOption allows setting custom parameters during construction
|
|
type ClientOption func(*Client) error
|
|
|
|
// Creates a new Client, with reasonable defaults
|
|
func NewClient(server string, opts ...ClientOption) (*Client, error) {
|
|
// create a client with sane default values
|
|
client := Client{
|
|
Server: server,
|
|
}
|
|
// mutate client and add all optional params
|
|
for _, o := range opts {
|
|
if err := o(&client); err != nil {
|
|
return nil, err
|
|
}
|
|
}
|
|
// ensure the server URL always has a trailing slash
|
|
if !strings.HasSuffix(client.Server, "/") {
|
|
client.Server += "/"
|
|
}
|
|
// create httpClient, if not already present
|
|
if client.Client == nil {
|
|
client.Client = &http.Client{}
|
|
}
|
|
return &client, nil
|
|
}
|
|
|
|
// WithHTTPClient allows overriding the default Doer, which is
|
|
// automatically created using http.Client. This is useful for tests.
|
|
func WithHTTPClient(doer HttpRequestDoer) ClientOption {
|
|
return func(c *Client) error {
|
|
c.Client = doer
|
|
return nil
|
|
}
|
|
}
|
|
|
|
// WithRequestEditorFn allows setting up a callback function, which will be
|
|
// called right before sending the request. This can be used to mutate the request.
|
|
func WithRequestEditorFn(fn RequestEditorFn) ClientOption {
|
|
return func(c *Client) error {
|
|
c.RequestEditors = append(c.RequestEditors, fn)
|
|
return nil
|
|
}
|
|
}
|
|
|
|
// The interface specification for the client above.
|
|
type ClientInterface interface {
|
|
// GetConfiguration request
|
|
GetConfiguration(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// FindBlenderExePath request
|
|
FindBlenderExePath(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// CheckBlenderExePath request with any body
|
|
CheckBlenderExePathWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
CheckBlenderExePath(ctx context.Context, body CheckBlenderExePathJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// CheckSharedStoragePath request with any body
|
|
CheckSharedStoragePathWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
CheckSharedStoragePath(ctx context.Context, body CheckSharedStoragePathJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// GetConfigurationFile request
|
|
GetConfigurationFile(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// SaveSetupAssistantConfig request with any body
|
|
SaveSetupAssistantConfigWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
SaveSetupAssistantConfig(ctx context.Context, body SaveSetupAssistantConfigJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// GetSharedStorage request
|
|
GetSharedStorage(ctx context.Context, audience ManagerVariableAudience, platform string, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// GetVariables request
|
|
GetVariables(ctx context.Context, audience ManagerVariableAudience, platform string, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// SubmitJob request with any body
|
|
SubmitJobWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
SubmitJob(ctx context.Context, body SubmitJobJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// SubmitJobCheck request with any body
|
|
SubmitJobCheckWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
SubmitJobCheck(ctx context.Context, body SubmitJobCheckJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// FetchGlobalLastRenderedInfo request
|
|
FetchGlobalLastRenderedInfo(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// DeleteJobMass request with any body
|
|
DeleteJobMassWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
DeleteJobMass(ctx context.Context, body DeleteJobMassJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// QueryJobs request with any body
|
|
QueryJobsWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
QueryJobs(ctx context.Context, body QueryJobsJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// GetJobType request
|
|
GetJobType(ctx context.Context, typeName string, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// GetJobTypes request
|
|
GetJobTypes(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// DeleteJob request
|
|
DeleteJob(ctx context.Context, jobId string, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// FetchJob request
|
|
FetchJob(ctx context.Context, jobId string, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// RemoveJobBlocklist request with any body
|
|
RemoveJobBlocklistWithBody(ctx context.Context, jobId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
RemoveJobBlocklist(ctx context.Context, jobId string, body RemoveJobBlocklistJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// FetchJobBlocklist request
|
|
FetchJobBlocklist(ctx context.Context, jobId string, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// FetchJobLastRenderedInfo request
|
|
FetchJobLastRenderedInfo(ctx context.Context, jobId string, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// SetJobPriority request with any body
|
|
SetJobPriorityWithBody(ctx context.Context, jobId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
SetJobPriority(ctx context.Context, jobId string, body SetJobPriorityJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// SetJobStatus request with any body
|
|
SetJobStatusWithBody(ctx context.Context, jobId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
SetJobStatus(ctx context.Context, jobId string, body SetJobStatusJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// FetchJobTasks request
|
|
FetchJobTasks(ctx context.Context, jobId string, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// DeleteJobWhatWouldItDo request
|
|
DeleteJobWhatWouldItDo(ctx context.Context, jobId string, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// ShamanCheckout request with any body
|
|
ShamanCheckoutWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
ShamanCheckout(ctx context.Context, body ShamanCheckoutJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// ShamanCheckoutRequirements request with any body
|
|
ShamanCheckoutRequirementsWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
ShamanCheckoutRequirements(ctx context.Context, body ShamanCheckoutRequirementsJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// ShamanFileStoreCheck request
|
|
ShamanFileStoreCheck(ctx context.Context, checksum string, filesize int, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// ShamanFileStore request with any body
|
|
ShamanFileStoreWithBody(ctx context.Context, checksum string, filesize int, params *ShamanFileStoreParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// FetchTask request
|
|
FetchTask(ctx context.Context, taskId string, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// FetchTaskLogInfo request
|
|
FetchTaskLogInfo(ctx context.Context, taskId string, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// FetchTaskLogTail request
|
|
FetchTaskLogTail(ctx context.Context, taskId string, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// SetTaskStatus request with any body
|
|
SetTaskStatusWithBody(ctx context.Context, taskId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
SetTaskStatus(ctx context.Context, taskId string, body SetTaskStatusJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// GetVersion request
|
|
GetVersion(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// DeleteWorkerTag request
|
|
DeleteWorkerTag(ctx context.Context, tagId string, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// FetchWorkerTag request
|
|
FetchWorkerTag(ctx context.Context, tagId string, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// UpdateWorkerTag request with any body
|
|
UpdateWorkerTagWithBody(ctx context.Context, tagId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
UpdateWorkerTag(ctx context.Context, tagId string, body UpdateWorkerTagJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// FetchWorkerTags request
|
|
FetchWorkerTags(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// CreateWorkerTag request with any body
|
|
CreateWorkerTagWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
CreateWorkerTag(ctx context.Context, body CreateWorkerTagJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// FetchWorkers request
|
|
FetchWorkers(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// DeleteWorker request
|
|
DeleteWorker(ctx context.Context, workerId string, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// FetchWorker request
|
|
FetchWorker(ctx context.Context, workerId string, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// RequestWorkerStatusChange request with any body
|
|
RequestWorkerStatusChangeWithBody(ctx context.Context, workerId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
RequestWorkerStatusChange(ctx context.Context, workerId string, body RequestWorkerStatusChangeJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// SetWorkerTags request with any body
|
|
SetWorkerTagsWithBody(ctx context.Context, workerId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
SetWorkerTags(ctx context.Context, workerId string, body SetWorkerTagsJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// FetchWorkerSleepSchedule request
|
|
FetchWorkerSleepSchedule(ctx context.Context, workerId string, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// SetWorkerSleepSchedule request with any body
|
|
SetWorkerSleepScheduleWithBody(ctx context.Context, workerId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
SetWorkerSleepSchedule(ctx context.Context, workerId string, body SetWorkerSleepScheduleJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// RegisterWorker request with any body
|
|
RegisterWorkerWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
RegisterWorker(ctx context.Context, body RegisterWorkerJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// SignOff request
|
|
SignOff(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// SignOn request with any body
|
|
SignOnWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
SignOn(ctx context.Context, body SignOnJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// WorkerState request
|
|
WorkerState(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// WorkerStateChanged request with any body
|
|
WorkerStateChangedWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
WorkerStateChanged(ctx context.Context, body WorkerStateChangedJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// ScheduleTask request
|
|
ScheduleTask(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// TaskUpdate request with any body
|
|
TaskUpdateWithBody(ctx context.Context, taskId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
TaskUpdate(ctx context.Context, taskId string, body TaskUpdateJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// MayWorkerRun request
|
|
MayWorkerRun(ctx context.Context, taskId string, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
|
|
// TaskOutputProduced request with any body
|
|
TaskOutputProducedWithBody(ctx context.Context, taskId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)
|
|
}
|
|
|
|
func (c *Client) GetConfiguration(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewGetConfigurationRequest(c.Server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) FindBlenderExePath(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewFindBlenderExePathRequest(c.Server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) CheckBlenderExePathWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewCheckBlenderExePathRequestWithBody(c.Server, contentType, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) CheckBlenderExePath(ctx context.Context, body CheckBlenderExePathJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewCheckBlenderExePathRequest(c.Server, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) CheckSharedStoragePathWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewCheckSharedStoragePathRequestWithBody(c.Server, contentType, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) CheckSharedStoragePath(ctx context.Context, body CheckSharedStoragePathJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewCheckSharedStoragePathRequest(c.Server, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) GetConfigurationFile(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewGetConfigurationFileRequest(c.Server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) SaveSetupAssistantConfigWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewSaveSetupAssistantConfigRequestWithBody(c.Server, contentType, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) SaveSetupAssistantConfig(ctx context.Context, body SaveSetupAssistantConfigJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewSaveSetupAssistantConfigRequest(c.Server, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) GetSharedStorage(ctx context.Context, audience ManagerVariableAudience, platform string, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewGetSharedStorageRequest(c.Server, audience, platform)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) GetVariables(ctx context.Context, audience ManagerVariableAudience, platform string, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewGetVariablesRequest(c.Server, audience, platform)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) SubmitJobWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewSubmitJobRequestWithBody(c.Server, contentType, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) SubmitJob(ctx context.Context, body SubmitJobJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewSubmitJobRequest(c.Server, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) SubmitJobCheckWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewSubmitJobCheckRequestWithBody(c.Server, contentType, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) SubmitJobCheck(ctx context.Context, body SubmitJobCheckJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewSubmitJobCheckRequest(c.Server, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) FetchGlobalLastRenderedInfo(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewFetchGlobalLastRenderedInfoRequest(c.Server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) DeleteJobMassWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewDeleteJobMassRequestWithBody(c.Server, contentType, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) DeleteJobMass(ctx context.Context, body DeleteJobMassJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewDeleteJobMassRequest(c.Server, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) QueryJobsWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewQueryJobsRequestWithBody(c.Server, contentType, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) QueryJobs(ctx context.Context, body QueryJobsJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewQueryJobsRequest(c.Server, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) GetJobType(ctx context.Context, typeName string, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewGetJobTypeRequest(c.Server, typeName)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) GetJobTypes(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewGetJobTypesRequest(c.Server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) DeleteJob(ctx context.Context, jobId string, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewDeleteJobRequest(c.Server, jobId)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) FetchJob(ctx context.Context, jobId string, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewFetchJobRequest(c.Server, jobId)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) RemoveJobBlocklistWithBody(ctx context.Context, jobId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewRemoveJobBlocklistRequestWithBody(c.Server, jobId, contentType, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) RemoveJobBlocklist(ctx context.Context, jobId string, body RemoveJobBlocklistJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewRemoveJobBlocklistRequest(c.Server, jobId, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) FetchJobBlocklist(ctx context.Context, jobId string, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewFetchJobBlocklistRequest(c.Server, jobId)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) FetchJobLastRenderedInfo(ctx context.Context, jobId string, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewFetchJobLastRenderedInfoRequest(c.Server, jobId)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) SetJobPriorityWithBody(ctx context.Context, jobId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewSetJobPriorityRequestWithBody(c.Server, jobId, contentType, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) SetJobPriority(ctx context.Context, jobId string, body SetJobPriorityJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewSetJobPriorityRequest(c.Server, jobId, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) SetJobStatusWithBody(ctx context.Context, jobId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewSetJobStatusRequestWithBody(c.Server, jobId, contentType, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) SetJobStatus(ctx context.Context, jobId string, body SetJobStatusJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewSetJobStatusRequest(c.Server, jobId, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) FetchJobTasks(ctx context.Context, jobId string, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewFetchJobTasksRequest(c.Server, jobId)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) DeleteJobWhatWouldItDo(ctx context.Context, jobId string, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewDeleteJobWhatWouldItDoRequest(c.Server, jobId)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) ShamanCheckoutWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewShamanCheckoutRequestWithBody(c.Server, contentType, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) ShamanCheckout(ctx context.Context, body ShamanCheckoutJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewShamanCheckoutRequest(c.Server, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) ShamanCheckoutRequirementsWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewShamanCheckoutRequirementsRequestWithBody(c.Server, contentType, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) ShamanCheckoutRequirements(ctx context.Context, body ShamanCheckoutRequirementsJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewShamanCheckoutRequirementsRequest(c.Server, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) ShamanFileStoreCheck(ctx context.Context, checksum string, filesize int, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewShamanFileStoreCheckRequest(c.Server, checksum, filesize)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) ShamanFileStoreWithBody(ctx context.Context, checksum string, filesize int, params *ShamanFileStoreParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewShamanFileStoreRequestWithBody(c.Server, checksum, filesize, params, contentType, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) FetchTask(ctx context.Context, taskId string, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewFetchTaskRequest(c.Server, taskId)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) FetchTaskLogInfo(ctx context.Context, taskId string, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewFetchTaskLogInfoRequest(c.Server, taskId)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) FetchTaskLogTail(ctx context.Context, taskId string, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewFetchTaskLogTailRequest(c.Server, taskId)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) SetTaskStatusWithBody(ctx context.Context, taskId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewSetTaskStatusRequestWithBody(c.Server, taskId, contentType, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) SetTaskStatus(ctx context.Context, taskId string, body SetTaskStatusJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewSetTaskStatusRequest(c.Server, taskId, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) GetVersion(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewGetVersionRequest(c.Server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) DeleteWorkerTag(ctx context.Context, tagId string, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewDeleteWorkerTagRequest(c.Server, tagId)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) FetchWorkerTag(ctx context.Context, tagId string, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewFetchWorkerTagRequest(c.Server, tagId)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) UpdateWorkerTagWithBody(ctx context.Context, tagId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewUpdateWorkerTagRequestWithBody(c.Server, tagId, contentType, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) UpdateWorkerTag(ctx context.Context, tagId string, body UpdateWorkerTagJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewUpdateWorkerTagRequest(c.Server, tagId, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) FetchWorkerTags(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewFetchWorkerTagsRequest(c.Server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) CreateWorkerTagWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewCreateWorkerTagRequestWithBody(c.Server, contentType, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) CreateWorkerTag(ctx context.Context, body CreateWorkerTagJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewCreateWorkerTagRequest(c.Server, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) FetchWorkers(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewFetchWorkersRequest(c.Server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) DeleteWorker(ctx context.Context, workerId string, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewDeleteWorkerRequest(c.Server, workerId)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) FetchWorker(ctx context.Context, workerId string, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewFetchWorkerRequest(c.Server, workerId)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) RequestWorkerStatusChangeWithBody(ctx context.Context, workerId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewRequestWorkerStatusChangeRequestWithBody(c.Server, workerId, contentType, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) RequestWorkerStatusChange(ctx context.Context, workerId string, body RequestWorkerStatusChangeJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewRequestWorkerStatusChangeRequest(c.Server, workerId, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) SetWorkerTagsWithBody(ctx context.Context, workerId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewSetWorkerTagsRequestWithBody(c.Server, workerId, contentType, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) SetWorkerTags(ctx context.Context, workerId string, body SetWorkerTagsJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewSetWorkerTagsRequest(c.Server, workerId, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) FetchWorkerSleepSchedule(ctx context.Context, workerId string, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewFetchWorkerSleepScheduleRequest(c.Server, workerId)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) SetWorkerSleepScheduleWithBody(ctx context.Context, workerId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewSetWorkerSleepScheduleRequestWithBody(c.Server, workerId, contentType, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) SetWorkerSleepSchedule(ctx context.Context, workerId string, body SetWorkerSleepScheduleJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewSetWorkerSleepScheduleRequest(c.Server, workerId, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) RegisterWorkerWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewRegisterWorkerRequestWithBody(c.Server, contentType, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) RegisterWorker(ctx context.Context, body RegisterWorkerJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewRegisterWorkerRequest(c.Server, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) SignOff(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewSignOffRequest(c.Server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) SignOnWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewSignOnRequestWithBody(c.Server, contentType, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) SignOn(ctx context.Context, body SignOnJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewSignOnRequest(c.Server, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) WorkerState(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewWorkerStateRequest(c.Server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) WorkerStateChangedWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewWorkerStateChangedRequestWithBody(c.Server, contentType, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) WorkerStateChanged(ctx context.Context, body WorkerStateChangedJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewWorkerStateChangedRequest(c.Server, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) ScheduleTask(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewScheduleTaskRequest(c.Server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) TaskUpdateWithBody(ctx context.Context, taskId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewTaskUpdateRequestWithBody(c.Server, taskId, contentType, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) TaskUpdate(ctx context.Context, taskId string, body TaskUpdateJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewTaskUpdateRequest(c.Server, taskId, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) MayWorkerRun(ctx context.Context, taskId string, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewMayWorkerRunRequest(c.Server, taskId)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
func (c *Client) TaskOutputProducedWithBody(ctx context.Context, taskId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) {
|
|
req, err := NewTaskOutputProducedRequestWithBody(c.Server, taskId, contentType, body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
req = req.WithContext(ctx)
|
|
if err := c.applyEditors(ctx, req, reqEditors); err != nil {
|
|
return nil, err
|
|
}
|
|
return c.Client.Do(req)
|
|
}
|
|
|
|
// NewGetConfigurationRequest generates requests for GetConfiguration
|
|
func NewGetConfigurationRequest(server string) (*http.Request, error) {
|
|
var err error
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/configuration")
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("GET", queryURL.String(), nil)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewFindBlenderExePathRequest generates requests for FindBlenderExePath
|
|
func NewFindBlenderExePathRequest(server string) (*http.Request, error) {
|
|
var err error
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/configuration/check/blender")
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("GET", queryURL.String(), nil)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewCheckBlenderExePathRequest calls the generic CheckBlenderExePath builder with application/json body
|
|
func NewCheckBlenderExePathRequest(server string, body CheckBlenderExePathJSONRequestBody) (*http.Request, error) {
|
|
var bodyReader io.Reader
|
|
buf, err := json.Marshal(body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
bodyReader = bytes.NewReader(buf)
|
|
return NewCheckBlenderExePathRequestWithBody(server, "application/json", bodyReader)
|
|
}
|
|
|
|
// NewCheckBlenderExePathRequestWithBody generates requests for CheckBlenderExePath with any type of body
|
|
func NewCheckBlenderExePathRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) {
|
|
var err error
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/configuration/check/blender")
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("POST", queryURL.String(), body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req.Header.Add("Content-Type", contentType)
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewCheckSharedStoragePathRequest calls the generic CheckSharedStoragePath builder with application/json body
|
|
func NewCheckSharedStoragePathRequest(server string, body CheckSharedStoragePathJSONRequestBody) (*http.Request, error) {
|
|
var bodyReader io.Reader
|
|
buf, err := json.Marshal(body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
bodyReader = bytes.NewReader(buf)
|
|
return NewCheckSharedStoragePathRequestWithBody(server, "application/json", bodyReader)
|
|
}
|
|
|
|
// NewCheckSharedStoragePathRequestWithBody generates requests for CheckSharedStoragePath with any type of body
|
|
func NewCheckSharedStoragePathRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) {
|
|
var err error
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/configuration/check/shared-storage")
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("POST", queryURL.String(), body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req.Header.Add("Content-Type", contentType)
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewGetConfigurationFileRequest generates requests for GetConfigurationFile
|
|
func NewGetConfigurationFileRequest(server string) (*http.Request, error) {
|
|
var err error
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/configuration/file")
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("GET", queryURL.String(), nil)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewSaveSetupAssistantConfigRequest calls the generic SaveSetupAssistantConfig builder with application/json body
|
|
func NewSaveSetupAssistantConfigRequest(server string, body SaveSetupAssistantConfigJSONRequestBody) (*http.Request, error) {
|
|
var bodyReader io.Reader
|
|
buf, err := json.Marshal(body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
bodyReader = bytes.NewReader(buf)
|
|
return NewSaveSetupAssistantConfigRequestWithBody(server, "application/json", bodyReader)
|
|
}
|
|
|
|
// NewSaveSetupAssistantConfigRequestWithBody generates requests for SaveSetupAssistantConfig with any type of body
|
|
func NewSaveSetupAssistantConfigRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) {
|
|
var err error
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/configuration/setup-assistant")
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("POST", queryURL.String(), body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req.Header.Add("Content-Type", contentType)
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewGetSharedStorageRequest generates requests for GetSharedStorage
|
|
func NewGetSharedStorageRequest(server string, audience ManagerVariableAudience, platform string) (*http.Request, error) {
|
|
var err error
|
|
|
|
var pathParam0 string
|
|
|
|
pathParam0, err = runtime.StyleParamWithLocation("simple", false, "audience", runtime.ParamLocationPath, audience)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
var pathParam1 string
|
|
|
|
pathParam1, err = runtime.StyleParamWithLocation("simple", false, "platform", runtime.ParamLocationPath, platform)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/configuration/shared-storage/%s/%s", pathParam0, pathParam1)
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("GET", queryURL.String(), nil)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewGetVariablesRequest generates requests for GetVariables
|
|
func NewGetVariablesRequest(server string, audience ManagerVariableAudience, platform string) (*http.Request, error) {
|
|
var err error
|
|
|
|
var pathParam0 string
|
|
|
|
pathParam0, err = runtime.StyleParamWithLocation("simple", false, "audience", runtime.ParamLocationPath, audience)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
var pathParam1 string
|
|
|
|
pathParam1, err = runtime.StyleParamWithLocation("simple", false, "platform", runtime.ParamLocationPath, platform)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/configuration/variables/%s/%s", pathParam0, pathParam1)
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("GET", queryURL.String(), nil)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewSubmitJobRequest calls the generic SubmitJob builder with application/json body
|
|
func NewSubmitJobRequest(server string, body SubmitJobJSONRequestBody) (*http.Request, error) {
|
|
var bodyReader io.Reader
|
|
buf, err := json.Marshal(body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
bodyReader = bytes.NewReader(buf)
|
|
return NewSubmitJobRequestWithBody(server, "application/json", bodyReader)
|
|
}
|
|
|
|
// NewSubmitJobRequestWithBody generates requests for SubmitJob with any type of body
|
|
func NewSubmitJobRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) {
|
|
var err error
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/jobs")
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("POST", queryURL.String(), body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req.Header.Add("Content-Type", contentType)
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewSubmitJobCheckRequest calls the generic SubmitJobCheck builder with application/json body
|
|
func NewSubmitJobCheckRequest(server string, body SubmitJobCheckJSONRequestBody) (*http.Request, error) {
|
|
var bodyReader io.Reader
|
|
buf, err := json.Marshal(body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
bodyReader = bytes.NewReader(buf)
|
|
return NewSubmitJobCheckRequestWithBody(server, "application/json", bodyReader)
|
|
}
|
|
|
|
// NewSubmitJobCheckRequestWithBody generates requests for SubmitJobCheck with any type of body
|
|
func NewSubmitJobCheckRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) {
|
|
var err error
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/jobs/check")
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("POST", queryURL.String(), body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req.Header.Add("Content-Type", contentType)
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewFetchGlobalLastRenderedInfoRequest generates requests for FetchGlobalLastRenderedInfo
|
|
func NewFetchGlobalLastRenderedInfoRequest(server string) (*http.Request, error) {
|
|
var err error
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/jobs/last-rendered")
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("GET", queryURL.String(), nil)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewDeleteJobMassRequest calls the generic DeleteJobMass builder with application/json body
|
|
func NewDeleteJobMassRequest(server string, body DeleteJobMassJSONRequestBody) (*http.Request, error) {
|
|
var bodyReader io.Reader
|
|
buf, err := json.Marshal(body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
bodyReader = bytes.NewReader(buf)
|
|
return NewDeleteJobMassRequestWithBody(server, "application/json", bodyReader)
|
|
}
|
|
|
|
// NewDeleteJobMassRequestWithBody generates requests for DeleteJobMass with any type of body
|
|
func NewDeleteJobMassRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) {
|
|
var err error
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/jobs/mass-delete")
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("DELETE", queryURL.String(), body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req.Header.Add("Content-Type", contentType)
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewQueryJobsRequest calls the generic QueryJobs builder with application/json body
|
|
func NewQueryJobsRequest(server string, body QueryJobsJSONRequestBody) (*http.Request, error) {
|
|
var bodyReader io.Reader
|
|
buf, err := json.Marshal(body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
bodyReader = bytes.NewReader(buf)
|
|
return NewQueryJobsRequestWithBody(server, "application/json", bodyReader)
|
|
}
|
|
|
|
// NewQueryJobsRequestWithBody generates requests for QueryJobs with any type of body
|
|
func NewQueryJobsRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) {
|
|
var err error
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/jobs/query")
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("POST", queryURL.String(), body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req.Header.Add("Content-Type", contentType)
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewGetJobTypeRequest generates requests for GetJobType
|
|
func NewGetJobTypeRequest(server string, typeName string) (*http.Request, error) {
|
|
var err error
|
|
|
|
var pathParam0 string
|
|
|
|
pathParam0, err = runtime.StyleParamWithLocation("simple", false, "typeName", runtime.ParamLocationPath, typeName)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/jobs/type/%s", pathParam0)
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("GET", queryURL.String(), nil)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewGetJobTypesRequest generates requests for GetJobTypes
|
|
func NewGetJobTypesRequest(server string) (*http.Request, error) {
|
|
var err error
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/jobs/types")
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("GET", queryURL.String(), nil)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewDeleteJobRequest generates requests for DeleteJob
|
|
func NewDeleteJobRequest(server string, jobId string) (*http.Request, error) {
|
|
var err error
|
|
|
|
var pathParam0 string
|
|
|
|
pathParam0, err = runtime.StyleParamWithLocation("simple", false, "job_id", runtime.ParamLocationPath, jobId)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/jobs/%s", pathParam0)
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("DELETE", queryURL.String(), nil)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewFetchJobRequest generates requests for FetchJob
|
|
func NewFetchJobRequest(server string, jobId string) (*http.Request, error) {
|
|
var err error
|
|
|
|
var pathParam0 string
|
|
|
|
pathParam0, err = runtime.StyleParamWithLocation("simple", false, "job_id", runtime.ParamLocationPath, jobId)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/jobs/%s", pathParam0)
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("GET", queryURL.String(), nil)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewRemoveJobBlocklistRequest calls the generic RemoveJobBlocklist builder with application/json body
|
|
func NewRemoveJobBlocklistRequest(server string, jobId string, body RemoveJobBlocklistJSONRequestBody) (*http.Request, error) {
|
|
var bodyReader io.Reader
|
|
buf, err := json.Marshal(body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
bodyReader = bytes.NewReader(buf)
|
|
return NewRemoveJobBlocklistRequestWithBody(server, jobId, "application/json", bodyReader)
|
|
}
|
|
|
|
// NewRemoveJobBlocklistRequestWithBody generates requests for RemoveJobBlocklist with any type of body
|
|
func NewRemoveJobBlocklistRequestWithBody(server string, jobId string, contentType string, body io.Reader) (*http.Request, error) {
|
|
var err error
|
|
|
|
var pathParam0 string
|
|
|
|
pathParam0, err = runtime.StyleParamWithLocation("simple", false, "job_id", runtime.ParamLocationPath, jobId)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/jobs/%s/blocklist", pathParam0)
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("DELETE", queryURL.String(), body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req.Header.Add("Content-Type", contentType)
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewFetchJobBlocklistRequest generates requests for FetchJobBlocklist
|
|
func NewFetchJobBlocklistRequest(server string, jobId string) (*http.Request, error) {
|
|
var err error
|
|
|
|
var pathParam0 string
|
|
|
|
pathParam0, err = runtime.StyleParamWithLocation("simple", false, "job_id", runtime.ParamLocationPath, jobId)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/jobs/%s/blocklist", pathParam0)
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("GET", queryURL.String(), nil)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewFetchJobLastRenderedInfoRequest generates requests for FetchJobLastRenderedInfo
|
|
func NewFetchJobLastRenderedInfoRequest(server string, jobId string) (*http.Request, error) {
|
|
var err error
|
|
|
|
var pathParam0 string
|
|
|
|
pathParam0, err = runtime.StyleParamWithLocation("simple", false, "job_id", runtime.ParamLocationPath, jobId)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/jobs/%s/last-rendered", pathParam0)
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("GET", queryURL.String(), nil)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewSetJobPriorityRequest calls the generic SetJobPriority builder with application/json body
|
|
func NewSetJobPriorityRequest(server string, jobId string, body SetJobPriorityJSONRequestBody) (*http.Request, error) {
|
|
var bodyReader io.Reader
|
|
buf, err := json.Marshal(body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
bodyReader = bytes.NewReader(buf)
|
|
return NewSetJobPriorityRequestWithBody(server, jobId, "application/json", bodyReader)
|
|
}
|
|
|
|
// NewSetJobPriorityRequestWithBody generates requests for SetJobPriority with any type of body
|
|
func NewSetJobPriorityRequestWithBody(server string, jobId string, contentType string, body io.Reader) (*http.Request, error) {
|
|
var err error
|
|
|
|
var pathParam0 string
|
|
|
|
pathParam0, err = runtime.StyleParamWithLocation("simple", false, "job_id", runtime.ParamLocationPath, jobId)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/jobs/%s/setpriority", pathParam0)
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("POST", queryURL.String(), body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req.Header.Add("Content-Type", contentType)
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewSetJobStatusRequest calls the generic SetJobStatus builder with application/json body
|
|
func NewSetJobStatusRequest(server string, jobId string, body SetJobStatusJSONRequestBody) (*http.Request, error) {
|
|
var bodyReader io.Reader
|
|
buf, err := json.Marshal(body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
bodyReader = bytes.NewReader(buf)
|
|
return NewSetJobStatusRequestWithBody(server, jobId, "application/json", bodyReader)
|
|
}
|
|
|
|
// NewSetJobStatusRequestWithBody generates requests for SetJobStatus with any type of body
|
|
func NewSetJobStatusRequestWithBody(server string, jobId string, contentType string, body io.Reader) (*http.Request, error) {
|
|
var err error
|
|
|
|
var pathParam0 string
|
|
|
|
pathParam0, err = runtime.StyleParamWithLocation("simple", false, "job_id", runtime.ParamLocationPath, jobId)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/jobs/%s/setstatus", pathParam0)
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("POST", queryURL.String(), body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req.Header.Add("Content-Type", contentType)
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewFetchJobTasksRequest generates requests for FetchJobTasks
|
|
func NewFetchJobTasksRequest(server string, jobId string) (*http.Request, error) {
|
|
var err error
|
|
|
|
var pathParam0 string
|
|
|
|
pathParam0, err = runtime.StyleParamWithLocation("simple", false, "job_id", runtime.ParamLocationPath, jobId)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/jobs/%s/tasks", pathParam0)
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("GET", queryURL.String(), nil)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewDeleteJobWhatWouldItDoRequest generates requests for DeleteJobWhatWouldItDo
|
|
func NewDeleteJobWhatWouldItDoRequest(server string, jobId string) (*http.Request, error) {
|
|
var err error
|
|
|
|
var pathParam0 string
|
|
|
|
pathParam0, err = runtime.StyleParamWithLocation("simple", false, "job_id", runtime.ParamLocationPath, jobId)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/jobs/%s/what-would-delete-do", pathParam0)
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("GET", queryURL.String(), nil)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewShamanCheckoutRequest calls the generic ShamanCheckout builder with application/json body
|
|
func NewShamanCheckoutRequest(server string, body ShamanCheckoutJSONRequestBody) (*http.Request, error) {
|
|
var bodyReader io.Reader
|
|
buf, err := json.Marshal(body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
bodyReader = bytes.NewReader(buf)
|
|
return NewShamanCheckoutRequestWithBody(server, "application/json", bodyReader)
|
|
}
|
|
|
|
// NewShamanCheckoutRequestWithBody generates requests for ShamanCheckout with any type of body
|
|
func NewShamanCheckoutRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) {
|
|
var err error
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/shaman/checkout/create")
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("POST", queryURL.String(), body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req.Header.Add("Content-Type", contentType)
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewShamanCheckoutRequirementsRequest calls the generic ShamanCheckoutRequirements builder with application/json body
|
|
func NewShamanCheckoutRequirementsRequest(server string, body ShamanCheckoutRequirementsJSONRequestBody) (*http.Request, error) {
|
|
var bodyReader io.Reader
|
|
buf, err := json.Marshal(body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
bodyReader = bytes.NewReader(buf)
|
|
return NewShamanCheckoutRequirementsRequestWithBody(server, "application/json", bodyReader)
|
|
}
|
|
|
|
// NewShamanCheckoutRequirementsRequestWithBody generates requests for ShamanCheckoutRequirements with any type of body
|
|
func NewShamanCheckoutRequirementsRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) {
|
|
var err error
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/shaman/checkout/requirements")
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("POST", queryURL.String(), body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req.Header.Add("Content-Type", contentType)
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewShamanFileStoreCheckRequest generates requests for ShamanFileStoreCheck
|
|
func NewShamanFileStoreCheckRequest(server string, checksum string, filesize int) (*http.Request, error) {
|
|
var err error
|
|
|
|
var pathParam0 string
|
|
|
|
pathParam0, err = runtime.StyleParamWithLocation("simple", false, "checksum", runtime.ParamLocationPath, checksum)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
var pathParam1 string
|
|
|
|
pathParam1, err = runtime.StyleParamWithLocation("simple", false, "filesize", runtime.ParamLocationPath, filesize)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/shaman/files/%s/%s", pathParam0, pathParam1)
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("GET", queryURL.String(), nil)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewShamanFileStoreRequestWithBody generates requests for ShamanFileStore with any type of body
|
|
func NewShamanFileStoreRequestWithBody(server string, checksum string, filesize int, params *ShamanFileStoreParams, contentType string, body io.Reader) (*http.Request, error) {
|
|
var err error
|
|
|
|
var pathParam0 string
|
|
|
|
pathParam0, err = runtime.StyleParamWithLocation("simple", false, "checksum", runtime.ParamLocationPath, checksum)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
var pathParam1 string
|
|
|
|
pathParam1, err = runtime.StyleParamWithLocation("simple", false, "filesize", runtime.ParamLocationPath, filesize)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/shaman/files/%s/%s", pathParam0, pathParam1)
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("POST", queryURL.String(), body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req.Header.Add("Content-Type", contentType)
|
|
|
|
if params.XShamanCanDeferUpload != nil {
|
|
var headerParam0 string
|
|
|
|
headerParam0, err = runtime.StyleParamWithLocation("simple", false, "X-Shaman-Can-Defer-Upload", runtime.ParamLocationHeader, *params.XShamanCanDeferUpload)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req.Header.Set("X-Shaman-Can-Defer-Upload", headerParam0)
|
|
}
|
|
|
|
if params.XShamanOriginalFilename != nil {
|
|
var headerParam1 string
|
|
|
|
headerParam1, err = runtime.StyleParamWithLocation("simple", false, "X-Shaman-Original-Filename", runtime.ParamLocationHeader, *params.XShamanOriginalFilename)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req.Header.Set("X-Shaman-Original-Filename", headerParam1)
|
|
}
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewFetchTaskRequest generates requests for FetchTask
|
|
func NewFetchTaskRequest(server string, taskId string) (*http.Request, error) {
|
|
var err error
|
|
|
|
var pathParam0 string
|
|
|
|
pathParam0, err = runtime.StyleParamWithLocation("simple", false, "task_id", runtime.ParamLocationPath, taskId)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/tasks/%s", pathParam0)
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("GET", queryURL.String(), nil)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewFetchTaskLogInfoRequest generates requests for FetchTaskLogInfo
|
|
func NewFetchTaskLogInfoRequest(server string, taskId string) (*http.Request, error) {
|
|
var err error
|
|
|
|
var pathParam0 string
|
|
|
|
pathParam0, err = runtime.StyleParamWithLocation("simple", false, "task_id", runtime.ParamLocationPath, taskId)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/tasks/%s/log", pathParam0)
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("GET", queryURL.String(), nil)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewFetchTaskLogTailRequest generates requests for FetchTaskLogTail
|
|
func NewFetchTaskLogTailRequest(server string, taskId string) (*http.Request, error) {
|
|
var err error
|
|
|
|
var pathParam0 string
|
|
|
|
pathParam0, err = runtime.StyleParamWithLocation("simple", false, "task_id", runtime.ParamLocationPath, taskId)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/tasks/%s/logtail", pathParam0)
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("GET", queryURL.String(), nil)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewSetTaskStatusRequest calls the generic SetTaskStatus builder with application/json body
|
|
func NewSetTaskStatusRequest(server string, taskId string, body SetTaskStatusJSONRequestBody) (*http.Request, error) {
|
|
var bodyReader io.Reader
|
|
buf, err := json.Marshal(body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
bodyReader = bytes.NewReader(buf)
|
|
return NewSetTaskStatusRequestWithBody(server, taskId, "application/json", bodyReader)
|
|
}
|
|
|
|
// NewSetTaskStatusRequestWithBody generates requests for SetTaskStatus with any type of body
|
|
func NewSetTaskStatusRequestWithBody(server string, taskId string, contentType string, body io.Reader) (*http.Request, error) {
|
|
var err error
|
|
|
|
var pathParam0 string
|
|
|
|
pathParam0, err = runtime.StyleParamWithLocation("simple", false, "task_id", runtime.ParamLocationPath, taskId)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/tasks/%s/setstatus", pathParam0)
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("POST", queryURL.String(), body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req.Header.Add("Content-Type", contentType)
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewGetVersionRequest generates requests for GetVersion
|
|
func NewGetVersionRequest(server string) (*http.Request, error) {
|
|
var err error
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/version")
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("GET", queryURL.String(), nil)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewDeleteWorkerTagRequest generates requests for DeleteWorkerTag
|
|
func NewDeleteWorkerTagRequest(server string, tagId string) (*http.Request, error) {
|
|
var err error
|
|
|
|
var pathParam0 string
|
|
|
|
pathParam0, err = runtime.StyleParamWithLocation("simple", false, "tag_id", runtime.ParamLocationPath, tagId)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/worker-mgt/tag/%s", pathParam0)
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("DELETE", queryURL.String(), nil)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewFetchWorkerTagRequest generates requests for FetchWorkerTag
|
|
func NewFetchWorkerTagRequest(server string, tagId string) (*http.Request, error) {
|
|
var err error
|
|
|
|
var pathParam0 string
|
|
|
|
pathParam0, err = runtime.StyleParamWithLocation("simple", false, "tag_id", runtime.ParamLocationPath, tagId)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/worker-mgt/tag/%s", pathParam0)
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("GET", queryURL.String(), nil)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewUpdateWorkerTagRequest calls the generic UpdateWorkerTag builder with application/json body
|
|
func NewUpdateWorkerTagRequest(server string, tagId string, body UpdateWorkerTagJSONRequestBody) (*http.Request, error) {
|
|
var bodyReader io.Reader
|
|
buf, err := json.Marshal(body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
bodyReader = bytes.NewReader(buf)
|
|
return NewUpdateWorkerTagRequestWithBody(server, tagId, "application/json", bodyReader)
|
|
}
|
|
|
|
// NewUpdateWorkerTagRequestWithBody generates requests for UpdateWorkerTag with any type of body
|
|
func NewUpdateWorkerTagRequestWithBody(server string, tagId string, contentType string, body io.Reader) (*http.Request, error) {
|
|
var err error
|
|
|
|
var pathParam0 string
|
|
|
|
pathParam0, err = runtime.StyleParamWithLocation("simple", false, "tag_id", runtime.ParamLocationPath, tagId)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/worker-mgt/tag/%s", pathParam0)
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("PUT", queryURL.String(), body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req.Header.Add("Content-Type", contentType)
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewFetchWorkerTagsRequest generates requests for FetchWorkerTags
|
|
func NewFetchWorkerTagsRequest(server string) (*http.Request, error) {
|
|
var err error
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/worker-mgt/tags")
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("GET", queryURL.String(), nil)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewCreateWorkerTagRequest calls the generic CreateWorkerTag builder with application/json body
|
|
func NewCreateWorkerTagRequest(server string, body CreateWorkerTagJSONRequestBody) (*http.Request, error) {
|
|
var bodyReader io.Reader
|
|
buf, err := json.Marshal(body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
bodyReader = bytes.NewReader(buf)
|
|
return NewCreateWorkerTagRequestWithBody(server, "application/json", bodyReader)
|
|
}
|
|
|
|
// NewCreateWorkerTagRequestWithBody generates requests for CreateWorkerTag with any type of body
|
|
func NewCreateWorkerTagRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) {
|
|
var err error
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/worker-mgt/tags")
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("POST", queryURL.String(), body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req.Header.Add("Content-Type", contentType)
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewFetchWorkersRequest generates requests for FetchWorkers
|
|
func NewFetchWorkersRequest(server string) (*http.Request, error) {
|
|
var err error
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/worker-mgt/workers")
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("GET", queryURL.String(), nil)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewDeleteWorkerRequest generates requests for DeleteWorker
|
|
func NewDeleteWorkerRequest(server string, workerId string) (*http.Request, error) {
|
|
var err error
|
|
|
|
var pathParam0 string
|
|
|
|
pathParam0, err = runtime.StyleParamWithLocation("simple", false, "worker_id", runtime.ParamLocationPath, workerId)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/worker-mgt/workers/%s", pathParam0)
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("DELETE", queryURL.String(), nil)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewFetchWorkerRequest generates requests for FetchWorker
|
|
func NewFetchWorkerRequest(server string, workerId string) (*http.Request, error) {
|
|
var err error
|
|
|
|
var pathParam0 string
|
|
|
|
pathParam0, err = runtime.StyleParamWithLocation("simple", false, "worker_id", runtime.ParamLocationPath, workerId)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/worker-mgt/workers/%s", pathParam0)
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("GET", queryURL.String(), nil)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewRequestWorkerStatusChangeRequest calls the generic RequestWorkerStatusChange builder with application/json body
|
|
func NewRequestWorkerStatusChangeRequest(server string, workerId string, body RequestWorkerStatusChangeJSONRequestBody) (*http.Request, error) {
|
|
var bodyReader io.Reader
|
|
buf, err := json.Marshal(body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
bodyReader = bytes.NewReader(buf)
|
|
return NewRequestWorkerStatusChangeRequestWithBody(server, workerId, "application/json", bodyReader)
|
|
}
|
|
|
|
// NewRequestWorkerStatusChangeRequestWithBody generates requests for RequestWorkerStatusChange with any type of body
|
|
func NewRequestWorkerStatusChangeRequestWithBody(server string, workerId string, contentType string, body io.Reader) (*http.Request, error) {
|
|
var err error
|
|
|
|
var pathParam0 string
|
|
|
|
pathParam0, err = runtime.StyleParamWithLocation("simple", false, "worker_id", runtime.ParamLocationPath, workerId)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/worker-mgt/workers/%s/setstatus", pathParam0)
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("POST", queryURL.String(), body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req.Header.Add("Content-Type", contentType)
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewSetWorkerTagsRequest calls the generic SetWorkerTags builder with application/json body
|
|
func NewSetWorkerTagsRequest(server string, workerId string, body SetWorkerTagsJSONRequestBody) (*http.Request, error) {
|
|
var bodyReader io.Reader
|
|
buf, err := json.Marshal(body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
bodyReader = bytes.NewReader(buf)
|
|
return NewSetWorkerTagsRequestWithBody(server, workerId, "application/json", bodyReader)
|
|
}
|
|
|
|
// NewSetWorkerTagsRequestWithBody generates requests for SetWorkerTags with any type of body
|
|
func NewSetWorkerTagsRequestWithBody(server string, workerId string, contentType string, body io.Reader) (*http.Request, error) {
|
|
var err error
|
|
|
|
var pathParam0 string
|
|
|
|
pathParam0, err = runtime.StyleParamWithLocation("simple", false, "worker_id", runtime.ParamLocationPath, workerId)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/worker-mgt/workers/%s/settags", pathParam0)
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("POST", queryURL.String(), body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req.Header.Add("Content-Type", contentType)
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewFetchWorkerSleepScheduleRequest generates requests for FetchWorkerSleepSchedule
|
|
func NewFetchWorkerSleepScheduleRequest(server string, workerId string) (*http.Request, error) {
|
|
var err error
|
|
|
|
var pathParam0 string
|
|
|
|
pathParam0, err = runtime.StyleParamWithLocation("simple", false, "worker_id", runtime.ParamLocationPath, workerId)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/worker-mgt/workers/%s/sleep-schedule", pathParam0)
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("GET", queryURL.String(), nil)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewSetWorkerSleepScheduleRequest calls the generic SetWorkerSleepSchedule builder with application/json body
|
|
func NewSetWorkerSleepScheduleRequest(server string, workerId string, body SetWorkerSleepScheduleJSONRequestBody) (*http.Request, error) {
|
|
var bodyReader io.Reader
|
|
buf, err := json.Marshal(body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
bodyReader = bytes.NewReader(buf)
|
|
return NewSetWorkerSleepScheduleRequestWithBody(server, workerId, "application/json", bodyReader)
|
|
}
|
|
|
|
// NewSetWorkerSleepScheduleRequestWithBody generates requests for SetWorkerSleepSchedule with any type of body
|
|
func NewSetWorkerSleepScheduleRequestWithBody(server string, workerId string, contentType string, body io.Reader) (*http.Request, error) {
|
|
var err error
|
|
|
|
var pathParam0 string
|
|
|
|
pathParam0, err = runtime.StyleParamWithLocation("simple", false, "worker_id", runtime.ParamLocationPath, workerId)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/worker-mgt/workers/%s/sleep-schedule", pathParam0)
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("POST", queryURL.String(), body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req.Header.Add("Content-Type", contentType)
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewRegisterWorkerRequest calls the generic RegisterWorker builder with application/json body
|
|
func NewRegisterWorkerRequest(server string, body RegisterWorkerJSONRequestBody) (*http.Request, error) {
|
|
var bodyReader io.Reader
|
|
buf, err := json.Marshal(body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
bodyReader = bytes.NewReader(buf)
|
|
return NewRegisterWorkerRequestWithBody(server, "application/json", bodyReader)
|
|
}
|
|
|
|
// NewRegisterWorkerRequestWithBody generates requests for RegisterWorker with any type of body
|
|
func NewRegisterWorkerRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) {
|
|
var err error
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/worker/register-worker")
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("POST", queryURL.String(), body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req.Header.Add("Content-Type", contentType)
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewSignOffRequest generates requests for SignOff
|
|
func NewSignOffRequest(server string) (*http.Request, error) {
|
|
var err error
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/worker/sign-off")
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("POST", queryURL.String(), nil)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewSignOnRequest calls the generic SignOn builder with application/json body
|
|
func NewSignOnRequest(server string, body SignOnJSONRequestBody) (*http.Request, error) {
|
|
var bodyReader io.Reader
|
|
buf, err := json.Marshal(body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
bodyReader = bytes.NewReader(buf)
|
|
return NewSignOnRequestWithBody(server, "application/json", bodyReader)
|
|
}
|
|
|
|
// NewSignOnRequestWithBody generates requests for SignOn with any type of body
|
|
func NewSignOnRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) {
|
|
var err error
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/worker/sign-on")
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("POST", queryURL.String(), body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req.Header.Add("Content-Type", contentType)
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewWorkerStateRequest generates requests for WorkerState
|
|
func NewWorkerStateRequest(server string) (*http.Request, error) {
|
|
var err error
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/worker/state")
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("GET", queryURL.String(), nil)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewWorkerStateChangedRequest calls the generic WorkerStateChanged builder with application/json body
|
|
func NewWorkerStateChangedRequest(server string, body WorkerStateChangedJSONRequestBody) (*http.Request, error) {
|
|
var bodyReader io.Reader
|
|
buf, err := json.Marshal(body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
bodyReader = bytes.NewReader(buf)
|
|
return NewWorkerStateChangedRequestWithBody(server, "application/json", bodyReader)
|
|
}
|
|
|
|
// NewWorkerStateChangedRequestWithBody generates requests for WorkerStateChanged with any type of body
|
|
func NewWorkerStateChangedRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) {
|
|
var err error
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/worker/state-changed")
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("POST", queryURL.String(), body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req.Header.Add("Content-Type", contentType)
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewScheduleTaskRequest generates requests for ScheduleTask
|
|
func NewScheduleTaskRequest(server string) (*http.Request, error) {
|
|
var err error
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/worker/task")
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("POST", queryURL.String(), nil)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewTaskUpdateRequest calls the generic TaskUpdate builder with application/json body
|
|
func NewTaskUpdateRequest(server string, taskId string, body TaskUpdateJSONRequestBody) (*http.Request, error) {
|
|
var bodyReader io.Reader
|
|
buf, err := json.Marshal(body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
bodyReader = bytes.NewReader(buf)
|
|
return NewTaskUpdateRequestWithBody(server, taskId, "application/json", bodyReader)
|
|
}
|
|
|
|
// NewTaskUpdateRequestWithBody generates requests for TaskUpdate with any type of body
|
|
func NewTaskUpdateRequestWithBody(server string, taskId string, contentType string, body io.Reader) (*http.Request, error) {
|
|
var err error
|
|
|
|
var pathParam0 string
|
|
|
|
pathParam0, err = runtime.StyleParamWithLocation("simple", false, "task_id", runtime.ParamLocationPath, taskId)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/worker/task/%s", pathParam0)
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("POST", queryURL.String(), body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req.Header.Add("Content-Type", contentType)
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewMayWorkerRunRequest generates requests for MayWorkerRun
|
|
func NewMayWorkerRunRequest(server string, taskId string) (*http.Request, error) {
|
|
var err error
|
|
|
|
var pathParam0 string
|
|
|
|
pathParam0, err = runtime.StyleParamWithLocation("simple", false, "task_id", runtime.ParamLocationPath, taskId)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/worker/task/%s/may-i-run", pathParam0)
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("GET", queryURL.String(), nil)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
return req, nil
|
|
}
|
|
|
|
// NewTaskOutputProducedRequestWithBody generates requests for TaskOutputProduced with any type of body
|
|
func NewTaskOutputProducedRequestWithBody(server string, taskId string, contentType string, body io.Reader) (*http.Request, error) {
|
|
var err error
|
|
|
|
var pathParam0 string
|
|
|
|
pathParam0, err = runtime.StyleParamWithLocation("simple", false, "task_id", runtime.ParamLocationPath, taskId)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
serverURL, err := url.Parse(server)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
operationPath := fmt.Sprintf("/api/v3/worker/task/%s/output-produced", pathParam0)
|
|
if operationPath[0] == '/' {
|
|
operationPath = "." + operationPath
|
|
}
|
|
|
|
queryURL, err := serverURL.Parse(operationPath)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req, err := http.NewRequest("POST", queryURL.String(), body)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
req.Header.Add("Content-Type", contentType)
|
|
|
|
return req, nil
|
|
}
|
|
|
|
func (c *Client) applyEditors(ctx context.Context, req *http.Request, additionalEditors []RequestEditorFn) error {
|
|
for _, r := range c.RequestEditors {
|
|
if err := r(ctx, req); err != nil {
|
|
return err
|
|
}
|
|
}
|
|
for _, r := range additionalEditors {
|
|
if err := r(ctx, req); err != nil {
|
|
return err
|
|
}
|
|
}
|
|
return nil
|
|
}
|
|
|
|
// ClientWithResponses builds on ClientInterface to offer response payloads
|
|
type ClientWithResponses struct {
|
|
ClientInterface
|
|
}
|
|
|
|
// NewClientWithResponses creates a new ClientWithResponses, which wraps
|
|
// Client with return type handling
|
|
func NewClientWithResponses(server string, opts ...ClientOption) (*ClientWithResponses, error) {
|
|
client, err := NewClient(server, opts...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return &ClientWithResponses{client}, nil
|
|
}
|
|
|
|
// WithBaseURL overrides the baseURL.
|
|
func WithBaseURL(baseURL string) ClientOption {
|
|
return func(c *Client) error {
|
|
newBaseURL, err := url.Parse(baseURL)
|
|
if err != nil {
|
|
return err
|
|
}
|
|
c.Server = newBaseURL.String()
|
|
return nil
|
|
}
|
|
}
|
|
|
|
// ClientWithResponsesInterface is the interface specification for the client with responses above.
|
|
type ClientWithResponsesInterface interface {
|
|
// GetConfiguration request
|
|
GetConfigurationWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetConfigurationResponse, error)
|
|
|
|
// FindBlenderExePath request
|
|
FindBlenderExePathWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*FindBlenderExePathResponse, error)
|
|
|
|
// CheckBlenderExePath request with any body
|
|
CheckBlenderExePathWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CheckBlenderExePathResponse, error)
|
|
|
|
CheckBlenderExePathWithResponse(ctx context.Context, body CheckBlenderExePathJSONRequestBody, reqEditors ...RequestEditorFn) (*CheckBlenderExePathResponse, error)
|
|
|
|
// CheckSharedStoragePath request with any body
|
|
CheckSharedStoragePathWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CheckSharedStoragePathResponse, error)
|
|
|
|
CheckSharedStoragePathWithResponse(ctx context.Context, body CheckSharedStoragePathJSONRequestBody, reqEditors ...RequestEditorFn) (*CheckSharedStoragePathResponse, error)
|
|
|
|
// GetConfigurationFile request
|
|
GetConfigurationFileWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetConfigurationFileResponse, error)
|
|
|
|
// SaveSetupAssistantConfig request with any body
|
|
SaveSetupAssistantConfigWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SaveSetupAssistantConfigResponse, error)
|
|
|
|
SaveSetupAssistantConfigWithResponse(ctx context.Context, body SaveSetupAssistantConfigJSONRequestBody, reqEditors ...RequestEditorFn) (*SaveSetupAssistantConfigResponse, error)
|
|
|
|
// GetSharedStorage request
|
|
GetSharedStorageWithResponse(ctx context.Context, audience ManagerVariableAudience, platform string, reqEditors ...RequestEditorFn) (*GetSharedStorageResponse, error)
|
|
|
|
// GetVariables request
|
|
GetVariablesWithResponse(ctx context.Context, audience ManagerVariableAudience, platform string, reqEditors ...RequestEditorFn) (*GetVariablesResponse, error)
|
|
|
|
// SubmitJob request with any body
|
|
SubmitJobWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SubmitJobResponse, error)
|
|
|
|
SubmitJobWithResponse(ctx context.Context, body SubmitJobJSONRequestBody, reqEditors ...RequestEditorFn) (*SubmitJobResponse, error)
|
|
|
|
// SubmitJobCheck request with any body
|
|
SubmitJobCheckWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SubmitJobCheckResponse, error)
|
|
|
|
SubmitJobCheckWithResponse(ctx context.Context, body SubmitJobCheckJSONRequestBody, reqEditors ...RequestEditorFn) (*SubmitJobCheckResponse, error)
|
|
|
|
// FetchGlobalLastRenderedInfo request
|
|
FetchGlobalLastRenderedInfoWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*FetchGlobalLastRenderedInfoResponse, error)
|
|
|
|
// DeleteJobMass request with any body
|
|
DeleteJobMassWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeleteJobMassResponse, error)
|
|
|
|
DeleteJobMassWithResponse(ctx context.Context, body DeleteJobMassJSONRequestBody, reqEditors ...RequestEditorFn) (*DeleteJobMassResponse, error)
|
|
|
|
// QueryJobs request with any body
|
|
QueryJobsWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*QueryJobsResponse, error)
|
|
|
|
QueryJobsWithResponse(ctx context.Context, body QueryJobsJSONRequestBody, reqEditors ...RequestEditorFn) (*QueryJobsResponse, error)
|
|
|
|
// GetJobType request
|
|
GetJobTypeWithResponse(ctx context.Context, typeName string, reqEditors ...RequestEditorFn) (*GetJobTypeResponse, error)
|
|
|
|
// GetJobTypes request
|
|
GetJobTypesWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetJobTypesResponse, error)
|
|
|
|
// DeleteJob request
|
|
DeleteJobWithResponse(ctx context.Context, jobId string, reqEditors ...RequestEditorFn) (*DeleteJobResponse, error)
|
|
|
|
// FetchJob request
|
|
FetchJobWithResponse(ctx context.Context, jobId string, reqEditors ...RequestEditorFn) (*FetchJobResponse, error)
|
|
|
|
// RemoveJobBlocklist request with any body
|
|
RemoveJobBlocklistWithBodyWithResponse(ctx context.Context, jobId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*RemoveJobBlocklistResponse, error)
|
|
|
|
RemoveJobBlocklistWithResponse(ctx context.Context, jobId string, body RemoveJobBlocklistJSONRequestBody, reqEditors ...RequestEditorFn) (*RemoveJobBlocklistResponse, error)
|
|
|
|
// FetchJobBlocklist request
|
|
FetchJobBlocklistWithResponse(ctx context.Context, jobId string, reqEditors ...RequestEditorFn) (*FetchJobBlocklistResponse, error)
|
|
|
|
// FetchJobLastRenderedInfo request
|
|
FetchJobLastRenderedInfoWithResponse(ctx context.Context, jobId string, reqEditors ...RequestEditorFn) (*FetchJobLastRenderedInfoResponse, error)
|
|
|
|
// SetJobPriority request with any body
|
|
SetJobPriorityWithBodyWithResponse(ctx context.Context, jobId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SetJobPriorityResponse, error)
|
|
|
|
SetJobPriorityWithResponse(ctx context.Context, jobId string, body SetJobPriorityJSONRequestBody, reqEditors ...RequestEditorFn) (*SetJobPriorityResponse, error)
|
|
|
|
// SetJobStatus request with any body
|
|
SetJobStatusWithBodyWithResponse(ctx context.Context, jobId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SetJobStatusResponse, error)
|
|
|
|
SetJobStatusWithResponse(ctx context.Context, jobId string, body SetJobStatusJSONRequestBody, reqEditors ...RequestEditorFn) (*SetJobStatusResponse, error)
|
|
|
|
// FetchJobTasks request
|
|
FetchJobTasksWithResponse(ctx context.Context, jobId string, reqEditors ...RequestEditorFn) (*FetchJobTasksResponse, error)
|
|
|
|
// DeleteJobWhatWouldItDo request
|
|
DeleteJobWhatWouldItDoWithResponse(ctx context.Context, jobId string, reqEditors ...RequestEditorFn) (*DeleteJobWhatWouldItDoResponse, error)
|
|
|
|
// ShamanCheckout request with any body
|
|
ShamanCheckoutWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ShamanCheckoutResponse, error)
|
|
|
|
ShamanCheckoutWithResponse(ctx context.Context, body ShamanCheckoutJSONRequestBody, reqEditors ...RequestEditorFn) (*ShamanCheckoutResponse, error)
|
|
|
|
// ShamanCheckoutRequirements request with any body
|
|
ShamanCheckoutRequirementsWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ShamanCheckoutRequirementsResponse, error)
|
|
|
|
ShamanCheckoutRequirementsWithResponse(ctx context.Context, body ShamanCheckoutRequirementsJSONRequestBody, reqEditors ...RequestEditorFn) (*ShamanCheckoutRequirementsResponse, error)
|
|
|
|
// ShamanFileStoreCheck request
|
|
ShamanFileStoreCheckWithResponse(ctx context.Context, checksum string, filesize int, reqEditors ...RequestEditorFn) (*ShamanFileStoreCheckResponse, error)
|
|
|
|
// ShamanFileStore request with any body
|
|
ShamanFileStoreWithBodyWithResponse(ctx context.Context, checksum string, filesize int, params *ShamanFileStoreParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ShamanFileStoreResponse, error)
|
|
|
|
// FetchTask request
|
|
FetchTaskWithResponse(ctx context.Context, taskId string, reqEditors ...RequestEditorFn) (*FetchTaskResponse, error)
|
|
|
|
// FetchTaskLogInfo request
|
|
FetchTaskLogInfoWithResponse(ctx context.Context, taskId string, reqEditors ...RequestEditorFn) (*FetchTaskLogInfoResponse, error)
|
|
|
|
// FetchTaskLogTail request
|
|
FetchTaskLogTailWithResponse(ctx context.Context, taskId string, reqEditors ...RequestEditorFn) (*FetchTaskLogTailResponse, error)
|
|
|
|
// SetTaskStatus request with any body
|
|
SetTaskStatusWithBodyWithResponse(ctx context.Context, taskId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SetTaskStatusResponse, error)
|
|
|
|
SetTaskStatusWithResponse(ctx context.Context, taskId string, body SetTaskStatusJSONRequestBody, reqEditors ...RequestEditorFn) (*SetTaskStatusResponse, error)
|
|
|
|
// GetVersion request
|
|
GetVersionWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetVersionResponse, error)
|
|
|
|
// DeleteWorkerTag request
|
|
DeleteWorkerTagWithResponse(ctx context.Context, tagId string, reqEditors ...RequestEditorFn) (*DeleteWorkerTagResponse, error)
|
|
|
|
// FetchWorkerTag request
|
|
FetchWorkerTagWithResponse(ctx context.Context, tagId string, reqEditors ...RequestEditorFn) (*FetchWorkerTagResponse, error)
|
|
|
|
// UpdateWorkerTag request with any body
|
|
UpdateWorkerTagWithBodyWithResponse(ctx context.Context, tagId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateWorkerTagResponse, error)
|
|
|
|
UpdateWorkerTagWithResponse(ctx context.Context, tagId string, body UpdateWorkerTagJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateWorkerTagResponse, error)
|
|
|
|
// FetchWorkerTags request
|
|
FetchWorkerTagsWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*FetchWorkerTagsResponse, error)
|
|
|
|
// CreateWorkerTag request with any body
|
|
CreateWorkerTagWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateWorkerTagResponse, error)
|
|
|
|
CreateWorkerTagWithResponse(ctx context.Context, body CreateWorkerTagJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateWorkerTagResponse, error)
|
|
|
|
// FetchWorkers request
|
|
FetchWorkersWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*FetchWorkersResponse, error)
|
|
|
|
// DeleteWorker request
|
|
DeleteWorkerWithResponse(ctx context.Context, workerId string, reqEditors ...RequestEditorFn) (*DeleteWorkerResponse, error)
|
|
|
|
// FetchWorker request
|
|
FetchWorkerWithResponse(ctx context.Context, workerId string, reqEditors ...RequestEditorFn) (*FetchWorkerResponse, error)
|
|
|
|
// RequestWorkerStatusChange request with any body
|
|
RequestWorkerStatusChangeWithBodyWithResponse(ctx context.Context, workerId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*RequestWorkerStatusChangeResponse, error)
|
|
|
|
RequestWorkerStatusChangeWithResponse(ctx context.Context, workerId string, body RequestWorkerStatusChangeJSONRequestBody, reqEditors ...RequestEditorFn) (*RequestWorkerStatusChangeResponse, error)
|
|
|
|
// SetWorkerTags request with any body
|
|
SetWorkerTagsWithBodyWithResponse(ctx context.Context, workerId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SetWorkerTagsResponse, error)
|
|
|
|
SetWorkerTagsWithResponse(ctx context.Context, workerId string, body SetWorkerTagsJSONRequestBody, reqEditors ...RequestEditorFn) (*SetWorkerTagsResponse, error)
|
|
|
|
// FetchWorkerSleepSchedule request
|
|
FetchWorkerSleepScheduleWithResponse(ctx context.Context, workerId string, reqEditors ...RequestEditorFn) (*FetchWorkerSleepScheduleResponse, error)
|
|
|
|
// SetWorkerSleepSchedule request with any body
|
|
SetWorkerSleepScheduleWithBodyWithResponse(ctx context.Context, workerId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SetWorkerSleepScheduleResponse, error)
|
|
|
|
SetWorkerSleepScheduleWithResponse(ctx context.Context, workerId string, body SetWorkerSleepScheduleJSONRequestBody, reqEditors ...RequestEditorFn) (*SetWorkerSleepScheduleResponse, error)
|
|
|
|
// RegisterWorker request with any body
|
|
RegisterWorkerWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*RegisterWorkerResponse, error)
|
|
|
|
RegisterWorkerWithResponse(ctx context.Context, body RegisterWorkerJSONRequestBody, reqEditors ...RequestEditorFn) (*RegisterWorkerResponse, error)
|
|
|
|
// SignOff request
|
|
SignOffWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*SignOffResponse, error)
|
|
|
|
// SignOn request with any body
|
|
SignOnWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SignOnResponse, error)
|
|
|
|
SignOnWithResponse(ctx context.Context, body SignOnJSONRequestBody, reqEditors ...RequestEditorFn) (*SignOnResponse, error)
|
|
|
|
// WorkerState request
|
|
WorkerStateWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*WorkerStateResponse, error)
|
|
|
|
// WorkerStateChanged request with any body
|
|
WorkerStateChangedWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*WorkerStateChangedResponse, error)
|
|
|
|
WorkerStateChangedWithResponse(ctx context.Context, body WorkerStateChangedJSONRequestBody, reqEditors ...RequestEditorFn) (*WorkerStateChangedResponse, error)
|
|
|
|
// ScheduleTask request
|
|
ScheduleTaskWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*ScheduleTaskResponse, error)
|
|
|
|
// TaskUpdate request with any body
|
|
TaskUpdateWithBodyWithResponse(ctx context.Context, taskId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*TaskUpdateResponse, error)
|
|
|
|
TaskUpdateWithResponse(ctx context.Context, taskId string, body TaskUpdateJSONRequestBody, reqEditors ...RequestEditorFn) (*TaskUpdateResponse, error)
|
|
|
|
// MayWorkerRun request
|
|
MayWorkerRunWithResponse(ctx context.Context, taskId string, reqEditors ...RequestEditorFn) (*MayWorkerRunResponse, error)
|
|
|
|
// TaskOutputProduced request with any body
|
|
TaskOutputProducedWithBodyWithResponse(ctx context.Context, taskId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*TaskOutputProducedResponse, error)
|
|
}
|
|
|
|
type GetConfigurationResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSON200 *ManagerConfiguration
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r GetConfigurationResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r GetConfigurationResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type FindBlenderExePathResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSON200 *BlenderPathFindResult
|
|
JSONDefault *Error
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r FindBlenderExePathResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r FindBlenderExePathResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type CheckBlenderExePathResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSON200 *BlenderPathCheckResult
|
|
JSONDefault *Error
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r CheckBlenderExePathResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r CheckBlenderExePathResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type CheckSharedStoragePathResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSON200 *PathCheckResult
|
|
JSONDefault *Error
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r CheckSharedStoragePathResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r CheckSharedStoragePathResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type GetConfigurationFileResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSON200 *struct {
|
|
AdditionalProperties map[string]interface{} `json:"-"`
|
|
}
|
|
YAML200 *string
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r GetConfigurationFileResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r GetConfigurationFileResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type SaveSetupAssistantConfigResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSONDefault *Error
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r SaveSetupAssistantConfigResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r SaveSetupAssistantConfigResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type GetSharedStorageResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSON200 *SharedStorageLocation
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r GetSharedStorageResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r GetSharedStorageResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type GetVariablesResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSON200 *ManagerVariables
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r GetVariablesResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r GetVariablesResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type SubmitJobResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSON200 *Job
|
|
JSON412 *Error
|
|
JSONDefault *Error
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r SubmitJobResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r SubmitJobResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type SubmitJobCheckResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSON412 *Error
|
|
JSONDefault *Error
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r SubmitJobCheckResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r SubmitJobCheckResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type FetchGlobalLastRenderedInfoResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSON200 *JobLastRenderedImageInfo
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r FetchGlobalLastRenderedInfoResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r FetchGlobalLastRenderedInfoResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type DeleteJobMassResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSON416 *Error
|
|
JSONDefault *Error
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r DeleteJobMassResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r DeleteJobMassResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type QueryJobsResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSON200 *JobsQueryResult
|
|
JSONDefault *Error
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r QueryJobsResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r QueryJobsResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type GetJobTypeResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSON200 *AvailableJobType
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r GetJobTypeResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r GetJobTypeResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type GetJobTypesResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSON200 *AvailableJobTypes
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r GetJobTypesResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r GetJobTypesResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type DeleteJobResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSONDefault *Error
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r DeleteJobResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r DeleteJobResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type FetchJobResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSON200 *Job
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r FetchJobResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r FetchJobResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type RemoveJobBlocklistResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSONDefault *Error
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r RemoveJobBlocklistResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r RemoveJobBlocklistResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type FetchJobBlocklistResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSON200 *JobBlocklist
|
|
JSONDefault *Error
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r FetchJobBlocklistResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r FetchJobBlocklistResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type FetchJobLastRenderedInfoResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSON200 *JobLastRenderedImageInfo
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r FetchJobLastRenderedInfoResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r FetchJobLastRenderedInfoResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type SetJobPriorityResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSONDefault *Error
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r SetJobPriorityResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r SetJobPriorityResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type SetJobStatusResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSONDefault *Error
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r SetJobStatusResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r SetJobStatusResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type FetchJobTasksResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSON200 *JobTasksSummary
|
|
JSONDefault *Error
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r FetchJobTasksResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r FetchJobTasksResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type DeleteJobWhatWouldItDoResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSON200 *JobDeletionInfo
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r DeleteJobWhatWouldItDoResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r DeleteJobWhatWouldItDoResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type ShamanCheckoutResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSON200 *ShamanCheckoutResult
|
|
JSON409 *Error
|
|
JSON424 *Error
|
|
JSONDefault *Error
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r ShamanCheckoutResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r ShamanCheckoutResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type ShamanCheckoutRequirementsResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSON200 *ShamanRequirementsResponse
|
|
JSONDefault *Error
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r ShamanCheckoutRequirementsResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r ShamanCheckoutRequirementsResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type ShamanFileStoreCheckResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSON200 *ShamanSingleFileStatus
|
|
JSONDefault *Error
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r ShamanFileStoreCheckResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r ShamanFileStoreCheckResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type ShamanFileStoreResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSONDefault *Error
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r ShamanFileStoreResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r ShamanFileStoreResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type FetchTaskResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSON200 *Task
|
|
JSONDefault *Error
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r FetchTaskResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r FetchTaskResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type FetchTaskLogInfoResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSON200 *TaskLogInfo
|
|
JSONDefault *Error
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r FetchTaskLogInfoResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r FetchTaskLogInfoResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type FetchTaskLogTailResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSONDefault *Error
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r FetchTaskLogTailResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r FetchTaskLogTailResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type SetTaskStatusResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSONDefault *Error
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r SetTaskStatusResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r SetTaskStatusResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type GetVersionResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSON200 *FlamencoVersion
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r GetVersionResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r GetVersionResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type DeleteWorkerTagResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSONDefault *Error
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r DeleteWorkerTagResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r DeleteWorkerTagResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type FetchWorkerTagResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSON200 *WorkerTag
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r FetchWorkerTagResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r FetchWorkerTagResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type UpdateWorkerTagResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSONDefault *Error
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r UpdateWorkerTagResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r UpdateWorkerTagResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type FetchWorkerTagsResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSON200 *WorkerTagList
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r FetchWorkerTagsResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r FetchWorkerTagsResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type CreateWorkerTagResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSON200 *WorkerTag
|
|
JSONDefault *Error
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r CreateWorkerTagResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r CreateWorkerTagResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type FetchWorkersResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSON200 *WorkerList
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r FetchWorkersResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r FetchWorkersResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type DeleteWorkerResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSONDefault *Error
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r DeleteWorkerResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r DeleteWorkerResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type FetchWorkerResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSON200 *Worker
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r FetchWorkerResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r FetchWorkerResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type RequestWorkerStatusChangeResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSONDefault *Error
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r RequestWorkerStatusChangeResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r RequestWorkerStatusChangeResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type SetWorkerTagsResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSONDefault *Error
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r SetWorkerTagsResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r SetWorkerTagsResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type FetchWorkerSleepScheduleResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSON200 *WorkerSleepSchedule
|
|
JSONDefault *Error
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r FetchWorkerSleepScheduleResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r FetchWorkerSleepScheduleResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type SetWorkerSleepScheduleResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSONDefault *Error
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r SetWorkerSleepScheduleResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r SetWorkerSleepScheduleResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type RegisterWorkerResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSON200 *RegisteredWorker
|
|
JSONDefault *Error
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r RegisterWorkerResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r RegisterWorkerResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type SignOffResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSONDefault *Error
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r SignOffResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r SignOffResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type SignOnResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSON200 *WorkerStateChange
|
|
JSONDefault *Error
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r SignOnResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r SignOnResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type WorkerStateResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSON200 *WorkerStateChange
|
|
JSONDefault *Error
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r WorkerStateResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r WorkerStateResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type WorkerStateChangedResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSONDefault *Error
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r WorkerStateChangedResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r WorkerStateChangedResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type ScheduleTaskResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSON200 *AssignedTask
|
|
JSON403 *SecurityError
|
|
JSON423 *WorkerStateChange
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r ScheduleTaskResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r ScheduleTaskResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type TaskUpdateResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSONDefault *Error
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r TaskUpdateResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r TaskUpdateResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type MayWorkerRunResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSON200 *MayKeepRunning
|
|
JSONDefault *Error
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r MayWorkerRunResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r MayWorkerRunResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type TaskOutputProducedResponse struct {
|
|
Body []byte
|
|
HTTPResponse *http.Response
|
|
JSON411 *Error
|
|
JSON413 *Error
|
|
JSON415 *Error
|
|
JSON429 *Error
|
|
JSONDefault *Error
|
|
}
|
|
|
|
// Status returns HTTPResponse.Status
|
|
func (r TaskOutputProducedResponse) Status() string {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.Status
|
|
}
|
|
return http.StatusText(0)
|
|
}
|
|
|
|
// StatusCode returns HTTPResponse.StatusCode
|
|
func (r TaskOutputProducedResponse) StatusCode() int {
|
|
if r.HTTPResponse != nil {
|
|
return r.HTTPResponse.StatusCode
|
|
}
|
|
return 0
|
|
}
|
|
|
|
// GetConfigurationWithResponse request returning *GetConfigurationResponse
|
|
func (c *ClientWithResponses) GetConfigurationWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetConfigurationResponse, error) {
|
|
rsp, err := c.GetConfiguration(ctx, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseGetConfigurationResponse(rsp)
|
|
}
|
|
|
|
// FindBlenderExePathWithResponse request returning *FindBlenderExePathResponse
|
|
func (c *ClientWithResponses) FindBlenderExePathWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*FindBlenderExePathResponse, error) {
|
|
rsp, err := c.FindBlenderExePath(ctx, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseFindBlenderExePathResponse(rsp)
|
|
}
|
|
|
|
// CheckBlenderExePathWithBodyWithResponse request with arbitrary body returning *CheckBlenderExePathResponse
|
|
func (c *ClientWithResponses) CheckBlenderExePathWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CheckBlenderExePathResponse, error) {
|
|
rsp, err := c.CheckBlenderExePathWithBody(ctx, contentType, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseCheckBlenderExePathResponse(rsp)
|
|
}
|
|
|
|
func (c *ClientWithResponses) CheckBlenderExePathWithResponse(ctx context.Context, body CheckBlenderExePathJSONRequestBody, reqEditors ...RequestEditorFn) (*CheckBlenderExePathResponse, error) {
|
|
rsp, err := c.CheckBlenderExePath(ctx, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseCheckBlenderExePathResponse(rsp)
|
|
}
|
|
|
|
// CheckSharedStoragePathWithBodyWithResponse request with arbitrary body returning *CheckSharedStoragePathResponse
|
|
func (c *ClientWithResponses) CheckSharedStoragePathWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CheckSharedStoragePathResponse, error) {
|
|
rsp, err := c.CheckSharedStoragePathWithBody(ctx, contentType, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseCheckSharedStoragePathResponse(rsp)
|
|
}
|
|
|
|
func (c *ClientWithResponses) CheckSharedStoragePathWithResponse(ctx context.Context, body CheckSharedStoragePathJSONRequestBody, reqEditors ...RequestEditorFn) (*CheckSharedStoragePathResponse, error) {
|
|
rsp, err := c.CheckSharedStoragePath(ctx, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseCheckSharedStoragePathResponse(rsp)
|
|
}
|
|
|
|
// GetConfigurationFileWithResponse request returning *GetConfigurationFileResponse
|
|
func (c *ClientWithResponses) GetConfigurationFileWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetConfigurationFileResponse, error) {
|
|
rsp, err := c.GetConfigurationFile(ctx, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseGetConfigurationFileResponse(rsp)
|
|
}
|
|
|
|
// SaveSetupAssistantConfigWithBodyWithResponse request with arbitrary body returning *SaveSetupAssistantConfigResponse
|
|
func (c *ClientWithResponses) SaveSetupAssistantConfigWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SaveSetupAssistantConfigResponse, error) {
|
|
rsp, err := c.SaveSetupAssistantConfigWithBody(ctx, contentType, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseSaveSetupAssistantConfigResponse(rsp)
|
|
}
|
|
|
|
func (c *ClientWithResponses) SaveSetupAssistantConfigWithResponse(ctx context.Context, body SaveSetupAssistantConfigJSONRequestBody, reqEditors ...RequestEditorFn) (*SaveSetupAssistantConfigResponse, error) {
|
|
rsp, err := c.SaveSetupAssistantConfig(ctx, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseSaveSetupAssistantConfigResponse(rsp)
|
|
}
|
|
|
|
// GetSharedStorageWithResponse request returning *GetSharedStorageResponse
|
|
func (c *ClientWithResponses) GetSharedStorageWithResponse(ctx context.Context, audience ManagerVariableAudience, platform string, reqEditors ...RequestEditorFn) (*GetSharedStorageResponse, error) {
|
|
rsp, err := c.GetSharedStorage(ctx, audience, platform, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseGetSharedStorageResponse(rsp)
|
|
}
|
|
|
|
// GetVariablesWithResponse request returning *GetVariablesResponse
|
|
func (c *ClientWithResponses) GetVariablesWithResponse(ctx context.Context, audience ManagerVariableAudience, platform string, reqEditors ...RequestEditorFn) (*GetVariablesResponse, error) {
|
|
rsp, err := c.GetVariables(ctx, audience, platform, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseGetVariablesResponse(rsp)
|
|
}
|
|
|
|
// SubmitJobWithBodyWithResponse request with arbitrary body returning *SubmitJobResponse
|
|
func (c *ClientWithResponses) SubmitJobWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SubmitJobResponse, error) {
|
|
rsp, err := c.SubmitJobWithBody(ctx, contentType, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseSubmitJobResponse(rsp)
|
|
}
|
|
|
|
func (c *ClientWithResponses) SubmitJobWithResponse(ctx context.Context, body SubmitJobJSONRequestBody, reqEditors ...RequestEditorFn) (*SubmitJobResponse, error) {
|
|
rsp, err := c.SubmitJob(ctx, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseSubmitJobResponse(rsp)
|
|
}
|
|
|
|
// SubmitJobCheckWithBodyWithResponse request with arbitrary body returning *SubmitJobCheckResponse
|
|
func (c *ClientWithResponses) SubmitJobCheckWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SubmitJobCheckResponse, error) {
|
|
rsp, err := c.SubmitJobCheckWithBody(ctx, contentType, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseSubmitJobCheckResponse(rsp)
|
|
}
|
|
|
|
func (c *ClientWithResponses) SubmitJobCheckWithResponse(ctx context.Context, body SubmitJobCheckJSONRequestBody, reqEditors ...RequestEditorFn) (*SubmitJobCheckResponse, error) {
|
|
rsp, err := c.SubmitJobCheck(ctx, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseSubmitJobCheckResponse(rsp)
|
|
}
|
|
|
|
// FetchGlobalLastRenderedInfoWithResponse request returning *FetchGlobalLastRenderedInfoResponse
|
|
func (c *ClientWithResponses) FetchGlobalLastRenderedInfoWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*FetchGlobalLastRenderedInfoResponse, error) {
|
|
rsp, err := c.FetchGlobalLastRenderedInfo(ctx, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseFetchGlobalLastRenderedInfoResponse(rsp)
|
|
}
|
|
|
|
// DeleteJobMassWithBodyWithResponse request with arbitrary body returning *DeleteJobMassResponse
|
|
func (c *ClientWithResponses) DeleteJobMassWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeleteJobMassResponse, error) {
|
|
rsp, err := c.DeleteJobMassWithBody(ctx, contentType, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseDeleteJobMassResponse(rsp)
|
|
}
|
|
|
|
func (c *ClientWithResponses) DeleteJobMassWithResponse(ctx context.Context, body DeleteJobMassJSONRequestBody, reqEditors ...RequestEditorFn) (*DeleteJobMassResponse, error) {
|
|
rsp, err := c.DeleteJobMass(ctx, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseDeleteJobMassResponse(rsp)
|
|
}
|
|
|
|
// QueryJobsWithBodyWithResponse request with arbitrary body returning *QueryJobsResponse
|
|
func (c *ClientWithResponses) QueryJobsWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*QueryJobsResponse, error) {
|
|
rsp, err := c.QueryJobsWithBody(ctx, contentType, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseQueryJobsResponse(rsp)
|
|
}
|
|
|
|
func (c *ClientWithResponses) QueryJobsWithResponse(ctx context.Context, body QueryJobsJSONRequestBody, reqEditors ...RequestEditorFn) (*QueryJobsResponse, error) {
|
|
rsp, err := c.QueryJobs(ctx, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseQueryJobsResponse(rsp)
|
|
}
|
|
|
|
// GetJobTypeWithResponse request returning *GetJobTypeResponse
|
|
func (c *ClientWithResponses) GetJobTypeWithResponse(ctx context.Context, typeName string, reqEditors ...RequestEditorFn) (*GetJobTypeResponse, error) {
|
|
rsp, err := c.GetJobType(ctx, typeName, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseGetJobTypeResponse(rsp)
|
|
}
|
|
|
|
// GetJobTypesWithResponse request returning *GetJobTypesResponse
|
|
func (c *ClientWithResponses) GetJobTypesWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetJobTypesResponse, error) {
|
|
rsp, err := c.GetJobTypes(ctx, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseGetJobTypesResponse(rsp)
|
|
}
|
|
|
|
// DeleteJobWithResponse request returning *DeleteJobResponse
|
|
func (c *ClientWithResponses) DeleteJobWithResponse(ctx context.Context, jobId string, reqEditors ...RequestEditorFn) (*DeleteJobResponse, error) {
|
|
rsp, err := c.DeleteJob(ctx, jobId, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseDeleteJobResponse(rsp)
|
|
}
|
|
|
|
// FetchJobWithResponse request returning *FetchJobResponse
|
|
func (c *ClientWithResponses) FetchJobWithResponse(ctx context.Context, jobId string, reqEditors ...RequestEditorFn) (*FetchJobResponse, error) {
|
|
rsp, err := c.FetchJob(ctx, jobId, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseFetchJobResponse(rsp)
|
|
}
|
|
|
|
// RemoveJobBlocklistWithBodyWithResponse request with arbitrary body returning *RemoveJobBlocklistResponse
|
|
func (c *ClientWithResponses) RemoveJobBlocklistWithBodyWithResponse(ctx context.Context, jobId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*RemoveJobBlocklistResponse, error) {
|
|
rsp, err := c.RemoveJobBlocklistWithBody(ctx, jobId, contentType, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseRemoveJobBlocklistResponse(rsp)
|
|
}
|
|
|
|
func (c *ClientWithResponses) RemoveJobBlocklistWithResponse(ctx context.Context, jobId string, body RemoveJobBlocklistJSONRequestBody, reqEditors ...RequestEditorFn) (*RemoveJobBlocklistResponse, error) {
|
|
rsp, err := c.RemoveJobBlocklist(ctx, jobId, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseRemoveJobBlocklistResponse(rsp)
|
|
}
|
|
|
|
// FetchJobBlocklistWithResponse request returning *FetchJobBlocklistResponse
|
|
func (c *ClientWithResponses) FetchJobBlocklistWithResponse(ctx context.Context, jobId string, reqEditors ...RequestEditorFn) (*FetchJobBlocklistResponse, error) {
|
|
rsp, err := c.FetchJobBlocklist(ctx, jobId, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseFetchJobBlocklistResponse(rsp)
|
|
}
|
|
|
|
// FetchJobLastRenderedInfoWithResponse request returning *FetchJobLastRenderedInfoResponse
|
|
func (c *ClientWithResponses) FetchJobLastRenderedInfoWithResponse(ctx context.Context, jobId string, reqEditors ...RequestEditorFn) (*FetchJobLastRenderedInfoResponse, error) {
|
|
rsp, err := c.FetchJobLastRenderedInfo(ctx, jobId, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseFetchJobLastRenderedInfoResponse(rsp)
|
|
}
|
|
|
|
// SetJobPriorityWithBodyWithResponse request with arbitrary body returning *SetJobPriorityResponse
|
|
func (c *ClientWithResponses) SetJobPriorityWithBodyWithResponse(ctx context.Context, jobId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SetJobPriorityResponse, error) {
|
|
rsp, err := c.SetJobPriorityWithBody(ctx, jobId, contentType, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseSetJobPriorityResponse(rsp)
|
|
}
|
|
|
|
func (c *ClientWithResponses) SetJobPriorityWithResponse(ctx context.Context, jobId string, body SetJobPriorityJSONRequestBody, reqEditors ...RequestEditorFn) (*SetJobPriorityResponse, error) {
|
|
rsp, err := c.SetJobPriority(ctx, jobId, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseSetJobPriorityResponse(rsp)
|
|
}
|
|
|
|
// SetJobStatusWithBodyWithResponse request with arbitrary body returning *SetJobStatusResponse
|
|
func (c *ClientWithResponses) SetJobStatusWithBodyWithResponse(ctx context.Context, jobId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SetJobStatusResponse, error) {
|
|
rsp, err := c.SetJobStatusWithBody(ctx, jobId, contentType, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseSetJobStatusResponse(rsp)
|
|
}
|
|
|
|
func (c *ClientWithResponses) SetJobStatusWithResponse(ctx context.Context, jobId string, body SetJobStatusJSONRequestBody, reqEditors ...RequestEditorFn) (*SetJobStatusResponse, error) {
|
|
rsp, err := c.SetJobStatus(ctx, jobId, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseSetJobStatusResponse(rsp)
|
|
}
|
|
|
|
// FetchJobTasksWithResponse request returning *FetchJobTasksResponse
|
|
func (c *ClientWithResponses) FetchJobTasksWithResponse(ctx context.Context, jobId string, reqEditors ...RequestEditorFn) (*FetchJobTasksResponse, error) {
|
|
rsp, err := c.FetchJobTasks(ctx, jobId, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseFetchJobTasksResponse(rsp)
|
|
}
|
|
|
|
// DeleteJobWhatWouldItDoWithResponse request returning *DeleteJobWhatWouldItDoResponse
|
|
func (c *ClientWithResponses) DeleteJobWhatWouldItDoWithResponse(ctx context.Context, jobId string, reqEditors ...RequestEditorFn) (*DeleteJobWhatWouldItDoResponse, error) {
|
|
rsp, err := c.DeleteJobWhatWouldItDo(ctx, jobId, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseDeleteJobWhatWouldItDoResponse(rsp)
|
|
}
|
|
|
|
// ShamanCheckoutWithBodyWithResponse request with arbitrary body returning *ShamanCheckoutResponse
|
|
func (c *ClientWithResponses) ShamanCheckoutWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ShamanCheckoutResponse, error) {
|
|
rsp, err := c.ShamanCheckoutWithBody(ctx, contentType, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseShamanCheckoutResponse(rsp)
|
|
}
|
|
|
|
func (c *ClientWithResponses) ShamanCheckoutWithResponse(ctx context.Context, body ShamanCheckoutJSONRequestBody, reqEditors ...RequestEditorFn) (*ShamanCheckoutResponse, error) {
|
|
rsp, err := c.ShamanCheckout(ctx, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseShamanCheckoutResponse(rsp)
|
|
}
|
|
|
|
// ShamanCheckoutRequirementsWithBodyWithResponse request with arbitrary body returning *ShamanCheckoutRequirementsResponse
|
|
func (c *ClientWithResponses) ShamanCheckoutRequirementsWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ShamanCheckoutRequirementsResponse, error) {
|
|
rsp, err := c.ShamanCheckoutRequirementsWithBody(ctx, contentType, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseShamanCheckoutRequirementsResponse(rsp)
|
|
}
|
|
|
|
func (c *ClientWithResponses) ShamanCheckoutRequirementsWithResponse(ctx context.Context, body ShamanCheckoutRequirementsJSONRequestBody, reqEditors ...RequestEditorFn) (*ShamanCheckoutRequirementsResponse, error) {
|
|
rsp, err := c.ShamanCheckoutRequirements(ctx, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseShamanCheckoutRequirementsResponse(rsp)
|
|
}
|
|
|
|
// ShamanFileStoreCheckWithResponse request returning *ShamanFileStoreCheckResponse
|
|
func (c *ClientWithResponses) ShamanFileStoreCheckWithResponse(ctx context.Context, checksum string, filesize int, reqEditors ...RequestEditorFn) (*ShamanFileStoreCheckResponse, error) {
|
|
rsp, err := c.ShamanFileStoreCheck(ctx, checksum, filesize, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseShamanFileStoreCheckResponse(rsp)
|
|
}
|
|
|
|
// ShamanFileStoreWithBodyWithResponse request with arbitrary body returning *ShamanFileStoreResponse
|
|
func (c *ClientWithResponses) ShamanFileStoreWithBodyWithResponse(ctx context.Context, checksum string, filesize int, params *ShamanFileStoreParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ShamanFileStoreResponse, error) {
|
|
rsp, err := c.ShamanFileStoreWithBody(ctx, checksum, filesize, params, contentType, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseShamanFileStoreResponse(rsp)
|
|
}
|
|
|
|
// FetchTaskWithResponse request returning *FetchTaskResponse
|
|
func (c *ClientWithResponses) FetchTaskWithResponse(ctx context.Context, taskId string, reqEditors ...RequestEditorFn) (*FetchTaskResponse, error) {
|
|
rsp, err := c.FetchTask(ctx, taskId, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseFetchTaskResponse(rsp)
|
|
}
|
|
|
|
// FetchTaskLogInfoWithResponse request returning *FetchTaskLogInfoResponse
|
|
func (c *ClientWithResponses) FetchTaskLogInfoWithResponse(ctx context.Context, taskId string, reqEditors ...RequestEditorFn) (*FetchTaskLogInfoResponse, error) {
|
|
rsp, err := c.FetchTaskLogInfo(ctx, taskId, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseFetchTaskLogInfoResponse(rsp)
|
|
}
|
|
|
|
// FetchTaskLogTailWithResponse request returning *FetchTaskLogTailResponse
|
|
func (c *ClientWithResponses) FetchTaskLogTailWithResponse(ctx context.Context, taskId string, reqEditors ...RequestEditorFn) (*FetchTaskLogTailResponse, error) {
|
|
rsp, err := c.FetchTaskLogTail(ctx, taskId, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseFetchTaskLogTailResponse(rsp)
|
|
}
|
|
|
|
// SetTaskStatusWithBodyWithResponse request with arbitrary body returning *SetTaskStatusResponse
|
|
func (c *ClientWithResponses) SetTaskStatusWithBodyWithResponse(ctx context.Context, taskId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SetTaskStatusResponse, error) {
|
|
rsp, err := c.SetTaskStatusWithBody(ctx, taskId, contentType, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseSetTaskStatusResponse(rsp)
|
|
}
|
|
|
|
func (c *ClientWithResponses) SetTaskStatusWithResponse(ctx context.Context, taskId string, body SetTaskStatusJSONRequestBody, reqEditors ...RequestEditorFn) (*SetTaskStatusResponse, error) {
|
|
rsp, err := c.SetTaskStatus(ctx, taskId, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseSetTaskStatusResponse(rsp)
|
|
}
|
|
|
|
// GetVersionWithResponse request returning *GetVersionResponse
|
|
func (c *ClientWithResponses) GetVersionWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetVersionResponse, error) {
|
|
rsp, err := c.GetVersion(ctx, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseGetVersionResponse(rsp)
|
|
}
|
|
|
|
// DeleteWorkerTagWithResponse request returning *DeleteWorkerTagResponse
|
|
func (c *ClientWithResponses) DeleteWorkerTagWithResponse(ctx context.Context, tagId string, reqEditors ...RequestEditorFn) (*DeleteWorkerTagResponse, error) {
|
|
rsp, err := c.DeleteWorkerTag(ctx, tagId, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseDeleteWorkerTagResponse(rsp)
|
|
}
|
|
|
|
// FetchWorkerTagWithResponse request returning *FetchWorkerTagResponse
|
|
func (c *ClientWithResponses) FetchWorkerTagWithResponse(ctx context.Context, tagId string, reqEditors ...RequestEditorFn) (*FetchWorkerTagResponse, error) {
|
|
rsp, err := c.FetchWorkerTag(ctx, tagId, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseFetchWorkerTagResponse(rsp)
|
|
}
|
|
|
|
// UpdateWorkerTagWithBodyWithResponse request with arbitrary body returning *UpdateWorkerTagResponse
|
|
func (c *ClientWithResponses) UpdateWorkerTagWithBodyWithResponse(ctx context.Context, tagId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateWorkerTagResponse, error) {
|
|
rsp, err := c.UpdateWorkerTagWithBody(ctx, tagId, contentType, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseUpdateWorkerTagResponse(rsp)
|
|
}
|
|
|
|
func (c *ClientWithResponses) UpdateWorkerTagWithResponse(ctx context.Context, tagId string, body UpdateWorkerTagJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateWorkerTagResponse, error) {
|
|
rsp, err := c.UpdateWorkerTag(ctx, tagId, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseUpdateWorkerTagResponse(rsp)
|
|
}
|
|
|
|
// FetchWorkerTagsWithResponse request returning *FetchWorkerTagsResponse
|
|
func (c *ClientWithResponses) FetchWorkerTagsWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*FetchWorkerTagsResponse, error) {
|
|
rsp, err := c.FetchWorkerTags(ctx, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseFetchWorkerTagsResponse(rsp)
|
|
}
|
|
|
|
// CreateWorkerTagWithBodyWithResponse request with arbitrary body returning *CreateWorkerTagResponse
|
|
func (c *ClientWithResponses) CreateWorkerTagWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateWorkerTagResponse, error) {
|
|
rsp, err := c.CreateWorkerTagWithBody(ctx, contentType, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseCreateWorkerTagResponse(rsp)
|
|
}
|
|
|
|
func (c *ClientWithResponses) CreateWorkerTagWithResponse(ctx context.Context, body CreateWorkerTagJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateWorkerTagResponse, error) {
|
|
rsp, err := c.CreateWorkerTag(ctx, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseCreateWorkerTagResponse(rsp)
|
|
}
|
|
|
|
// FetchWorkersWithResponse request returning *FetchWorkersResponse
|
|
func (c *ClientWithResponses) FetchWorkersWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*FetchWorkersResponse, error) {
|
|
rsp, err := c.FetchWorkers(ctx, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseFetchWorkersResponse(rsp)
|
|
}
|
|
|
|
// DeleteWorkerWithResponse request returning *DeleteWorkerResponse
|
|
func (c *ClientWithResponses) DeleteWorkerWithResponse(ctx context.Context, workerId string, reqEditors ...RequestEditorFn) (*DeleteWorkerResponse, error) {
|
|
rsp, err := c.DeleteWorker(ctx, workerId, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseDeleteWorkerResponse(rsp)
|
|
}
|
|
|
|
// FetchWorkerWithResponse request returning *FetchWorkerResponse
|
|
func (c *ClientWithResponses) FetchWorkerWithResponse(ctx context.Context, workerId string, reqEditors ...RequestEditorFn) (*FetchWorkerResponse, error) {
|
|
rsp, err := c.FetchWorker(ctx, workerId, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseFetchWorkerResponse(rsp)
|
|
}
|
|
|
|
// RequestWorkerStatusChangeWithBodyWithResponse request with arbitrary body returning *RequestWorkerStatusChangeResponse
|
|
func (c *ClientWithResponses) RequestWorkerStatusChangeWithBodyWithResponse(ctx context.Context, workerId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*RequestWorkerStatusChangeResponse, error) {
|
|
rsp, err := c.RequestWorkerStatusChangeWithBody(ctx, workerId, contentType, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseRequestWorkerStatusChangeResponse(rsp)
|
|
}
|
|
|
|
func (c *ClientWithResponses) RequestWorkerStatusChangeWithResponse(ctx context.Context, workerId string, body RequestWorkerStatusChangeJSONRequestBody, reqEditors ...RequestEditorFn) (*RequestWorkerStatusChangeResponse, error) {
|
|
rsp, err := c.RequestWorkerStatusChange(ctx, workerId, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseRequestWorkerStatusChangeResponse(rsp)
|
|
}
|
|
|
|
// SetWorkerTagsWithBodyWithResponse request with arbitrary body returning *SetWorkerTagsResponse
|
|
func (c *ClientWithResponses) SetWorkerTagsWithBodyWithResponse(ctx context.Context, workerId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SetWorkerTagsResponse, error) {
|
|
rsp, err := c.SetWorkerTagsWithBody(ctx, workerId, contentType, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseSetWorkerTagsResponse(rsp)
|
|
}
|
|
|
|
func (c *ClientWithResponses) SetWorkerTagsWithResponse(ctx context.Context, workerId string, body SetWorkerTagsJSONRequestBody, reqEditors ...RequestEditorFn) (*SetWorkerTagsResponse, error) {
|
|
rsp, err := c.SetWorkerTags(ctx, workerId, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseSetWorkerTagsResponse(rsp)
|
|
}
|
|
|
|
// FetchWorkerSleepScheduleWithResponse request returning *FetchWorkerSleepScheduleResponse
|
|
func (c *ClientWithResponses) FetchWorkerSleepScheduleWithResponse(ctx context.Context, workerId string, reqEditors ...RequestEditorFn) (*FetchWorkerSleepScheduleResponse, error) {
|
|
rsp, err := c.FetchWorkerSleepSchedule(ctx, workerId, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseFetchWorkerSleepScheduleResponse(rsp)
|
|
}
|
|
|
|
// SetWorkerSleepScheduleWithBodyWithResponse request with arbitrary body returning *SetWorkerSleepScheduleResponse
|
|
func (c *ClientWithResponses) SetWorkerSleepScheduleWithBodyWithResponse(ctx context.Context, workerId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SetWorkerSleepScheduleResponse, error) {
|
|
rsp, err := c.SetWorkerSleepScheduleWithBody(ctx, workerId, contentType, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseSetWorkerSleepScheduleResponse(rsp)
|
|
}
|
|
|
|
func (c *ClientWithResponses) SetWorkerSleepScheduleWithResponse(ctx context.Context, workerId string, body SetWorkerSleepScheduleJSONRequestBody, reqEditors ...RequestEditorFn) (*SetWorkerSleepScheduleResponse, error) {
|
|
rsp, err := c.SetWorkerSleepSchedule(ctx, workerId, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseSetWorkerSleepScheduleResponse(rsp)
|
|
}
|
|
|
|
// RegisterWorkerWithBodyWithResponse request with arbitrary body returning *RegisterWorkerResponse
|
|
func (c *ClientWithResponses) RegisterWorkerWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*RegisterWorkerResponse, error) {
|
|
rsp, err := c.RegisterWorkerWithBody(ctx, contentType, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseRegisterWorkerResponse(rsp)
|
|
}
|
|
|
|
func (c *ClientWithResponses) RegisterWorkerWithResponse(ctx context.Context, body RegisterWorkerJSONRequestBody, reqEditors ...RequestEditorFn) (*RegisterWorkerResponse, error) {
|
|
rsp, err := c.RegisterWorker(ctx, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseRegisterWorkerResponse(rsp)
|
|
}
|
|
|
|
// SignOffWithResponse request returning *SignOffResponse
|
|
func (c *ClientWithResponses) SignOffWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*SignOffResponse, error) {
|
|
rsp, err := c.SignOff(ctx, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseSignOffResponse(rsp)
|
|
}
|
|
|
|
// SignOnWithBodyWithResponse request with arbitrary body returning *SignOnResponse
|
|
func (c *ClientWithResponses) SignOnWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SignOnResponse, error) {
|
|
rsp, err := c.SignOnWithBody(ctx, contentType, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseSignOnResponse(rsp)
|
|
}
|
|
|
|
func (c *ClientWithResponses) SignOnWithResponse(ctx context.Context, body SignOnJSONRequestBody, reqEditors ...RequestEditorFn) (*SignOnResponse, error) {
|
|
rsp, err := c.SignOn(ctx, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseSignOnResponse(rsp)
|
|
}
|
|
|
|
// WorkerStateWithResponse request returning *WorkerStateResponse
|
|
func (c *ClientWithResponses) WorkerStateWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*WorkerStateResponse, error) {
|
|
rsp, err := c.WorkerState(ctx, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseWorkerStateResponse(rsp)
|
|
}
|
|
|
|
// WorkerStateChangedWithBodyWithResponse request with arbitrary body returning *WorkerStateChangedResponse
|
|
func (c *ClientWithResponses) WorkerStateChangedWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*WorkerStateChangedResponse, error) {
|
|
rsp, err := c.WorkerStateChangedWithBody(ctx, contentType, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseWorkerStateChangedResponse(rsp)
|
|
}
|
|
|
|
func (c *ClientWithResponses) WorkerStateChangedWithResponse(ctx context.Context, body WorkerStateChangedJSONRequestBody, reqEditors ...RequestEditorFn) (*WorkerStateChangedResponse, error) {
|
|
rsp, err := c.WorkerStateChanged(ctx, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseWorkerStateChangedResponse(rsp)
|
|
}
|
|
|
|
// ScheduleTaskWithResponse request returning *ScheduleTaskResponse
|
|
func (c *ClientWithResponses) ScheduleTaskWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*ScheduleTaskResponse, error) {
|
|
rsp, err := c.ScheduleTask(ctx, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseScheduleTaskResponse(rsp)
|
|
}
|
|
|
|
// TaskUpdateWithBodyWithResponse request with arbitrary body returning *TaskUpdateResponse
|
|
func (c *ClientWithResponses) TaskUpdateWithBodyWithResponse(ctx context.Context, taskId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*TaskUpdateResponse, error) {
|
|
rsp, err := c.TaskUpdateWithBody(ctx, taskId, contentType, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseTaskUpdateResponse(rsp)
|
|
}
|
|
|
|
func (c *ClientWithResponses) TaskUpdateWithResponse(ctx context.Context, taskId string, body TaskUpdateJSONRequestBody, reqEditors ...RequestEditorFn) (*TaskUpdateResponse, error) {
|
|
rsp, err := c.TaskUpdate(ctx, taskId, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseTaskUpdateResponse(rsp)
|
|
}
|
|
|
|
// MayWorkerRunWithResponse request returning *MayWorkerRunResponse
|
|
func (c *ClientWithResponses) MayWorkerRunWithResponse(ctx context.Context, taskId string, reqEditors ...RequestEditorFn) (*MayWorkerRunResponse, error) {
|
|
rsp, err := c.MayWorkerRun(ctx, taskId, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseMayWorkerRunResponse(rsp)
|
|
}
|
|
|
|
// TaskOutputProducedWithBodyWithResponse request with arbitrary body returning *TaskOutputProducedResponse
|
|
func (c *ClientWithResponses) TaskOutputProducedWithBodyWithResponse(ctx context.Context, taskId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*TaskOutputProducedResponse, error) {
|
|
rsp, err := c.TaskOutputProducedWithBody(ctx, taskId, contentType, body, reqEditors...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return ParseTaskOutputProducedResponse(rsp)
|
|
}
|
|
|
|
// ParseGetConfigurationResponse parses an HTTP response from a GetConfigurationWithResponse call
|
|
func ParseGetConfigurationResponse(rsp *http.Response) (*GetConfigurationResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &GetConfigurationResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200:
|
|
var dest ManagerConfiguration
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON200 = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseFindBlenderExePathResponse parses an HTTP response from a FindBlenderExePathWithResponse call
|
|
func ParseFindBlenderExePathResponse(rsp *http.Response) (*FindBlenderExePathResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &FindBlenderExePathResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200:
|
|
var dest BlenderPathFindResult
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON200 = &dest
|
|
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && true:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSONDefault = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseCheckBlenderExePathResponse parses an HTTP response from a CheckBlenderExePathWithResponse call
|
|
func ParseCheckBlenderExePathResponse(rsp *http.Response) (*CheckBlenderExePathResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &CheckBlenderExePathResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200:
|
|
var dest BlenderPathCheckResult
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON200 = &dest
|
|
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && true:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSONDefault = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseCheckSharedStoragePathResponse parses an HTTP response from a CheckSharedStoragePathWithResponse call
|
|
func ParseCheckSharedStoragePathResponse(rsp *http.Response) (*CheckSharedStoragePathResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &CheckSharedStoragePathResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200:
|
|
var dest PathCheckResult
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON200 = &dest
|
|
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && true:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSONDefault = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseGetConfigurationFileResponse parses an HTTP response from a GetConfigurationFileWithResponse call
|
|
func ParseGetConfigurationFileResponse(rsp *http.Response) (*GetConfigurationFileResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &GetConfigurationFileResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200:
|
|
var dest struct {
|
|
AdditionalProperties map[string]interface{} `json:"-"`
|
|
}
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON200 = &dest
|
|
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "yaml") && rsp.StatusCode == 200:
|
|
var dest string
|
|
if err := yaml.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.YAML200 = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseSaveSetupAssistantConfigResponse parses an HTTP response from a SaveSetupAssistantConfigWithResponse call
|
|
func ParseSaveSetupAssistantConfigResponse(rsp *http.Response) (*SaveSetupAssistantConfigResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &SaveSetupAssistantConfigResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && true:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSONDefault = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseGetSharedStorageResponse parses an HTTP response from a GetSharedStorageWithResponse call
|
|
func ParseGetSharedStorageResponse(rsp *http.Response) (*GetSharedStorageResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &GetSharedStorageResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200:
|
|
var dest SharedStorageLocation
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON200 = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseGetVariablesResponse parses an HTTP response from a GetVariablesWithResponse call
|
|
func ParseGetVariablesResponse(rsp *http.Response) (*GetVariablesResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &GetVariablesResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200:
|
|
var dest ManagerVariables
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON200 = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseSubmitJobResponse parses an HTTP response from a SubmitJobWithResponse call
|
|
func ParseSubmitJobResponse(rsp *http.Response) (*SubmitJobResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &SubmitJobResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200:
|
|
var dest Job
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON200 = &dest
|
|
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 412:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON412 = &dest
|
|
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && true:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSONDefault = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseSubmitJobCheckResponse parses an HTTP response from a SubmitJobCheckWithResponse call
|
|
func ParseSubmitJobCheckResponse(rsp *http.Response) (*SubmitJobCheckResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &SubmitJobCheckResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 412:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON412 = &dest
|
|
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && true:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSONDefault = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseFetchGlobalLastRenderedInfoResponse parses an HTTP response from a FetchGlobalLastRenderedInfoWithResponse call
|
|
func ParseFetchGlobalLastRenderedInfoResponse(rsp *http.Response) (*FetchGlobalLastRenderedInfoResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &FetchGlobalLastRenderedInfoResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200:
|
|
var dest JobLastRenderedImageInfo
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON200 = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseDeleteJobMassResponse parses an HTTP response from a DeleteJobMassWithResponse call
|
|
func ParseDeleteJobMassResponse(rsp *http.Response) (*DeleteJobMassResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &DeleteJobMassResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 416:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON416 = &dest
|
|
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && true:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSONDefault = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseQueryJobsResponse parses an HTTP response from a QueryJobsWithResponse call
|
|
func ParseQueryJobsResponse(rsp *http.Response) (*QueryJobsResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &QueryJobsResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200:
|
|
var dest JobsQueryResult
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON200 = &dest
|
|
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && true:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSONDefault = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseGetJobTypeResponse parses an HTTP response from a GetJobTypeWithResponse call
|
|
func ParseGetJobTypeResponse(rsp *http.Response) (*GetJobTypeResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &GetJobTypeResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200:
|
|
var dest AvailableJobType
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON200 = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseGetJobTypesResponse parses an HTTP response from a GetJobTypesWithResponse call
|
|
func ParseGetJobTypesResponse(rsp *http.Response) (*GetJobTypesResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &GetJobTypesResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200:
|
|
var dest AvailableJobTypes
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON200 = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseDeleteJobResponse parses an HTTP response from a DeleteJobWithResponse call
|
|
func ParseDeleteJobResponse(rsp *http.Response) (*DeleteJobResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &DeleteJobResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && true:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSONDefault = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseFetchJobResponse parses an HTTP response from a FetchJobWithResponse call
|
|
func ParseFetchJobResponse(rsp *http.Response) (*FetchJobResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &FetchJobResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200:
|
|
var dest Job
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON200 = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseRemoveJobBlocklistResponse parses an HTTP response from a RemoveJobBlocklistWithResponse call
|
|
func ParseRemoveJobBlocklistResponse(rsp *http.Response) (*RemoveJobBlocklistResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &RemoveJobBlocklistResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && true:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSONDefault = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseFetchJobBlocklistResponse parses an HTTP response from a FetchJobBlocklistWithResponse call
|
|
func ParseFetchJobBlocklistResponse(rsp *http.Response) (*FetchJobBlocklistResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &FetchJobBlocklistResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200:
|
|
var dest JobBlocklist
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON200 = &dest
|
|
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && true:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSONDefault = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseFetchJobLastRenderedInfoResponse parses an HTTP response from a FetchJobLastRenderedInfoWithResponse call
|
|
func ParseFetchJobLastRenderedInfoResponse(rsp *http.Response) (*FetchJobLastRenderedInfoResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &FetchJobLastRenderedInfoResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200:
|
|
var dest JobLastRenderedImageInfo
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON200 = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseSetJobPriorityResponse parses an HTTP response from a SetJobPriorityWithResponse call
|
|
func ParseSetJobPriorityResponse(rsp *http.Response) (*SetJobPriorityResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &SetJobPriorityResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && true:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSONDefault = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseSetJobStatusResponse parses an HTTP response from a SetJobStatusWithResponse call
|
|
func ParseSetJobStatusResponse(rsp *http.Response) (*SetJobStatusResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &SetJobStatusResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && true:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSONDefault = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseFetchJobTasksResponse parses an HTTP response from a FetchJobTasksWithResponse call
|
|
func ParseFetchJobTasksResponse(rsp *http.Response) (*FetchJobTasksResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &FetchJobTasksResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200:
|
|
var dest JobTasksSummary
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON200 = &dest
|
|
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && true:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSONDefault = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseDeleteJobWhatWouldItDoResponse parses an HTTP response from a DeleteJobWhatWouldItDoWithResponse call
|
|
func ParseDeleteJobWhatWouldItDoResponse(rsp *http.Response) (*DeleteJobWhatWouldItDoResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &DeleteJobWhatWouldItDoResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200:
|
|
var dest JobDeletionInfo
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON200 = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseShamanCheckoutResponse parses an HTTP response from a ShamanCheckoutWithResponse call
|
|
func ParseShamanCheckoutResponse(rsp *http.Response) (*ShamanCheckoutResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &ShamanCheckoutResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200:
|
|
var dest ShamanCheckoutResult
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON200 = &dest
|
|
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 409:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON409 = &dest
|
|
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 424:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON424 = &dest
|
|
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && true:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSONDefault = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseShamanCheckoutRequirementsResponse parses an HTTP response from a ShamanCheckoutRequirementsWithResponse call
|
|
func ParseShamanCheckoutRequirementsResponse(rsp *http.Response) (*ShamanCheckoutRequirementsResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &ShamanCheckoutRequirementsResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200:
|
|
var dest ShamanRequirementsResponse
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON200 = &dest
|
|
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && true:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSONDefault = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseShamanFileStoreCheckResponse parses an HTTP response from a ShamanFileStoreCheckWithResponse call
|
|
func ParseShamanFileStoreCheckResponse(rsp *http.Response) (*ShamanFileStoreCheckResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &ShamanFileStoreCheckResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200:
|
|
var dest ShamanSingleFileStatus
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON200 = &dest
|
|
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && true:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSONDefault = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseShamanFileStoreResponse parses an HTTP response from a ShamanFileStoreWithResponse call
|
|
func ParseShamanFileStoreResponse(rsp *http.Response) (*ShamanFileStoreResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &ShamanFileStoreResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && true:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSONDefault = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseFetchTaskResponse parses an HTTP response from a FetchTaskWithResponse call
|
|
func ParseFetchTaskResponse(rsp *http.Response) (*FetchTaskResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &FetchTaskResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200:
|
|
var dest Task
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON200 = &dest
|
|
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && true:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSONDefault = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseFetchTaskLogInfoResponse parses an HTTP response from a FetchTaskLogInfoWithResponse call
|
|
func ParseFetchTaskLogInfoResponse(rsp *http.Response) (*FetchTaskLogInfoResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &FetchTaskLogInfoResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200:
|
|
var dest TaskLogInfo
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON200 = &dest
|
|
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && true:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSONDefault = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseFetchTaskLogTailResponse parses an HTTP response from a FetchTaskLogTailWithResponse call
|
|
func ParseFetchTaskLogTailResponse(rsp *http.Response) (*FetchTaskLogTailResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &FetchTaskLogTailResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && true:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSONDefault = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseSetTaskStatusResponse parses an HTTP response from a SetTaskStatusWithResponse call
|
|
func ParseSetTaskStatusResponse(rsp *http.Response) (*SetTaskStatusResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &SetTaskStatusResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && true:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSONDefault = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseGetVersionResponse parses an HTTP response from a GetVersionWithResponse call
|
|
func ParseGetVersionResponse(rsp *http.Response) (*GetVersionResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &GetVersionResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200:
|
|
var dest FlamencoVersion
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON200 = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseDeleteWorkerTagResponse parses an HTTP response from a DeleteWorkerTagWithResponse call
|
|
func ParseDeleteWorkerTagResponse(rsp *http.Response) (*DeleteWorkerTagResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &DeleteWorkerTagResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && true:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSONDefault = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseFetchWorkerTagResponse parses an HTTP response from a FetchWorkerTagWithResponse call
|
|
func ParseFetchWorkerTagResponse(rsp *http.Response) (*FetchWorkerTagResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &FetchWorkerTagResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200:
|
|
var dest WorkerTag
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON200 = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseUpdateWorkerTagResponse parses an HTTP response from a UpdateWorkerTagWithResponse call
|
|
func ParseUpdateWorkerTagResponse(rsp *http.Response) (*UpdateWorkerTagResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &UpdateWorkerTagResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && true:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSONDefault = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseFetchWorkerTagsResponse parses an HTTP response from a FetchWorkerTagsWithResponse call
|
|
func ParseFetchWorkerTagsResponse(rsp *http.Response) (*FetchWorkerTagsResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &FetchWorkerTagsResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200:
|
|
var dest WorkerTagList
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON200 = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseCreateWorkerTagResponse parses an HTTP response from a CreateWorkerTagWithResponse call
|
|
func ParseCreateWorkerTagResponse(rsp *http.Response) (*CreateWorkerTagResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &CreateWorkerTagResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200:
|
|
var dest WorkerTag
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON200 = &dest
|
|
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && true:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSONDefault = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseFetchWorkersResponse parses an HTTP response from a FetchWorkersWithResponse call
|
|
func ParseFetchWorkersResponse(rsp *http.Response) (*FetchWorkersResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &FetchWorkersResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200:
|
|
var dest WorkerList
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON200 = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseDeleteWorkerResponse parses an HTTP response from a DeleteWorkerWithResponse call
|
|
func ParseDeleteWorkerResponse(rsp *http.Response) (*DeleteWorkerResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &DeleteWorkerResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && true:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSONDefault = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseFetchWorkerResponse parses an HTTP response from a FetchWorkerWithResponse call
|
|
func ParseFetchWorkerResponse(rsp *http.Response) (*FetchWorkerResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &FetchWorkerResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200:
|
|
var dest Worker
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON200 = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseRequestWorkerStatusChangeResponse parses an HTTP response from a RequestWorkerStatusChangeWithResponse call
|
|
func ParseRequestWorkerStatusChangeResponse(rsp *http.Response) (*RequestWorkerStatusChangeResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &RequestWorkerStatusChangeResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && true:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSONDefault = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseSetWorkerTagsResponse parses an HTTP response from a SetWorkerTagsWithResponse call
|
|
func ParseSetWorkerTagsResponse(rsp *http.Response) (*SetWorkerTagsResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &SetWorkerTagsResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && true:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSONDefault = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseFetchWorkerSleepScheduleResponse parses an HTTP response from a FetchWorkerSleepScheduleWithResponse call
|
|
func ParseFetchWorkerSleepScheduleResponse(rsp *http.Response) (*FetchWorkerSleepScheduleResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &FetchWorkerSleepScheduleResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200:
|
|
var dest WorkerSleepSchedule
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON200 = &dest
|
|
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && true:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSONDefault = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseSetWorkerSleepScheduleResponse parses an HTTP response from a SetWorkerSleepScheduleWithResponse call
|
|
func ParseSetWorkerSleepScheduleResponse(rsp *http.Response) (*SetWorkerSleepScheduleResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &SetWorkerSleepScheduleResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && true:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSONDefault = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseRegisterWorkerResponse parses an HTTP response from a RegisterWorkerWithResponse call
|
|
func ParseRegisterWorkerResponse(rsp *http.Response) (*RegisterWorkerResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &RegisterWorkerResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200:
|
|
var dest RegisteredWorker
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON200 = &dest
|
|
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && true:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSONDefault = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseSignOffResponse parses an HTTP response from a SignOffWithResponse call
|
|
func ParseSignOffResponse(rsp *http.Response) (*SignOffResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &SignOffResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && true:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSONDefault = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseSignOnResponse parses an HTTP response from a SignOnWithResponse call
|
|
func ParseSignOnResponse(rsp *http.Response) (*SignOnResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &SignOnResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200:
|
|
var dest WorkerStateChange
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON200 = &dest
|
|
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && true:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSONDefault = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseWorkerStateResponse parses an HTTP response from a WorkerStateWithResponse call
|
|
func ParseWorkerStateResponse(rsp *http.Response) (*WorkerStateResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &WorkerStateResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200:
|
|
var dest WorkerStateChange
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON200 = &dest
|
|
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && true:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSONDefault = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseWorkerStateChangedResponse parses an HTTP response from a WorkerStateChangedWithResponse call
|
|
func ParseWorkerStateChangedResponse(rsp *http.Response) (*WorkerStateChangedResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &WorkerStateChangedResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && true:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSONDefault = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseScheduleTaskResponse parses an HTTP response from a ScheduleTaskWithResponse call
|
|
func ParseScheduleTaskResponse(rsp *http.Response) (*ScheduleTaskResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &ScheduleTaskResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200:
|
|
var dest AssignedTask
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON200 = &dest
|
|
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403:
|
|
var dest SecurityError
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON403 = &dest
|
|
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 423:
|
|
var dest WorkerStateChange
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON423 = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseTaskUpdateResponse parses an HTTP response from a TaskUpdateWithResponse call
|
|
func ParseTaskUpdateResponse(rsp *http.Response) (*TaskUpdateResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &TaskUpdateResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && true:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSONDefault = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseMayWorkerRunResponse parses an HTTP response from a MayWorkerRunWithResponse call
|
|
func ParseMayWorkerRunResponse(rsp *http.Response) (*MayWorkerRunResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &MayWorkerRunResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200:
|
|
var dest MayKeepRunning
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON200 = &dest
|
|
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && true:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSONDefault = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|
|
|
|
// ParseTaskOutputProducedResponse parses an HTTP response from a TaskOutputProducedWithResponse call
|
|
func ParseTaskOutputProducedResponse(rsp *http.Response) (*TaskOutputProducedResponse, error) {
|
|
bodyBytes, err := ioutil.ReadAll(rsp.Body)
|
|
defer func() { _ = rsp.Body.Close() }()
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
response := &TaskOutputProducedResponse{
|
|
Body: bodyBytes,
|
|
HTTPResponse: rsp,
|
|
}
|
|
|
|
switch {
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 411:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON411 = &dest
|
|
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 413:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON413 = &dest
|
|
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 415:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON415 = &dest
|
|
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSON429 = &dest
|
|
|
|
case strings.Contains(rsp.Header.Get("Content-Type"), "json") && true:
|
|
var dest Error
|
|
if err := json.Unmarshal(bodyBytes, &dest); err != nil {
|
|
return nil, err
|
|
}
|
|
response.JSONDefault = &dest
|
|
|
|
}
|
|
|
|
return response, nil
|
|
}
|