errors

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Apr 12, 2026 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Overview

Package errors provides error types and handling for the MCP server.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ToolError

func ToolError(err *APIError) string

ToolError formats an APIError as an actionable message for AI agents.

Types

type APIError

type APIError struct {
	StatusCode int
	Code       string
	Message    string
}

APIError represents a parsed error from the deploybase API.

func ParseAPIError

func ParseAPIError(statusCode int, body []byte) *APIError

ParseAPIError parses a non-2xx response body into an APIError.

func (*APIError) Error

func (e *APIError) Error() string

Jump to

Keyboard shortcuts

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