usercenter

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Feb 7, 2024 License: MIT Imports: 10 Imported by: 0

Documentation

Overview

Package usercenter provide methods used to access usercenter service.

Index

Constants

This section is empty.

Variables

View Source
var ProviderSet = wire.NewSet(New, wire.Bind(new(Interface), new(*clientImpl)))

ProviderSet is the usercenter providers.

Functions

func New

func New(opts *Options) (*clientImpl, error)

New creates a new client to work with usercenter services.

Types

type GetSecretRequest

type GetSecretRequest struct {
	Username string
	Name     string
}

type GetSecretResponse

type GetSecretResponse = usercenterv1.SecretReply

type Interface

type Interface interface {
	GetSecret(ctx context.Context, rq *GetSecretRequest) (*GetSecretResponse, error)
}

Interface is an interface that presents a subset of the usercenter API.

type Options

type Options struct {
	Server string `json:"server" mapstructure:"server"`
}

Options is a list of options for the specific client.

func NewOptions

func NewOptions() *Options

NewOptions returns initialized Options.

func (*Options) AddFlags

func (o *Options) AddFlags(fs *pflag.FlagSet)

AddFlags adds flags for a specific APIServer to the specified FlagSet.

func (*Options) Validate

func (o *Options) Validate() []error

Validate validates all the required options.

Jump to

Keyboard shortcuts

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