API error response schema with status, message, and optional traceback fields.
from marshmallow import Schema, fields
class ErrorSchema(Schema):
status = fields.String(example="error", description="Request status")
message = fields.String(description="Error message")
traceback = fields.String(load_default=None)
class SuccessSchema(Schema):
status = fields.String(example="success", description="Request status")
class CryptoItemSchema(Schema):
name = fields.String(
description="Crypto identifier used in API endpoints", example="ETH"
)
display_name = fields.String(
description="Human-readable crypto name", example="Ethereum"
)
class GetCryptoResponseSchema(Schema):
status = fields.String(description="Response status", example="success")
crypto = fields.List(
fields.String(),
description="Leg
... (truncated -- full source via MCP)
See the full source, get the GitHub permalink, and search 40K more like it.
Get a free API key