http

package
v0.1.1-alpha Latest Latest
Warning

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

Go to latest
Published: Feb 18, 2023 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	CustomApiUrl = ""
)

Functions

This section is empty.

Types

type Client

type Client struct {
	TokenHelper *helpers.TokenHelper
}

func (*Client) GetArtifact

func (c *Client) GetArtifact(artifactID string) (models.Artifact, error)

func (*Client) GetDeployment

func (c *Client) GetDeployment(deploymentID string) (models.Deployment, error)

func (*Client) GetEnvironment

func (c *Client) GetEnvironment(environmentId string) (models.Environment, error)

func (*Client) GetOrganisation

func (c *Client) GetOrganisation(organisationId string) (models.Organisation, error)

func (*Client) GetProject

func (c *Client) GetProject(projectId string) (models.Project, error)

func (*Client) GetUser

func (c *Client) GetUser() (models.User, error)

func (*Client) Login

func (c *Client) Login(login models.Login) (models.Token, error)

func (*Client) SaveArtifact

func (c *Client) SaveArtifact(artifact models.Artifact) (models.Artifact, error)

func (*Client) SaveDeployment

func (c *Client) SaveDeployment(deployment models.Deployment) (models.Deployment, error)

SaveDeployment provisions the artifact and deploys it on the serverless infrastructure. The artifact must be uploaded on the cloud storage before deploying

func (*Client) UploadArtifact

func (c *Client) UploadArtifact(artifact models.Artifact, content string) error

UploadArtifact uploads to the storage provider. The upload URL is provided by the api and returned after the SaveArtifact call.

type ClientType

type ClientType interface {
	GetArtifact(artifactID string) (models.Artifact, error)
	SaveArtifact(artifact models.Artifact) (models.Artifact, error)
	UploadArtifact(artifact models.Artifact, content string) error
	SaveDeployment(deployment models.Deployment) (models.Deployment, error)
	GetDeployment(deploymentID string) (models.Deployment, error)
	Login(login models.Login) (models.Token, error)
	GetUser() (models.User, error)
	GetOrganisation(organisationId string) (models.Organisation, error)
	GetEnvironment(environmentId string) (models.Environment, error)
	GetProject(projectId string) (models.Project, error)
}

Jump to

Keyboard shortcuts

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