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,667 @@
|
|
|
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
|
+
import warnings
|
|
15
|
+
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
|
|
16
|
+
from typing import Any, Dict, List, Optional, Tuple, Union
|
|
17
|
+
from typing_extensions import Annotated
|
|
18
|
+
|
|
19
|
+
from datetime import datetime
|
|
20
|
+
from pydantic import StrictBool, StrictStr
|
|
21
|
+
from typing import List, Optional
|
|
22
|
+
from across.sdk.v1.models.telescope import Telescope
|
|
23
|
+
|
|
24
|
+
from across.sdk.v1.api_client import ApiClient, RequestSerialized
|
|
25
|
+
from across.sdk.v1.api_response import ApiResponse
|
|
26
|
+
from across.sdk.v1.rest import RESTResponseType
|
|
27
|
+
|
|
28
|
+
|
|
29
|
+
class TelescopeApi:
|
|
30
|
+
"""NOTE: This class is auto generated by OpenAPI Generator
|
|
31
|
+
Ref: https://openapi-generator.tech
|
|
32
|
+
|
|
33
|
+
Do not edit the class manually.
|
|
34
|
+
"""
|
|
35
|
+
|
|
36
|
+
def __init__(self, api_client=None) -> None:
|
|
37
|
+
if api_client is None:
|
|
38
|
+
api_client = ApiClient.get_default()
|
|
39
|
+
self.api_client = api_client
|
|
40
|
+
|
|
41
|
+
|
|
42
|
+
@validate_call
|
|
43
|
+
def get_telescope(
|
|
44
|
+
self,
|
|
45
|
+
telescope_id: StrictStr,
|
|
46
|
+
_request_timeout: Union[
|
|
47
|
+
None,
|
|
48
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
49
|
+
Tuple[
|
|
50
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
51
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
52
|
+
]
|
|
53
|
+
] = None,
|
|
54
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
55
|
+
_content_type: Optional[StrictStr] = None,
|
|
56
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
57
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
58
|
+
) -> Telescope:
|
|
59
|
+
"""Read an telescope
|
|
60
|
+
|
|
61
|
+
Read a telescope by a telescope ID.
|
|
62
|
+
|
|
63
|
+
:param telescope_id: (required)
|
|
64
|
+
:type telescope_id: str
|
|
65
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
66
|
+
number provided, it will be total request
|
|
67
|
+
timeout. It can also be a pair (tuple) of
|
|
68
|
+
(connection, read) timeouts.
|
|
69
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
70
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
71
|
+
request; this effectively ignores the
|
|
72
|
+
authentication in the spec for a single request.
|
|
73
|
+
:type _request_auth: dict, optional
|
|
74
|
+
:param _content_type: force content-type for the request.
|
|
75
|
+
:type _content_type: str, Optional
|
|
76
|
+
:param _headers: set to override the headers for a single
|
|
77
|
+
request; this effectively ignores the headers
|
|
78
|
+
in the spec for a single request.
|
|
79
|
+
:type _headers: dict, optional
|
|
80
|
+
:param _host_index: set to override the host_index for a single
|
|
81
|
+
request; this effectively ignores the host_index
|
|
82
|
+
in the spec for a single request.
|
|
83
|
+
:type _host_index: int, optional
|
|
84
|
+
:return: Returns the result object.
|
|
85
|
+
""" # noqa: E501
|
|
86
|
+
|
|
87
|
+
_param = self._get_telescope_serialize(
|
|
88
|
+
telescope_id=telescope_id,
|
|
89
|
+
_request_auth=_request_auth,
|
|
90
|
+
_content_type=_content_type,
|
|
91
|
+
_headers=_headers,
|
|
92
|
+
_host_index=_host_index
|
|
93
|
+
)
|
|
94
|
+
|
|
95
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
96
|
+
'200': "Telescope",
|
|
97
|
+
'404': None,
|
|
98
|
+
'422': "HTTPValidationError",
|
|
99
|
+
}
|
|
100
|
+
response_data = self.api_client.call_api(
|
|
101
|
+
*_param,
|
|
102
|
+
_request_timeout=_request_timeout
|
|
103
|
+
)
|
|
104
|
+
response_data.read()
|
|
105
|
+
return self.api_client.response_deserialize(
|
|
106
|
+
response_data=response_data,
|
|
107
|
+
response_types_map=_response_types_map,
|
|
108
|
+
).data
|
|
109
|
+
|
|
110
|
+
|
|
111
|
+
@validate_call
|
|
112
|
+
def get_telescope_with_http_info(
|
|
113
|
+
self,
|
|
114
|
+
telescope_id: StrictStr,
|
|
115
|
+
_request_timeout: Union[
|
|
116
|
+
None,
|
|
117
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
118
|
+
Tuple[
|
|
119
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
120
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
121
|
+
]
|
|
122
|
+
] = None,
|
|
123
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
124
|
+
_content_type: Optional[StrictStr] = None,
|
|
125
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
126
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
127
|
+
) -> ApiResponse[Telescope]:
|
|
128
|
+
"""Read an telescope
|
|
129
|
+
|
|
130
|
+
Read a telescope by a telescope ID.
|
|
131
|
+
|
|
132
|
+
:param telescope_id: (required)
|
|
133
|
+
:type telescope_id: str
|
|
134
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
135
|
+
number provided, it will be total request
|
|
136
|
+
timeout. It can also be a pair (tuple) of
|
|
137
|
+
(connection, read) timeouts.
|
|
138
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
139
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
140
|
+
request; this effectively ignores the
|
|
141
|
+
authentication in the spec for a single request.
|
|
142
|
+
:type _request_auth: dict, optional
|
|
143
|
+
:param _content_type: force content-type for the request.
|
|
144
|
+
:type _content_type: str, Optional
|
|
145
|
+
:param _headers: set to override the headers for a single
|
|
146
|
+
request; this effectively ignores the headers
|
|
147
|
+
in the spec for a single request.
|
|
148
|
+
:type _headers: dict, optional
|
|
149
|
+
:param _host_index: set to override the host_index for a single
|
|
150
|
+
request; this effectively ignores the host_index
|
|
151
|
+
in the spec for a single request.
|
|
152
|
+
:type _host_index: int, optional
|
|
153
|
+
:return: Returns the result object.
|
|
154
|
+
""" # noqa: E501
|
|
155
|
+
|
|
156
|
+
_param = self._get_telescope_serialize(
|
|
157
|
+
telescope_id=telescope_id,
|
|
158
|
+
_request_auth=_request_auth,
|
|
159
|
+
_content_type=_content_type,
|
|
160
|
+
_headers=_headers,
|
|
161
|
+
_host_index=_host_index
|
|
162
|
+
)
|
|
163
|
+
|
|
164
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
165
|
+
'200': "Telescope",
|
|
166
|
+
'404': None,
|
|
167
|
+
'422': "HTTPValidationError",
|
|
168
|
+
}
|
|
169
|
+
response_data = self.api_client.call_api(
|
|
170
|
+
*_param,
|
|
171
|
+
_request_timeout=_request_timeout
|
|
172
|
+
)
|
|
173
|
+
response_data.read()
|
|
174
|
+
return self.api_client.response_deserialize(
|
|
175
|
+
response_data=response_data,
|
|
176
|
+
response_types_map=_response_types_map,
|
|
177
|
+
)
|
|
178
|
+
|
|
179
|
+
|
|
180
|
+
@validate_call
|
|
181
|
+
def get_telescope_without_preload_content(
|
|
182
|
+
self,
|
|
183
|
+
telescope_id: StrictStr,
|
|
184
|
+
_request_timeout: Union[
|
|
185
|
+
None,
|
|
186
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
187
|
+
Tuple[
|
|
188
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
189
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
190
|
+
]
|
|
191
|
+
] = None,
|
|
192
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
193
|
+
_content_type: Optional[StrictStr] = None,
|
|
194
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
195
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
196
|
+
) -> RESTResponseType:
|
|
197
|
+
"""Read an telescope
|
|
198
|
+
|
|
199
|
+
Read a telescope by a telescope ID.
|
|
200
|
+
|
|
201
|
+
:param telescope_id: (required)
|
|
202
|
+
:type telescope_id: str
|
|
203
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
204
|
+
number provided, it will be total request
|
|
205
|
+
timeout. It can also be a pair (tuple) of
|
|
206
|
+
(connection, read) timeouts.
|
|
207
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
208
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
209
|
+
request; this effectively ignores the
|
|
210
|
+
authentication in the spec for a single request.
|
|
211
|
+
:type _request_auth: dict, optional
|
|
212
|
+
:param _content_type: force content-type for the request.
|
|
213
|
+
:type _content_type: str, Optional
|
|
214
|
+
:param _headers: set to override the headers for a single
|
|
215
|
+
request; this effectively ignores the headers
|
|
216
|
+
in the spec for a single request.
|
|
217
|
+
:type _headers: dict, optional
|
|
218
|
+
:param _host_index: set to override the host_index for a single
|
|
219
|
+
request; this effectively ignores the host_index
|
|
220
|
+
in the spec for a single request.
|
|
221
|
+
:type _host_index: int, optional
|
|
222
|
+
:return: Returns the result object.
|
|
223
|
+
""" # noqa: E501
|
|
224
|
+
|
|
225
|
+
_param = self._get_telescope_serialize(
|
|
226
|
+
telescope_id=telescope_id,
|
|
227
|
+
_request_auth=_request_auth,
|
|
228
|
+
_content_type=_content_type,
|
|
229
|
+
_headers=_headers,
|
|
230
|
+
_host_index=_host_index
|
|
231
|
+
)
|
|
232
|
+
|
|
233
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
234
|
+
'200': "Telescope",
|
|
235
|
+
'404': None,
|
|
236
|
+
'422': "HTTPValidationError",
|
|
237
|
+
}
|
|
238
|
+
response_data = self.api_client.call_api(
|
|
239
|
+
*_param,
|
|
240
|
+
_request_timeout=_request_timeout
|
|
241
|
+
)
|
|
242
|
+
return response_data.response
|
|
243
|
+
|
|
244
|
+
|
|
245
|
+
def _get_telescope_serialize(
|
|
246
|
+
self,
|
|
247
|
+
telescope_id,
|
|
248
|
+
_request_auth,
|
|
249
|
+
_content_type,
|
|
250
|
+
_headers,
|
|
251
|
+
_host_index,
|
|
252
|
+
) -> RequestSerialized:
|
|
253
|
+
|
|
254
|
+
_host = None
|
|
255
|
+
|
|
256
|
+
_collection_formats: Dict[str, str] = {
|
|
257
|
+
}
|
|
258
|
+
|
|
259
|
+
_path_params: Dict[str, str] = {}
|
|
260
|
+
_query_params: List[Tuple[str, str]] = []
|
|
261
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
262
|
+
_form_params: List[Tuple[str, str]] = []
|
|
263
|
+
_files: Dict[
|
|
264
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
265
|
+
] = {}
|
|
266
|
+
_body_params: Optional[bytes] = None
|
|
267
|
+
|
|
268
|
+
# process the path parameters
|
|
269
|
+
if telescope_id is not None:
|
|
270
|
+
_path_params['telescope_id'] = telescope_id
|
|
271
|
+
# process the query parameters
|
|
272
|
+
# process the header parameters
|
|
273
|
+
# process the form parameters
|
|
274
|
+
# process the body parameter
|
|
275
|
+
|
|
276
|
+
|
|
277
|
+
# set the HTTP header `Accept`
|
|
278
|
+
if 'Accept' not in _header_params:
|
|
279
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
|
280
|
+
[
|
|
281
|
+
'application/json'
|
|
282
|
+
]
|
|
283
|
+
)
|
|
284
|
+
|
|
285
|
+
|
|
286
|
+
# authentication setting
|
|
287
|
+
_auth_settings: List[str] = [
|
|
288
|
+
]
|
|
289
|
+
|
|
290
|
+
return self.api_client.param_serialize(
|
|
291
|
+
method='GET',
|
|
292
|
+
resource_path='/telescope/{telescope_id}',
|
|
293
|
+
path_params=_path_params,
|
|
294
|
+
query_params=_query_params,
|
|
295
|
+
header_params=_header_params,
|
|
296
|
+
body=_body_params,
|
|
297
|
+
post_params=_form_params,
|
|
298
|
+
files=_files,
|
|
299
|
+
auth_settings=_auth_settings,
|
|
300
|
+
collection_formats=_collection_formats,
|
|
301
|
+
_host=_host,
|
|
302
|
+
_request_auth=_request_auth
|
|
303
|
+
)
|
|
304
|
+
|
|
305
|
+
|
|
306
|
+
|
|
307
|
+
|
|
308
|
+
@validate_call
|
|
309
|
+
def get_telescopes(
|
|
310
|
+
self,
|
|
311
|
+
name: Optional[StrictStr] = None,
|
|
312
|
+
instrument_id: Optional[StrictStr] = None,
|
|
313
|
+
instrument_name: Optional[StrictStr] = None,
|
|
314
|
+
created_on: Optional[datetime] = None,
|
|
315
|
+
include_filters: Optional[StrictBool] = None,
|
|
316
|
+
include_footprints: Optional[StrictBool] = None,
|
|
317
|
+
_request_timeout: Union[
|
|
318
|
+
None,
|
|
319
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
320
|
+
Tuple[
|
|
321
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
322
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
323
|
+
]
|
|
324
|
+
] = None,
|
|
325
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
326
|
+
_content_type: Optional[StrictStr] = None,
|
|
327
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
328
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
329
|
+
) -> List[Telescope]:
|
|
330
|
+
"""Read telescopes(s)
|
|
331
|
+
|
|
332
|
+
Read most recent telescopes based on query params
|
|
333
|
+
|
|
334
|
+
:param name:
|
|
335
|
+
:type name: str
|
|
336
|
+
:param instrument_id:
|
|
337
|
+
:type instrument_id: str
|
|
338
|
+
:param instrument_name:
|
|
339
|
+
:type instrument_name: str
|
|
340
|
+
:param created_on:
|
|
341
|
+
:type created_on: datetime
|
|
342
|
+
:param include_filters:
|
|
343
|
+
:type include_filters: bool
|
|
344
|
+
:param include_footprints:
|
|
345
|
+
:type include_footprints: bool
|
|
346
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
347
|
+
number provided, it will be total request
|
|
348
|
+
timeout. It can also be a pair (tuple) of
|
|
349
|
+
(connection, read) timeouts.
|
|
350
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
351
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
352
|
+
request; this effectively ignores the
|
|
353
|
+
authentication in the spec for a single request.
|
|
354
|
+
:type _request_auth: dict, optional
|
|
355
|
+
:param _content_type: force content-type for the request.
|
|
356
|
+
:type _content_type: str, Optional
|
|
357
|
+
:param _headers: set to override the headers for a single
|
|
358
|
+
request; this effectively ignores the headers
|
|
359
|
+
in the spec for a single request.
|
|
360
|
+
:type _headers: dict, optional
|
|
361
|
+
:param _host_index: set to override the host_index for a single
|
|
362
|
+
request; this effectively ignores the host_index
|
|
363
|
+
in the spec for a single request.
|
|
364
|
+
:type _host_index: int, optional
|
|
365
|
+
:return: Returns the result object.
|
|
366
|
+
""" # noqa: E501
|
|
367
|
+
|
|
368
|
+
_param = self._get_telescopes_serialize(
|
|
369
|
+
name=name,
|
|
370
|
+
instrument_id=instrument_id,
|
|
371
|
+
instrument_name=instrument_name,
|
|
372
|
+
created_on=created_on,
|
|
373
|
+
include_filters=include_filters,
|
|
374
|
+
include_footprints=include_footprints,
|
|
375
|
+
_request_auth=_request_auth,
|
|
376
|
+
_content_type=_content_type,
|
|
377
|
+
_headers=_headers,
|
|
378
|
+
_host_index=_host_index
|
|
379
|
+
)
|
|
380
|
+
|
|
381
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
382
|
+
'200': "List[Telescope]",
|
|
383
|
+
'404': None,
|
|
384
|
+
'422': "HTTPValidationError",
|
|
385
|
+
}
|
|
386
|
+
response_data = self.api_client.call_api(
|
|
387
|
+
*_param,
|
|
388
|
+
_request_timeout=_request_timeout
|
|
389
|
+
)
|
|
390
|
+
response_data.read()
|
|
391
|
+
return self.api_client.response_deserialize(
|
|
392
|
+
response_data=response_data,
|
|
393
|
+
response_types_map=_response_types_map,
|
|
394
|
+
).data
|
|
395
|
+
|
|
396
|
+
|
|
397
|
+
@validate_call
|
|
398
|
+
def get_telescopes_with_http_info(
|
|
399
|
+
self,
|
|
400
|
+
name: Optional[StrictStr] = None,
|
|
401
|
+
instrument_id: Optional[StrictStr] = None,
|
|
402
|
+
instrument_name: Optional[StrictStr] = None,
|
|
403
|
+
created_on: Optional[datetime] = None,
|
|
404
|
+
include_filters: Optional[StrictBool] = None,
|
|
405
|
+
include_footprints: Optional[StrictBool] = None,
|
|
406
|
+
_request_timeout: Union[
|
|
407
|
+
None,
|
|
408
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
409
|
+
Tuple[
|
|
410
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
411
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
412
|
+
]
|
|
413
|
+
] = None,
|
|
414
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
415
|
+
_content_type: Optional[StrictStr] = None,
|
|
416
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
417
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
418
|
+
) -> ApiResponse[List[Telescope]]:
|
|
419
|
+
"""Read telescopes(s)
|
|
420
|
+
|
|
421
|
+
Read most recent telescopes based on query params
|
|
422
|
+
|
|
423
|
+
:param name:
|
|
424
|
+
:type name: str
|
|
425
|
+
:param instrument_id:
|
|
426
|
+
:type instrument_id: str
|
|
427
|
+
:param instrument_name:
|
|
428
|
+
:type instrument_name: str
|
|
429
|
+
:param created_on:
|
|
430
|
+
:type created_on: datetime
|
|
431
|
+
:param include_filters:
|
|
432
|
+
:type include_filters: bool
|
|
433
|
+
:param include_footprints:
|
|
434
|
+
:type include_footprints: bool
|
|
435
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
436
|
+
number provided, it will be total request
|
|
437
|
+
timeout. It can also be a pair (tuple) of
|
|
438
|
+
(connection, read) timeouts.
|
|
439
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
440
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
441
|
+
request; this effectively ignores the
|
|
442
|
+
authentication in the spec for a single request.
|
|
443
|
+
:type _request_auth: dict, optional
|
|
444
|
+
:param _content_type: force content-type for the request.
|
|
445
|
+
:type _content_type: str, Optional
|
|
446
|
+
:param _headers: set to override the headers for a single
|
|
447
|
+
request; this effectively ignores the headers
|
|
448
|
+
in the spec for a single request.
|
|
449
|
+
:type _headers: dict, optional
|
|
450
|
+
:param _host_index: set to override the host_index for a single
|
|
451
|
+
request; this effectively ignores the host_index
|
|
452
|
+
in the spec for a single request.
|
|
453
|
+
:type _host_index: int, optional
|
|
454
|
+
:return: Returns the result object.
|
|
455
|
+
""" # noqa: E501
|
|
456
|
+
|
|
457
|
+
_param = self._get_telescopes_serialize(
|
|
458
|
+
name=name,
|
|
459
|
+
instrument_id=instrument_id,
|
|
460
|
+
instrument_name=instrument_name,
|
|
461
|
+
created_on=created_on,
|
|
462
|
+
include_filters=include_filters,
|
|
463
|
+
include_footprints=include_footprints,
|
|
464
|
+
_request_auth=_request_auth,
|
|
465
|
+
_content_type=_content_type,
|
|
466
|
+
_headers=_headers,
|
|
467
|
+
_host_index=_host_index
|
|
468
|
+
)
|
|
469
|
+
|
|
470
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
471
|
+
'200': "List[Telescope]",
|
|
472
|
+
'404': None,
|
|
473
|
+
'422': "HTTPValidationError",
|
|
474
|
+
}
|
|
475
|
+
response_data = self.api_client.call_api(
|
|
476
|
+
*_param,
|
|
477
|
+
_request_timeout=_request_timeout
|
|
478
|
+
)
|
|
479
|
+
response_data.read()
|
|
480
|
+
return self.api_client.response_deserialize(
|
|
481
|
+
response_data=response_data,
|
|
482
|
+
response_types_map=_response_types_map,
|
|
483
|
+
)
|
|
484
|
+
|
|
485
|
+
|
|
486
|
+
@validate_call
|
|
487
|
+
def get_telescopes_without_preload_content(
|
|
488
|
+
self,
|
|
489
|
+
name: Optional[StrictStr] = None,
|
|
490
|
+
instrument_id: Optional[StrictStr] = None,
|
|
491
|
+
instrument_name: Optional[StrictStr] = None,
|
|
492
|
+
created_on: Optional[datetime] = None,
|
|
493
|
+
include_filters: Optional[StrictBool] = None,
|
|
494
|
+
include_footprints: Optional[StrictBool] = None,
|
|
495
|
+
_request_timeout: Union[
|
|
496
|
+
None,
|
|
497
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
498
|
+
Tuple[
|
|
499
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
500
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
501
|
+
]
|
|
502
|
+
] = None,
|
|
503
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
504
|
+
_content_type: Optional[StrictStr] = None,
|
|
505
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
506
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
507
|
+
) -> RESTResponseType:
|
|
508
|
+
"""Read telescopes(s)
|
|
509
|
+
|
|
510
|
+
Read most recent telescopes based on query params
|
|
511
|
+
|
|
512
|
+
:param name:
|
|
513
|
+
:type name: str
|
|
514
|
+
:param instrument_id:
|
|
515
|
+
:type instrument_id: str
|
|
516
|
+
:param instrument_name:
|
|
517
|
+
:type instrument_name: str
|
|
518
|
+
:param created_on:
|
|
519
|
+
:type created_on: datetime
|
|
520
|
+
:param include_filters:
|
|
521
|
+
:type include_filters: bool
|
|
522
|
+
:param include_footprints:
|
|
523
|
+
:type include_footprints: bool
|
|
524
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
525
|
+
number provided, it will be total request
|
|
526
|
+
timeout. It can also be a pair (tuple) of
|
|
527
|
+
(connection, read) timeouts.
|
|
528
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
529
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
530
|
+
request; this effectively ignores the
|
|
531
|
+
authentication in the spec for a single request.
|
|
532
|
+
:type _request_auth: dict, optional
|
|
533
|
+
:param _content_type: force content-type for the request.
|
|
534
|
+
:type _content_type: str, Optional
|
|
535
|
+
:param _headers: set to override the headers for a single
|
|
536
|
+
request; this effectively ignores the headers
|
|
537
|
+
in the spec for a single request.
|
|
538
|
+
:type _headers: dict, optional
|
|
539
|
+
:param _host_index: set to override the host_index for a single
|
|
540
|
+
request; this effectively ignores the host_index
|
|
541
|
+
in the spec for a single request.
|
|
542
|
+
:type _host_index: int, optional
|
|
543
|
+
:return: Returns the result object.
|
|
544
|
+
""" # noqa: E501
|
|
545
|
+
|
|
546
|
+
_param = self._get_telescopes_serialize(
|
|
547
|
+
name=name,
|
|
548
|
+
instrument_id=instrument_id,
|
|
549
|
+
instrument_name=instrument_name,
|
|
550
|
+
created_on=created_on,
|
|
551
|
+
include_filters=include_filters,
|
|
552
|
+
include_footprints=include_footprints,
|
|
553
|
+
_request_auth=_request_auth,
|
|
554
|
+
_content_type=_content_type,
|
|
555
|
+
_headers=_headers,
|
|
556
|
+
_host_index=_host_index
|
|
557
|
+
)
|
|
558
|
+
|
|
559
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
560
|
+
'200': "List[Telescope]",
|
|
561
|
+
'404': None,
|
|
562
|
+
'422': "HTTPValidationError",
|
|
563
|
+
}
|
|
564
|
+
response_data = self.api_client.call_api(
|
|
565
|
+
*_param,
|
|
566
|
+
_request_timeout=_request_timeout
|
|
567
|
+
)
|
|
568
|
+
return response_data.response
|
|
569
|
+
|
|
570
|
+
|
|
571
|
+
def _get_telescopes_serialize(
|
|
572
|
+
self,
|
|
573
|
+
name,
|
|
574
|
+
instrument_id,
|
|
575
|
+
instrument_name,
|
|
576
|
+
created_on,
|
|
577
|
+
include_filters,
|
|
578
|
+
include_footprints,
|
|
579
|
+
_request_auth,
|
|
580
|
+
_content_type,
|
|
581
|
+
_headers,
|
|
582
|
+
_host_index,
|
|
583
|
+
) -> RequestSerialized:
|
|
584
|
+
|
|
585
|
+
_host = None
|
|
586
|
+
|
|
587
|
+
_collection_formats: Dict[str, str] = {
|
|
588
|
+
}
|
|
589
|
+
|
|
590
|
+
_path_params: Dict[str, str] = {}
|
|
591
|
+
_query_params: List[Tuple[str, str]] = []
|
|
592
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
593
|
+
_form_params: List[Tuple[str, str]] = []
|
|
594
|
+
_files: Dict[
|
|
595
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
596
|
+
] = {}
|
|
597
|
+
_body_params: Optional[bytes] = None
|
|
598
|
+
|
|
599
|
+
# process the path parameters
|
|
600
|
+
# process the query parameters
|
|
601
|
+
if name is not None:
|
|
602
|
+
|
|
603
|
+
_query_params.append(('name', name))
|
|
604
|
+
|
|
605
|
+
if instrument_id is not None:
|
|
606
|
+
|
|
607
|
+
_query_params.append(('instrument_id', instrument_id))
|
|
608
|
+
|
|
609
|
+
if instrument_name is not None:
|
|
610
|
+
|
|
611
|
+
_query_params.append(('instrument_name', instrument_name))
|
|
612
|
+
|
|
613
|
+
if created_on is not None:
|
|
614
|
+
if isinstance(created_on, datetime):
|
|
615
|
+
_query_params.append(
|
|
616
|
+
(
|
|
617
|
+
'created_on',
|
|
618
|
+
created_on.strftime(
|
|
619
|
+
self.api_client.configuration.datetime_format
|
|
620
|
+
)
|
|
621
|
+
)
|
|
622
|
+
)
|
|
623
|
+
else:
|
|
624
|
+
_query_params.append(('created_on', created_on))
|
|
625
|
+
|
|
626
|
+
if include_filters is not None:
|
|
627
|
+
|
|
628
|
+
_query_params.append(('include_filters', include_filters))
|
|
629
|
+
|
|
630
|
+
if include_footprints is not None:
|
|
631
|
+
|
|
632
|
+
_query_params.append(('include_footprints', include_footprints))
|
|
633
|
+
|
|
634
|
+
# process the header parameters
|
|
635
|
+
# process the form parameters
|
|
636
|
+
# process the body parameter
|
|
637
|
+
|
|
638
|
+
|
|
639
|
+
# set the HTTP header `Accept`
|
|
640
|
+
if 'Accept' not in _header_params:
|
|
641
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
|
642
|
+
[
|
|
643
|
+
'application/json'
|
|
644
|
+
]
|
|
645
|
+
)
|
|
646
|
+
|
|
647
|
+
|
|
648
|
+
# authentication setting
|
|
649
|
+
_auth_settings: List[str] = [
|
|
650
|
+
]
|
|
651
|
+
|
|
652
|
+
return self.api_client.param_serialize(
|
|
653
|
+
method='GET',
|
|
654
|
+
resource_path='/telescope/',
|
|
655
|
+
path_params=_path_params,
|
|
656
|
+
query_params=_query_params,
|
|
657
|
+
header_params=_header_params,
|
|
658
|
+
body=_body_params,
|
|
659
|
+
post_params=_form_params,
|
|
660
|
+
files=_files,
|
|
661
|
+
auth_settings=_auth_settings,
|
|
662
|
+
collection_formats=_collection_formats,
|
|
663
|
+
_host=_host,
|
|
664
|
+
_request_auth=_request_auth
|
|
665
|
+
)
|
|
666
|
+
|
|
667
|
+
|