vercelgo

package module
v1.1.0 Latest Latest
Warning

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

Go to latest
Published: Aug 8, 2025 License: MIT Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type VercelClient

type VercelClient struct {
	Token string
}

func GetVercelClient

func GetVercelClient(token string) *VercelClient

func (*VercelClient) AddProjectDomain

func (c *VercelClient) AddProjectDomain(domainName, teamId, projectIdOrName string) (*schemas.AllDomainWithVerification, error)

AddProjectDomain adds a new domain to a specific project. It requires the domain name, team ID, project ID or name and returns the domain information along with its configuration.

func (*VercelClient) CreateProject

func (c *VercelClient) CreateProject(payload schemas.CreateProjectRequest, teamId string) (*schemas.Project, error)

Allows to create a new project with the provided configuration. It only requires the project name and team ID but more configuration can be provided to override the defaults.

func (*VercelClient) CreateTeam

func (c *VercelClient) CreateTeam(slug, name string) (string, error)

Create a new Team under your account. You need to send a POST request with the desired Team slug, and optionally the Team name.

func (*VercelClient) DeleteProject

func (c *VercelClient) DeleteProject(projectIdOrName string, teamId string) error

Delete a specific project by passing either the project id or name

func (*VercelClient) DeleteProjectDomain

func (c *VercelClient) DeleteProjectDomain(domainName, projectIdOrName, teamId string) (*schemas.AllDomainWithVerification, error)

DeleteProjectDomain removes a domain from a specific project by its name or ID. It requires the domain name, project ID or name, and team ID.

func (*VercelClient) DeleteTeam

func (c *VercelClient) DeleteTeam(teamId string, reasons []schemas.Reason) error

Delete a team under your account. You need to send teamId as required parameter. An optional array of reasons for deletion may also be sent.

func (*VercelClient) Deploy

func (c *VercelClient) Deploy(projectId, deploymentName, directory, teamId string) (*schemas.AllDomainWithVerification, string, error)

Deploy uploads files to Vercel from a directory and creates a deployment for the specified project.

func (*VercelClient) GetDeploymentStatus

func (c *VercelClient) GetDeploymentStatus(deploymentId, teamId string) (*schemas.DeploymentStatus, error)

GetDeploymentStatus gets the status of a specific deployment by its ID and team ID.

func (*VercelClient) GetDomainConfig

func (c *VercelClient) GetDomainConfig(domainName, teamId string) (*schemas.DomainConfigInfo, error)

GetDomainConfig retrieves the configuration details of a domain by its name and team ID. It returns a DomainConfigInfo struct containing the configuration details.

func (*VercelClient) GetHeaders

func (c *VercelClient) GetHeaders() map[string]string

func (*VercelClient) GetProjectDomains

func (c *VercelClient) GetProjectDomains(projectIdOrName, teamId string, opts *schemas.Options) (*schemas.AllDomainWithVerification, error)

GetProjectDomains retrieves all domains associated with a project by ID or name. It supports various filtering options including production, target environment, git branch, etc.

func (*VercelClient) GetTeam

func (c *VercelClient) GetTeam(teamId string) (*schemas.Team, error)

Get information for the Team specified by the teamId parameter.

func (*VercelClient) ListTeams

func (c *VercelClient) ListTeams(filter *schemas.Filter) ([]schemas.Team, error)

Get a paginated list of all the Teams the authenticated User is a member of.

func (*VercelClient) PauseProject added in v1.1.0

func (c *VercelClient) PauseProject(projectIdOrName string, teamId string) error

PauseProject pauses a Vercel project by its ID or name

func (*VercelClient) UnpauseProject added in v1.1.0

func (c *VercelClient) UnpauseProject(projectIdOrName string, teamId string) error

UnpauseProject unpauses (resumes) a paused Vercel project by its ID or name

func (*VercelClient) UpdateProject

func (c *VercelClient) UpdateProject(projectIdOrName string, payload schemas.CreateProjectRequest, teamId string) (*schemas.Project, error)

Update the fields of a project using either its name or id

func (*VercelClient) UpdateTeam

func (c *VercelClient) UpdateTeam(teamId, name, slug string) (*schemas.Team, error)

Update the information of a Team specified by the teamId parameter. The name and slug parameters are optional.

func (*VercelClient) WaitForDeployment

func (c *VercelClient) WaitForDeployment(deploymentId, teamId string, timeout time.Duration) (*schemas.DeploymentStatus, error)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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