maleo-foundation 0.2.97__py3-none-any.whl → 0.2.98__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- maleo_foundation/models/transfers/general/__init__.py +11 -11
- maleo_foundation/models/transfers/general/token.py +14 -18
- {maleo_foundation-0.2.97.dist-info → maleo_foundation-0.2.98.dist-info}/METADATA +1 -1
- {maleo_foundation-0.2.97.dist-info → maleo_foundation-0.2.98.dist-info}/RECORD +6 -6
- {maleo_foundation-0.2.97.dist-info → maleo_foundation-0.2.98.dist-info}/WHEEL +0 -0
- {maleo_foundation-0.2.97.dist-info → maleo_foundation-0.2.98.dist-info}/top_level.txt +0 -0
@@ -34,7 +34,7 @@ class RequestContextTransfers(BaseModel):
|
|
34
34
|
forwarded_proto: BaseTypes.OptionalString = Field(None, description="Forwarded protocol (http/https)")
|
35
35
|
language: BaseTypes.OptionalString = Field(None, description="Accepted languages from client")
|
36
36
|
|
37
|
-
def
|
37
|
+
def to_google_pubsub_object(self) -> Dict[str, Any]:
|
38
38
|
result = {
|
39
39
|
"request_id": str(self.request_id),
|
40
40
|
"requested_at": self.requested_at.isoformat(),
|
@@ -67,14 +67,14 @@ class RequestContextTransfers(BaseModel):
|
|
67
67
|
path_params = obj["path_params"]["map"] or {},
|
68
68
|
query_params = obj["query_params"]["map"] or {},
|
69
69
|
ip_address = obj["ip_address"],
|
70
|
-
is_internal = None if obj["is_internal"] is None else bool(obj["is_internal"]),
|
71
|
-
user_agent = obj["user_agent"],
|
72
|
-
ua_browser = obj["ua_browser"],
|
73
|
-
ua_mobile = obj["ua_mobile"],
|
74
|
-
platform = obj["platform"],
|
75
|
-
referer = obj["referer"],
|
76
|
-
origin = obj["origin"],
|
77
|
-
host = obj["host"],
|
78
|
-
forwarded_proto = obj["forwarded_proto"],
|
79
|
-
language = obj["language"],
|
70
|
+
is_internal = None if obj["is_internal"] is None else bool(obj["is_internal"]["boolean"]),
|
71
|
+
user_agent = None if obj["user_agent"] is None else obj["user_agent"]["string"],
|
72
|
+
ua_browser = None if obj["ua_browser"] is None else obj["ua_browser"]["string"],
|
73
|
+
ua_mobile = None if obj["ua_mobile"] is None else obj["ua_mobile"]["string"],
|
74
|
+
platform = None if obj["platform"] is None else obj["platform"]["string"],
|
75
|
+
referer = None if obj["referer"] is None else obj["referer"]["string"],
|
76
|
+
origin = None if obj["origin"] is None else obj["origin"]["string"],
|
77
|
+
host = None if obj["host"] is None else obj["host"]["string"],
|
78
|
+
forwarded_proto = None if obj["forwarded_proto"] is None else obj["forwarded_proto"]["string"],
|
79
|
+
language = None if obj["language"] is None else obj["language"]["string"],
|
80
80
|
)
|
@@ -28,7 +28,7 @@ class MaleoFoundationTokenGeneralTransfers:
|
|
28
28
|
exp_dt: datetime = Field(..., description="Expired at (datetime)")
|
29
29
|
exp: int = Field(..., description="Expired at (integer)")
|
30
30
|
|
31
|
-
def
|
31
|
+
def to_google_pubsub_object(self) -> Dict[str, Any]:
|
32
32
|
result = {
|
33
33
|
"iss": None if self.iss is None else {"string": self.iss},
|
34
34
|
"sub": self.sub,
|
@@ -54,23 +54,19 @@ class MaleoFoundationTokenGeneralTransfers:
|
|
54
54
|
@classmethod
|
55
55
|
def from_google_pubsub_object(cls, obj:Dict[str, Any]):
|
56
56
|
return cls(
|
57
|
-
iss = obj["iss"],
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
origin = obj["origin"],
|
71
|
-
host = obj["host"],
|
72
|
-
forwarded_proto = obj["forwarded_proto"],
|
73
|
-
language = obj["language"],
|
57
|
+
iss = None if obj["iss"] is None else obj["iss"]["string"],
|
58
|
+
sub = obj["sub"],
|
59
|
+
sr = obj["sr"],
|
60
|
+
u_i = obj["u_i"],
|
61
|
+
u_uu = UUID(obj["u_uu"]),
|
62
|
+
u_u = obj["u_u"],
|
63
|
+
u_e = obj["u_e"],
|
64
|
+
u_ut = obj["u_ut"],
|
65
|
+
o_i = None if obj["o_i"] is None else obj["o_i"]["int"],
|
66
|
+
o_uu = None if obj["o_uu"] is None else UUID(obj["o_uu"]["string"]),
|
67
|
+
o_k = None if obj["o_k"] is None else obj["o_k"]["string"],
|
68
|
+
o_ot = None if obj["o_ot"] is None else obj["o_ot"]["string"],
|
69
|
+
uor = None if obj["uor"] is None else obj["uor"]["array"],
|
74
70
|
iat_dt = datetime.fromisoformat(obj["iat_dt"]),
|
75
71
|
iat = int(obj["iat"]),
|
76
72
|
exp_dt = datetime.fromisoformat(obj["exp_dt"]),
|
@@ -62,10 +62,10 @@ maleo_foundation/models/schemas/result.py,sha256=Utpq7ZPb55Q08-j_P5GukcYnNxaIlHX
|
|
62
62
|
maleo_foundation/models/schemas/signature.py,sha256=pP78JZpoizQguVKXv4AXQmB8ebVy0BmcIfpEm9_YbRU,625
|
63
63
|
maleo_foundation/models/schemas/token.py,sha256=Ay-ntAiKeBjCT4YYw0S3Zd4e-KvHSYvG_hzCMYzd5qY,567
|
64
64
|
maleo_foundation/models/transfers/__init__.py,sha256=oJLJ3Geeme6vBw7R2Dhvdvg4ziVvzEYAGJaP-tm_90w,299
|
65
|
-
maleo_foundation/models/transfers/general/__init__.py,sha256=
|
65
|
+
maleo_foundation/models/transfers/general/__init__.py,sha256=rzHpxhyNphl5RVrsAlzEvuYEonmWgb69gJ8XOLMvFDc,4686
|
66
66
|
maleo_foundation/models/transfers/general/key.py,sha256=S37SqD3qwTbgMk7785hW7Kl9d4Kouh4uPZcGoyMQ_-Q,755
|
67
67
|
maleo_foundation/models/transfers/general/signature.py,sha256=J9xQy2HjpCQOnES7RJqsUnDgjFPuakQ1mxyfdTdstSE,297
|
68
|
-
maleo_foundation/models/transfers/general/token.py,sha256=
|
68
|
+
maleo_foundation/models/transfers/general/token.py,sha256=PU-_wLFaY2i8pwRi9-jlk4nh7XzoTKOk0BEsUCGbD80,4979
|
69
69
|
maleo_foundation/models/transfers/parameters/__init__.py,sha256=oKW4RPIEISISRjsJzD8lsCGY1HhZRTzshPpWHcJu86k,353
|
70
70
|
maleo_foundation/models/transfers/parameters/client.py,sha256=wI2-ML99yn5HR0AciFg2C9EQixrWjbIR8x_bDbqKeDM,4069
|
71
71
|
maleo_foundation/models/transfers/parameters/general.py,sha256=-nSIcn0thtodk-69Uwj6qdrX8zfe-PX-gWwD-_VCVyY,779
|
@@ -120,7 +120,7 @@ maleo_foundation/utils/loaders/credential/__init__.py,sha256=qopTKvcMVoTFwyRijeg
|
|
120
120
|
maleo_foundation/utils/loaders/credential/google.py,sha256=yEL0DIVjiKSlZOxogC5pr_NAdWth9dj_ZatLjRsutIk,1269
|
121
121
|
maleo_foundation/utils/loaders/key/__init__.py,sha256=hVygcC2ImHc_aVrSrOmyedR8tMUZokWUKCKOSh5ctbo,106
|
122
122
|
maleo_foundation/utils/loaders/key/rsa.py,sha256=gDhyX6iTFtHiluuhFCozaZ3pOLKU2Y9TlrNMK_GVyGU,3796
|
123
|
-
maleo_foundation-0.2.
|
124
|
-
maleo_foundation-0.2.
|
125
|
-
maleo_foundation-0.2.
|
126
|
-
maleo_foundation-0.2.
|
123
|
+
maleo_foundation-0.2.98.dist-info/METADATA,sha256=8ZinmqAZ0RtlOGjb-d8-i4_oFqbRGNHnfbn7Y6ItpI0,3598
|
124
|
+
maleo_foundation-0.2.98.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
125
|
+
maleo_foundation-0.2.98.dist-info/top_level.txt,sha256=_iBos3F_bhEOdjOnzeiEYSrCucasc810xXtLBXI8cQc,17
|
126
|
+
maleo_foundation-0.2.98.dist-info/RECORD,,
|
File without changes
|
File without changes
|