api

package
v0.3.1 Latest Latest
Warning

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

Go to latest
Published: Aug 27, 2021 License: Apache-2.0 Imports: 18 Imported by: 0

Documentation

Overview

Package api is the base for all aep rest functions.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Package api is the base for all aep rest functions.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Package api is the base for all aep rest functions.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Package catalog consists of catalog functions.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Package catalog consists of catalog functions.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Package api is the base for all aep rest functions.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Package api is the base for all aep rest functions.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Package api is the base for all aep rest functions.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Package api is the base for all aep rest functions.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Package api is the base for all aep rest functions.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Package api is the base for all aep rest functions.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Package api is the base for all aep rest functions.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Package api is the base for all aep rest functions.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Package api is the base for all aep rest functions. Copyright 2021 Michael Bungenstock

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Index

Constants

View Source
const (
	// JSONOut is used for JSON
	AcceptIDs = iota
	AcceptLinks
	AcceptObjects
)

Variables

View Source
var All = map[string]Func{
	"ACGetPermissionsAndResources": ACGetPermissionsAndResourcesP,
	"ACGetEffecticeACLPolicies":    ACGetEffecticeACLPoliciesP,
	"CatalogGetBatches":            CatalogGetBatchesP,
	"CatalogGetDatasets":           CatalogGetDatasetsP,
	"DADownload":                   DADownloadP,
	"DAGetFiles":                   DAGetFilesP,
	"DAGetFils":                    DAGetFileP,
	"ODGet":                        ODGetP,
	"ODQuery":                      ODQueryP,
	"FlowGetConnections":           FlowGetConnectionsP,
	"SBGetSandbox":                 SBGetSandboxP,
	"SBListAllSandboxes":           SBListAllSandboxesP,
	"SBListSandboxes":              SBListSandboxesP,
	"SBListSandboxTypes":           SBListSandboxTypesP,
	"SRGetBehaviorsP":              SRListBehaviorsP,
	"SRGetBehaviorP":               SRGetBehaviorP,
	"SRGetStats":                   SRGetStatsP,
	"SRGetSchemas":                 SRListSchemasP,
	"SRGetSchema":                  SRGetSchemaP,
	"UPSGetEntities":               UPSGetEntitiesP,
}

Functions

func ACGetEffecticeACLPolicies added in v0.3.0

func ACGetEffecticeACLPolicies(ctx context.Context, p *AuthenticationConfig, params ACGetEffecticeACLPoliciesParams) (*http.Response, error)

ACGetEffecticeACLPolicies returns the effective acl policies

func ACGetEffecticeACLPoliciesP added in v0.3.0

func ACGetEffecticeACLPoliciesP(ctx context.Context, p *AuthenticationConfig, params util.Params) (*http.Response, error)

ACGetEffecticeACLPolicies returns the effective acl policies

func ACGetPermissionsAndResources added in v0.3.0

func ACGetPermissionsAndResources(ctx context.Context, p *AuthenticationConfig) (*http.Response, error)

ACGetPermissionsAndResources returns the access control policies.

func ACGetPermissionsAndResourcesP added in v0.3.0

func ACGetPermissionsAndResourcesP(ctx context.Context, p *AuthenticationConfig, _ util.Params) (*http.Response, error)

ACGetPermissionsAndResources returns the access control policies.

func CatalogCreateDataset added in v0.3.0

func CatalogCreateDataset(ctx context.Context, p *AuthenticationConfig, obj interface{}) (*http.Response, error)

Create creates a new object

func CatalogCreateProfileUnionDataset added in v0.3.0

func CatalogCreateProfileUnionDataset(ctx context.Context, p *AuthenticationConfig, name, format string) (*http.Response, error)

func CatalogGetBatches added in v0.3.0

func CatalogGetBatches(ctx context.Context, p *AuthenticationConfig, options *BatchesOptions) (*http.Response, error)

CatalogGetBatches returns a list of batches

func CatalogGetBatchesP added in v0.3.0

func CatalogGetBatchesP(ctx context.Context, p *AuthenticationConfig, params util.Params) (*http.Response, error)

CatalogGetBatchesP returns a list of batches

func CatalogGetDatasets added in v0.3.0

func CatalogGetDatasets(ctx context.Context, p *AuthenticationConfig, options *BatchesOptions) (*http.Response, error)

CatalogGetDatasets returns a list of batches

func CatalogGetDatasetsP added in v0.3.0

func CatalogGetDatasetsP(ctx context.Context, p *AuthenticationConfig, params util.Params) (*http.Response, error)

CatalogGetDatasets returns a list of batches

func DADownload added in v0.2.0

func DADownload(ctx context.Context, p *AuthenticationConfig, fileId, path string) (*http.Response, error)

DADownload downloads a file fromt the given url

func DADownloadP added in v0.3.0

func DADownloadP(ctx context.Context, p *AuthenticationConfig, params util.Params) (*http.Response, error)

DADownload downloads a file fromt the given url

func DAGetFile added in v0.2.0

func DAGetFile(ctx context.Context, p *AuthenticationConfig, options *DAOptions) (*http.Response, error)

DAGetFile returns a list of files for the passed fileId

func DAGetFileP added in v0.3.0

func DAGetFileP(ctx context.Context, p *AuthenticationConfig, params util.Params) (*http.Response, error)

DAGetFileP returns a list of files for the passed fileId

func DAGetFiles added in v0.2.0

func DAGetFiles(ctx context.Context, p *AuthenticationConfig, options *DAOptions) (*http.Response, error)

DAGetFilesP returns a list of files for the passed batchId

func DAGetFilesP added in v0.3.0

func DAGetFilesP(ctx context.Context, p *AuthenticationConfig, params util.Params) (*http.Response, error)

DAGetFilesP returns a list of files for the passed batchId

func DropResponse added in v0.3.1

func DropResponse(res *http.Response, err error) error

func FlowGetConnectionsP added in v0.3.0

func FlowGetConnectionsP(ctx context.Context, auth *AuthenticationConfig, params util.Params) (*http.Response, error)

DAGetFile returns a list of files for the passed fileId

func HandleStatusCode added in v0.2.0

func HandleStatusCode(res *http.Response, err error) (*http.Response, error)

HandleStatusCode checks for a previous error and the HTTP status code. If an error exists or the status code is good then the passed objects will be returned. Otherwise it will create an error object from the status information and the returned HTTP body.

func ISCreateNamespace added in v0.3.1

func ISCreateNamespace(ctx context.Context, a *AuthenticationConfig, body []byte) (*http.Response, error)

func ISGetCluster added in v0.3.1

func ISGetClusterR added in v0.3.1

func ISGetClusterR(ctx context.Context, a *AuthenticationConfig, req *Request) (*http.Response, error)

func ISGetClusters added in v0.3.1

func ISGetClustersR added in v0.3.1

func ISGetClustersR(ctx context.Context, a *AuthenticationConfig, req *Request) (*http.Response, error)

func ISGetHistories added in v0.3.1

func ISGetHistories(ctx context.Context, a *AuthenticationConfig, p *ISClustersParams) (*http.Response, error)

func ISGetHistoriesR added in v0.3.1

func ISGetHistoriesR(ctx context.Context, a *AuthenticationConfig, req *Request) (*http.Response, error)

func ISGetHistory added in v0.3.1

func ISGetHistoryR added in v0.3.1

func ISGetHistoryR(ctx context.Context, a *AuthenticationConfig, req *Request) (*http.Response, error)

func ISGetMapping added in v0.3.1

func ISGetMappingR added in v0.3.1

func ISGetMappingR(ctx context.Context, a *AuthenticationConfig, req *Request) (*http.Response, error)

func ISGetMappings added in v0.3.1

func ISGetNamespace added in v0.3.1

func ISGetNamespace(ctx context.Context, a *AuthenticationConfig, id string) (*http.Response, error)

func ISGetNamespaceIMSOrg added in v0.3.1

func ISGetNamespaceIMSOrg(ctx context.Context, a *AuthenticationConfig, imsOrg, id string) (*http.Response, error)

func ISGetXID added in v0.3.1

ISGetXID returns the XID for the given namespace and id combination

func ISGetXIDR added in v0.3.1

func ISGetXIDR(ctx context.Context, a *AuthenticationConfig, req *Request) (*http.Response, error)

func ISListNamespaces added in v0.3.1

func ISListNamespaces(ctx context.Context, a *AuthenticationConfig) (*http.Response, error)

func ISListNamespacesIMSOrg added in v0.3.1

func ISListNamespacesIMSOrg(ctx context.Context, a *AuthenticationConfig, imsOrg string) (*http.Response, error)

func ISUpdateNamespace added in v0.3.1

func ISUpdateNamespace(ctx context.Context, a *AuthenticationConfig, id string, body []byte) (*http.Response, error)

func List added in v0.3.0

func List(ctx context.Context, p *AuthenticationConfig) (interface{}, error)

List returns a list of usable sandboxes TODO implement new generic API

func NewJSONIterator added in v0.2.0

func NewJSONIterator(res *http.Response, err error) (*util.JSONIterator, error)

func NewQuery added in v0.2.0

func NewQuery(res *http.Response, err error) (*util.Query, error)

func ODGet added in v0.3.0

ODGet returns a collection by name (wild cards are supported) or id (exact match)

func ODGetP added in v0.3.0

func ODGetP(ctx context.Context, p *AuthenticationConfig, params util.Params) (*http.Response, error)

ODGetP returns a collection by name (wild cards are supported) or id (exact match)

func ODQueryP added in v0.3.0

func ODQueryP(ctx context.Context, p *AuthenticationConfig, params util.Params) (*http.Response, error)

ODQueryP sends a query to the offer decisioning API

func PrintResponse added in v0.3.1

func PrintResponse(res *http.Response, err error) error

func SBGetSandbox added in v0.3.0

func SBGetSandbox(ctx context.Context, p *AuthenticationConfig, params SBGetSandboxParams) (*http.Response, error)

SBGetSandbox returns the details of a sandbox with the given name

func SBGetSandboxP added in v0.3.0

func SBGetSandboxP(ctx context.Context, p *AuthenticationConfig, params util.Params) (*http.Response, error)

SBGetSandboxP returns the details of a sandbox with the given name

func SBListAllSandboxes added in v0.3.0

func SBListAllSandboxes(ctx context.Context, p *AuthenticationConfig) (*http.Response, error)

SBListAllSandboxes returns a list of all sandboxes

func SBListAllSandboxesP added in v0.3.0

func SBListAllSandboxesP(ctx context.Context, p *AuthenticationConfig, _ util.Params) (*http.Response, error)

SBListAllSandboxesP returns a list of all sandboxes. This variant implements the api.Func type.

func SBListSandboxTypes added in v0.3.0

func SBListSandboxTypes(ctx context.Context, p *AuthenticationConfig) (*http.Response, error)

SBListSandboxTypes lists the available sandbox types

func SBListSandboxTypesP added in v0.3.0

func SBListSandboxTypesP(ctx context.Context, p *AuthenticationConfig, _ util.Params) (*http.Response, error)

SBListSandboxTypes lists the available sandbox types. This variant implements the api.Func type.

func SBListSandboxes added in v0.3.0

func SBListSandboxes(ctx context.Context, p *AuthenticationConfig) (*http.Response, error)

SBListSandboxes returns a list of usable sandboxes

func SBListSandboxesP added in v0.3.0

func SBListSandboxesP(ctx context.Context, p *AuthenticationConfig, _ util.Params) (*http.Response, error)

SBListSandboxesP returns a list of usable sandboxes. This variant implements the api.Func type.

func SRCreateClass added in v0.3.1

func SRCreateClass(ctx context.Context, a *AuthenticationConfig, payload []byte) (*http.Response, error)

func SRCreateDataType added in v0.3.1

func SRCreateDataType(ctx context.Context, a *AuthenticationConfig, payload []byte) (*http.Response, error)

func SRCreateDescriptor added in v0.3.1

func SRCreateDescriptor(ctx context.Context, a *AuthenticationConfig, payload []byte) (*http.Response, error)

func SRCreateFieldGroup added in v0.3.1

func SRCreateFieldGroup(ctx context.Context, a *AuthenticationConfig, payload []byte) (*http.Response, error)

func SRCreateSchema added in v0.3.1

func SRCreateSchema(ctx context.Context, a *AuthenticationConfig, payload []byte) (*http.Response, error)

func SRDeleteClass added in v0.3.0

func SRDeleteClass(ctx context.Context, a *AuthenticationConfig, id string) (*http.Response, error)

func SRDeleteDataType added in v0.3.0

func SRDeleteDataType(ctx context.Context, a *AuthenticationConfig, id string) (*http.Response, error)

func SRDeleteDescriptor added in v0.3.0

func SRDeleteDescriptor(ctx context.Context, a *AuthenticationConfig, id string) (*http.Response, error)

func SRDeleteFieldGroup added in v0.3.0

func SRDeleteFieldGroup(ctx context.Context, a *AuthenticationConfig, id string) (*http.Response, error)

func SRDeleteSchema added in v0.3.0

func SRDeleteSchema(ctx context.Context, a *AuthenticationConfig, id string) (*http.Response, error)

func SRExport added in v0.3.0

func SRExport(ctx context.Context, a *AuthenticationConfig, id string) (*http.Response, error)

func SRExportP added in v0.3.0

func SRGetAuditLog added in v0.3.0

func SRGetAuditLog(ctx context.Context, a *AuthenticationConfig, schemaID string) (*http.Response, error)

func SRGetBehavior added in v0.3.0

func SRGetBehaviorP added in v0.3.0

func SRGetBehaviorP(ctx context.Context, a *AuthenticationConfig, p util.Params) (*http.Response, error)

func SRGetClass added in v0.3.0

func SRGetClassP added in v0.3.0

func SRGetClassP(ctx context.Context, a *AuthenticationConfig, p util.Params) (*http.Response, error)

func SRGetDataType added in v0.3.0

func SRGetDataType(ctx context.Context, a *AuthenticationConfig, p *SRGetParams) (*http.Response, error)

func SRGetDataTypeP added in v0.3.0

func SRGetDataTypeP(ctx context.Context, a *AuthenticationConfig, p util.Params) (*http.Response, error)

func SRGetDescriptor added in v0.3.0

func SRGetDescriptor(ctx context.Context, a *AuthenticationConfig, p *SRGetParams) (*http.Response, error)

func SRGetDescriptorP added in v0.3.0

func SRGetDescriptorP(ctx context.Context, a *AuthenticationConfig, p util.Params) (*http.Response, error)

func SRGetFieldGroup added in v0.3.0

func SRGetFieldGroup(ctx context.Context, a *AuthenticationConfig, p *SRGetParams) (*http.Response, error)

func SRGetFieldGroupP added in v0.3.0

func SRGetFieldGroupP(ctx context.Context, a *AuthenticationConfig, p util.Params) (*http.Response, error)

func SRGetSample added in v0.3.0

func SRGetSample(ctx context.Context, a *AuthenticationConfig, schemaID string) (*http.Response, error)

func SRGetSchema added in v0.3.0

func SRGetSchema(ctx context.Context, a *AuthenticationConfig, p *SRGetParams) (*http.Response, error)

func SRGetSchemaP added in v0.3.0

func SRGetSchemaP(ctx context.Context, a *AuthenticationConfig, p util.Params) (*http.Response, error)

func SRGetStats added in v0.3.0

func SRGetStats(ctx context.Context, p *AuthenticationConfig) (*http.Response, error)

GetStats returns schema registry informations

func SRGetStatsP added in v0.3.0

func SRGetStatsP(ctx context.Context, p *AuthenticationConfig, _ util.Params) (*http.Response, error)

GetStatsP returns schema registry informations

func SRGetUnion added in v0.3.0

func SRGetUnionP added in v0.3.0

func SRGetUnionP(ctx context.Context, a *AuthenticationConfig, p util.Params) (*http.Response, error)

func SRImport added in v0.3.0

func SRImport(ctx context.Context, a *AuthenticationConfig, resource []byte) (*http.Response, error)

func SRImportStream added in v0.3.0

func SRImportStream(ctx context.Context, a *AuthenticationConfig, r io.Reader) (*http.Response, error)

func SRListBehaviors added in v0.3.0

func SRListBehaviors(ctx context.Context, a *AuthenticationConfig, p *SRListParams) (*http.Response, error)

func SRListBehaviorsP added in v0.3.0

func SRListBehaviorsP(ctx context.Context, a *AuthenticationConfig, p util.Params) (*http.Response, error)

func SRListClasses added in v0.3.0

func SRListClasses(ctx context.Context, a *AuthenticationConfig, p *SRListParams) (*http.Response, error)

func SRListClassesP added in v0.3.0

func SRListClassesP(ctx context.Context, a *AuthenticationConfig, p util.Params) (*http.Response, error)

func SRListDataTypes added in v0.3.0

func SRListDataTypes(ctx context.Context, a *AuthenticationConfig, p *SRListParams) (*http.Response, error)

func SRListDataTypesP added in v0.3.0

func SRListDataTypesP(ctx context.Context, a *AuthenticationConfig, p util.Params) (*http.Response, error)

func SRListDescriptors added in v0.3.0

func SRListDescriptorsP added in v0.3.0

func SRListDescriptorsP(ctx context.Context, a *AuthenticationConfig, p util.Params) (*http.Response, error)

func SRListFieldGroups added in v0.3.0

func SRListFieldGroups(ctx context.Context, a *AuthenticationConfig, p *SRListParams) (*http.Response, error)

func SRListFieldGroupsP added in v0.3.0

func SRListFieldGroupsP(ctx context.Context, a *AuthenticationConfig, p util.Params) (*http.Response, error)

func SRListSchemas added in v0.3.0

func SRListSchemas(ctx context.Context, a *AuthenticationConfig, p *SRListParams) (*http.Response, error)

func SRListSchemasP added in v0.3.0

func SRListSchemasP(ctx context.Context, a *AuthenticationConfig, p util.Params) (*http.Response, error)

func SRListUnions added in v0.3.0

func SRListUnions(ctx context.Context, a *AuthenticationConfig, p *SRListParams) (*http.Response, error)

func SRListUnionsP added in v0.3.0

func SRListUnionsP(ctx context.Context, a *AuthenticationConfig, p util.Params) (*http.Response, error)

func SRPatchClass added in v0.3.1

func SRPatchClass(ctx context.Context, a *AuthenticationConfig, id string, payload []byte) (*http.Response, error)

func SRPatchDataType added in v0.3.1

func SRPatchDataType(ctx context.Context, a *AuthenticationConfig, id string, payload []byte) (*http.Response, error)

func SRPatchFieldGroup added in v0.3.1

func SRPatchFieldGroup(ctx context.Context, a *AuthenticationConfig, id string, payload []byte) (*http.Response, error)

func SRPatchSchema added in v0.3.1

func SRPatchSchema(ctx context.Context, a *AuthenticationConfig, id string, payload []byte) (*http.Response, error)

func SRUpdateClass added in v0.3.1

func SRUpdateClass(ctx context.Context, a *AuthenticationConfig, id string, payload []byte) (*http.Response, error)

func SRUpdateDataType added in v0.3.1

func SRUpdateDataType(ctx context.Context, a *AuthenticationConfig, id string, payload []byte) (*http.Response, error)

func SRUpdateDescriptor added in v0.3.1

func SRUpdateDescriptor(ctx context.Context, a *AuthenticationConfig, id string, payload []byte) (*http.Response, error)

func SRUpdateFieldGroup added in v0.3.1

func SRUpdateFieldGroup(ctx context.Context, a *AuthenticationConfig, id string, payload []byte) (*http.Response, error)

func SRUpdateSchema added in v0.3.1

func SRUpdateSchema(ctx context.Context, a *AuthenticationConfig, id string, payload []byte) (*http.Response, error)

func UPSGetEntities added in v0.2.0

func UPSGetEntities(ctx context.Context, auth *AuthenticationConfig, p *UPSEntitiesParams) (*http.Response, error)

func UPSGetEntitiesP added in v0.3.0

func UPSGetEntitiesP(ctx context.Context, auth *AuthenticationConfig, p util.Params) (*http.Response, error)

Types

type ACGetEffecticeACLPoliciesParams added in v0.3.0

type ACGetEffecticeACLPoliciesParams []string

func (ACGetEffecticeACLPoliciesParams) Params added in v0.3.0

type AuthenticationConfig

type AuthenticationConfig struct {
	Cache            bool
	DryRun           bool
	Server           string
	Organization     string
	TechnicalAccount string
	Audience         string
	ClientID         string
	ClientSecret     string
	Key              string
	Sandbox          string
	LoadToken        func() (*BearerToken, error)
	SaveToken        func(token *BearerToken) error
}

AuthenticationConfig contains the configuraion for getting the bearer token

func (*AuthenticationConfig) DeleteRequest

func (o *AuthenticationConfig) DeleteRequest(ctx context.Context, url string, a ...interface{}) (interface{}, error)

DeleteRequest sends a http delete request to the passed url

func (*AuthenticationConfig) DeleteRequestRaw added in v0.3.0

func (o *AuthenticationConfig) DeleteRequestRaw(ctx context.Context, url string, a ...interface{}) (*http.Response, error)

DeleteRequestRaw sends a HTTP DELETE request to the passed url

func (*AuthenticationConfig) FullRequest

func (o *AuthenticationConfig) FullRequest(ctx context.Context, verb string, header map[string]string, body io.Reader, url string, a ...interface{}) (interface{}, error)

FullRequest sends a http request with the passed verb to the passed url

func (*AuthenticationConfig) FullRequestRaw added in v0.2.0

func (o *AuthenticationConfig) FullRequestRaw(ctx context.Context, verb string, header map[string]string, body io.Reader, url string, a ...interface{}) (*http.Response, error)

FullRequestRaw sends a http request with the passed verb to the passed url

func (*AuthenticationConfig) GetRequest

func (o *AuthenticationConfig) GetRequest(ctx context.Context, url string, a ...interface{}) (interface{}, error)

GetRequest sends a http get request to the passed url

func (*AuthenticationConfig) GetRequestHRaw added in v0.3.0

func (o *AuthenticationConfig) GetRequestHRaw(ctx context.Context, header map[string]string, url string, a ...interface{}) (*http.Response, error)

GetRequestHRaw sends a http get request to the passed url

func (*AuthenticationConfig) GetRequestRaw added in v0.2.0

func (o *AuthenticationConfig) GetRequestRaw(ctx context.Context, url string, a ...interface{}) (*http.Response, error)

GetRequestRaw sends a http get request to the passed url

func (*AuthenticationConfig) GetToken

func (o *AuthenticationConfig) GetToken() (*BearerToken, error)

GetToken uses JWT to get a bearer token

func (*AuthenticationConfig) GetTokenRaw added in v0.2.0

func (o *AuthenticationConfig) GetTokenRaw() (*http.Response, error)

GetTokenRaw uses JWT to get a bearer token

func (*AuthenticationConfig) NoDryRun added in v0.2.0

func (*AuthenticationConfig) PatchRequest

func (o *AuthenticationConfig) PatchRequest(ctx context.Context, header map[string]string, data []byte, url string, a ...interface{}) (interface{}, error)

PatchRequest sends a http patch request to the passed url

func (*AuthenticationConfig) PatchRequestRaw added in v0.3.1

func (o *AuthenticationConfig) PatchRequestRaw(ctx context.Context, header map[string]string, data []byte, url string, a ...interface{}) (*http.Response, error)

PatchRequestRaw sends a http patch request to the passed url

func (*AuthenticationConfig) PostJSONRequest

func (o *AuthenticationConfig) PostJSONRequest(ctx context.Context, obj interface{}, url string, a ...interface{}) (interface{}, error)

PostJSONRequest serializes the passed object to JSON and sends a http post request to the passed url

func (*AuthenticationConfig) PostJSONRequestRaw added in v0.2.0

func (o *AuthenticationConfig) PostJSONRequestRaw(ctx context.Context, obj interface{}, url string, a ...interface{}) (*http.Response, error)

PostJSONRequestRaw serializes the passed object to JSON and sends a http post request to the passed url

func (*AuthenticationConfig) PostRequest

func (o *AuthenticationConfig) PostRequest(ctx context.Context, header map[string]string, data []byte, url string, a ...interface{}) (interface{}, error)

PostRequest sends a http post request to the passed url

func (*AuthenticationConfig) PostRequestRaw added in v0.3.0

func (o *AuthenticationConfig) PostRequestRaw(ctx context.Context, header map[string]string, data []byte, url string, a ...interface{}) (*http.Response, error)

PostRequestRaw sends a http post request to the passed url

func (*AuthenticationConfig) PostRequestStream added in v0.3.0

func (o *AuthenticationConfig) PostRequestStream(ctx context.Context, header map[string]string, r io.Reader, url string, a ...interface{}) (*http.Response, error)

PostRequestRaw sends a http post request to the passed url

func (*AuthenticationConfig) PutRequestRaw added in v0.3.1

func (o *AuthenticationConfig) PutRequestRaw(ctx context.Context, header map[string]string, data []byte, url string, a ...interface{}) (*http.Response, error)

PutRequestRaw sends a http put request to the passed url

func (*AuthenticationConfig) Request

func (o *AuthenticationConfig) Request(ctx context.Context, verb, url string, a ...interface{}) (interface{}, error)

Request sends a http request with the passed verb to the passed url

func (*AuthenticationConfig) UpdateHeader

func (o *AuthenticationConfig) UpdateHeader(req *http.Request) error

UpdateHeader adds the authentication headers to the passed http request

type BatchesOptions added in v0.3.0

type BatchesOptions struct {
	Limit         int
	TimeFormat    string
	CreatedAfter  string
	CreatedBefore string
	Dataset       string
	EndAfter      string
	EndBefore     string
	Name          string
	OrderBy       string
	StartAfter    string
	StartBefore   string
}

BatchesOptions contains all options for batch requests

func (*BatchesOptions) Params added in v0.3.0

func (b *BatchesOptions) Params() (util.Params, error)

ToURLPar converts the options to a URL parameter query

type BearerToken

type BearerToken struct {
	Token   string
	Expires time.Time
}

BearerToken contains a token and an expiration date

func (*BearerToken) LocalTime

func (t *BearerToken) LocalTime() string

LocalTime returns the expiry date as string in the local time zone

func (*BearerToken) ValidIn

func (t *BearerToken) ValidIn(d time.Duration) bool

ValidIn in checks if the token is still valid for passed duration

type DAOptions added in v0.3.0

type DAOptions struct {
	ID    string
	Start int
	Limit int
}

func (*DAOptions) Params added in v0.3.0

func (d *DAOptions) Params() util.Params

type DataSetRequest added in v0.3.0

type DataSetRequest struct {
	ConncectorID    string           `json:"connectorId,omitempty" yaml:"connectorId,omitempty"`
	ConncectoionID  string           `json:"connectionId,omitempty" yaml:"connectionId,omitempty"`
	Name            string           `json:"name,omitempty" yaml:"name,omitempty"`
	Namespace       string           `json:"namespace,omitempty" yaml:"namespace,omitempty"`
	FileDescription *FileDescription `json:"fileDescription,omitempty" yaml:"fileDescription,omitempty"`
	SchemaRef       *SchemaRef       `json:"schemaRef,omitempty" yaml:"schemaRef,omitempty"`
}

type FileDescription added in v0.3.0

type FileDescription struct {
	Format          string `json:"format,omitempty" yaml:"format,omitempty"`
	ContainerFormat string `json:"containerFormat,omitempty" yaml:"containerFormat,omitempty"`
	Persisted       bool   `json:"persisted,omitempty" yaml:"persisted,omitempty"`
}

type FlowGetConnectionsParams added in v0.2.0

type FlowGetConnectionsParams struct {
	Property          string
	Limit             int
	OrderBy           string
	ContinuationToken string
	Count             bool
}

func (*FlowGetConnectionsParams) Params added in v0.3.0

func (p *FlowGetConnectionsParams) Params() util.Params

type Func added in v0.3.0

type FuncID added in v0.3.0

type FuncPost added in v0.3.1

type FuncPost func(context.Context, *AuthenticationConfig, []byte) (*http.Response, error)

type FuncPostID added in v0.3.1

type FuncPostID func(context.Context, *AuthenticationConfig, string, []byte) (*http.Response, error)

type FuncTable added in v0.3.0

type FuncTable map[string]Func

func (FuncTable) Call added in v0.3.0

func (ft FuncTable) Call(name string, ctx context.Context, auth *AuthenticationConfig, params util.Params) (*http.Response, error)

type ISClusterParams added in v0.3.1

type ISClusterParams struct {
	ISParams
	GraphType string
}

func (*ISClusterParams) Accept added in v0.3.1

func (p *ISClusterParams) Accept() string

func (*ISClusterParams) Params added in v0.3.1

func (p *ISClusterParams) Params() util.Params

func (*ISClusterParams) Request added in v0.3.1

func (p *ISClusterParams) Request() *Request

type ISClustersParams added in v0.3.1

type ISClustersParams struct {
	Namespaces   []string
	NamesapceIDs []string
	IDs          []string
	GraphType    string
	Region       string
}

func (*ISClustersParams) Body added in v0.3.1

func (p *ISClustersParams) Body() ([]byte, error)

func (*ISClustersParams) Request added in v0.3.1

func (p *ISClustersParams) Request() (*Request, error)

type ISGetMappingParams added in v0.3.1

type ISGetMappingParams struct {
	ISParams
	TargetNS string
}

type ISParams added in v0.3.1

type ISParams struct {
	Namespace   string
	NamespaceID string
	ID          string
	Region      string
}

func (*ISParams) Request added in v0.3.1

func (p *ISParams) Request() *Request

func (*ISParams) Validate added in v0.3.1

func (p *ISParams) Validate() error

type ODGetParams added in v0.3.0

type ODGetParams struct {
	ID          string
	ContainerID string
	Schema      string
}

func (*ODGetParams) Params added in v0.3.0

func (p *ODGetParams) Params() util.Params

Params returns the parameters in generic util.Params format

type ODQueryParames added in v0.3.0

type ODQueryParames struct {
	ContainerID string
	Schema      string
	Query       string
	QOP         string
	Field       string
	OrderBy     string
	Limit       int
}

ODQueryParames contains all available parameters for offer decisioning queries.

func (*ODQueryParames) Params added in v0.3.0

func (p *ODQueryParames) Params() util.Params

Params returns the parameters in generic util.Params format

type Parameters added in v0.3.0

type Parameters interface {
	Params() util.Params
}

type ParametersE added in v0.3.0

type ParametersE interface {
	Params() (util.Params, error)
}

type Request added in v0.3.1

type Request struct {
	Query RequestQuery
	Body  []byte
	Aux   map[string]string
	// contains filtered or unexported fields
}

func NewRequest added in v0.3.1

func NewRequest(pairs ...string) *Request

func NewRequestBody added in v0.3.1

func NewRequestBody(body []byte, pairs ...string) *Request

func NewRequestHeader added in v0.3.1

func NewRequestHeader(header RequestHeader, pairs ...string) *Request

func (*Request) Accept added in v0.3.1

func (r *Request) Accept(value string)

func (*Request) ContentType added in v0.3.1

func (r *Request) ContentType(value string)

func (*Request) EncodedQuery added in v0.3.1

func (r *Request) EncodedQuery() string

func (*Request) GetValue added in v0.3.1

func (r *Request) GetValue(name string) string

func (*Request) GetValuePath added in v0.3.1

func (r *Request) GetValuePath(name string) string

func (*Request) GetValueQuery added in v0.3.1

func (r *Request) GetValueQuery(name string) string

func (*Request) GetValueV added in v0.3.1

func (r *Request) GetValueV(name, value string) string

GetValueV returns the value with the passed name. If the value doesn't exist it returns the second value.

func (*Request) Header added in v0.3.1

func (r *Request) Header() RequestHeader

func (*Request) SetHeader added in v0.3.1

func (r *Request) SetHeader(name, value string)

func (*Request) SetValue added in v0.3.1

func (r *Request) SetValue(name, value string)

type RequestHeader added in v0.3.1

type RequestHeader map[string]string

type RequestHost added in v0.3.1

type RequestHost map[string]string

type RequestQuery added in v0.3.1

type RequestQuery map[string][]string

func NewRequestQuery added in v0.3.1

func NewRequestQuery(pairs ...string) RequestQuery

func (RequestQuery) Add added in v0.3.1

func (p RequestQuery) Add(name, value string)

func (RequestQuery) Encode added in v0.3.1

func (p RequestQuery) Encode() string

Encode builds an URL query

func (RequestQuery) Set added in v0.3.1

func (p RequestQuery) Set(pairs ...string)

type SBGetSandboxParams added in v0.3.0

type SBGetSandboxParams string

func (SBGetSandboxParams) Params added in v0.3.0

func (p SBGetSandboxParams) Params() util.Params

type SRBaseParams added in v0.3.0

type SRBaseParams struct {
	Property string
	OrderBy  string
	Start    string
	Limit    uint
	Global   bool
}

func (*SRBaseParams) Params added in v0.3.0

func (p *SRBaseParams) Params() util.Params

type SRDescriptorFormat added in v0.3.0

type SRDescriptorFormat int

func (SRDescriptorFormat) Accept added in v0.3.0

func (f SRDescriptorFormat) Accept() string

type SRFormat added in v0.3.0

type SRFormat struct {
	Short       bool
	Full        bool
	NoText      bool
	Descriptors bool
	Version     string
}

func (*SRFormat) Accept added in v0.3.0

func (s *SRFormat) Accept() string

accept builds the accept string

func (*SRFormat) Params added in v0.3.0

func (s *SRFormat) Params() util.Params

type SRGetBaseParams added in v0.3.0

type SRGetBaseParams struct {
	ID     string
	Global bool
}

func (*SRGetBaseParams) Params added in v0.3.0

func (p *SRGetBaseParams) Params() util.Params

type SRGetDescriptorParams added in v0.3.0

type SRGetDescriptorParams struct {
	SRGetBaseParams
	SRDescriptorFormat
}

func (*SRGetDescriptorParams) Params added in v0.3.0

func (p *SRGetDescriptorParams) Params() util.Params

type SRGetGlobalParams added in v0.3.0

type SRGetGlobalParams struct {
	SRFormat
	ID string
}

func (*SRGetGlobalParams) Params added in v0.3.0

func (p *SRGetGlobalParams) Params() util.Params

type SRGetParams added in v0.3.0

type SRGetParams struct {
	SRGetBaseParams
	SRFormat
}

func (*SRGetParams) Params added in v0.3.0

func (p *SRGetParams) Params() util.Params

type SRListDescriptorsParams added in v0.3.0

type SRListDescriptorsParams struct {
	SRBaseParams
	SRDescriptorFormat
}

func (*SRListDescriptorsParams) Params added in v0.3.0

func (p *SRListDescriptorsParams) Params() util.Params

type SRListParams added in v0.3.0

type SRListParams struct {
	SRBaseParams
	SRFormat
}

func (*SRListParams) Params added in v0.3.0

func (p *SRListParams) Params() util.Params

type SchemaRef added in v0.3.0

type SchemaRef struct {
	ID          string `json:"id,omitempty" yaml:"id,omitempty"`
	ContentType string `json:"contentType,omitempty" yaml:"contentType,omitempty"`
}

type UPSEntitiesParams added in v0.2.0

type UPSEntitiesParams struct {
	Schema        string
	RelatedSchema string
	ID            string
	NS            string
	RelatedID     string
	RelatedNS     string
	Fields        string
	MP            string
	Start         string
	End           string
	Limit         int
	Order         string
	Property      string
	CA            bool
	TimeFormat    string
}

func (*UPSEntitiesParams) Params added in v0.3.0

func (p *UPSEntitiesParams) Params() (util.Params, error)

Directories

Path Synopsis
Package od contains offer decisiong related functions.
Package od contains offer decisiong related functions.

Jump to

Keyboard shortcuts

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