across-server-openapi-python 0.0.1__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.
- across/__init__.py +0 -0
- across/sdk/__init__.py +0 -0
- across/sdk/v1/__init__.py +251 -0
- across/sdk/v1/abstract_credential_storage.py +16 -0
- across/sdk/v1/api/__init__.py +20 -0
- across/sdk/v1/api/auth_api.py +1097 -0
- across/sdk/v1/api/filter_api.py +623 -0
- across/sdk/v1/api/group_api.py +586 -0
- across/sdk/v1/api/group_invite_api.py +1165 -0
- across/sdk/v1/api/group_role_api.py +2070 -0
- across/sdk/v1/api/instrument_api.py +633 -0
- across/sdk/v1/api/internal_api.py +571 -0
- across/sdk/v1/api/observation_api.py +940 -0
- across/sdk/v1/api/observatory_api.py +670 -0
- across/sdk/v1/api/permission_api.py +285 -0
- across/sdk/v1/api/role_api.py +552 -0
- across/sdk/v1/api/schedule_api.py +1914 -0
- across/sdk/v1/api/service_account_api.py +2353 -0
- across/sdk/v1/api/telescope_api.py +667 -0
- across/sdk/v1/api/tle_api.py +317 -0
- across/sdk/v1/api/tools_api.py +812 -0
- across/sdk/v1/api/user_api.py +2263 -0
- across/sdk/v1/api_client.py +801 -0
- across/sdk/v1/api_client_wrapper.py +239 -0
- across/sdk/v1/api_response.py +21 -0
- across/sdk/v1/configuration.py +605 -0
- across/sdk/v1/exceptions.py +216 -0
- across/sdk/v1/models/__init__.py +103 -0
- across/sdk/v1/models/access_token_response.py +89 -0
- across/sdk/v1/models/across_server_routes_v1_group_invite_schemas_group_invite.py +104 -0
- across/sdk/v1/models/across_server_routes_v1_group_role_schemas_group_role.py +124 -0
- across/sdk/v1/models/across_server_routes_v1_group_role_schemas_service_account.py +106 -0
- across/sdk/v1/models/across_server_routes_v1_group_role_schemas_user.py +95 -0
- across/sdk/v1/models/across_server_routes_v1_group_schemas_group.py +111 -0
- across/sdk/v1/models/across_server_routes_v1_group_schemas_user.py +105 -0
- across/sdk/v1/models/across_server_routes_v1_role_schemas_user.py +96 -0
- across/sdk/v1/models/across_server_routes_v1_system_service_account_schemas_service_account.py +90 -0
- across/sdk/v1/models/across_server_routes_v1_system_service_account_schemas_service_account_secret.py +92 -0
- across/sdk/v1/models/across_server_routes_v1_user_schemas_group.py +101 -0
- across/sdk/v1/models/across_server_routes_v1_user_schemas_group_invite.py +99 -0
- across/sdk/v1/models/across_server_routes_v1_user_schemas_group_role.py +99 -0
- across/sdk/v1/models/across_server_routes_v1_user_schemas_user.py +135 -0
- across/sdk/v1/models/across_server_routes_v1_user_service_account_schemas_service_account.py +111 -0
- across/sdk/v1/models/across_server_routes_v1_user_service_account_schemas_service_account_secret.py +118 -0
- across/sdk/v1/models/alt_az_constraint.py +130 -0
- across/sdk/v1/models/bandpass.py +149 -0
- across/sdk/v1/models/bandpass_type.py +155 -0
- across/sdk/v1/models/constrained_date.py +93 -0
- across/sdk/v1/models/constraint_reason.py +89 -0
- across/sdk/v1/models/constraint_type.py +43 -0
- across/sdk/v1/models/coordinate.py +100 -0
- across/sdk/v1/models/date_range.py +90 -0
- across/sdk/v1/models/depth_unit.py +39 -0
- across/sdk/v1/models/earth_limb_constraint.py +124 -0
- across/sdk/v1/models/energy_bandpass.py +121 -0
- across/sdk/v1/models/energy_unit.py +40 -0
- across/sdk/v1/models/ephemeris_type.py +39 -0
- across/sdk/v1/models/filter.py +135 -0
- across/sdk/v1/models/frequency_bandpass.py +121 -0
- across/sdk/v1/models/frequency_unit.py +40 -0
- across/sdk/v1/models/grant_type.py +37 -0
- across/sdk/v1/models/ground_parameters.py +91 -0
- across/sdk/v1/models/group_invite_create.py +87 -0
- across/sdk/v1/models/group_invite_group_details.py +94 -0
- across/sdk/v1/models/group_read.py +91 -0
- across/sdk/v1/models/group_role_create.py +89 -0
- across/sdk/v1/models/group_role_read.py +99 -0
- across/sdk/v1/models/http_validation_error.py +95 -0
- across/sdk/v1/models/id_name_schema.py +96 -0
- across/sdk/v1/models/instrument.py +163 -0
- across/sdk/v1/models/instrument_constraints_inner.py +237 -0
- across/sdk/v1/models/ivoa_obs_category.py +39 -0
- across/sdk/v1/models/ivoa_obs_tracking_type.py +38 -0
- across/sdk/v1/models/jpl_parameters.py +87 -0
- across/sdk/v1/models/moon_angle_constraint.py +124 -0
- across/sdk/v1/models/nullable_date_range.py +100 -0
- across/sdk/v1/models/observation.py +248 -0
- across/sdk/v1/models/observation_create.py +249 -0
- across/sdk/v1/models/observation_status.py +40 -0
- across/sdk/v1/models/observation_type.py +39 -0
- across/sdk/v1/models/observatory.py +145 -0
- across/sdk/v1/models/observatory_ephemeris_type.py +96 -0
- across/sdk/v1/models/observatory_type.py +37 -0
- across/sdk/v1/models/page_observation.py +116 -0
- across/sdk/v1/models/page_schedule.py +116 -0
- across/sdk/v1/models/parameters.py +164 -0
- across/sdk/v1/models/permission.py +89 -0
- across/sdk/v1/models/point.py +89 -0
- across/sdk/v1/models/role.py +100 -0
- across/sdk/v1/models/role_base.py +89 -0
- across/sdk/v1/models/saa_polygon_constraint.py +101 -0
- across/sdk/v1/models/schedule.py +144 -0
- across/sdk/v1/models/schedule_cadence.py +99 -0
- across/sdk/v1/models/schedule_create.py +123 -0
- across/sdk/v1/models/schedule_create_many.py +97 -0
- across/sdk/v1/models/schedule_fidelity.py +37 -0
- across/sdk/v1/models/schedule_status.py +38 -0
- across/sdk/v1/models/service_account_create.py +101 -0
- across/sdk/v1/models/service_account_secret.py +103 -0
- across/sdk/v1/models/service_account_update.py +106 -0
- across/sdk/v1/models/spice_parameters.py +89 -0
- across/sdk/v1/models/sun_angle_constraint.py +124 -0
- across/sdk/v1/models/system_service_account.py +121 -0
- across/sdk/v1/models/system_service_account_secret.py +123 -0
- across/sdk/v1/models/telescope.py +135 -0
- across/sdk/v1/models/telescope_instrument.py +163 -0
- across/sdk/v1/models/tle.py +99 -0
- across/sdk/v1/models/tle_create.py +94 -0
- across/sdk/v1/models/tle_parameters.py +89 -0
- across/sdk/v1/models/unit_value.py +94 -0
- across/sdk/v1/models/user_create.py +93 -0
- across/sdk/v1/models/user_info.py +95 -0
- across/sdk/v1/models/user_update.py +106 -0
- across/sdk/v1/models/validation_error.py +99 -0
- across/sdk/v1/models/validation_error_loc_inner.py +138 -0
- across/sdk/v1/models/visibility_result.py +97 -0
- across/sdk/v1/models/visibility_type.py +38 -0
- across/sdk/v1/models/visibility_window.py +99 -0
- across/sdk/v1/models/wavelength_bandpass.py +142 -0
- across/sdk/v1/models/wavelength_unit.py +39 -0
- across/sdk/v1/models/window.py +96 -0
- across/sdk/v1/py.typed +0 -0
- across/sdk/v1/rest.py +258 -0
- across_server_openapi_python-0.0.1.dist-info/METADATA +326 -0
- across_server_openapi_python-0.0.1.dist-info/RECORD +128 -0
- across_server_openapi_python-0.0.1.dist-info/WHEEL +5 -0
- across_server_openapi_python-0.0.1.dist-info/licenses/LICENSE +42 -0
- across_server_openapi_python-0.0.1.dist-info/top_level.txt +1 -0
|
@@ -0,0 +1,216 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
ACROSS Server
|
|
5
|
+
|
|
6
|
+
Server providing tools and utilities for various NASA missions to aid in coordination of large observation efforts.
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: 0.3.2
|
|
9
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
10
|
+
|
|
11
|
+
Do not edit the class manually.
|
|
12
|
+
""" # noqa: E501
|
|
13
|
+
|
|
14
|
+
from typing import Any, Optional
|
|
15
|
+
from typing_extensions import Self
|
|
16
|
+
|
|
17
|
+
class OpenApiException(Exception):
|
|
18
|
+
"""The base exception class for all OpenAPIExceptions"""
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
class ApiTypeError(OpenApiException, TypeError):
|
|
22
|
+
def __init__(self, msg, path_to_item=None, valid_classes=None,
|
|
23
|
+
key_type=None) -> None:
|
|
24
|
+
""" Raises an exception for TypeErrors
|
|
25
|
+
|
|
26
|
+
Args:
|
|
27
|
+
msg (str): the exception message
|
|
28
|
+
|
|
29
|
+
Keyword Args:
|
|
30
|
+
path_to_item (list): a list of keys an indices to get to the
|
|
31
|
+
current_item
|
|
32
|
+
None if unset
|
|
33
|
+
valid_classes (tuple): the primitive classes that current item
|
|
34
|
+
should be an instance of
|
|
35
|
+
None if unset
|
|
36
|
+
key_type (bool): False if our value is a value in a dict
|
|
37
|
+
True if it is a key in a dict
|
|
38
|
+
False if our item is an item in a list
|
|
39
|
+
None if unset
|
|
40
|
+
"""
|
|
41
|
+
self.path_to_item = path_to_item
|
|
42
|
+
self.valid_classes = valid_classes
|
|
43
|
+
self.key_type = key_type
|
|
44
|
+
full_msg = msg
|
|
45
|
+
if path_to_item:
|
|
46
|
+
full_msg = "{0} at {1}".format(msg, render_path(path_to_item))
|
|
47
|
+
super(ApiTypeError, self).__init__(full_msg)
|
|
48
|
+
|
|
49
|
+
|
|
50
|
+
class ApiValueError(OpenApiException, ValueError):
|
|
51
|
+
def __init__(self, msg, path_to_item=None) -> None:
|
|
52
|
+
"""
|
|
53
|
+
Args:
|
|
54
|
+
msg (str): the exception message
|
|
55
|
+
|
|
56
|
+
Keyword Args:
|
|
57
|
+
path_to_item (list) the path to the exception in the
|
|
58
|
+
received_data dict. None if unset
|
|
59
|
+
"""
|
|
60
|
+
|
|
61
|
+
self.path_to_item = path_to_item
|
|
62
|
+
full_msg = msg
|
|
63
|
+
if path_to_item:
|
|
64
|
+
full_msg = "{0} at {1}".format(msg, render_path(path_to_item))
|
|
65
|
+
super(ApiValueError, self).__init__(full_msg)
|
|
66
|
+
|
|
67
|
+
|
|
68
|
+
class ApiAttributeError(OpenApiException, AttributeError):
|
|
69
|
+
def __init__(self, msg, path_to_item=None) -> None:
|
|
70
|
+
"""
|
|
71
|
+
Raised when an attribute reference or assignment fails.
|
|
72
|
+
|
|
73
|
+
Args:
|
|
74
|
+
msg (str): the exception message
|
|
75
|
+
|
|
76
|
+
Keyword Args:
|
|
77
|
+
path_to_item (None/list) the path to the exception in the
|
|
78
|
+
received_data dict
|
|
79
|
+
"""
|
|
80
|
+
self.path_to_item = path_to_item
|
|
81
|
+
full_msg = msg
|
|
82
|
+
if path_to_item:
|
|
83
|
+
full_msg = "{0} at {1}".format(msg, render_path(path_to_item))
|
|
84
|
+
super(ApiAttributeError, self).__init__(full_msg)
|
|
85
|
+
|
|
86
|
+
|
|
87
|
+
class ApiKeyError(OpenApiException, KeyError):
|
|
88
|
+
def __init__(self, msg, path_to_item=None) -> None:
|
|
89
|
+
"""
|
|
90
|
+
Args:
|
|
91
|
+
msg (str): the exception message
|
|
92
|
+
|
|
93
|
+
Keyword Args:
|
|
94
|
+
path_to_item (None/list) the path to the exception in the
|
|
95
|
+
received_data dict
|
|
96
|
+
"""
|
|
97
|
+
self.path_to_item = path_to_item
|
|
98
|
+
full_msg = msg
|
|
99
|
+
if path_to_item:
|
|
100
|
+
full_msg = "{0} at {1}".format(msg, render_path(path_to_item))
|
|
101
|
+
super(ApiKeyError, self).__init__(full_msg)
|
|
102
|
+
|
|
103
|
+
|
|
104
|
+
class ApiException(OpenApiException):
|
|
105
|
+
|
|
106
|
+
def __init__(
|
|
107
|
+
self,
|
|
108
|
+
status=None,
|
|
109
|
+
reason=None,
|
|
110
|
+
http_resp=None,
|
|
111
|
+
*,
|
|
112
|
+
body: Optional[str] = None,
|
|
113
|
+
data: Optional[Any] = None,
|
|
114
|
+
) -> None:
|
|
115
|
+
self.status = status
|
|
116
|
+
self.reason = reason
|
|
117
|
+
self.body = body
|
|
118
|
+
self.data = data
|
|
119
|
+
self.headers = None
|
|
120
|
+
|
|
121
|
+
if http_resp:
|
|
122
|
+
if self.status is None:
|
|
123
|
+
self.status = http_resp.status
|
|
124
|
+
if self.reason is None:
|
|
125
|
+
self.reason = http_resp.reason
|
|
126
|
+
if self.body is None:
|
|
127
|
+
try:
|
|
128
|
+
self.body = http_resp.data.decode('utf-8')
|
|
129
|
+
except Exception:
|
|
130
|
+
pass
|
|
131
|
+
self.headers = http_resp.getheaders()
|
|
132
|
+
|
|
133
|
+
@classmethod
|
|
134
|
+
def from_response(
|
|
135
|
+
cls,
|
|
136
|
+
*,
|
|
137
|
+
http_resp,
|
|
138
|
+
body: Optional[str],
|
|
139
|
+
data: Optional[Any],
|
|
140
|
+
) -> Self:
|
|
141
|
+
if http_resp.status == 400:
|
|
142
|
+
raise BadRequestException(http_resp=http_resp, body=body, data=data)
|
|
143
|
+
|
|
144
|
+
if http_resp.status == 401:
|
|
145
|
+
raise UnauthorizedException(http_resp=http_resp, body=body, data=data)
|
|
146
|
+
|
|
147
|
+
if http_resp.status == 403:
|
|
148
|
+
raise ForbiddenException(http_resp=http_resp, body=body, data=data)
|
|
149
|
+
|
|
150
|
+
if http_resp.status == 404:
|
|
151
|
+
raise NotFoundException(http_resp=http_resp, body=body, data=data)
|
|
152
|
+
|
|
153
|
+
# Added new conditions for 409 and 422
|
|
154
|
+
if http_resp.status == 409:
|
|
155
|
+
raise ConflictException(http_resp=http_resp, body=body, data=data)
|
|
156
|
+
|
|
157
|
+
if http_resp.status == 422:
|
|
158
|
+
raise UnprocessableEntityException(http_resp=http_resp, body=body, data=data)
|
|
159
|
+
|
|
160
|
+
if 500 <= http_resp.status <= 599:
|
|
161
|
+
raise ServiceException(http_resp=http_resp, body=body, data=data)
|
|
162
|
+
raise ApiException(http_resp=http_resp, body=body, data=data)
|
|
163
|
+
|
|
164
|
+
def __str__(self):
|
|
165
|
+
"""Custom error messages for exception"""
|
|
166
|
+
error_message = "({0})\n"\
|
|
167
|
+
"Reason: {1}\n".format(self.status, self.reason)
|
|
168
|
+
if self.headers:
|
|
169
|
+
error_message += "HTTP response headers: {0}\n".format(
|
|
170
|
+
self.headers)
|
|
171
|
+
|
|
172
|
+
if self.data or self.body:
|
|
173
|
+
error_message += "HTTP response body: {0}\n".format(self.data or self.body)
|
|
174
|
+
|
|
175
|
+
return error_message
|
|
176
|
+
|
|
177
|
+
|
|
178
|
+
class BadRequestException(ApiException):
|
|
179
|
+
pass
|
|
180
|
+
|
|
181
|
+
|
|
182
|
+
class NotFoundException(ApiException):
|
|
183
|
+
pass
|
|
184
|
+
|
|
185
|
+
|
|
186
|
+
class UnauthorizedException(ApiException):
|
|
187
|
+
pass
|
|
188
|
+
|
|
189
|
+
|
|
190
|
+
class ForbiddenException(ApiException):
|
|
191
|
+
pass
|
|
192
|
+
|
|
193
|
+
|
|
194
|
+
class ServiceException(ApiException):
|
|
195
|
+
pass
|
|
196
|
+
|
|
197
|
+
|
|
198
|
+
class ConflictException(ApiException):
|
|
199
|
+
"""Exception for HTTP 409 Conflict."""
|
|
200
|
+
pass
|
|
201
|
+
|
|
202
|
+
|
|
203
|
+
class UnprocessableEntityException(ApiException):
|
|
204
|
+
"""Exception for HTTP 422 Unprocessable Entity."""
|
|
205
|
+
pass
|
|
206
|
+
|
|
207
|
+
|
|
208
|
+
def render_path(path_to_item):
|
|
209
|
+
"""Returns a string representation of a path"""
|
|
210
|
+
result = ""
|
|
211
|
+
for pth in path_to_item:
|
|
212
|
+
if isinstance(pth, int):
|
|
213
|
+
result += "[{0}]".format(pth)
|
|
214
|
+
else:
|
|
215
|
+
result += "['{0}']".format(pth)
|
|
216
|
+
return result
|
|
@@ -0,0 +1,103 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
# flake8: noqa
|
|
4
|
+
"""
|
|
5
|
+
ACROSS Server
|
|
6
|
+
|
|
7
|
+
Server providing tools and utilities for various NASA missions to aid in coordination of large observation efforts.
|
|
8
|
+
|
|
9
|
+
The version of the OpenAPI document: 0.3.2
|
|
10
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
11
|
+
|
|
12
|
+
Do not edit the class manually.
|
|
13
|
+
""" # noqa: E501
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
# import models into model package
|
|
17
|
+
from across.sdk.v1.models.access_token_response import AccessTokenResponse
|
|
18
|
+
from across.sdk.v1.models.across_server_routes_v1_group_invite_schemas_group_invite import AcrossServerRoutesV1GroupInviteSchemasGroupInvite
|
|
19
|
+
from across.sdk.v1.models.across_server_routes_v1_group_role_schemas_group_role import AcrossServerRoutesV1GroupRoleSchemasGroupRole
|
|
20
|
+
from across.sdk.v1.models.across_server_routes_v1_group_role_schemas_service_account import AcrossServerRoutesV1GroupRoleSchemasServiceAccount
|
|
21
|
+
from across.sdk.v1.models.across_server_routes_v1_group_role_schemas_user import AcrossServerRoutesV1GroupRoleSchemasUser
|
|
22
|
+
from across.sdk.v1.models.across_server_routes_v1_group_schemas_group import AcrossServerRoutesV1GroupSchemasGroup
|
|
23
|
+
from across.sdk.v1.models.across_server_routes_v1_group_schemas_user import AcrossServerRoutesV1GroupSchemasUser
|
|
24
|
+
from across.sdk.v1.models.across_server_routes_v1_user_schemas_group import AcrossServerRoutesV1UserSchemasGroup
|
|
25
|
+
from across.sdk.v1.models.across_server_routes_v1_user_schemas_group_invite import AcrossServerRoutesV1UserSchemasGroupInvite
|
|
26
|
+
from across.sdk.v1.models.across_server_routes_v1_user_schemas_group_role import AcrossServerRoutesV1UserSchemasGroupRole
|
|
27
|
+
from across.sdk.v1.models.across_server_routes_v1_user_schemas_user import AcrossServerRoutesV1UserSchemasUser
|
|
28
|
+
from across.sdk.v1.models.across_server_routes_v1_user_service_account_schemas_service_account import AcrossServerRoutesV1UserServiceAccountSchemasServiceAccount
|
|
29
|
+
from across.sdk.v1.models.alt_az_constraint import AltAzConstraint
|
|
30
|
+
from across.sdk.v1.models.bandpass import Bandpass
|
|
31
|
+
from across.sdk.v1.models.bandpass_type import BandpassType
|
|
32
|
+
from across.sdk.v1.models.constrained_date import ConstrainedDate
|
|
33
|
+
from across.sdk.v1.models.constraint_reason import ConstraintReason
|
|
34
|
+
from across.sdk.v1.models.constraint_type import ConstraintType
|
|
35
|
+
from across.sdk.v1.models.coordinate import Coordinate
|
|
36
|
+
from across.sdk.v1.models.date_range import DateRange
|
|
37
|
+
from across.sdk.v1.models.depth_unit import DepthUnit
|
|
38
|
+
from across.sdk.v1.models.earth_limb_constraint import EarthLimbConstraint
|
|
39
|
+
from across.sdk.v1.models.energy_bandpass import EnergyBandpass
|
|
40
|
+
from across.sdk.v1.models.energy_unit import EnergyUnit
|
|
41
|
+
from across.sdk.v1.models.ephemeris_type import EphemerisType
|
|
42
|
+
from across.sdk.v1.models.filter import Filter
|
|
43
|
+
from across.sdk.v1.models.frequency_bandpass import FrequencyBandpass
|
|
44
|
+
from across.sdk.v1.models.frequency_unit import FrequencyUnit
|
|
45
|
+
from across.sdk.v1.models.grant_type import GrantType
|
|
46
|
+
from across.sdk.v1.models.ground_parameters import GroundParameters
|
|
47
|
+
from across.sdk.v1.models.group_invite_create import GroupInviteCreate
|
|
48
|
+
from across.sdk.v1.models.group_invite_group_details import GroupInviteGroupDetails
|
|
49
|
+
from across.sdk.v1.models.group_read import GroupRead
|
|
50
|
+
from across.sdk.v1.models.group_role_create import GroupRoleCreate
|
|
51
|
+
from across.sdk.v1.models.group_role_read import GroupRoleRead
|
|
52
|
+
from across.sdk.v1.models.http_validation_error import HTTPValidationError
|
|
53
|
+
from across.sdk.v1.models.id_name_schema import IDNameSchema
|
|
54
|
+
from across.sdk.v1.models.ivoa_obs_category import IVOAObsCategory
|
|
55
|
+
from across.sdk.v1.models.ivoa_obs_tracking_type import IVOAObsTrackingType
|
|
56
|
+
from across.sdk.v1.models.instrument import Instrument
|
|
57
|
+
from across.sdk.v1.models.instrument_constraints_inner import InstrumentConstraintsInner
|
|
58
|
+
from across.sdk.v1.models.jpl_parameters import JPLParameters
|
|
59
|
+
from across.sdk.v1.models.moon_angle_constraint import MoonAngleConstraint
|
|
60
|
+
from across.sdk.v1.models.nullable_date_range import NullableDateRange
|
|
61
|
+
from across.sdk.v1.models.observation import Observation
|
|
62
|
+
from across.sdk.v1.models.observation_create import ObservationCreate
|
|
63
|
+
from across.sdk.v1.models.observation_status import ObservationStatus
|
|
64
|
+
from across.sdk.v1.models.observation_type import ObservationType
|
|
65
|
+
from across.sdk.v1.models.observatory import Observatory
|
|
66
|
+
from across.sdk.v1.models.observatory_ephemeris_type import ObservatoryEphemerisType
|
|
67
|
+
from across.sdk.v1.models.observatory_type import ObservatoryType
|
|
68
|
+
from across.sdk.v1.models.page_observation import PageObservation
|
|
69
|
+
from across.sdk.v1.models.page_schedule import PageSchedule
|
|
70
|
+
from across.sdk.v1.models.parameters import Parameters
|
|
71
|
+
from across.sdk.v1.models.permission import Permission
|
|
72
|
+
from across.sdk.v1.models.point import Point
|
|
73
|
+
from across.sdk.v1.models.role_base import RoleBase
|
|
74
|
+
from across.sdk.v1.models.saa_polygon_constraint import SAAPolygonConstraint
|
|
75
|
+
from across.sdk.v1.models.spice_parameters import SPICEParameters
|
|
76
|
+
from across.sdk.v1.models.schedule import Schedule
|
|
77
|
+
from across.sdk.v1.models.schedule_cadence import ScheduleCadence
|
|
78
|
+
from across.sdk.v1.models.schedule_create import ScheduleCreate
|
|
79
|
+
from across.sdk.v1.models.schedule_create_many import ScheduleCreateMany
|
|
80
|
+
from across.sdk.v1.models.schedule_fidelity import ScheduleFidelity
|
|
81
|
+
from across.sdk.v1.models.schedule_status import ScheduleStatus
|
|
82
|
+
from across.sdk.v1.models.service_account_create import ServiceAccountCreate
|
|
83
|
+
from across.sdk.v1.models.service_account_secret import ServiceAccountSecret
|
|
84
|
+
from across.sdk.v1.models.service_account_update import ServiceAccountUpdate
|
|
85
|
+
from across.sdk.v1.models.sun_angle_constraint import SunAngleConstraint
|
|
86
|
+
from across.sdk.v1.models.system_service_account import SystemServiceAccount
|
|
87
|
+
from across.sdk.v1.models.tle import TLE
|
|
88
|
+
from across.sdk.v1.models.tle_create import TLECreate
|
|
89
|
+
from across.sdk.v1.models.tle_parameters import TLEParameters
|
|
90
|
+
from across.sdk.v1.models.telescope import Telescope
|
|
91
|
+
from across.sdk.v1.models.telescope_instrument import TelescopeInstrument
|
|
92
|
+
from across.sdk.v1.models.unit_value import UnitValue
|
|
93
|
+
from across.sdk.v1.models.user_create import UserCreate
|
|
94
|
+
from across.sdk.v1.models.user_info import UserInfo
|
|
95
|
+
from across.sdk.v1.models.user_update import UserUpdate
|
|
96
|
+
from across.sdk.v1.models.validation_error import ValidationError
|
|
97
|
+
from across.sdk.v1.models.validation_error_loc_inner import ValidationErrorLocInner
|
|
98
|
+
from across.sdk.v1.models.visibility_result import VisibilityResult
|
|
99
|
+
from across.sdk.v1.models.visibility_type import VisibilityType
|
|
100
|
+
from across.sdk.v1.models.visibility_window import VisibilityWindow
|
|
101
|
+
from across.sdk.v1.models.wavelength_bandpass import WavelengthBandpass
|
|
102
|
+
from across.sdk.v1.models.wavelength_unit import WavelengthUnit
|
|
103
|
+
from across.sdk.v1.models.window import Window
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
ACROSS Server
|
|
5
|
+
|
|
6
|
+
Server providing tools and utilities for various NASA missions to aid in coordination of large observation efforts.
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: 0.3.2
|
|
9
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
10
|
+
|
|
11
|
+
Do not edit the class manually.
|
|
12
|
+
""" # noqa: E501
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
from __future__ import annotations
|
|
16
|
+
import pprint
|
|
17
|
+
import re # noqa: F401
|
|
18
|
+
import json
|
|
19
|
+
|
|
20
|
+
from pydantic import BaseModel, ConfigDict, StrictStr
|
|
21
|
+
from typing import Any, ClassVar, Dict, List, Optional
|
|
22
|
+
from typing import Optional, Set
|
|
23
|
+
from typing_extensions import Self
|
|
24
|
+
|
|
25
|
+
class AccessTokenResponse(BaseModel):
|
|
26
|
+
"""
|
|
27
|
+
AccessTokenResponse
|
|
28
|
+
""" # noqa: E501
|
|
29
|
+
access_token: StrictStr
|
|
30
|
+
token_type: Optional[StrictStr] = 'bearer'
|
|
31
|
+
__properties: ClassVar[List[str]] = ["access_token", "token_type"]
|
|
32
|
+
|
|
33
|
+
model_config = ConfigDict(
|
|
34
|
+
populate_by_name=True,
|
|
35
|
+
validate_assignment=True,
|
|
36
|
+
protected_namespaces=(),
|
|
37
|
+
)
|
|
38
|
+
|
|
39
|
+
|
|
40
|
+
def to_str(self) -> str:
|
|
41
|
+
"""Returns the string representation of the model using alias"""
|
|
42
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
43
|
+
|
|
44
|
+
def to_json(self) -> str:
|
|
45
|
+
"""Returns the JSON representation of the model using alias"""
|
|
46
|
+
# TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
|
|
47
|
+
return json.dumps(self.to_dict())
|
|
48
|
+
|
|
49
|
+
@classmethod
|
|
50
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
51
|
+
"""Create an instance of AccessTokenResponse from a JSON string"""
|
|
52
|
+
return cls.from_dict(json.loads(json_str))
|
|
53
|
+
|
|
54
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
55
|
+
"""Return the dictionary representation of the model using alias.
|
|
56
|
+
|
|
57
|
+
This has the following differences from calling pydantic's
|
|
58
|
+
`self.model_dump(by_alias=True)`:
|
|
59
|
+
|
|
60
|
+
* `None` is only added to the output dict for nullable fields that
|
|
61
|
+
were set at model initialization. Other fields with value `None`
|
|
62
|
+
are ignored.
|
|
63
|
+
"""
|
|
64
|
+
excluded_fields: Set[str] = set([
|
|
65
|
+
])
|
|
66
|
+
|
|
67
|
+
_dict = self.model_dump(
|
|
68
|
+
by_alias=True,
|
|
69
|
+
exclude=excluded_fields,
|
|
70
|
+
exclude_none=True,
|
|
71
|
+
)
|
|
72
|
+
return _dict
|
|
73
|
+
|
|
74
|
+
@classmethod
|
|
75
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
76
|
+
"""Create an instance of AccessTokenResponse from a dict"""
|
|
77
|
+
if obj is None:
|
|
78
|
+
return None
|
|
79
|
+
|
|
80
|
+
if not isinstance(obj, dict):
|
|
81
|
+
return cls.model_validate(obj)
|
|
82
|
+
|
|
83
|
+
_obj = cls.model_validate({
|
|
84
|
+
"access_token": obj.get("access_token"),
|
|
85
|
+
"token_type": obj.get("token_type") if obj.get("token_type") is not None else 'bearer'
|
|
86
|
+
})
|
|
87
|
+
return _obj
|
|
88
|
+
|
|
89
|
+
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
ACROSS Server
|
|
5
|
+
|
|
6
|
+
Server providing tools and utilities for various NASA missions to aid in coordination of large observation efforts.
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: 0.3.2
|
|
9
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
10
|
+
|
|
11
|
+
Do not edit the class manually.
|
|
12
|
+
""" # noqa: E501
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
from __future__ import annotations
|
|
16
|
+
import pprint
|
|
17
|
+
import re # noqa: F401
|
|
18
|
+
import json
|
|
19
|
+
|
|
20
|
+
from pydantic import BaseModel, ConfigDict, StrictStr
|
|
21
|
+
from typing import Any, ClassVar, Dict, List
|
|
22
|
+
from across.sdk.v1.models.group_read import GroupRead
|
|
23
|
+
from across.sdk.v1.models.user_info import UserInfo
|
|
24
|
+
from typing import Optional, Set
|
|
25
|
+
from typing_extensions import Self
|
|
26
|
+
|
|
27
|
+
class AcrossServerRoutesV1GroupInviteSchemasGroupInvite(BaseModel):
|
|
28
|
+
"""
|
|
29
|
+
AcrossServerRoutesV1GroupInviteSchemasGroupInvite
|
|
30
|
+
""" # noqa: E501
|
|
31
|
+
id: StrictStr
|
|
32
|
+
group: GroupRead
|
|
33
|
+
receiver: UserInfo
|
|
34
|
+
sender: UserInfo
|
|
35
|
+
__properties: ClassVar[List[str]] = ["id", "group", "receiver", "sender"]
|
|
36
|
+
|
|
37
|
+
model_config = ConfigDict(
|
|
38
|
+
populate_by_name=True,
|
|
39
|
+
validate_assignment=True,
|
|
40
|
+
protected_namespaces=(),
|
|
41
|
+
)
|
|
42
|
+
|
|
43
|
+
|
|
44
|
+
def to_str(self) -> str:
|
|
45
|
+
"""Returns the string representation of the model using alias"""
|
|
46
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
47
|
+
|
|
48
|
+
def to_json(self) -> str:
|
|
49
|
+
"""Returns the JSON representation of the model using alias"""
|
|
50
|
+
# TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
|
|
51
|
+
return json.dumps(self.to_dict())
|
|
52
|
+
|
|
53
|
+
@classmethod
|
|
54
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
55
|
+
"""Create an instance of AcrossServerRoutesV1GroupInviteSchemasGroupInvite from a JSON string"""
|
|
56
|
+
return cls.from_dict(json.loads(json_str))
|
|
57
|
+
|
|
58
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
59
|
+
"""Return the dictionary representation of the model using alias.
|
|
60
|
+
|
|
61
|
+
This has the following differences from calling pydantic's
|
|
62
|
+
`self.model_dump(by_alias=True)`:
|
|
63
|
+
|
|
64
|
+
* `None` is only added to the output dict for nullable fields that
|
|
65
|
+
were set at model initialization. Other fields with value `None`
|
|
66
|
+
are ignored.
|
|
67
|
+
"""
|
|
68
|
+
excluded_fields: Set[str] = set([
|
|
69
|
+
])
|
|
70
|
+
|
|
71
|
+
_dict = self.model_dump(
|
|
72
|
+
by_alias=True,
|
|
73
|
+
exclude=excluded_fields,
|
|
74
|
+
exclude_none=True,
|
|
75
|
+
)
|
|
76
|
+
# override the default output from pydantic by calling `to_dict()` of group
|
|
77
|
+
if self.group:
|
|
78
|
+
_dict['group'] = self.group.to_dict()
|
|
79
|
+
# override the default output from pydantic by calling `to_dict()` of receiver
|
|
80
|
+
if self.receiver:
|
|
81
|
+
_dict['receiver'] = self.receiver.to_dict()
|
|
82
|
+
# override the default output from pydantic by calling `to_dict()` of sender
|
|
83
|
+
if self.sender:
|
|
84
|
+
_dict['sender'] = self.sender.to_dict()
|
|
85
|
+
return _dict
|
|
86
|
+
|
|
87
|
+
@classmethod
|
|
88
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
89
|
+
"""Create an instance of AcrossServerRoutesV1GroupInviteSchemasGroupInvite from a dict"""
|
|
90
|
+
if obj is None:
|
|
91
|
+
return None
|
|
92
|
+
|
|
93
|
+
if not isinstance(obj, dict):
|
|
94
|
+
return cls.model_validate(obj)
|
|
95
|
+
|
|
96
|
+
_obj = cls.model_validate({
|
|
97
|
+
"id": obj.get("id"),
|
|
98
|
+
"group": GroupRead.from_dict(obj["group"]) if obj.get("group") is not None else None,
|
|
99
|
+
"receiver": UserInfo.from_dict(obj["receiver"]) if obj.get("receiver") is not None else None,
|
|
100
|
+
"sender": UserInfo.from_dict(obj["sender"]) if obj.get("sender") is not None else None
|
|
101
|
+
})
|
|
102
|
+
return _obj
|
|
103
|
+
|
|
104
|
+
|
|
@@ -0,0 +1,124 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
ACROSS Server
|
|
5
|
+
|
|
6
|
+
Server providing tools and utilities for various NASA missions to aid in coordination of large observation efforts.
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: 0.3.2
|
|
9
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
10
|
+
|
|
11
|
+
Do not edit the class manually.
|
|
12
|
+
""" # noqa: E501
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
from __future__ import annotations
|
|
16
|
+
import pprint
|
|
17
|
+
import re # noqa: F401
|
|
18
|
+
import json
|
|
19
|
+
|
|
20
|
+
from pydantic import BaseModel, ConfigDict, StrictStr
|
|
21
|
+
from typing import Any, ClassVar, Dict, List, Optional
|
|
22
|
+
from across.sdk.v1.models.across_server_routes_v1_group_role_schemas_service_account import AcrossServerRoutesV1GroupRoleSchemasServiceAccount
|
|
23
|
+
from across.sdk.v1.models.across_server_routes_v1_group_role_schemas_user import AcrossServerRoutesV1GroupRoleSchemasUser
|
|
24
|
+
from across.sdk.v1.models.permission import Permission
|
|
25
|
+
from typing import Optional, Set
|
|
26
|
+
from typing_extensions import Self
|
|
27
|
+
|
|
28
|
+
class AcrossServerRoutesV1GroupRoleSchemasGroupRole(BaseModel):
|
|
29
|
+
"""
|
|
30
|
+
AcrossServerRoutesV1GroupRoleSchemasGroupRole
|
|
31
|
+
""" # noqa: E501
|
|
32
|
+
name: StrictStr
|
|
33
|
+
permissions: List[Permission]
|
|
34
|
+
id: StrictStr
|
|
35
|
+
users: List[AcrossServerRoutesV1GroupRoleSchemasUser]
|
|
36
|
+
service_accounts: Optional[List[AcrossServerRoutesV1GroupRoleSchemasServiceAccount]]
|
|
37
|
+
__properties: ClassVar[List[str]] = ["name", "permissions", "id", "users", "service_accounts"]
|
|
38
|
+
|
|
39
|
+
model_config = ConfigDict(
|
|
40
|
+
populate_by_name=True,
|
|
41
|
+
validate_assignment=True,
|
|
42
|
+
protected_namespaces=(),
|
|
43
|
+
)
|
|
44
|
+
|
|
45
|
+
|
|
46
|
+
def to_str(self) -> str:
|
|
47
|
+
"""Returns the string representation of the model using alias"""
|
|
48
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
49
|
+
|
|
50
|
+
def to_json(self) -> str:
|
|
51
|
+
"""Returns the JSON representation of the model using alias"""
|
|
52
|
+
# TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
|
|
53
|
+
return json.dumps(self.to_dict())
|
|
54
|
+
|
|
55
|
+
@classmethod
|
|
56
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
57
|
+
"""Create an instance of AcrossServerRoutesV1GroupRoleSchemasGroupRole from a JSON string"""
|
|
58
|
+
return cls.from_dict(json.loads(json_str))
|
|
59
|
+
|
|
60
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
61
|
+
"""Return the dictionary representation of the model using alias.
|
|
62
|
+
|
|
63
|
+
This has the following differences from calling pydantic's
|
|
64
|
+
`self.model_dump(by_alias=True)`:
|
|
65
|
+
|
|
66
|
+
* `None` is only added to the output dict for nullable fields that
|
|
67
|
+
were set at model initialization. Other fields with value `None`
|
|
68
|
+
are ignored.
|
|
69
|
+
"""
|
|
70
|
+
excluded_fields: Set[str] = set([
|
|
71
|
+
])
|
|
72
|
+
|
|
73
|
+
_dict = self.model_dump(
|
|
74
|
+
by_alias=True,
|
|
75
|
+
exclude=excluded_fields,
|
|
76
|
+
exclude_none=True,
|
|
77
|
+
)
|
|
78
|
+
# override the default output from pydantic by calling `to_dict()` of each item in permissions (list)
|
|
79
|
+
_items = []
|
|
80
|
+
if self.permissions:
|
|
81
|
+
for _item_permissions in self.permissions:
|
|
82
|
+
if _item_permissions:
|
|
83
|
+
_items.append(_item_permissions.to_dict())
|
|
84
|
+
_dict['permissions'] = _items
|
|
85
|
+
# override the default output from pydantic by calling `to_dict()` of each item in users (list)
|
|
86
|
+
_items = []
|
|
87
|
+
if self.users:
|
|
88
|
+
for _item_users in self.users:
|
|
89
|
+
if _item_users:
|
|
90
|
+
_items.append(_item_users.to_dict())
|
|
91
|
+
_dict['users'] = _items
|
|
92
|
+
# override the default output from pydantic by calling `to_dict()` of each item in service_accounts (list)
|
|
93
|
+
_items = []
|
|
94
|
+
if self.service_accounts:
|
|
95
|
+
for _item_service_accounts in self.service_accounts:
|
|
96
|
+
if _item_service_accounts:
|
|
97
|
+
_items.append(_item_service_accounts.to_dict())
|
|
98
|
+
_dict['service_accounts'] = _items
|
|
99
|
+
# set to None if service_accounts (nullable) is None
|
|
100
|
+
# and model_fields_set contains the field
|
|
101
|
+
if self.service_accounts is None and "service_accounts" in self.model_fields_set:
|
|
102
|
+
_dict['service_accounts'] = None
|
|
103
|
+
|
|
104
|
+
return _dict
|
|
105
|
+
|
|
106
|
+
@classmethod
|
|
107
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
108
|
+
"""Create an instance of AcrossServerRoutesV1GroupRoleSchemasGroupRole from a dict"""
|
|
109
|
+
if obj is None:
|
|
110
|
+
return None
|
|
111
|
+
|
|
112
|
+
if not isinstance(obj, dict):
|
|
113
|
+
return cls.model_validate(obj)
|
|
114
|
+
|
|
115
|
+
_obj = cls.model_validate({
|
|
116
|
+
"name": obj.get("name"),
|
|
117
|
+
"permissions": [Permission.from_dict(_item) for _item in obj["permissions"]] if obj.get("permissions") is not None else None,
|
|
118
|
+
"id": obj.get("id"),
|
|
119
|
+
"users": [AcrossServerRoutesV1GroupRoleSchemasUser.from_dict(_item) for _item in obj["users"]] if obj.get("users") is not None else None,
|
|
120
|
+
"service_accounts": [AcrossServerRoutesV1GroupRoleSchemasServiceAccount.from_dict(_item) for _item in obj["service_accounts"]] if obj.get("service_accounts") is not None else None
|
|
121
|
+
})
|
|
122
|
+
return _obj
|
|
123
|
+
|
|
124
|
+
|