Help us shape the future of Go! Take the 2026 Go Developer Survey

avatar

package
v3.2.0 Latest Latest
Warning

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

Go to latest
Published: Oct 9, 2026 License: MIT Imports: 6 Imported by: 0

Documentation

Overview

Package avatar implements MCP tools for GitLab avatar lookup operations.

The package wraps the GitLab Avatar API:

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ActionSpecs

func ActionSpecs(client *gitlabclient.Client) []toolutil.ActionSpec

ActionSpecs returns canonical specs for avatar lookup actions exposed through gitlab_user.

func FormatMarkdown

func FormatMarkdown(out GetOutput) string

FormatMarkdown renders the avatar lookup as a card. The address is the whole answer, so it is written as the link it is rather than as escaped text: a reader told to "use the avatar URL directly" has to be able to open it, and an empty answer writes no row at all rather than a label with nothing after it.

Types

type GetInput

type GetInput struct {
	Email string `json:"email" jsonschema:"Email address to look up avatar for,required"`
	Size  int64  `json:"size" jsonschema:"Desired avatar size in pixels"`
}

GetInput contains parameters for getting an avatar URL.

type GetOutput

type GetOutput struct {
	toolutil.HintableOutput
	AvatarURL string `json:"avatar_url"`
}

GetOutput contains the avatar URL.

func Get

func Get(ctx context.Context, client *gitlabclient.Client, input GetInput) (GetOutput, error)

Get retrieves the avatar URL for an email address.

Jump to

Keyboard shortcuts

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