Core API
Admin UI
Admin UI API router Provides a web-based dashboard for managing the Petal App Manager system.
Health Endpoints
- async petal_app_manager.api.health.detailed_health_check() HealthMessage[source]
Comprehensive health check endpoint that reports the status of each proxy.
Configuration API
- class petal_app_manager.api.config_api.AllComponentsResponse(*, petals: List[PetalInfo], proxies: List[ProxyInfo], total_petals: int, total_proxies: int)[source]
Bases:
BaseModel- model_config: ClassVar[ConfigDict] = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class petal_app_manager.api.config_api.ConfigResponse(*, enabled_proxies: List[str], enabled_petals: List[str], petal_dependencies: Dict[str, List[str]], proxy_dependencies: Dict[str, List[str]])[source]
Bases:
BaseModel- model_config: ClassVar[ConfigDict] = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class petal_app_manager.api.config_api.PetalControlRequest(*, petals: List[str], action: str)[source]
Bases:
BaseModel- model_config: ClassVar[ConfigDict] = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class petal_app_manager.api.config_api.PetalInfo(*, name: str, enabled: bool, dependencies: List[str])[source]
Bases:
BaseModel- model_config: ClassVar[ConfigDict] = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class petal_app_manager.api.config_api.ProxyInfo(*, name: str, enabled: bool, dependencies: List[str], dependents: List[str])[source]
Bases:
BaseModel- model_config: ClassVar[ConfigDict] = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- async petal_app_manager.api.config_api.control_petals(request: PetalControlRequest) Dict[str, Any][source]
Enable or disable one or more petals
- async petal_app_manager.api.config_api.control_proxies(request: PetalControlRequest) Dict[str, Any][source]
Enable or disable one or more proxies
- async petal_app_manager.api.config_api.get_status() ConfigResponse[source]
Get current configuration status
Cloud API
- class petal_app_manager.api.cloud_api.GetItemRequest(*, table_name: str, key_name: str, key_value: str)[source]
Bases:
BaseModel- model_config: ClassVar[ConfigDict] = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class petal_app_manager.api.cloud_api.ScanTableRequest(*, table_name: str, filters: list = [])[source]
Bases:
BaseModel- model_config: ClassVar[ConfigDict] = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class petal_app_manager.api.cloud_api.SetItemRequest(*, table_name: str, item_data: Dict[str, Any])[source]
Bases:
BaseModel- model_config: ClassVar[ConfigDict] = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class petal_app_manager.api.cloud_api.UpdateItemRequest(*, table_name: str, key_name: str, key_value: str, update_data: Dict[str, Any])[source]
Bases:
BaseModel- model_config: ClassVar[ConfigDict] = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- async petal_app_manager.api.cloud_api.delete_item(request: GetItemRequest) Dict[str, Any][source]
Delete an item from the cloud database.
- async petal_app_manager.api.cloud_api.get_item(request: GetItemRequest) Dict[str, Any][source]
Get a specific item from the cloud database.
- async petal_app_manager.api.cloud_api.scan_table(request: ScanTableRequest) Dict[str, Any][source]
List all data in a particular table in the cloud database.
Bucket API
- async petal_app_manager.api.bucket_api.delete_file_test(s3_key: str) Dict[str, Any][source]
Delete a flight log file from S3 bucket for testing.
- async petal_app_manager.api.bucket_api.download_file_test(s3_key: str, return_file: bool = Query(False)) Dict[str, Any][source]
Download a flight log file from S3 bucket for testing.
- async petal_app_manager.api.bucket_api.get_info() Dict[str, Any][source]
Get S3 bucket proxy information.
MAVLink FTP API
- class petal_app_manager.api.mavftp_api.ClearFailLogsRequest(*, remote_path: str = '/fs/microsd')[source]
Bases:
BaseModel- model_config: ClassVar[ConfigDict] = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
MQTT API
- class petal_app_manager.api.mqtt_api.MQTTResponse(*, status: str, message: str | None = None)[source]
Bases:
BaseModel- model_config: ClassVar[ConfigDict] = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class petal_app_manager.api.mqtt_api.PublishMessageRequest(*, topic: str, payload: Dict[str, Any], qos: int = 1)[source]
Bases:
BaseModel- model_config: ClassVar[ConfigDict] = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class petal_app_manager.api.mqtt_api.SubscribePatternRequest(*, pattern: str)[source]
Bases:
BaseModel- model_config: ClassVar[ConfigDict] = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class petal_app_manager.api.mqtt_api.SubscribeTopicRequest(*, topic: str)[source]
Bases:
BaseModel- model_config: ClassVar[ConfigDict] = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class petal_app_manager.api.mqtt_api.UnsubscribeTopicRequest(*, topic: str)[source]
Bases:
BaseModel- model_config: ClassVar[ConfigDict] = {}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- async petal_app_manager.api.mqtt_api.get_mqtt_status() Dict[str, Any][source]
Get MQTT proxy status and health information.
- async petal_app_manager.api.mqtt_api.list_subscriptions() Dict[str, Any][source]
List current MQTT subscriptions.
- async petal_app_manager.api.mqtt_api.publish_message(request: PublishMessageRequest) MQTTResponse[source]
Publish a message to an MQTT topic.
- async petal_app_manager.api.mqtt_api.subscribe_topic(request: SubscribeTopicRequest) MQTTResponse[source]
Subscribe to an MQTT topic.
- async petal_app_manager.api.mqtt_api.unsubscribe_topic(request: UnsubscribeTopicRequest) MQTTResponse[source]
Unsubscribe from an MQTT topic.