lfsauthenticate

package
v14.39.0 Latest Latest
Warning

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

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

Documentation

Overview

Package lfsauthenticate provides functionality for authenticating Large File Storage (LFS) requests

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

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

Client represents a client for LFS authentication

func NewClient

func NewClient(config *config.Config, args *commandargs.Shell) (*Client, error)

NewClient creates a new LFS authentication client

func (*Client) Authenticate

func (c *Client) Authenticate(ctx context.Context, operation, repo, userID string) (*Response, error)

Authenticate performs authentication for LFS requests

type Request

type Request struct {
	Operation string `json:"operation"`
	Repo      string `json:"project"`
	KeyID     string `json:"key_id,omitempty"`
	UserID    string `json:"user_id,omitempty"`
}

Request represents a request for LFS authentication

type Response

type Response struct {
	Username  string `json:"username"`
	LfsToken  string `json:"lfs_token"`
	RepoPath  string `json:"repository_http_path"`
	ExpiresIn int    `json:"expires_in"`
}

Response represents a response from LFS authentication

Jump to

Keyboard shortcuts

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