connect

package
v0.0.0-...-e2bdc13 Latest Latest
Warning

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

Go to latest
Published: Aug 12, 2023 License: MIT Imports: 16 Imported by: 0

Documentation

Index

Constants

View Source
const Version = "1.3.0"

Version identifies the current library version. Should match the git tag

Variables

View Source
var ErrNotFound = errors.New("resource not found")

Functions

func GetUserAgent

func GetUserAgent() string

Types

type ApplicationDeployment

type ApplicationDeployment struct {
	// Unique identifier of the application deployment.
	ID string `json:"id"`
	// Name of the application. Should match the value of `name` within the connect.yaml file of the Connector.
	ApplicationName string `json:"applicationName"`
	// Contains values of keys that are saved in plain text. Can be accessed after being set.
	StandardConfiguration []ConfigurationValue `json:"standardConfiguration"`
	// Contains values of secret keys. Cannot be accessed after being set.
	SecuredConfiguration []ConfigurationValue `json:"securedConfiguration"`
	// URL generated after deployment of service applications.
	Url *string `json:"url,omitempty"`
	// Pub/Sub Topic generated after deployment of event applications.
	Topic *string `json:"topic,omitempty"`
	// Cron schedule for job applications.
	Schedule *string `json:"schedule,omitempty"`
}

* * Describes an application deployment of the Connector. *

type Artifact

type Artifact struct {
	ApplicationName string `json:"applicationName"`
	ArtifactPath    string `json:"artifactPath"`
}

* * A connector internal build artifact (ex: docker image). *

type AuthenticationError

type AuthenticationError struct {
	// `"Bad credientals or Client ID is not defined"`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when the client cannot be authenticated. *

func (*AuthenticationError) DecodeStruct

func (obj *AuthenticationError) DecodeStruct(src map[string]interface{}) error

func (AuthenticationError) Error

func (obj AuthenticationError) Error() string

func (AuthenticationError) MarshalJSON

func (obj AuthenticationError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*AuthenticationError) UnmarshalJSON

func (obj *AuthenticationError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type AuthorizationError

type AuthorizationError struct {
	// `"Access denied"`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when the client does not have sufficient permissions for this operation. *

func (*AuthorizationError) DecodeStruct

func (obj *AuthorizationError) DecodeStruct(src map[string]interface{}) error

func (AuthorizationError) Error

func (obj AuthorizationError) Error() string

func (AuthorizationError) MarshalJSON

func (obj AuthorizationError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*AuthorizationError) UnmarshalJSON

func (obj *AuthorizationError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type BadGatewayError

type BadGatewayError struct {
	// Plain text description of the error.
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when a server-side problem is caused by scaling infrastructure resources. * * The client application should retry the request with exponential backoff up to a point where further delay is unacceptable. *

func (*BadGatewayError) DecodeStruct

func (obj *BadGatewayError) DecodeStruct(src map[string]interface{}) error

func (BadGatewayError) Error

func (obj BadGatewayError) Error() string

func (BadGatewayError) MarshalJSON

func (obj BadGatewayError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*BadGatewayError) UnmarshalJSON

func (obj *BadGatewayError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ByProjectKeyDeploymentsByIDLogsRequestBuilder

type ByProjectKeyDeploymentsByIDLogsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyDeploymentsByIDLogsRequestBuilder) Get

* * Retrieves logs for the given deployment.

type ByProjectKeyDeploymentsByIDLogsRequestMethodGet

type ByProjectKeyDeploymentsByIDLogsRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyDeploymentsByIDLogsRequestMethodGet) ApplicationName

func (*ByProjectKeyDeploymentsByIDLogsRequestMethodGet) Dump

func (r *ByProjectKeyDeploymentsByIDLogsRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyDeploymentsByIDLogsRequestMethodGet) EndDate

func (*ByProjectKeyDeploymentsByIDLogsRequestMethodGet) Execute

* * Retrieves logs for the given deployment.

func (*ByProjectKeyDeploymentsByIDLogsRequestMethodGet) PageToken

func (*ByProjectKeyDeploymentsByIDLogsRequestMethodGet) StartDate

func (*ByProjectKeyDeploymentsByIDLogsRequestMethodGet) WithHeaders

type ByProjectKeyDeploymentsByIDLogsRequestMethodGetInput

type ByProjectKeyDeploymentsByIDLogsRequestMethodGetInput struct {
	PageToken       *string
	ApplicationName *string
	StartDate       *time.Time
	EndDate         *time.Time
}

func (*ByProjectKeyDeploymentsByIDLogsRequestMethodGetInput) Values

type ByProjectKeyDeploymentsByIDLogsStreamRequestBuilder

type ByProjectKeyDeploymentsByIDLogsStreamRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyDeploymentsByIDLogsStreamRequestBuilder) Get

* * Stream logs for the given deployment.

type ByProjectKeyDeploymentsByIDLogsStreamRequestMethodGet

type ByProjectKeyDeploymentsByIDLogsStreamRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyDeploymentsByIDLogsStreamRequestMethodGet) ApplicationName

func (*ByProjectKeyDeploymentsByIDLogsStreamRequestMethodGet) Dump

func (*ByProjectKeyDeploymentsByIDLogsStreamRequestMethodGet) Execute

func (rb *ByProjectKeyDeploymentsByIDLogsStreamRequestMethodGet) Execute(ctx context.Context) (result *interface{}, err error)

* * Stream logs for the given deployment.

func (*ByProjectKeyDeploymentsByIDLogsStreamRequestMethodGet) WithHeaders

type ByProjectKeyDeploymentsByIDLogsStreamRequestMethodGetInput

type ByProjectKeyDeploymentsByIDLogsStreamRequestMethodGetInput struct {
	ApplicationName *string
}

func (*ByProjectKeyDeploymentsByIDLogsStreamRequestMethodGetInput) Values

type ByProjectKeyDeploymentsByIDRequestBuilder

type ByProjectKeyDeploymentsByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyDeploymentsByIDRequestBuilder) Delete

func (*ByProjectKeyDeploymentsByIDRequestBuilder) Get

func (*ByProjectKeyDeploymentsByIDRequestBuilder) Logs

func (*ByProjectKeyDeploymentsByIDRequestBuilder) LogsStream

func (*ByProjectKeyDeploymentsByIDRequestBuilder) Post

type ByProjectKeyDeploymentsByIDRequestMethodDelete

type ByProjectKeyDeploymentsByIDRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyDeploymentsByIDRequestMethodDelete) Dump

func (r *ByProjectKeyDeploymentsByIDRequestMethodDelete) Dump() map[string]interface{}

func (*ByProjectKeyDeploymentsByIDRequestMethodDelete) Execute

func (*ByProjectKeyDeploymentsByIDRequestMethodDelete) WithHeaders

type ByProjectKeyDeploymentsByIDRequestMethodGet

type ByProjectKeyDeploymentsByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyDeploymentsByIDRequestMethodGet) Dump

func (r *ByProjectKeyDeploymentsByIDRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyDeploymentsByIDRequestMethodGet) Execute

func (*ByProjectKeyDeploymentsByIDRequestMethodGet) WithHeaders

type ByProjectKeyDeploymentsByIDRequestMethodPost

type ByProjectKeyDeploymentsByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyDeploymentsByIDRequestMethodPost) Dump

func (r *ByProjectKeyDeploymentsByIDRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyDeploymentsByIDRequestMethodPost) Execute

func (*ByProjectKeyDeploymentsByIDRequestMethodPost) WithHeaders

type ByProjectKeyDeploymentsKeyByKeyLogsRequestBuilder

type ByProjectKeyDeploymentsKeyByKeyLogsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyDeploymentsKeyByKeyLogsRequestBuilder) Get

* * Retrieves logs for the given deployment.

type ByProjectKeyDeploymentsKeyByKeyLogsRequestMethodGet

type ByProjectKeyDeploymentsKeyByKeyLogsRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyDeploymentsKeyByKeyLogsRequestMethodGet) ApplicationName

func (*ByProjectKeyDeploymentsKeyByKeyLogsRequestMethodGet) Dump

func (*ByProjectKeyDeploymentsKeyByKeyLogsRequestMethodGet) EndDate

func (*ByProjectKeyDeploymentsKeyByKeyLogsRequestMethodGet) Execute

* * Retrieves logs for the given deployment.

func (*ByProjectKeyDeploymentsKeyByKeyLogsRequestMethodGet) PageToken

func (*ByProjectKeyDeploymentsKeyByKeyLogsRequestMethodGet) StartDate

func (*ByProjectKeyDeploymentsKeyByKeyLogsRequestMethodGet) WithHeaders

type ByProjectKeyDeploymentsKeyByKeyLogsRequestMethodGetInput

type ByProjectKeyDeploymentsKeyByKeyLogsRequestMethodGetInput struct {
	PageToken       *string
	ApplicationName *string
	StartDate       *time.Time
	EndDate         *time.Time
}

func (*ByProjectKeyDeploymentsKeyByKeyLogsRequestMethodGetInput) Values

type ByProjectKeyDeploymentsKeyByKeyLogsStreamRequestBuilder

type ByProjectKeyDeploymentsKeyByKeyLogsStreamRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyDeploymentsKeyByKeyLogsStreamRequestBuilder) Get

* * Stream logs for the given deployment.

type ByProjectKeyDeploymentsKeyByKeyLogsStreamRequestMethodGet

type ByProjectKeyDeploymentsKeyByKeyLogsStreamRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyDeploymentsKeyByKeyLogsStreamRequestMethodGet) ApplicationName

func (*ByProjectKeyDeploymentsKeyByKeyLogsStreamRequestMethodGet) Dump

func (*ByProjectKeyDeploymentsKeyByKeyLogsStreamRequestMethodGet) Execute

func (rb *ByProjectKeyDeploymentsKeyByKeyLogsStreamRequestMethodGet) Execute(ctx context.Context) (result *interface{}, err error)

* * Stream logs for the given deployment.

func (*ByProjectKeyDeploymentsKeyByKeyLogsStreamRequestMethodGet) WithHeaders

type ByProjectKeyDeploymentsKeyByKeyLogsStreamRequestMethodGetInput

type ByProjectKeyDeploymentsKeyByKeyLogsStreamRequestMethodGetInput struct {
	ApplicationName *string
}

func (*ByProjectKeyDeploymentsKeyByKeyLogsStreamRequestMethodGetInput) Values

type ByProjectKeyDeploymentsKeyByKeyRequestBuilder

type ByProjectKeyDeploymentsKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyDeploymentsKeyByKeyRequestBuilder) Delete

func (*ByProjectKeyDeploymentsKeyByKeyRequestBuilder) Get

func (*ByProjectKeyDeploymentsKeyByKeyRequestBuilder) Logs

func (*ByProjectKeyDeploymentsKeyByKeyRequestBuilder) LogsStream

func (*ByProjectKeyDeploymentsKeyByKeyRequestBuilder) Post

type ByProjectKeyDeploymentsKeyByKeyRequestMethodDelete

type ByProjectKeyDeploymentsKeyByKeyRequestMethodDelete struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyDeploymentsKeyByKeyRequestMethodDelete) Dump

func (*ByProjectKeyDeploymentsKeyByKeyRequestMethodDelete) Execute

func (*ByProjectKeyDeploymentsKeyByKeyRequestMethodDelete) WithHeaders

type ByProjectKeyDeploymentsKeyByKeyRequestMethodGet

type ByProjectKeyDeploymentsKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyDeploymentsKeyByKeyRequestMethodGet) Dump

func (r *ByProjectKeyDeploymentsKeyByKeyRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyDeploymentsKeyByKeyRequestMethodGet) Execute

func (*ByProjectKeyDeploymentsKeyByKeyRequestMethodGet) WithHeaders

type ByProjectKeyDeploymentsKeyByKeyRequestMethodPost

type ByProjectKeyDeploymentsKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyDeploymentsKeyByKeyRequestMethodPost) Dump

func (r *ByProjectKeyDeploymentsKeyByKeyRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyDeploymentsKeyByKeyRequestMethodPost) Execute

func (*ByProjectKeyDeploymentsKeyByKeyRequestMethodPost) WithHeaders

type ByProjectKeyDeploymentsRequestBuilder

type ByProjectKeyDeploymentsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyDeploymentsRequestBuilder) Get

* * Retrieves all deployments of a project key.

func (*ByProjectKeyDeploymentsRequestBuilder) Post

* * Specific Error Codes: * - [ConnectorStagedNotPreviewable](ctp:connect:type:ConnectorStagedNotPreviewableError) * - [DeploymentUnsupportedRegion](ctp:connect:type:DeploymentUnsupportedRegionError) * - [DeploymentUnknownApplicationConfiguration](ctp:connect:type:DeploymentUnknownApplicationConfigurationError) * - [DeploymentUnknownApplicationConfigurationKey](ctp:connect:type:DeploymentUnknownApplicationConfigurationKeyError) *

func (*ByProjectKeyDeploymentsRequestBuilder) WithId

func (*ByProjectKeyDeploymentsRequestBuilder) WithKey

type ByProjectKeyDeploymentsRequestMethodGet

type ByProjectKeyDeploymentsRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyDeploymentsRequestMethodGet) Dump

func (r *ByProjectKeyDeploymentsRequestMethodGet) Dump() map[string]interface{}

func (*ByProjectKeyDeploymentsRequestMethodGet) Execute

func (rb *ByProjectKeyDeploymentsRequestMethodGet) Execute(ctx context.Context) (result *Paged, err error)

* * Retrieves all deployments of a project key.

func (*ByProjectKeyDeploymentsRequestMethodGet) Limit

func (*ByProjectKeyDeploymentsRequestMethodGet) Offset

func (*ByProjectKeyDeploymentsRequestMethodGet) Sort

func (*ByProjectKeyDeploymentsRequestMethodGet) WithHeaders

type ByProjectKeyDeploymentsRequestMethodGetInput

type ByProjectKeyDeploymentsRequestMethodGetInput struct {
	Limit  *int
	Offset *int
	Sort   []string
}

func (*ByProjectKeyDeploymentsRequestMethodGetInput) Values

type ByProjectKeyDeploymentsRequestMethodPost

type ByProjectKeyDeploymentsRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyDeploymentsRequestMethodPost) Dump

func (r *ByProjectKeyDeploymentsRequestMethodPost) Dump() map[string]interface{}

func (*ByProjectKeyDeploymentsRequestMethodPost) Execute

* * Specific Error Codes: * - [ConnectorStagedNotPreviewable](ctp:connect:type:ConnectorStagedNotPreviewableError) * - [DeploymentUnsupportedRegion](ctp:connect:type:DeploymentUnsupportedRegionError) * - [DeploymentUnknownApplicationConfiguration](ctp:connect:type:DeploymentUnknownApplicationConfigurationError) * - [DeploymentUnknownApplicationConfigurationKey](ctp:connect:type:DeploymentUnknownApplicationConfigurationKeyError) *

func (*ByProjectKeyDeploymentsRequestMethodPost) WithHeaders

type ByProjectKeyRequestBuilder

type ByProjectKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ByProjectKeyRequestBuilder) Deployments

type CertificationInfo

type CertificationInfo struct {
	// Comments made during the certification process.
	Comments []CertificationInfoComment `json:"comments"`
}

type CertificationInfoComment

type CertificationInfoComment struct {
	// The commercetools Composable Commerce Project key associated with the person making the comment.
	UserId string `json:"userId"`
	// Date and time (UTC) the comment was added.
	Datetime time.Time `json:"datetime"`
	// The body text of the comment.
	Comment string `json:"comment"`
}

* * Contains metadata and body text of a comment made during the certification process. *

type Client

type Client struct {
	// contains filtered or unexported fields
}

func NewClient

func NewClient(cfg *ClientConfig) (*Client, error)

NewClient creates a new client based on the provided ClientConfig

func (*Client) Connectors

func (c *Client) Connectors() *ConnectorsRequestBuilder

func (*Client) WithProjectKey

func (c *Client) WithProjectKey(projectKey string) *ByProjectKeyRequestBuilder

* * The Project endpoint is used to retrieve certain information from a project.

type ClientConfig

type ClientConfig struct {
	URL         string
	Credentials *clientcredentials.Config
	LogLevel    int
	HTTPClient  *http.Client
	UserAgent   string
}

type ConcurrentModificationError

type ConcurrentModificationError struct {
	// `"Object id=$resourceId or key=$resourceKey has a different version than expected. Expected: $expectedVersion - Actual: $currentVersion)"`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Expected version of the resource.
	ExpectedVersion int `json:"expectedVersion"`
	// Current version of the resource.
	CurrentVersion *int `json:"currentVersion,omitempty"`
}

* * Returned when the request conflicts with the current state of the involved resources. Typically, the request attempts to modify a resource that is out of date (that is modified by another client since it was last retrieved). * The client application should resolve the conflict (with or without involving the end-user) before retrying the request. *

func (*ConcurrentModificationError) DecodeStruct

func (obj *ConcurrentModificationError) DecodeStruct(src map[string]interface{}) error

func (ConcurrentModificationError) Error

func (obj ConcurrentModificationError) Error() string

func (ConcurrentModificationError) MarshalJSON

func (obj ConcurrentModificationError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ConcurrentModificationError) UnmarshalJSON

func (obj *ConcurrentModificationError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ConfigurationKey

type ConfigurationKey struct {
	// Name of the environment variable.
	Key string `json:"key"`
	// Description of the environment variable.
	Description string `json:"description"`
}

type ConfigurationValue

type ConfigurationValue struct {
	// Name of the environment variable.
	Key string `json:"key"`
	// Value of the environment variable.
	Value string `json:"value"`
}

type Connector

type Connector struct {
	// Unique identifier of the Connector.
	ID string `json:"id"`
	// User-defined unique identifier of the Connector.
	Key *string `json:"key,omitempty"`
	// Current version of the Connector.
	Version int `json:"version"`
	// Name of the Connector.
	Name string `json:"name"`
	// Description of the Connector.
	Description *string `json:"description,omitempty"`
	// Owner of the Connector.
	Creator Creator `json:"creator"`
	// GitHub repository details of the Connector.
	Repository Repository `json:"repository"`
	// Configurations needed by Connectors for hosting. Loaded as environment variables in the workload.
	Configurations []ConnectorConfigurationApplication `json:"configurations"`
	// If `true`, only Composable Commerce Projects specified in `privateProjects` can access the Connector.
	Private bool `json:"private"`
	// If not empty, Connectors can only be deployed in these Regions. If empty, Connectors can be deployed in any [supported Region](hosts-and-authorization#hosts).
	SupportedRegions []Region `json:"supportedRegions"`
}

func (Connector) MarshalJSON

func (obj Connector) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ConnectorAddCertificationCommentAction

type ConnectorAddCertificationCommentAction struct {
	// Comment to add.
	Comment string `json:"comment"`
}

* * Add a comment during the certification process of the Connector. *

func (ConnectorAddCertificationCommentAction) MarshalJSON

func (obj ConnectorAddCertificationCommentAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ConnectorAddPrivateProjectAction

type ConnectorAddPrivateProjectAction struct {
	// The Composable Commerce Project to add to `privateProjects`. Must use the format "{region}:{projectKey}".
	PrivateProject string `json:"privateProject"`
}

* * Allow a Composable Commerce Project to access a private Connector. * * Attempting to add a `privateProject` to a non-private ConnectorStaged returns the [ConnectorStagedNotPrivate](ctp:connect:type:ConnectorStagedNotPrivateError) error. *

func (ConnectorAddPrivateProjectAction) MarshalJSON

func (obj ConnectorAddPrivateProjectAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ConnectorAlreadyCertifiedError

type ConnectorAlreadyCertifiedError struct {
	// `"The ConnectorStaged is already certified"`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when trying to trigger the certification process for a Connector, but the Connector is already certified. * * The error is returned as a failed response to the [Trigger Certification Process](ctp:connect:type:ConnectorTriggerCertificationAction) update action. *

func (*ConnectorAlreadyCertifiedError) DecodeStruct

func (obj *ConnectorAlreadyCertifiedError) DecodeStruct(src map[string]interface{}) error

func (ConnectorAlreadyCertifiedError) Error

func (ConnectorAlreadyCertifiedError) MarshalJSON

func (obj ConnectorAlreadyCertifiedError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ConnectorAlreadyCertifiedError) UnmarshalJSON

func (obj *ConnectorAlreadyCertifiedError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ConnectorConfigurationApplication

type ConnectorConfigurationApplication struct {
	// Name of the application. Should match the value of `name` within the connect.yaml file of the Connect application.
	ApplicationName string `json:"applicationName"`
	// Contains the name and description of keys saved as plain text.
	StandardConfiguration []ConfigurationKey `json:"standardConfiguration"`
	// Contains the name and description of secret keys.
	SecuredConfiguration []ConfigurationKey `json:"securedConfiguration"`
}

* * Describes the required configuration for a Connector. *

type ConnectorDraft

type ConnectorDraft struct {
	// User-defined unique identifier of the Connector.
	Key *string `json:"key,omitempty"`
	// Name of the Connector.
	Name string `json:"name"`
	// Description of the Connector.
	Description *string `json:"description,omitempty"`
	// Owner of the Connector.
	Creator Creator `json:"creator"`
	// GitHub repository details of the Connector.
	Repository Repository `json:"repository"`
	// If provided, Connectors can only be deployed in these Regions. If not provided, Connectors can be deployed in any [supported Region](hosts-and-authorization#hosts).
	SupportedRegions []Region `json:"supportedRegions"`
	// Contains Composable Commerce Project keys listed using the format "{region}:{projectKey}". If `private` is true, only these Composable Commerce Projects can access the Connector.
	PrivateProjects []string `json:"privateProjects"`
}

func (ConnectorDraft) MarshalJSON

func (obj ConnectorDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ConnectorReference

type ConnectorReference struct {
	// Unique identifier of the referenced Connector.
	ID *string `json:"id,omitempty"`
	// User-defined unique identifier of the referenced Connector.
	Key *string `json:"key,omitempty"`
	// If `true`, the previewable [ConnectorStaged](ctp:connect:type:ConnectorStaged) will be referenced instead of the certified Connector. The `isPreviewable` field of the [ConnectorStaged](ctp:connect:type:ConnectorStaged) must be `true` to reference a previewable ConnectorStaged.
	Staged *bool `json:"staged,omitempty"`
	// Version of the referenced Connector.
	Version int `json:"version"`
}

* * Reference to a Connector. Either `id` or `key` is required.

type ConnectorRemovePrivateProjectAction

type ConnectorRemovePrivateProjectAction struct {
	// The Composable Commerce Project to remove from `privateProjects`. Must use the format "{region}:{projectKey}".
	PrivateProject string `json:"privateProject"`
}

* * Remove a Composable Commerce Project's access to a private Connector. * * Attempting to remove a `privateProject` from a non-private ConnectorStaged returns the [ConnectorStagedNotPrivate](ctp:connect:type:ConnectorStagedNotPrivateError) error. *

func (ConnectorRemovePrivateProjectAction) MarshalJSON

func (obj ConnectorRemovePrivateProjectAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ConnectorSetConfigurationsAction

type ConnectorSetConfigurationsAction struct {
	// Value to set. If null or empty, any existing value is removed.
	Configurations []ConnectorConfigurationApplication `json:"configurations"`
}

* * Set the configuration for the Connector. *

func (ConnectorSetConfigurationsAction) MarshalJSON

func (obj ConnectorSetConfigurationsAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ConnectorSetCreatorCompanyAction

type ConnectorSetCreatorCompanyAction struct {
	// Value to set.
	CreatorCompany string `json:"creatorCompany"`
}

* * Updates the creator's company. *

func (ConnectorSetCreatorCompanyAction) MarshalJSON

func (obj ConnectorSetCreatorCompanyAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ConnectorSetCreatorEmailAction

type ConnectorSetCreatorEmailAction struct {
	// Value to set.
	CreatorEmail string `json:"creatorEmail"`
}

* * Updates the creator's contact email address. *

func (ConnectorSetCreatorEmailAction) MarshalJSON

func (obj ConnectorSetCreatorEmailAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ConnectorSetCreatorNameAction

type ConnectorSetCreatorNameAction struct {
	// Value to set.
	CreatorName string `json:"creatorName"`
}

* * Updates the creator's name. *

func (ConnectorSetCreatorNameAction) MarshalJSON

func (obj ConnectorSetCreatorNameAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ConnectorSetCreatorNoOfDevelopersAction

type ConnectorSetCreatorNoOfDevelopersAction struct {
	// Value to set.
	CreatorNoOfDevelopers int `json:"creatorNoOfDevelopers"`
}

* * Updates the number of developers within the creator's company. *

func (ConnectorSetCreatorNoOfDevelopersAction) MarshalJSON

func (obj ConnectorSetCreatorNoOfDevelopersAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ConnectorSetCreatorTitleAction

type ConnectorSetCreatorTitleAction struct {
	// Value to set.
	CreatorTitle string `json:"creatorTitle"`
}

* * Updates the creator's title. *

func (ConnectorSetCreatorTitleAction) MarshalJSON

func (obj ConnectorSetCreatorTitleAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ConnectorSetDescriptionAction

type ConnectorSetDescriptionAction struct {
	// Value to set.
	Description string `json:"description"`
}

* * Updates the description in Connector. *

func (ConnectorSetDescriptionAction) MarshalJSON

func (obj ConnectorSetDescriptionAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ConnectorSetNameAction

type ConnectorSetNameAction struct {
	// Value to set.
	Name string `json:"name"`
}

* * Updates the name of the Connector. *

func (ConnectorSetNameAction) MarshalJSON

func (obj ConnectorSetNameAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ConnectorSetRepositoryAction

type ConnectorSetRepositoryAction struct {
	// New HTTPS or SSH GitHub URL to assign to the Connector.
	Url string `json:"url"`
	// New Git tag to assign to the Connector.
	Tag string `json:"tag"`
}

* * Update the GitHub repository details for the Connector. *

func (ConnectorSetRepositoryAction) MarshalJSON

func (obj ConnectorSetRepositoryAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ConnectorSetSupportedRegionsAction

type ConnectorSetSupportedRegionsAction struct {
	// New value to set.
	Regions []Region `json:"regions"`
}

* * Updates the Regions that the Connector can be deployed in. *

func (ConnectorSetSupportedRegionsAction) MarshalJSON

func (obj ConnectorSetSupportedRegionsAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ConnectorStaged

type ConnectorStaged struct {
	// Unique identifier of the Connector.
	ID string `json:"id"`
	// User-defined unique identifier of the Connector.
	Key *string `json:"key,omitempty"`
	// Current version of the Connector.
	Version int `json:"version"`
	// Name of the Connector.
	Name string `json:"name"`
	// Description of the Connector.
	Description string `json:"description"`
	// Owner of the Connector.
	Creator Creator `json:"creator"`
	// GitHub repository details of the Connector.
	Repository Repository `json:"repository"`
	// Configurations needed by Connectors for hosting. Loaded as environment variables in the workload.
	Configurations []ConnectorConfigurationApplication `json:"configurations"`
	// If `true`, only Composable Commerce Projects specified in `privateProjects` can access the Connector.
	Private bool `json:"private"`
	// Contains Composable Commerce Project keys listed using the format "{region}:{projectKey}". If `private` is true, only these Composable Commerce Projects can access the Connector once listed.
	PrivateProjects []string `json:"privateProjects"`
	// If not empty, Connectors can only be deployed in these Regions. If empty, Connectors can be deployed in any [supported Region](hosts-and-authorization#hosts).
	SupportedRegions []Region `json:"supportedRegions"`
	// Comments made during the certification process.
	CertificationInfo *CertificationInfo `json:"certificationInfo,omitempty"`
	// Current status of the Connector.
	Status string `json:"status"`
	// If `true`, the Connector is published and ready for use.
	AlreadyListed bool `json:"alreadyListed"`
	// If `true`, the ConnectorStaged data is different from the production [Connector](ctp:connect:type:Connector) data.
	HasChanges bool `json:"hasChanges"`
	// The previewable status of the ConnectorStaged.
	IsPreviewable *string `json:"isPreviewable,omitempty"`
}

type ConnectorStagedInCertificationError

type ConnectorStagedInCertificationError struct {
	// `"The ConnectorStaged is already in certification"`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when trying to trigger the certification process for a Connector that is already in the certification process. * * The error is returned as a failed response to the [Trigger Certification Process](ctp:connect:type:ConnectorTriggerCertificationAction) update action. *

func (*ConnectorStagedInCertificationError) DecodeStruct

func (obj *ConnectorStagedInCertificationError) DecodeStruct(src map[string]interface{}) error

func (ConnectorStagedInCertificationError) Error

func (ConnectorStagedInCertificationError) MarshalJSON

func (obj ConnectorStagedInCertificationError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ConnectorStagedInCertificationError) UnmarshalJSON

func (obj *ConnectorStagedInCertificationError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ConnectorStagedNotPreviewableError

type ConnectorStagedNotPreviewableError struct {
	// `"Connector id=$resourceId or key=$resourceKey with version $version is not previewable"`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when a ConnectorStaged to be deployed is not previewable. * * The error is returned as a failed response to the [Create a Deployment](deployments#create-deployment) request. *

func (*ConnectorStagedNotPreviewableError) DecodeStruct

func (obj *ConnectorStagedNotPreviewableError) DecodeStruct(src map[string]interface{}) error

func (ConnectorStagedNotPreviewableError) Error

func (ConnectorStagedNotPreviewableError) MarshalJSON

func (obj ConnectorStagedNotPreviewableError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ConnectorStagedNotPreviewableError) UnmarshalJSON

func (obj *ConnectorStagedNotPreviewableError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ConnectorStagedNotPrivateError

type ConnectorStagedNotPrivateError struct {
	// `"The operation is not valid because ConnectorStaged with id=$resourceId or key=$resourceKey is not private"`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when attempting to change the `privateProjects` of a non-private ConnectorStaged. * * The error is returned as a failed response to the [Add Project to Private Connector](ctp:connect:type:ConnectorAddPrivateProjectAction) and [Remove Project from Private Connector](ctp:connect:type:ConnectorRemovePrivateProjectAction) update actions. *

func (*ConnectorStagedNotPrivateError) DecodeStruct

func (obj *ConnectorStagedNotPrivateError) DecodeStruct(src map[string]interface{}) error

func (ConnectorStagedNotPrivateError) Error

func (ConnectorStagedNotPrivateError) MarshalJSON

func (obj ConnectorStagedNotPrivateError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ConnectorStagedNotPrivateError) UnmarshalJSON

func (obj *ConnectorStagedNotPrivateError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ConnectorStagedPreviewRequestUnderProcessError

type ConnectorStagedPreviewRequestUnderProcessError struct {
	// `"The ConnectorStaged preview request is already in progress"`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when attempting to request previewable status of a ConnectorStaged that is currently being reviewed for previewable status. * * The error is returned as a failed response to the [Preview Connector](ctp:connect:type:ConnectorUpdatePreviewableAction) update action. *

func (*ConnectorStagedPreviewRequestUnderProcessError) DecodeStruct

func (obj *ConnectorStagedPreviewRequestUnderProcessError) DecodeStruct(src map[string]interface{}) error

func (ConnectorStagedPreviewRequestUnderProcessError) Error

func (ConnectorStagedPreviewRequestUnderProcessError) MarshalJSON

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ConnectorStagedPreviewRequestUnderProcessError) UnmarshalJSON

func (obj *ConnectorStagedPreviewRequestUnderProcessError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ConnectorStatus

type ConnectorStatus string

* * Indicates the current status of the ConnectorStaged. *

const (
	ConnectorStatusDraft                 ConnectorStatus = "Draft"
	ConnectorStatusReadyForCertification ConnectorStatus = "ReadyForCertification"
	ConnectorStatusInCertification       ConnectorStatus = "InCertification"
	ConnectorStatusFeedbackRequired      ConnectorStatus = "FeedbackRequired"
	ConnectorStatusCertified             ConnectorStatus = "Certified"
)

type ConnectorTriggerCertificationAction

type ConnectorTriggerCertificationAction struct {
}

* * After triggering the certification process you cannot update the Connector until the review process is complete. * * Triggering the certification process when the Connector is already certified, or when the Connector is in the certification process, returns the [ConnectorAlreadyCertified](ctp:connect:type:ConnectorAlreadyCertifiedError) and [ConnectorStagedInCertification](ctp:connect:type:ConnectorStagedInCertificationError) errors, respectively. *

func (ConnectorTriggerCertificationAction) MarshalJSON

func (obj ConnectorTriggerCertificationAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ConnectorUnlistAction

type ConnectorUnlistAction struct {
}

* * Removes a certified and listed Connector from search results and listings. This update action does not affect deployed instances of the Connector. *

func (ConnectorUnlistAction) MarshalJSON

func (obj ConnectorUnlistAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ConnectorUpdate

type ConnectorUpdate struct {
	// Expected version of the Connector on which the changes apply.
	Version int `json:"version"`
	// Update actions to be performed on the Connector.
	Actions []ConnectorUpdateAction `json:"actions"`
}

func (*ConnectorUpdate) UnmarshalJSON

func (obj *ConnectorUpdate) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ConnectorUpdateAction

type ConnectorUpdateAction interface{}

type ConnectorUpdatePreviewableAction

type ConnectorUpdatePreviewableAction struct {
}

* * Requests previewable status for the ConnectorStaged. A previewable ConnectorStaged can used in a Deployment for testing/preview purposes. * * After using this update action the status of `isPreviewable` will change to `pending` and your request will be reviewed by the Connect team. After being reviewed, the status of `isPreviewable` will change to `true` if the previewable status has been granted or `false` if rejected. * * If `false`, the Connect team will contact you regarding any issues raised during the review process. * * Requesting previewable status for a ConnectorStaged that is currently being reviewed for previewable status returns the [ConnectorStagedPreviewRequestUnderProcess](ctp:connect:type:ConnectorStagedPreviewRequestUnderProcessError) error. *

func (ConnectorUpdatePreviewableAction) MarshalJSON

func (obj ConnectorUpdatePreviewableAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type ConnectorsByIDRequestBuilder

type ConnectorsByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ConnectorsByIDRequestBuilder) Get

type ConnectorsByIDRequestMethodGet

type ConnectorsByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ConnectorsByIDRequestMethodGet) Dump

func (r *ConnectorsByIDRequestMethodGet) Dump() map[string]interface{}

func (*ConnectorsByIDRequestMethodGet) Execute

func (rb *ConnectorsByIDRequestMethodGet) Execute(ctx context.Context) (result *Connector, err error)

func (*ConnectorsByIDRequestMethodGet) WithHeaders

type ConnectorsDraftsByIDRequestBuilder

type ConnectorsDraftsByIDRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ConnectorsDraftsByIDRequestBuilder) Get

func (*ConnectorsDraftsByIDRequestBuilder) Post

type ConnectorsDraftsByIDRequestMethodGet

type ConnectorsDraftsByIDRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ConnectorsDraftsByIDRequestMethodGet) Dump

func (r *ConnectorsDraftsByIDRequestMethodGet) Dump() map[string]interface{}

func (*ConnectorsDraftsByIDRequestMethodGet) Execute

func (*ConnectorsDraftsByIDRequestMethodGet) WithHeaders

type ConnectorsDraftsByIDRequestMethodPost

type ConnectorsDraftsByIDRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ConnectorsDraftsByIDRequestMethodPost) Dump

func (r *ConnectorsDraftsByIDRequestMethodPost) Dump() map[string]interface{}

func (*ConnectorsDraftsByIDRequestMethodPost) Execute

func (*ConnectorsDraftsByIDRequestMethodPost) WithHeaders

type ConnectorsDraftsKeyByKeyRequestBuilder

type ConnectorsDraftsKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ConnectorsDraftsKeyByKeyRequestBuilder) Get

func (*ConnectorsDraftsKeyByKeyRequestBuilder) Post

type ConnectorsDraftsKeyByKeyRequestMethodGet

type ConnectorsDraftsKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ConnectorsDraftsKeyByKeyRequestMethodGet) Dump

func (r *ConnectorsDraftsKeyByKeyRequestMethodGet) Dump() map[string]interface{}

func (*ConnectorsDraftsKeyByKeyRequestMethodGet) Execute

func (*ConnectorsDraftsKeyByKeyRequestMethodGet) WithHeaders

type ConnectorsDraftsKeyByKeyRequestMethodPost

type ConnectorsDraftsKeyByKeyRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ConnectorsDraftsKeyByKeyRequestMethodPost) Dump

func (r *ConnectorsDraftsKeyByKeyRequestMethodPost) Dump() map[string]interface{}

func (*ConnectorsDraftsKeyByKeyRequestMethodPost) Execute

func (*ConnectorsDraftsKeyByKeyRequestMethodPost) WithHeaders

type ConnectorsDraftsRequestBuilder

type ConnectorsDraftsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ConnectorsDraftsRequestBuilder) Get

func (*ConnectorsDraftsRequestBuilder) Post

func (*ConnectorsDraftsRequestBuilder) WithId

func (*ConnectorsDraftsRequestBuilder) WithKey

type ConnectorsDraftsRequestMethodGet

type ConnectorsDraftsRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ConnectorsDraftsRequestMethodGet) Dump

func (r *ConnectorsDraftsRequestMethodGet) Dump() map[string]interface{}

func (*ConnectorsDraftsRequestMethodGet) Execute

func (rb *ConnectorsDraftsRequestMethodGet) Execute(ctx context.Context) (result *Paged, err error)

func (*ConnectorsDraftsRequestMethodGet) Limit

func (*ConnectorsDraftsRequestMethodGet) Offset

func (*ConnectorsDraftsRequestMethodGet) Sort

func (*ConnectorsDraftsRequestMethodGet) WithHeaders

func (*ConnectorsDraftsRequestMethodGet) WithQueryParams

type ConnectorsDraftsRequestMethodGetInput

type ConnectorsDraftsRequestMethodGetInput struct {
	Limit  *int
	Offset *int
	Sort   []string
}

func (*ConnectorsDraftsRequestMethodGetInput) Values

type ConnectorsDraftsRequestMethodPost

type ConnectorsDraftsRequestMethodPost struct {
	// contains filtered or unexported fields
}

func (*ConnectorsDraftsRequestMethodPost) Dump

func (r *ConnectorsDraftsRequestMethodPost) Dump() map[string]interface{}

func (*ConnectorsDraftsRequestMethodPost) Execute

func (rb *ConnectorsDraftsRequestMethodPost) Execute(ctx context.Context) (result *ConnectorStaged, err error)

func (*ConnectorsDraftsRequestMethodPost) WithHeaders

type ConnectorsKeyByKeyRequestBuilder

type ConnectorsKeyByKeyRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ConnectorsKeyByKeyRequestBuilder) Get

type ConnectorsKeyByKeyRequestMethodGet

type ConnectorsKeyByKeyRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ConnectorsKeyByKeyRequestMethodGet) Dump

func (r *ConnectorsKeyByKeyRequestMethodGet) Dump() map[string]interface{}

func (*ConnectorsKeyByKeyRequestMethodGet) Execute

func (rb *ConnectorsKeyByKeyRequestMethodGet) Execute(ctx context.Context) (result *Connector, err error)

func (*ConnectorsKeyByKeyRequestMethodGet) WithHeaders

type ConnectorsRequestBuilder

type ConnectorsRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ConnectorsRequestBuilder) Drafts

func (*ConnectorsRequestBuilder) Search

func (*ConnectorsRequestBuilder) WithId

func (*ConnectorsRequestBuilder) WithKey

type ConnectorsSearchRequestBuilder

type ConnectorsSearchRequestBuilder struct {
	// contains filtered or unexported fields
}

func (*ConnectorsSearchRequestBuilder) Get

* * Retrieves all available Connectors.

type ConnectorsSearchRequestMethodGet

type ConnectorsSearchRequestMethodGet struct {
	// contains filtered or unexported fields
}

func (*ConnectorsSearchRequestMethodGet) CreatorCompany

func (*ConnectorsSearchRequestMethodGet) Dump

func (r *ConnectorsSearchRequestMethodGet) Dump() map[string]interface{}

func (*ConnectorsSearchRequestMethodGet) Execute

func (rb *ConnectorsSearchRequestMethodGet) Execute(ctx context.Context) (result *Paged, err error)

* * Retrieves all available Connectors.

func (*ConnectorsSearchRequestMethodGet) ID

func (*ConnectorsSearchRequestMethodGet) Key

func (*ConnectorsSearchRequestMethodGet) Limit

func (*ConnectorsSearchRequestMethodGet) Offset

func (*ConnectorsSearchRequestMethodGet) Private

func (*ConnectorsSearchRequestMethodGet) Sort

func (*ConnectorsSearchRequestMethodGet) Text

func (*ConnectorsSearchRequestMethodGet) WithHeaders

func (*ConnectorsSearchRequestMethodGet) WithQueryParams

type ConnectorsSearchRequestMethodGetInput

type ConnectorsSearchRequestMethodGetInput struct {
	Text           *string
	Limit          *int
	Offset         *int
	Sort           []string
	Private        *bool
	CreatorCompany *string
	ID             []string
	Key            []string
}

func (*ConnectorsSearchRequestMethodGetInput) Values

type Creator

type Creator struct {
	// Name of the person who owns the Connector.
	Name *string `json:"name,omitempty"`
	// Title of the person who owns the Connector.
	Title *string `json:"title,omitempty"`
	// Contact email address of the Creator.
	Email string `json:"email"`
	// Name of the company that owns the Connector.
	Company *string `json:"company,omitempty"`
	// Number of developers currently working for the company.
	NoOfDevelopers *int `json:"noOfDevelopers,omitempty"`
}

* * Contains details of the creator of the Connector. * These details are used to contact the creator during the certification process. *

type CursorPaged

type CursorPaged struct {
	Data interface{} `json:"data"`
	Next string      `json:"next"`
}

* * A Cursor Paged Result. *

type Date

type Date struct {
	Year  int
	Month time.Month
	Day   int
}

Date holds date information for Commercetools API format

func NewDate

func NewDate(year int, month time.Month, day int) Date

NewDate initializes a Date struct

func (*Date) MarshalJSON

func (d *Date) MarshalJSON() ([]byte, error)

MarshalJSON marshals into the commercetools date format

func (*Date) UnmarshalJSON

func (d *Date) UnmarshalJSON(data []byte) error

UnmarshalJSON decodes JSON data into a Date struct

type DecodeStruct

type DecodeStruct interface {
	DecodeStruct(map[string]interface{}) error
}

type Deployment

type Deployment struct {
	// Unique identifier of the Deployment.
	ID string `json:"id"`
	// User-defined unique identifier of the Deployment.
	Key *string `json:"key,omitempty"`
	// Current version of the Deployment.
	Version int `json:"version"`
	// Details of the [Connector](ctp:connect:type:Connector) being deployed.
	Connector DeploymentConnector `json:"connector"`
	// Build reference id and outcome of the Deployment.
	Details DeploymentDetails `json:"details"`
	// Region of the Deployment.
	DeployedRegion string `json:"deployedRegion"`
	// Application deployments needed by the connector for hosting and configuration, refer to Connector configurations for details.
	Applications []ApplicationDeployment `json:"applications"`
	// Indicates the current status of the Deployment.
	Status string `json:"status"`
}

type DeploymentConfigurationApplication

type DeploymentConfigurationApplication struct {
	// Name of the application. Should match the value of `name` within the connect.yaml file of the Connect application.
	ApplicationName string `json:"applicationName"`
	// Contains values of keys that are saved in plain text. Can be accessed after being set.
	StandardConfiguration []ConfigurationValue `json:"standardConfiguration"`
	// Contains values of secret keys. Cannot be accessed after being set.
	SecuredConfiguration []ConfigurationValue `json:"securedConfiguration"`
}

* * Describes the configuration set of a given application. *

type DeploymentConnector

type DeploymentConnector struct {
	// `id` of the Connector.
	ID string `json:"id"`
	// User-defined unique identifier of the Connector.
	Key *string `json:"key,omitempty"`
	// Version of the Connector.
	Version int `json:"version"`
	// Name of the Connector.
	Name string `json:"name"`
	// Description of the Connector.
	Description *string `json:"description,omitempty"`
	// Owner of the Connector.
	Creator Creator `json:"creator"`
	// GitHub repository details of the Connector.
	Repository Repository `json:"repository"`
}

* * The details of the deployed Connector(ctp:connect:type:Connector).

type DeploymentDetails

type DeploymentDetails struct {
	// The build details of deployed applications.
	Build DeploymentDetailsBuild `json:"build"`
}

* * The build and runtime details of deployed applications.

type DeploymentDetailsBuild

type DeploymentDetailsBuild struct {
	// The build execution id of the deployed application.
	ID string `json:"id"`
}

type DeploymentDraft

type DeploymentDraft struct {
	// User-defined unique identifier for the Deployment.
	Key *string `json:"key,omitempty"`
	// Reference to the [Connector](ctp:connect:type:Connector) being deployed.
	Connector ConnectorReference `json:"connector"`
	// Configuration values needed by the [Connector](ctp:connect:type:Connector) for hosting. Keys should match those in the Connector's `configurations` field.
	Configurations []DeploymentConfigurationApplication `json:"configurations"`
	// Region of Deployment.
	Region string `json:"region"`
}

func (DeploymentDraft) MarshalJSON

func (obj DeploymentDraft) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type DeploymentInvalidStatusTransitionError

type DeploymentInvalidStatusTransitionError struct {
	// `"Invalid status change\: Already deploying"`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when the Deployment operation results in a invalid status transition. * * The error is returned as a failed response to the [Redeploy](ctp:connect:type:DeploymentRedeploy) update action. * * The message will contain `Already queued`, `Already deploying`, or `Already undeploying` based on the DeploymentStatus(ctp:connect:type:DeploymentStatus) of the Deployment. *

func (*DeploymentInvalidStatusTransitionError) DecodeStruct

func (obj *DeploymentInvalidStatusTransitionError) DecodeStruct(src map[string]interface{}) error

func (DeploymentInvalidStatusTransitionError) Error

func (DeploymentInvalidStatusTransitionError) MarshalJSON

func (obj DeploymentInvalidStatusTransitionError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*DeploymentInvalidStatusTransitionError) UnmarshalJSON

func (obj *DeploymentInvalidStatusTransitionError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type DeploymentLog

type DeploymentLog struct {
	Type string `json:"type"`
	// Unique identifier of the [Deployment](ctp:connect:type:Deployment).
	DeploymentId string `json:"deploymentId"`
	// Name of the Connect application.
	ApplicationName string `json:"applicationName"`
	// Severity of the log message.
	Severity string `json:"severity"`
	// Timestamp of the log message.
	Timestamp time.Time `json:"timestamp"`
	// Event details of the log message.
	Details interface{} `json:"details"`
}

* * The data representation of a Deployment log. *

type DeploymentRedeployAction

type DeploymentRedeployAction struct {
	// New configuration values for Deployment.
	ConfigurationValues []DeploymentConfigurationApplication `json:"configurationValues"`
}

* * Update the configuration values and redeploy the Deployment. * * Attempting to redeploy a Deployment that does not require configuration or a configuration key for an application returns the [DeploymentUnknownApplicationConfiguration](ctp:connect:type:DeploymentUnknownApplicationConfigurationError) or [DeploymentUnknownApplicationConfigurationKey](ctp:connect:type:DeploymentUnknownApplicationConfigurationKeyError) errors, respectively. * * Attempting to redeploy a Deployment with a `Queued`, `Deploying`, or `Undeploying` DeploymentStatus(ctp:connect:type:DeploymentStatus) returns a [DeploymentInvalidStatusTransition](ctp:connect:type:DeploymentInvalidStatusTransitionError) error. *

func (DeploymentRedeployAction) MarshalJSON

func (obj DeploymentRedeployAction) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

type DeploymentStatus

type DeploymentStatus string

* * Indicates the current status of the Deployment. *

const (
	DeploymentStatusDraft          DeploymentStatus = "Draft"
	DeploymentStatusQueued         DeploymentStatus = "Queued"
	DeploymentStatusDeploying      DeploymentStatus = "Deploying"
	DeploymentStatusDeployed       DeploymentStatus = "Deployed"
	DeploymentStatusFailed         DeploymentStatus = "Failed"
	DeploymentStatusUndeploying    DeploymentStatus = "Undeploying"
	DeploymentStatusUndeployFailed DeploymentStatus = "UndeployFailed"
)

type DeploymentUnknownApplicationConfigurationError

type DeploymentUnknownApplicationConfigurationError struct {
	// `"Deployment does not require configuration for application named '$unknownApplicationName'."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when the Deployment contains configuration values that are not defined in the Connect application's connect.yaml file. * * The error is returned as a failed response to the [Redeploy](ctp:connect:type:DeploymentRedeploy) update action and [Create a Deployment](deployments#create-deployment) request. *

func (*DeploymentUnknownApplicationConfigurationError) DecodeStruct

func (obj *DeploymentUnknownApplicationConfigurationError) DecodeStruct(src map[string]interface{}) error

func (DeploymentUnknownApplicationConfigurationError) Error

func (DeploymentUnknownApplicationConfigurationError) MarshalJSON

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*DeploymentUnknownApplicationConfigurationError) UnmarshalJSON

func (obj *DeploymentUnknownApplicationConfigurationError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type DeploymentUnknownApplicationConfigurationKeyError

type DeploymentUnknownApplicationConfigurationKeyError struct {
	// `"Deployment does not require (secret|standard) configuration with key $configurationKey for application named $applicationName."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when the Deployment contains a configuration key that is not defined in the Connect application's connect.yaml file. * * The error is returned as a failed response to the [Redeploy](ctp:connect:type:DeploymentRedeploy) update action and [Create a Deployment](deployments#create-deployment) request. *

func (*DeploymentUnknownApplicationConfigurationKeyError) DecodeStruct

func (obj *DeploymentUnknownApplicationConfigurationKeyError) DecodeStruct(src map[string]interface{}) error

func (DeploymentUnknownApplicationConfigurationKeyError) Error

func (DeploymentUnknownApplicationConfigurationKeyError) MarshalJSON

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*DeploymentUnknownApplicationConfigurationKeyError) UnmarshalJSON

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type DeploymentUnsupportedRegionError

type DeploymentUnsupportedRegionError struct {
	// `"Deployment unsupported region $region"`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when the Deployment region is not supported. * * The error is returned as a failed response to the [Create a Deployment](deployments#create-deployment) request. *

func (*DeploymentUnsupportedRegionError) DecodeStruct

func (obj *DeploymentUnsupportedRegionError) DecodeStruct(src map[string]interface{}) error

func (DeploymentUnsupportedRegionError) Error

func (DeploymentUnsupportedRegionError) MarshalJSON

func (obj DeploymentUnsupportedRegionError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*DeploymentUnsupportedRegionError) UnmarshalJSON

func (obj *DeploymentUnsupportedRegionError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type DeploymentUpdate

type DeploymentUpdate struct {
	// Expected version of the Deployment on which the changes apply.
	Version int `json:"version"`
	// Update actions to be performed on the Deployment.
	Actions []DeploymentUpdateAction `json:"actions"`
}

func (*DeploymentUpdate) UnmarshalJSON

func (obj *DeploymentUpdate) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type DeploymentUpdateAction

type DeploymentUpdateAction interface{}

type DuplicateFieldError

type DuplicateFieldError struct {
	// `"A duplicate value $duplicateValue exists for field $field."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Name of the conflicting field.
	Field string `json:"field"`
	// Conflicting duplicate value.
	DuplicateValue interface{} `json:"duplicateValue"`
}

* * Returned when a field value conflicts with an existing value causing a duplicate. *

func (*DuplicateFieldError) DecodeStruct

func (obj *DuplicateFieldError) DecodeStruct(src map[string]interface{}) error

func (DuplicateFieldError) Error

func (obj DuplicateFieldError) Error() string

func (DuplicateFieldError) MarshalJSON

func (obj DuplicateFieldError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*DuplicateFieldError) UnmarshalJSON

func (obj *DuplicateFieldError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type ErrorObject

type ErrorObject interface{}

* * Represents a single error. Multiple errors may be included in an ErrorResponse(ctp:connect:type:ErrorResponse).

type ErrorResponse

type ErrorResponse struct {
	// HTTP status code corresponding to the error.
	StatusCode int `json:"statusCode"`
	// First error message in the `errors` array.
	Message string `json:"message"`
	// Errors returned for a request.
	//
	// A single error response can contain multiple errors if the errors are related to the same HTTP status code such as `400`.
	Errors []ErrorObject `json:"errors"`
}

* * Base representation of an error response containing common fields to all errors. *

func (ErrorResponse) Error

func (obj ErrorResponse) Error() string

func (ErrorResponse) MarshalJSON

func (obj ErrorResponse) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ErrorResponse) UnmarshalJSON

func (obj *ErrorResponse) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type FeatureRemovedError

type FeatureRemovedError struct {
	// Description of the feature that is removed.
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when the requested feature was removed. *

func (*FeatureRemovedError) DecodeStruct

func (obj *FeatureRemovedError) DecodeStruct(src map[string]interface{}) error

func (FeatureRemovedError) Error

func (obj FeatureRemovedError) Error() string

func (FeatureRemovedError) MarshalJSON

func (obj FeatureRemovedError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*FeatureRemovedError) UnmarshalJSON

func (obj *FeatureRemovedError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GeneralError

type GeneralError struct {
	// Description about any known details of the problem, for example, `"Write operations are temporarily unavailable"`.
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when a server-side problem occurs. * * If you encounter this error, report it using the [Support Portal](TBC for connect). *

func (*GeneralError) DecodeStruct

func (obj *GeneralError) DecodeStruct(src map[string]interface{}) error

func (GeneralError) Error

func (obj GeneralError) Error() string

func (GeneralError) MarshalJSON

func (obj GeneralError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*GeneralError) UnmarshalJSON

func (obj *GeneralError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type GenericRequestError

type GenericRequestError struct {
	Content    []byte
	StatusCode int
	Response   *http.Response
}

func (GenericRequestError) Error

func (e GenericRequestError) Error() string

type InvalidJsonInputError

type InvalidJsonInputError struct {
	// `"Request body does not contain valid JSON."`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Further explanation about why the JSON is invalid.
	DetailedErrorMessage string `json:"detailedErrorMessage"`
}

* * Returned when an invalid JSON input has been sent. * Either the JSON is syntactically incorrect or does not conform to the expected shape (for example is missing a required field). * * The client application should validate the input according to the constraints described in the error message before sending the request. *

func (*InvalidJsonInputError) DecodeStruct

func (obj *InvalidJsonInputError) DecodeStruct(src map[string]interface{}) error

func (InvalidJsonInputError) Error

func (obj InvalidJsonInputError) Error() string

func (InvalidJsonInputError) MarshalJSON

func (obj InvalidJsonInputError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*InvalidJsonInputError) UnmarshalJSON

func (obj *InvalidJsonInputError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type InvalidPathParamError

type InvalidPathParamError struct {
	// `"Request path param is not valid"`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Further explanation about why the path parameter is invalid.
	DetailedErrorMessage string `json:"detailedErrorMessage"`
}

* * Returned when an invalid path parameter has been sent. *

func (*InvalidPathParamError) DecodeStruct

func (obj *InvalidPathParamError) DecodeStruct(src map[string]interface{}) error

func (InvalidPathParamError) Error

func (obj InvalidPathParamError) Error() string

func (InvalidPathParamError) MarshalJSON

func (obj InvalidPathParamError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*InvalidPathParamError) UnmarshalJSON

func (obj *InvalidPathParamError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type InvalidQueryParamError

type InvalidQueryParamError struct {
	// `"Request query param is not valid"`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
	// Further explanation about why the query parameter is invalid.
	DetailedErrorMessage string `json:"detailedErrorMessage"`
}

* * Returned when an invalid query parameter has been sent. *

func (*InvalidQueryParamError) DecodeStruct

func (obj *InvalidQueryParamError) DecodeStruct(src map[string]interface{}) error

func (InvalidQueryParamError) Error

func (obj InvalidQueryParamError) Error() string

func (InvalidQueryParamError) MarshalJSON

func (obj InvalidQueryParamError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*InvalidQueryParamError) UnmarshalJSON

func (obj *InvalidQueryParamError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type IsPreviewable

type IsPreviewable string

* * The previewable status of the ConnectorStaged. *

const (
	IsPreviewableTrue    IsPreviewable = "true"
	IsPreviewableFalse   IsPreviewable = "false"
	IsPreviewablePending IsPreviewable = "pending"
	IsPreviewableNone    IsPreviewable = "none"
)

type Paged

type Paged struct {
	Limit   float64     `json:"limit"`
	Offset  float64     `json:"offset"`
	Count   float64     `json:"count"`
	Total   float64     `json:"total"`
	Results interface{} `json:"results"`
}

* * A Paged Result. *

type Region

type Region string

* * The host Region of a commercetools Composable Commerce Project. For more information, see [Hosts](hosts-and-authorization#hosts). *

const (
	RegionEuropeWest1Gcp         Region = "europe-west1.gcp"
	RegionUsCentral1Gcp          Region = "us-central1.gcp"
	RegionAustraliaSoutheast1Gcp Region = "australia-southeast1.gcp"
)

type Repository

type Repository struct {
	// HTTPS or SSH GitHub URL of the GitHub repository. Private repositories must use an SSH URL.
	Url string `json:"url"`
	// Git tag of the release to use.
	Tag string `json:"tag"`
}

* * Details of the GitHub repository that contains the Connect application. *

type ResourceNotFoundError

type ResourceNotFoundError struct {
	// `"Deployment with id=$resourceId or key=$resourceKey does not exist"`
	Message string `json:"message"`
	// Error-specific additional fields.
	ExtraValues map[string]interface{} `json:"-"`
}

* * Returned when the resource addressed by the request URL does not exist. *

func (*ResourceNotFoundError) DecodeStruct

func (obj *ResourceNotFoundError) DecodeStruct(src map[string]interface{}) error

func (ResourceNotFoundError) Error

func (obj ResourceNotFoundError) Error() string

func (ResourceNotFoundError) MarshalJSON

func (obj ResourceNotFoundError) MarshalJSON() ([]byte, error)

MarshalJSON override to set the discriminator value or remove optional nil slices

func (*ResourceNotFoundError) UnmarshalJSON

func (obj *ResourceNotFoundError) UnmarshalJSON(data []byte) error

UnmarshalJSON override to deserialize correct attribute types based on the discriminator value

type SetUserAgentTransport

type SetUserAgentTransport struct {
	T http.RoundTripper
	// contains filtered or unexported fields
}

func (*SetUserAgentTransport) RoundTrip

func (sat *SetUserAgentTransport) RoundTrip(req *http.Request) (*http.Response, error)

Source Files

Jump to

Keyboard shortcuts

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