observation.py 768 Bytes
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28
"""
    schema: platform-specific decoded status message (DRAFT)
"""
from . import message_header_schema, platform_schema, api
from flask_restx import fields


observation_schema = api.model(
    "Observation",
    {
        "message": fields.Nested(
            message_header_schema,
            required=True,
            description="Message header",
        ),
        "platform": fields.Nested(platform_schema),
        "time": fields.String(
            required=True,
            description="Timestamp of message",
            example="2022-11-16T00:00:00Z",
        ),
        "discuss_other_fields": fields.String(
            required=False,
            description="",  # we can track the version of the AE plan?
            example="",
        ),
    }
)