Phantom.Prompt.Argument (phantom_mcp v0.3.2)

View Source

Summary

Functions

Build a prompt argument spec

Represent a Prompt argument spec as json when listing the available prompts to clients.

Types

json()

@type json() :: %{name: String.t(), description: String.t(), required: boolean()}

t()

@type t() :: %Phantom.Prompt.Argument{
  description: String.t(),
  name: String.t(),
  required: boolean()
}

Functions

build(attrs)

@spec build(map() | Keyword.t()) :: t()

Build a prompt argument spec

When building a prompt with Phantom.Prompt.build/1, arguments will be built automatically.

to_json(argument)

@spec to_json(t()) :: json()

Represent a Prompt argument spec as json when listing the available prompts to clients.