projects

package
v0.4.19 Latest Latest
Warning

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

Go to latest
Published: May 10, 2024 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Overview

Package projects provides the project related business logic.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateProject

func CreateProject(
	ctx context.Context,
	be *backend.Backend,
	owner types.ID,
	name string,
) (*types.Project, error)

CreateProject creates a project.

func From

func From(ctx context.Context) *types.Project

From returns the project from the context.

func GetProject added in v0.2.6

func GetProject(
	ctx context.Context,
	be *backend.Backend,
	owner types.ID,
	name string,
) (*types.Project, error)

GetProject returns a project by the given name.

func GetProjectFromAPIKey

func GetProjectFromAPIKey(ctx context.Context, be *backend.Backend, apiKey string) (*types.Project, error)

GetProjectFromAPIKey returns a project from an API key.

func GetProjectFromSecretKey added in v0.4.13

func GetProjectFromSecretKey(ctx context.Context, be *backend.Backend, secretKey string) (*types.Project, error)

GetProjectFromSecretKey returns a project from a secret key.

func ListProjects

func ListProjects(
	ctx context.Context,
	be *backend.Backend,
	owner types.ID,
) ([]*types.Project, error)

ListProjects lists all projects.

func UpdateProject

func UpdateProject(
	ctx context.Context,
	be *backend.Backend,
	owner types.ID,
	id types.ID,
	fields *types.UpdatableProjectFields,
) (*types.Project, error)

UpdateProject updates a project.

func With

func With(ctx context.Context, project *types.Project) context.Context

With creates a new context with the given Project.

Types

This section is empty.

Jump to

Keyboard shortcuts

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