Documentation
¶
Overview ¶
Package catalog provides the embedded D2 v0.9.0 capability reference.
Index ¶
Constants ¶
View Source
const ( Version = "v0.9.0" DefaultSearchLimit = 8 MaxSearchLimit = 20 ResourceMIMEType = "text/markdown; charset=utf-8" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Category ¶
type Category struct {
ID string `json:"id"`
Title string `json:"title"`
Summary string `json:"summary"`
}
Category groups related D2 capabilities.
func ListCategories ¶
func ListCategories() []Category
ListCategories returns all categories in display order.
type Entry ¶
type Entry struct {
ID string `json:"id"`
CategoryID string `json:"category_id"`
Title string `json:"title"`
Summary string `json:"summary"`
URI string `json:"uri"`
SourceURLs []string `json:"source_urls"`
}
Entry describes one reference document in the catalog.
func ListCategory ¶
ListCategory returns entries in display order for an exact category ID.
type ResourceContent ¶
type ResourceContent struct {
URI string `json:"uri"`
MIMEType string `json:"mimeType"`
Text string `json:"text"`
}
ResourceContent is transport-neutral text suitable for an MCP resource response.
func ReadResource ¶
func ReadResource(uri string) (ResourceContent, bool)
ReadResource returns embedded Markdown for an exact catalog URI.
Click to show internal directories.
Click to hide internal directories.