Documentation
¶
Index ¶
- func BuildRootCmd() (*cobra.Command, error)
- func Execute(ctx context.Context) error
- func InstallMCPForClient(opts InstallOptions) error
- type ApiKeyCreateOutput
- type ApiKeyOutput
- type ClientInfo
- type ClientOption
- type DatabaseCreateOutput
- type DatabaseForkOutput
- type DatabaseListItem
- type InstallOptions
- type InvoiceDetailOutput
- type InvoiceLineItemOutput
- type InvoiceOutput
- type MCPClient
- type MCPServerConfig
- type PaymentMethodOutput
- type Share
- type VersionOutput
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BuildRootCmd ¶
BuildRootCmd exposes the root command for tools like doc generators.
func InstallMCPForClient ¶
func InstallMCPForClient(opts InstallOptions) error
InstallMCPForClient installs an MCP server configuration for the specified client. This is a generic, configurable function exported for use by external projects via pkg/mcpinstall. Required options: ServerName, Command, Args must all be provided.
Types ¶
type ApiKeyCreateOutput ¶
type ApiKeyCreateOutput struct {
ApiKey string `json:"api_key"`
}
ApiKeyCreateOutput represents the output format for the api-key create command.
type ApiKeyOutput ¶
type ApiKeyOutput struct {
Prefix string `json:"prefix"`
Name string `json:"name"`
CreatedAt string `json:"created_at"`
}
ApiKeyOutput represents the output format for a single API key.
type ClientInfo ¶
type ClientInfo struct {
// Name is the human-readable display name (e.g., "Claude Code", "Cursor")
Name string
// ClientName is the identifier to use in InstallOptions.ClientName (e.g., "claude-code", "cursor")
ClientName string
}
ClientInfo contains information about a supported MCP client.
func SupportedClients ¶
func SupportedClients() []ClientInfo
SupportedClients returns information about all supported MCP clients.
type ClientOption ¶
type ClientOption struct {
Name string // Display name
ClientName string // Client name to pass to installMCPForClient
}
ClientOption represents a client choice for interactive selection
type DatabaseCreateOutput ¶
type DatabaseCreateOutput struct {
Name string `json:"name"`
ID string `json:"id"`
Size string `json:"size,omitempty"`
Connection string `json:"connection"`
Type api.DatabaseType `json:"-"`
}
DatabaseCreateOutput represents the output format for the create command
type DatabaseForkOutput ¶
type DatabaseForkOutput struct {
SourceName string `json:"source_name"`
Name string `json:"name"`
ID string `json:"id"`
Size string `json:"size,omitempty"`
Connection string `json:"connection"`
Type api.DatabaseType `json:"-"`
}
DatabaseForkOutput represents the output format for the fork command
type DatabaseListItem ¶
type DatabaseListItem struct {
ID string `json:"id"`
Name string `json:"name"`
Type api.DatabaseType `json:"type"`
Size *api.DatabaseSize `json:"size,omitempty"`
Status api.DatabaseStatus `json:"status"`
StorageMib *int `json:"storage_mib"`
ComputeMinutes *int64 `json:"compute_minutes,omitempty"`
}
DatabaseListItem represents a database in the list command output
type InstallOptions ¶
type InstallOptions struct {
// ClientName is the name of the client to configure (required)
ClientName string
// ServerName is the name to register the MCP server as (required)
ServerName string
// Command is the path to the MCP server binary (required)
Command string
// Args are the arguments to pass to the MCP server binary (required)
Args []string
// CreateBackup creates a backup of existing config files before modification
CreateBackup bool
// CustomConfigPath overrides the default config file location
CustomConfigPath string
}
InstallOptions configures the MCP server installation behavior
type InvoiceDetailOutput ¶ added in v0.10.0
type InvoiceDetailOutput struct {
LineItems []InvoiceLineItemOutput `json:"line_items"`
}
InvoiceDetailOutput represents the output format for an invoice detail.
type InvoiceLineItemOutput ¶ added in v0.10.0
type InvoiceLineItemOutput struct {
ProductType string `json:"product_type"`
DatabaseID string `json:"database_id,omitempty"`
DetailedSpec string `json:"detailed_spec,omitempty"`
Quantity float64 `json:"quantity"`
UnitPrice float64 `json:"unit_price"`
LineTotal float64 `json:"line_total"`
}
InvoiceLineItemOutput represents the output format for a single invoice line item.
type InvoiceOutput ¶ added in v0.10.0
type InvoiceOutput struct {
ID string `json:"id"`
InvoiceNumber string `json:"invoice_number"`
InvoiceDate string `json:"invoice_date"`
Total float64 `json:"total"`
Status string `json:"status"`
}
InvoiceOutput represents the output format for a single invoice.
type MCPServerConfig ¶
MCPServerConfig represents the MCP server configuration
type PaymentMethodOutput ¶
type PaymentMethodOutput struct {
ID string `json:"id"`
Brand string `json:"brand"`
Last4 string `json:"last4"`
ExpMonth int `json:"exp_month"`
ExpYear int `json:"exp_year"`
Primary bool `json:"is_primary"`
PendingDeletion bool `json:"pending_deletion"`
}
PaymentMethodOutput represents the output format for a payment method
type Share ¶ added in v0.12.0
type Share struct {
}
Share represents a database share in CLI output. The share_token (also embedded in the URL) is the only identifier exposed — it's what a recipient passes to 'ghost create', and it's also what you pass back to 'ghost share revoke' to revoke the share.
Source Files
¶
- api_key.go
- api_key_create.go
- api_key_delete.go
- api_key_list.go
- completion.go
- config.go
- config_reset.go
- config_set.go
- config_unset.go
- connect.go
- create.go
- create_dedicated.go
- delete.go
- errors.go
- feedback.go
- fork.go
- fork_dedicated.go
- invoice.go
- invoice_list.go
- invoice_view.go
- list.go
- logger.go
- login.go
- logout.go
- logs.go
- mcp.go
- mcp_get.go
- mcp_install.go
- mcp_list.go
- mcp_start.go
- password.go
- pause.go
- payment.go
- payment_add.go
- payment_delete.go
- payment_list.go
- payment_primary.go
- payment_undelete.go
- psql.go
- rename.go
- resume.go
- root.go
- schema.go
- share.go
- share_list.go
- share_revoke.go
- sql.go
- status.go
- upgrade.go
- version.go