We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 59565a8 commit 4435244Copy full SHA for 4435244
1 file changed
xpwebapi/ws.py
@@ -8,6 +8,7 @@
8
import json
9
import time
10
11
+from dataclasses import dataclass
12
from datetime import datetime
13
from typing import Tuple, Dict
14
from enum import Enum
@@ -50,6 +51,16 @@ class CALLBACK_TYPE(Enum):
50
51
AFTER_START = "after_start"
52
BEFORE_STOP = "before_stop"
53
54
+@dataclass
55
+class Request:
56
+ """Pythonic dataclass to host X-Plane Beacon data."""
57
+
58
+ r_id: int # Request id
59
+ body: dict # Request body
60
+ success: bool | None # sucess of request, None if no feedback yet
61
+ error: str | None # error message, if any
62
63
64
65
# #############################################
66
# WEBSOCKET API
0 commit comments