samplehc 0.17.0__py3-none-any.whl → 0.19.0__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.
- samplehc/_base_client.py +5 -2
- samplehc/_client.py +1 -38
- samplehc/_compat.py +3 -3
- samplehc/_utils/_json.py +35 -0
- samplehc/_version.py +1 -1
- samplehc/resources/__init__.py +0 -14
- samplehc/resources/v2/__init__.py +0 -98
- samplehc/resources/v2/async_results.py +0 -79
- samplehc/resources/v2/documents/__init__.py +0 -14
- samplehc/resources/v2/documents/documents.py +44 -196
- samplehc/resources/v2/v2.py +0 -224
- samplehc/types/__init__.py +0 -5
- samplehc/types/v2/__init__.py +0 -53
- samplehc/types/v2/document_extract_params.py +20 -1
- samplehc/types/v2/documents/__init__.py +0 -3
- {samplehc-0.17.0.dist-info → samplehc-0.19.0.dist-info}/METADATA +22 -27
- samplehc-0.19.0.dist-info/RECORD +93 -0
- samplehc/resources/v1/__init__.py +0 -19
- samplehc/resources/v1/v1.py +0 -298
- samplehc/resources/v2/clearinghouse/__init__.py +0 -47
- samplehc/resources/v2/clearinghouse/claim.py +0 -407
- samplehc/resources/v2/clearinghouse/clearinghouse.py +0 -844
- samplehc/resources/v2/clearinghouse/payers.py +0 -224
- samplehc/resources/v2/documents/pdf_template.py +0 -165
- samplehc/resources/v2/hie/__init__.py +0 -47
- samplehc/resources/v2/hie/adt.py +0 -249
- samplehc/resources/v2/hie/documents.py +0 -390
- samplehc/resources/v2/hie/hie.py +0 -134
- samplehc/resources/v2/integrations/__init__.py +0 -131
- samplehc/resources/v2/integrations/bank/__init__.py +0 -33
- samplehc/resources/v2/integrations/bank/bank.py +0 -102
- samplehc/resources/v2/integrations/bank/transactions.py +0 -185
- samplehc/resources/v2/integrations/careviso.py +0 -372
- samplehc/resources/v2/integrations/glidian/__init__.py +0 -33
- samplehc/resources/v2/integrations/glidian/glidian.py +0 -425
- samplehc/resources/v2/integrations/glidian/prior_authorizations/__init__.py +0 -33
- samplehc/resources/v2/integrations/glidian/prior_authorizations/clinical_questions.py +0 -276
- samplehc/resources/v2/integrations/glidian/prior_authorizations/prior_authorizations.py +0 -527
- samplehc/resources/v2/integrations/integrations.py +0 -326
- samplehc/resources/v2/integrations/kno2/__init__.py +0 -33
- samplehc/resources/v2/integrations/kno2/kno2.py +0 -102
- samplehc/resources/v2/integrations/kno2/messages.py +0 -260
- samplehc/resources/v2/integrations/salesforce.py +0 -277
- samplehc/resources/v2/integrations/snowflake.py +0 -173
- samplehc/resources/v2/integrations/wellsky/__init__.py +0 -33
- samplehc/resources/v2/integrations/wellsky/patients.py +0 -324
- samplehc/resources/v2/integrations/wellsky/wellsky.py +0 -102
- samplehc/resources/v2/integrations/xcures.py +0 -197
- samplehc/resources/v2/policies.py +0 -655
- samplehc/resources/v2/tasks/__init__.py +0 -33
- samplehc/resources/v2/tasks/state.py +0 -266
- samplehc/resources/v2/tasks/tasks.py +0 -754
- samplehc/resources/v2/workflow_runs/__init__.py +0 -33
- samplehc/resources/v2/workflow_runs/step.py +0 -169
- samplehc/resources/v2/workflow_runs/workflow_runs.py +0 -479
- samplehc/resources/v2/workflows.py +0 -377
- samplehc/types/v1/__init__.py +0 -3
- samplehc/types/v1_query_audit_logs_params.py +0 -12
- samplehc/types/v1_query_audit_logs_response.py +0 -16
- samplehc/types/v1_sql_execute_params.py +0 -27
- samplehc/types/v1_sql_execute_response.py +0 -27
- samplehc/types/v2/async_result_retrieve_response.py +0 -18
- samplehc/types/v2/clearinghouse/__init__.py +0 -9
- samplehc/types/v2/clearinghouse/claim_submit_params.py +0 -2693
- samplehc/types/v2/clearinghouse/claim_submit_response.py +0 -23
- samplehc/types/v2/clearinghouse/payer_list_response.py +0 -27
- samplehc/types/v2/clearinghouse/payer_search_params.py +0 -12
- samplehc/types/v2/clearinghouse/payer_search_response.py +0 -33
- samplehc/types/v2/clearinghouse_calculate_patient_cost_params.py +0 -3129
- samplehc/types/v2/clearinghouse_check_claim_status_params.py +0 -41
- samplehc/types/v2/clearinghouse_check_eligibility_params.py +0 -36
- samplehc/types/v2/clearinghouse_check_eligibility_response.py +0 -15
- samplehc/types/v2/clearinghouse_coordination_of_benefits_params.py +0 -35
- samplehc/types/v2/clearinghouse_run_discovery_params.py +0 -59
- samplehc/types/v2/clearinghouse_run_discovery_response.py +0 -13
- samplehc/types/v2/document_unzip_async_response.py +0 -12
- samplehc/types/v2/document_unzip_response.py +0 -20
- samplehc/types/v2/documents/pdf_template_retrieve_metadata_response.py +0 -17
- samplehc/types/v2/hie/__init__.py +0 -8
- samplehc/types/v2/hie/adt_subscribe_params.py +0 -92
- samplehc/types/v2/hie/document_query_params.py +0 -92
- samplehc/types/v2/hie/document_query_response.py +0 -16
- samplehc/types/v2/hie/document_upload_params.py +0 -54
- samplehc/types/v2/integrations/__init__.py +0 -23
- samplehc/types/v2/integrations/bank/__init__.py +0 -6
- samplehc/types/v2/integrations/bank/transaction_sync_params.py +0 -15
- samplehc/types/v2/integrations/bank/transaction_sync_response.py +0 -26
- samplehc/types/v2/integrations/careviso_get_payers_response.py +0 -19
- samplehc/types/v2/integrations/careviso_submit_prior_authorization_params.py +0 -90
- samplehc/types/v2/integrations/glidian/__init__.py +0 -20
- samplehc/types/v2/integrations/glidian/prior_authorization_create_draft_params.py +0 -32
- samplehc/types/v2/integrations/glidian/prior_authorization_create_draft_response.py +0 -24
- samplehc/types/v2/integrations/glidian/prior_authorization_retrieve_record_response.py +0 -13
- samplehc/types/v2/integrations/glidian/prior_authorization_submit_response.py +0 -16
- samplehc/types/v2/integrations/glidian/prior_authorization_update_record_params.py +0 -20
- samplehc/types/v2/integrations/glidian/prior_authorization_update_record_response.py +0 -16
- samplehc/types/v2/integrations/glidian/prior_authorizations/__init__.py +0 -7
- samplehc/types/v2/integrations/glidian/prior_authorizations/clinical_question_list_response.py +0 -42
- samplehc/types/v2/integrations/glidian/prior_authorizations/clinical_question_update_params.py +0 -23
- samplehc/types/v2/integrations/glidian/prior_authorizations/clinical_question_update_response.py +0 -19
- samplehc/types/v2/integrations/glidian_get_submission_requirements_params.py +0 -17
- samplehc/types/v2/integrations/glidian_get_submission_requirements_response.py +0 -31
- samplehc/types/v2/integrations/glidian_list_payers_params.py +0 -11
- samplehc/types/v2/integrations/glidian_list_payers_response.py +0 -17
- samplehc/types/v2/integrations/glidian_list_services_params.py +0 -13
- samplehc/types/v2/integrations/glidian_list_services_response.py +0 -19
- samplehc/types/v2/integrations/kno2/__init__.py +0 -6
- samplehc/types/v2/integrations/kno2/message_get_attachment_response.py +0 -15
- samplehc/types/v2/integrations/kno2/message_retrieve_response.py +0 -13
- samplehc/types/v2/integrations/salesforce_run_crud_action_params.py +0 -22
- samplehc/types/v2/integrations/salesforce_run_soql_query_params.py +0 -11
- samplehc/types/v2/integrations/snowflake_query_params.py +0 -12
- samplehc/types/v2/integrations/snowflake_query_response.py +0 -8
- samplehc/types/v2/integrations/wellsky/__init__.py +0 -6
- samplehc/types/v2/integrations/wellsky/patient_add_params.py +0 -13
- samplehc/types/v2/integrations/wellsky/patient_search_params.py +0 -32
- samplehc/types/v2/integrations/xcure_make_request_params.py +0 -18
- samplehc/types/v2/ledger/__init__.py +0 -3
- samplehc/types/v2/policy_list_companies_params.py +0 -18
- samplehc/types/v2/policy_list_companies_response.py +0 -24
- samplehc/types/v2/policy_list_params.py +0 -47
- samplehc/types/v2/policy_list_plans_params.py +0 -18
- samplehc/types/v2/policy_list_plans_response.py +0 -30
- samplehc/types/v2/policy_list_response.py +0 -67
- samplehc/types/v2/policy_retrieve_presigned_url_response.py +0 -17
- samplehc/types/v2/policy_retrieve_text_response.py +0 -12
- samplehc/types/v2/task_cancel_response.py +0 -12
- samplehc/types/v2/task_complete_params.py +0 -12
- samplehc/types/v2/task_complete_response.py +0 -16
- samplehc/types/v2/task_get_suspended_payload_response.py +0 -8
- samplehc/types/v2/task_retrieve_response.py +0 -22
- samplehc/types/v2/task_retry_response.py +0 -10
- samplehc/types/v2/task_update_column_params.py +0 -19
- samplehc/types/v2/task_update_column_response.py +0 -9
- samplehc/types/v2/task_update_screen_time_params.py +0 -14
- samplehc/types/v2/task_update_screen_time_response.py +0 -8
- samplehc/types/v2/tasks/__init__.py +0 -7
- samplehc/types/v2/tasks/state_get_response.py +0 -8
- samplehc/types/v2/tasks/state_update_params.py +0 -13
- samplehc/types/v2/tasks/state_update_response.py +0 -9
- samplehc/types/v2/workflow_deploy_response.py +0 -12
- samplehc/types/v2/workflow_query_params.py +0 -12
- samplehc/types/v2/workflow_query_response.py +0 -8
- samplehc/types/v2/workflow_run_get_start_data_response.py +0 -14
- samplehc/types/v2/workflow_run_resume_when_complete_params.py +0 -14
- samplehc/types/v2/workflow_run_resume_when_complete_response.py +0 -12
- samplehc/types/v2/workflow_run_retrieve_response.py +0 -16
- samplehc/types/v2/workflow_runs/__init__.py +0 -5
- samplehc/types/v2/workflow_runs/step_get_output_response.py +0 -14
- samplehc/types/v2/workflow_start_params.py +0 -25
- samplehc/types/v2/workflow_start_response.py +0 -25
- samplehc-0.17.0.dist-info/RECORD +0 -226
- {samplehc-0.17.0.dist-info → samplehc-0.19.0.dist-info}/WHEEL +0 -0
- {samplehc-0.17.0.dist-info → samplehc-0.19.0.dist-info}/licenses/LICENSE +0 -0
samplehc/resources/v2/v2.py
CHANGED
|
@@ -10,14 +10,6 @@ from .events import (
|
|
|
10
10
|
EventsResourceWithStreamingResponse,
|
|
11
11
|
AsyncEventsResourceWithStreamingResponse,
|
|
12
12
|
)
|
|
13
|
-
from .hie.hie import (
|
|
14
|
-
HieResource,
|
|
15
|
-
AsyncHieResource,
|
|
16
|
-
HieResourceWithRawResponse,
|
|
17
|
-
AsyncHieResourceWithRawResponse,
|
|
18
|
-
HieResourceWithStreamingResponse,
|
|
19
|
-
AsyncHieResourceWithStreamingResponse,
|
|
20
|
-
)
|
|
21
13
|
from .database import (
|
|
22
14
|
DatabaseResource,
|
|
23
15
|
AsyncDatabaseResource,
|
|
@@ -26,32 +18,8 @@ from .database import (
|
|
|
26
18
|
DatabaseResourceWithStreamingResponse,
|
|
27
19
|
AsyncDatabaseResourceWithStreamingResponse,
|
|
28
20
|
)
|
|
29
|
-
from .policies import (
|
|
30
|
-
PoliciesResource,
|
|
31
|
-
AsyncPoliciesResource,
|
|
32
|
-
PoliciesResourceWithRawResponse,
|
|
33
|
-
AsyncPoliciesResourceWithRawResponse,
|
|
34
|
-
PoliciesResourceWithStreamingResponse,
|
|
35
|
-
AsyncPoliciesResourceWithStreamingResponse,
|
|
36
|
-
)
|
|
37
21
|
from ..._compat import cached_property
|
|
38
|
-
from .workflows import (
|
|
39
|
-
WorkflowsResource,
|
|
40
|
-
AsyncWorkflowsResource,
|
|
41
|
-
WorkflowsResourceWithRawResponse,
|
|
42
|
-
AsyncWorkflowsResourceWithRawResponse,
|
|
43
|
-
WorkflowsResourceWithStreamingResponse,
|
|
44
|
-
AsyncWorkflowsResourceWithStreamingResponse,
|
|
45
|
-
)
|
|
46
22
|
from ..._resource import SyncAPIResource, AsyncAPIResource
|
|
47
|
-
from .tasks.tasks import (
|
|
48
|
-
TasksResource,
|
|
49
|
-
AsyncTasksResource,
|
|
50
|
-
TasksResourceWithRawResponse,
|
|
51
|
-
AsyncTasksResourceWithRawResponse,
|
|
52
|
-
TasksResourceWithStreamingResponse,
|
|
53
|
-
AsyncTasksResourceWithStreamingResponse,
|
|
54
|
-
)
|
|
55
23
|
from .async_results import (
|
|
56
24
|
AsyncResultsResource,
|
|
57
25
|
AsyncAsyncResultsResource,
|
|
@@ -76,30 +44,6 @@ from .documents.documents import (
|
|
|
76
44
|
DocumentsResourceWithStreamingResponse,
|
|
77
45
|
AsyncDocumentsResourceWithStreamingResponse,
|
|
78
46
|
)
|
|
79
|
-
from .integrations.integrations import (
|
|
80
|
-
IntegrationsResource,
|
|
81
|
-
AsyncIntegrationsResource,
|
|
82
|
-
IntegrationsResourceWithRawResponse,
|
|
83
|
-
AsyncIntegrationsResourceWithRawResponse,
|
|
84
|
-
IntegrationsResourceWithStreamingResponse,
|
|
85
|
-
AsyncIntegrationsResourceWithStreamingResponse,
|
|
86
|
-
)
|
|
87
|
-
from .clearinghouse.clearinghouse import (
|
|
88
|
-
ClearinghouseResource,
|
|
89
|
-
AsyncClearinghouseResource,
|
|
90
|
-
ClearinghouseResourceWithRawResponse,
|
|
91
|
-
AsyncClearinghouseResourceWithRawResponse,
|
|
92
|
-
ClearinghouseResourceWithStreamingResponse,
|
|
93
|
-
AsyncClearinghouseResourceWithStreamingResponse,
|
|
94
|
-
)
|
|
95
|
-
from .workflow_runs.workflow_runs import (
|
|
96
|
-
WorkflowRunsResource,
|
|
97
|
-
AsyncWorkflowRunsResource,
|
|
98
|
-
WorkflowRunsResourceWithRawResponse,
|
|
99
|
-
AsyncWorkflowRunsResourceWithRawResponse,
|
|
100
|
-
WorkflowRunsResourceWithStreamingResponse,
|
|
101
|
-
AsyncWorkflowRunsResourceWithStreamingResponse,
|
|
102
|
-
)
|
|
103
47
|
|
|
104
48
|
__all__ = ["V2Resource", "AsyncV2Resource"]
|
|
105
49
|
|
|
@@ -109,18 +53,6 @@ class V2Resource(SyncAPIResource):
|
|
|
109
53
|
def async_results(self) -> AsyncResultsResource:
|
|
110
54
|
return AsyncResultsResource(self._client)
|
|
111
55
|
|
|
112
|
-
@cached_property
|
|
113
|
-
def workflow_runs(self) -> WorkflowRunsResource:
|
|
114
|
-
return WorkflowRunsResource(self._client)
|
|
115
|
-
|
|
116
|
-
@cached_property
|
|
117
|
-
def tasks(self) -> TasksResource:
|
|
118
|
-
return TasksResource(self._client)
|
|
119
|
-
|
|
120
|
-
@cached_property
|
|
121
|
-
def workflows(self) -> WorkflowsResource:
|
|
122
|
-
return WorkflowsResource(self._client)
|
|
123
|
-
|
|
124
56
|
@cached_property
|
|
125
57
|
def documents(self) -> DocumentsResource:
|
|
126
58
|
return DocumentsResource(self._client)
|
|
@@ -129,26 +61,10 @@ class V2Resource(SyncAPIResource):
|
|
|
129
61
|
def communication(self) -> CommunicationResource:
|
|
130
62
|
return CommunicationResource(self._client)
|
|
131
63
|
|
|
132
|
-
@cached_property
|
|
133
|
-
def clearinghouse(self) -> ClearinghouseResource:
|
|
134
|
-
return ClearinghouseResource(self._client)
|
|
135
|
-
|
|
136
|
-
@cached_property
|
|
137
|
-
def integrations(self) -> IntegrationsResource:
|
|
138
|
-
return IntegrationsResource(self._client)
|
|
139
|
-
|
|
140
64
|
@cached_property
|
|
141
65
|
def events(self) -> EventsResource:
|
|
142
66
|
return EventsResource(self._client)
|
|
143
67
|
|
|
144
|
-
@cached_property
|
|
145
|
-
def policies(self) -> PoliciesResource:
|
|
146
|
-
return PoliciesResource(self._client)
|
|
147
|
-
|
|
148
|
-
@cached_property
|
|
149
|
-
def hie(self) -> HieResource:
|
|
150
|
-
return HieResource(self._client)
|
|
151
|
-
|
|
152
68
|
@cached_property
|
|
153
69
|
def database(self) -> DatabaseResource:
|
|
154
70
|
return DatabaseResource(self._client)
|
|
@@ -178,18 +94,6 @@ class AsyncV2Resource(AsyncAPIResource):
|
|
|
178
94
|
def async_results(self) -> AsyncAsyncResultsResource:
|
|
179
95
|
return AsyncAsyncResultsResource(self._client)
|
|
180
96
|
|
|
181
|
-
@cached_property
|
|
182
|
-
def workflow_runs(self) -> AsyncWorkflowRunsResource:
|
|
183
|
-
return AsyncWorkflowRunsResource(self._client)
|
|
184
|
-
|
|
185
|
-
@cached_property
|
|
186
|
-
def tasks(self) -> AsyncTasksResource:
|
|
187
|
-
return AsyncTasksResource(self._client)
|
|
188
|
-
|
|
189
|
-
@cached_property
|
|
190
|
-
def workflows(self) -> AsyncWorkflowsResource:
|
|
191
|
-
return AsyncWorkflowsResource(self._client)
|
|
192
|
-
|
|
193
97
|
@cached_property
|
|
194
98
|
def documents(self) -> AsyncDocumentsResource:
|
|
195
99
|
return AsyncDocumentsResource(self._client)
|
|
@@ -198,26 +102,10 @@ class AsyncV2Resource(AsyncAPIResource):
|
|
|
198
102
|
def communication(self) -> AsyncCommunicationResource:
|
|
199
103
|
return AsyncCommunicationResource(self._client)
|
|
200
104
|
|
|
201
|
-
@cached_property
|
|
202
|
-
def clearinghouse(self) -> AsyncClearinghouseResource:
|
|
203
|
-
return AsyncClearinghouseResource(self._client)
|
|
204
|
-
|
|
205
|
-
@cached_property
|
|
206
|
-
def integrations(self) -> AsyncIntegrationsResource:
|
|
207
|
-
return AsyncIntegrationsResource(self._client)
|
|
208
|
-
|
|
209
105
|
@cached_property
|
|
210
106
|
def events(self) -> AsyncEventsResource:
|
|
211
107
|
return AsyncEventsResource(self._client)
|
|
212
108
|
|
|
213
|
-
@cached_property
|
|
214
|
-
def policies(self) -> AsyncPoliciesResource:
|
|
215
|
-
return AsyncPoliciesResource(self._client)
|
|
216
|
-
|
|
217
|
-
@cached_property
|
|
218
|
-
def hie(self) -> AsyncHieResource:
|
|
219
|
-
return AsyncHieResource(self._client)
|
|
220
|
-
|
|
221
109
|
@cached_property
|
|
222
110
|
def database(self) -> AsyncDatabaseResource:
|
|
223
111
|
return AsyncDatabaseResource(self._client)
|
|
@@ -250,18 +138,6 @@ class V2ResourceWithRawResponse:
|
|
|
250
138
|
def async_results(self) -> AsyncResultsResourceWithRawResponse:
|
|
251
139
|
return AsyncResultsResourceWithRawResponse(self._v2.async_results)
|
|
252
140
|
|
|
253
|
-
@cached_property
|
|
254
|
-
def workflow_runs(self) -> WorkflowRunsResourceWithRawResponse:
|
|
255
|
-
return WorkflowRunsResourceWithRawResponse(self._v2.workflow_runs)
|
|
256
|
-
|
|
257
|
-
@cached_property
|
|
258
|
-
def tasks(self) -> TasksResourceWithRawResponse:
|
|
259
|
-
return TasksResourceWithRawResponse(self._v2.tasks)
|
|
260
|
-
|
|
261
|
-
@cached_property
|
|
262
|
-
def workflows(self) -> WorkflowsResourceWithRawResponse:
|
|
263
|
-
return WorkflowsResourceWithRawResponse(self._v2.workflows)
|
|
264
|
-
|
|
265
141
|
@cached_property
|
|
266
142
|
def documents(self) -> DocumentsResourceWithRawResponse:
|
|
267
143
|
return DocumentsResourceWithRawResponse(self._v2.documents)
|
|
@@ -270,26 +146,10 @@ class V2ResourceWithRawResponse:
|
|
|
270
146
|
def communication(self) -> CommunicationResourceWithRawResponse:
|
|
271
147
|
return CommunicationResourceWithRawResponse(self._v2.communication)
|
|
272
148
|
|
|
273
|
-
@cached_property
|
|
274
|
-
def clearinghouse(self) -> ClearinghouseResourceWithRawResponse:
|
|
275
|
-
return ClearinghouseResourceWithRawResponse(self._v2.clearinghouse)
|
|
276
|
-
|
|
277
|
-
@cached_property
|
|
278
|
-
def integrations(self) -> IntegrationsResourceWithRawResponse:
|
|
279
|
-
return IntegrationsResourceWithRawResponse(self._v2.integrations)
|
|
280
|
-
|
|
281
149
|
@cached_property
|
|
282
150
|
def events(self) -> EventsResourceWithRawResponse:
|
|
283
151
|
return EventsResourceWithRawResponse(self._v2.events)
|
|
284
152
|
|
|
285
|
-
@cached_property
|
|
286
|
-
def policies(self) -> PoliciesResourceWithRawResponse:
|
|
287
|
-
return PoliciesResourceWithRawResponse(self._v2.policies)
|
|
288
|
-
|
|
289
|
-
@cached_property
|
|
290
|
-
def hie(self) -> HieResourceWithRawResponse:
|
|
291
|
-
return HieResourceWithRawResponse(self._v2.hie)
|
|
292
|
-
|
|
293
153
|
@cached_property
|
|
294
154
|
def database(self) -> DatabaseResourceWithRawResponse:
|
|
295
155
|
return DatabaseResourceWithRawResponse(self._v2.database)
|
|
@@ -303,18 +163,6 @@ class AsyncV2ResourceWithRawResponse:
|
|
|
303
163
|
def async_results(self) -> AsyncAsyncResultsResourceWithRawResponse:
|
|
304
164
|
return AsyncAsyncResultsResourceWithRawResponse(self._v2.async_results)
|
|
305
165
|
|
|
306
|
-
@cached_property
|
|
307
|
-
def workflow_runs(self) -> AsyncWorkflowRunsResourceWithRawResponse:
|
|
308
|
-
return AsyncWorkflowRunsResourceWithRawResponse(self._v2.workflow_runs)
|
|
309
|
-
|
|
310
|
-
@cached_property
|
|
311
|
-
def tasks(self) -> AsyncTasksResourceWithRawResponse:
|
|
312
|
-
return AsyncTasksResourceWithRawResponse(self._v2.tasks)
|
|
313
|
-
|
|
314
|
-
@cached_property
|
|
315
|
-
def workflows(self) -> AsyncWorkflowsResourceWithRawResponse:
|
|
316
|
-
return AsyncWorkflowsResourceWithRawResponse(self._v2.workflows)
|
|
317
|
-
|
|
318
166
|
@cached_property
|
|
319
167
|
def documents(self) -> AsyncDocumentsResourceWithRawResponse:
|
|
320
168
|
return AsyncDocumentsResourceWithRawResponse(self._v2.documents)
|
|
@@ -323,26 +171,10 @@ class AsyncV2ResourceWithRawResponse:
|
|
|
323
171
|
def communication(self) -> AsyncCommunicationResourceWithRawResponse:
|
|
324
172
|
return AsyncCommunicationResourceWithRawResponse(self._v2.communication)
|
|
325
173
|
|
|
326
|
-
@cached_property
|
|
327
|
-
def clearinghouse(self) -> AsyncClearinghouseResourceWithRawResponse:
|
|
328
|
-
return AsyncClearinghouseResourceWithRawResponse(self._v2.clearinghouse)
|
|
329
|
-
|
|
330
|
-
@cached_property
|
|
331
|
-
def integrations(self) -> AsyncIntegrationsResourceWithRawResponse:
|
|
332
|
-
return AsyncIntegrationsResourceWithRawResponse(self._v2.integrations)
|
|
333
|
-
|
|
334
174
|
@cached_property
|
|
335
175
|
def events(self) -> AsyncEventsResourceWithRawResponse:
|
|
336
176
|
return AsyncEventsResourceWithRawResponse(self._v2.events)
|
|
337
177
|
|
|
338
|
-
@cached_property
|
|
339
|
-
def policies(self) -> AsyncPoliciesResourceWithRawResponse:
|
|
340
|
-
return AsyncPoliciesResourceWithRawResponse(self._v2.policies)
|
|
341
|
-
|
|
342
|
-
@cached_property
|
|
343
|
-
def hie(self) -> AsyncHieResourceWithRawResponse:
|
|
344
|
-
return AsyncHieResourceWithRawResponse(self._v2.hie)
|
|
345
|
-
|
|
346
178
|
@cached_property
|
|
347
179
|
def database(self) -> AsyncDatabaseResourceWithRawResponse:
|
|
348
180
|
return AsyncDatabaseResourceWithRawResponse(self._v2.database)
|
|
@@ -356,18 +188,6 @@ class V2ResourceWithStreamingResponse:
|
|
|
356
188
|
def async_results(self) -> AsyncResultsResourceWithStreamingResponse:
|
|
357
189
|
return AsyncResultsResourceWithStreamingResponse(self._v2.async_results)
|
|
358
190
|
|
|
359
|
-
@cached_property
|
|
360
|
-
def workflow_runs(self) -> WorkflowRunsResourceWithStreamingResponse:
|
|
361
|
-
return WorkflowRunsResourceWithStreamingResponse(self._v2.workflow_runs)
|
|
362
|
-
|
|
363
|
-
@cached_property
|
|
364
|
-
def tasks(self) -> TasksResourceWithStreamingResponse:
|
|
365
|
-
return TasksResourceWithStreamingResponse(self._v2.tasks)
|
|
366
|
-
|
|
367
|
-
@cached_property
|
|
368
|
-
def workflows(self) -> WorkflowsResourceWithStreamingResponse:
|
|
369
|
-
return WorkflowsResourceWithStreamingResponse(self._v2.workflows)
|
|
370
|
-
|
|
371
191
|
@cached_property
|
|
372
192
|
def documents(self) -> DocumentsResourceWithStreamingResponse:
|
|
373
193
|
return DocumentsResourceWithStreamingResponse(self._v2.documents)
|
|
@@ -376,26 +196,10 @@ class V2ResourceWithStreamingResponse:
|
|
|
376
196
|
def communication(self) -> CommunicationResourceWithStreamingResponse:
|
|
377
197
|
return CommunicationResourceWithStreamingResponse(self._v2.communication)
|
|
378
198
|
|
|
379
|
-
@cached_property
|
|
380
|
-
def clearinghouse(self) -> ClearinghouseResourceWithStreamingResponse:
|
|
381
|
-
return ClearinghouseResourceWithStreamingResponse(self._v2.clearinghouse)
|
|
382
|
-
|
|
383
|
-
@cached_property
|
|
384
|
-
def integrations(self) -> IntegrationsResourceWithStreamingResponse:
|
|
385
|
-
return IntegrationsResourceWithStreamingResponse(self._v2.integrations)
|
|
386
|
-
|
|
387
199
|
@cached_property
|
|
388
200
|
def events(self) -> EventsResourceWithStreamingResponse:
|
|
389
201
|
return EventsResourceWithStreamingResponse(self._v2.events)
|
|
390
202
|
|
|
391
|
-
@cached_property
|
|
392
|
-
def policies(self) -> PoliciesResourceWithStreamingResponse:
|
|
393
|
-
return PoliciesResourceWithStreamingResponse(self._v2.policies)
|
|
394
|
-
|
|
395
|
-
@cached_property
|
|
396
|
-
def hie(self) -> HieResourceWithStreamingResponse:
|
|
397
|
-
return HieResourceWithStreamingResponse(self._v2.hie)
|
|
398
|
-
|
|
399
203
|
@cached_property
|
|
400
204
|
def database(self) -> DatabaseResourceWithStreamingResponse:
|
|
401
205
|
return DatabaseResourceWithStreamingResponse(self._v2.database)
|
|
@@ -409,18 +213,6 @@ class AsyncV2ResourceWithStreamingResponse:
|
|
|
409
213
|
def async_results(self) -> AsyncAsyncResultsResourceWithStreamingResponse:
|
|
410
214
|
return AsyncAsyncResultsResourceWithStreamingResponse(self._v2.async_results)
|
|
411
215
|
|
|
412
|
-
@cached_property
|
|
413
|
-
def workflow_runs(self) -> AsyncWorkflowRunsResourceWithStreamingResponse:
|
|
414
|
-
return AsyncWorkflowRunsResourceWithStreamingResponse(self._v2.workflow_runs)
|
|
415
|
-
|
|
416
|
-
@cached_property
|
|
417
|
-
def tasks(self) -> AsyncTasksResourceWithStreamingResponse:
|
|
418
|
-
return AsyncTasksResourceWithStreamingResponse(self._v2.tasks)
|
|
419
|
-
|
|
420
|
-
@cached_property
|
|
421
|
-
def workflows(self) -> AsyncWorkflowsResourceWithStreamingResponse:
|
|
422
|
-
return AsyncWorkflowsResourceWithStreamingResponse(self._v2.workflows)
|
|
423
|
-
|
|
424
216
|
@cached_property
|
|
425
217
|
def documents(self) -> AsyncDocumentsResourceWithStreamingResponse:
|
|
426
218
|
return AsyncDocumentsResourceWithStreamingResponse(self._v2.documents)
|
|
@@ -429,26 +221,10 @@ class AsyncV2ResourceWithStreamingResponse:
|
|
|
429
221
|
def communication(self) -> AsyncCommunicationResourceWithStreamingResponse:
|
|
430
222
|
return AsyncCommunicationResourceWithStreamingResponse(self._v2.communication)
|
|
431
223
|
|
|
432
|
-
@cached_property
|
|
433
|
-
def clearinghouse(self) -> AsyncClearinghouseResourceWithStreamingResponse:
|
|
434
|
-
return AsyncClearinghouseResourceWithStreamingResponse(self._v2.clearinghouse)
|
|
435
|
-
|
|
436
|
-
@cached_property
|
|
437
|
-
def integrations(self) -> AsyncIntegrationsResourceWithStreamingResponse:
|
|
438
|
-
return AsyncIntegrationsResourceWithStreamingResponse(self._v2.integrations)
|
|
439
|
-
|
|
440
224
|
@cached_property
|
|
441
225
|
def events(self) -> AsyncEventsResourceWithStreamingResponse:
|
|
442
226
|
return AsyncEventsResourceWithStreamingResponse(self._v2.events)
|
|
443
227
|
|
|
444
|
-
@cached_property
|
|
445
|
-
def policies(self) -> AsyncPoliciesResourceWithStreamingResponse:
|
|
446
|
-
return AsyncPoliciesResourceWithStreamingResponse(self._v2.policies)
|
|
447
|
-
|
|
448
|
-
@cached_property
|
|
449
|
-
def hie(self) -> AsyncHieResourceWithStreamingResponse:
|
|
450
|
-
return AsyncHieResourceWithStreamingResponse(self._v2.hie)
|
|
451
|
-
|
|
452
228
|
@cached_property
|
|
453
229
|
def database(self) -> AsyncDatabaseResourceWithStreamingResponse:
|
|
454
230
|
return AsyncDatabaseResourceWithStreamingResponse(self._v2.database)
|
samplehc/types/__init__.py
CHANGED
|
@@ -1,8 +1,3 @@
|
|
|
1
1
|
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
2
|
|
|
3
3
|
from __future__ import annotations
|
|
4
|
-
|
|
5
|
-
from .v1_sql_execute_params import V1SqlExecuteParams as V1SqlExecuteParams
|
|
6
|
-
from .v1_sql_execute_response import V1SqlExecuteResponse as V1SqlExecuteResponse
|
|
7
|
-
from .v1_query_audit_logs_params import V1QueryAuditLogsParams as V1QueryAuditLogsParams
|
|
8
|
-
from .v1_query_audit_logs_response import V1QueryAuditLogsResponse as V1QueryAuditLogsResponse
|
samplehc/types/v2/__init__.py
CHANGED
|
@@ -3,66 +3,34 @@
|
|
|
3
3
|
from __future__ import annotations
|
|
4
4
|
|
|
5
5
|
from .event_emit_params import EventEmitParams as EventEmitParams
|
|
6
|
-
from .policy_list_params import PolicyListParams as PolicyListParams
|
|
7
6
|
from .event_emit_response import EventEmitResponse as EventEmitResponse
|
|
8
|
-
from .task_retry_response import TaskRetryResponse as TaskRetryResponse
|
|
9
|
-
from .policy_list_response import PolicyListResponse as PolicyListResponse
|
|
10
|
-
from .task_cancel_response import TaskCancelResponse as TaskCancelResponse
|
|
11
|
-
from .task_complete_params import TaskCompleteParams as TaskCompleteParams
|
|
12
7
|
from .document_split_params import DocumentSplitParams as DocumentSplitParams
|
|
13
|
-
from .workflow_query_params import WorkflowQueryParams as WorkflowQueryParams
|
|
14
|
-
from .workflow_start_params import WorkflowStartParams as WorkflowStartParams
|
|
15
8
|
from .document_search_params import DocumentSearchParams as DocumentSearchParams
|
|
16
|
-
from .task_complete_response import TaskCompleteResponse as TaskCompleteResponse
|
|
17
|
-
from .task_retrieve_response import TaskRetrieveResponse as TaskRetrieveResponse
|
|
18
9
|
from .document_combine_params import DocumentCombineParams as DocumentCombineParams
|
|
19
10
|
from .document_extract_params import DocumentExtractParams as DocumentExtractParams
|
|
20
11
|
from .document_split_response import DocumentSplitResponse as DocumentSplitResponse
|
|
21
|
-
from .document_unzip_response import DocumentUnzipResponse as DocumentUnzipResponse
|
|
22
|
-
from .workflow_query_response import WorkflowQueryResponse as WorkflowQueryResponse
|
|
23
|
-
from .workflow_start_response import WorkflowStartResponse as WorkflowStartResponse
|
|
24
12
|
from .document_classify_params import DocumentClassifyParams as DocumentClassifyParams
|
|
25
13
|
from .document_search_response import DocumentSearchResponse as DocumentSearchResponse
|
|
26
|
-
from .policy_list_plans_params import PolicyListPlansParams as PolicyListPlansParams
|
|
27
|
-
from .workflow_deploy_response import WorkflowDeployResponse as WorkflowDeployResponse
|
|
28
14
|
from .async_result_sleep_params import AsyncResultSleepParams as AsyncResultSleepParams
|
|
29
15
|
from .document_combine_response import DocumentCombineResponse as DocumentCombineResponse
|
|
30
16
|
from .document_extract_response import DocumentExtractResponse as DocumentExtractResponse
|
|
31
|
-
from .task_update_column_params import TaskUpdateColumnParams as TaskUpdateColumnParams
|
|
32
17
|
from .document_classify_response import DocumentClassifyResponse as DocumentClassifyResponse
|
|
33
18
|
from .document_retrieve_response import DocumentRetrieveResponse as DocumentRetrieveResponse
|
|
34
|
-
from .policy_list_plans_response import PolicyListPlansResponse as PolicyListPlansResponse
|
|
35
19
|
from .async_result_sleep_response import AsyncResultSleepResponse as AsyncResultSleepResponse
|
|
36
20
|
from .database_execute_sql_params import DatabaseExecuteSqlParams as DatabaseExecuteSqlParams
|
|
37
|
-
from .task_update_column_response import TaskUpdateColumnResponse as TaskUpdateColumnResponse
|
|
38
21
|
from .document_generate_csv_params import DocumentGenerateCsvParams as DocumentGenerateCsvParams
|
|
39
|
-
from .policy_list_companies_params import PolicyListCompaniesParams as PolicyListCompaniesParams
|
|
40
22
|
from .communication_send_fax_params import CommunicationSendFaxParams as CommunicationSendFaxParams
|
|
41
23
|
from .database_execute_sql_response import DatabaseExecuteSqlResponse as DatabaseExecuteSqlResponse
|
|
42
|
-
from .document_unzip_async_response import DocumentUnzipAsyncResponse as DocumentUnzipAsyncResponse
|
|
43
|
-
from .policy_retrieve_text_response import PolicyRetrieveTextResponse as PolicyRetrieveTextResponse
|
|
44
|
-
from .async_result_retrieve_response import AsyncResultRetrieveResponse as AsyncResultRetrieveResponse
|
|
45
24
|
from .document_generate_csv_response import DocumentGenerateCsvResponse as DocumentGenerateCsvResponse
|
|
46
|
-
from .policy_list_companies_response import PolicyListCompaniesResponse as PolicyListCompaniesResponse
|
|
47
|
-
from .task_update_screen_time_params import TaskUpdateScreenTimeParams as TaskUpdateScreenTimeParams
|
|
48
|
-
from .workflow_run_retrieve_response import WorkflowRunRetrieveResponse as WorkflowRunRetrieveResponse
|
|
49
25
|
from .communication_send_email_params import CommunicationSendEmailParams as CommunicationSendEmailParams
|
|
50
26
|
from .communication_send_fax_response import CommunicationSendFaxResponse as CommunicationSendFaxResponse
|
|
51
27
|
from .communication_send_letter_params import CommunicationSendLetterParams as CommunicationSendLetterParams
|
|
52
|
-
from .task_update_screen_time_response import TaskUpdateScreenTimeResponse as TaskUpdateScreenTimeResponse
|
|
53
28
|
from .communication_send_email_response import CommunicationSendEmailResponse as CommunicationSendEmailResponse
|
|
54
|
-
from .clearinghouse_run_discovery_params import ClearinghouseRunDiscoveryParams as ClearinghouseRunDiscoveryParams
|
|
55
29
|
from .communication_send_letter_response import CommunicationSendLetterResponse as CommunicationSendLetterResponse
|
|
56
30
|
from .document_create_from_splits_params import DocumentCreateFromSplitsParams as DocumentCreateFromSplitsParams
|
|
57
31
|
from .document_retrieve_metadata_response import DocumentRetrieveMetadataResponse as DocumentRetrieveMetadataResponse
|
|
58
|
-
from .task_get_suspended_payload_response import TaskGetSuspendedPayloadResponse as TaskGetSuspendedPayloadResponse
|
|
59
|
-
from .clearinghouse_run_discovery_response import ClearinghouseRunDiscoveryResponse as ClearinghouseRunDiscoveryResponse
|
|
60
32
|
from .document_create_from_splits_response import DocumentCreateFromSplitsResponse as DocumentCreateFromSplitsResponse
|
|
61
33
|
from .document_presigned_upload_url_params import DocumentPresignedUploadURLParams as DocumentPresignedUploadURLParams
|
|
62
|
-
from .workflow_run_get_start_data_response import WorkflowRunGetStartDataResponse as WorkflowRunGetStartDataResponse
|
|
63
|
-
from .clearinghouse_check_eligibility_params import (
|
|
64
|
-
ClearinghouseCheckEligibilityParams as ClearinghouseCheckEligibilityParams,
|
|
65
|
-
)
|
|
66
34
|
from .document_presigned_upload_url_response import (
|
|
67
35
|
DocumentPresignedUploadURLResponse as DocumentPresignedUploadURLResponse,
|
|
68
36
|
)
|
|
@@ -72,27 +40,6 @@ from .document_retrieve_csv_content_response import (
|
|
|
72
40
|
from .document_transform_json_to_html_params import (
|
|
73
41
|
DocumentTransformJsonToHTMLParams as DocumentTransformJsonToHTMLParams,
|
|
74
42
|
)
|
|
75
|
-
from .policy_retrieve_presigned_url_response import (
|
|
76
|
-
PolicyRetrievePresignedURLResponse as PolicyRetrievePresignedURLResponse,
|
|
77
|
-
)
|
|
78
|
-
from .clearinghouse_check_claim_status_params import (
|
|
79
|
-
ClearinghouseCheckClaimStatusParams as ClearinghouseCheckClaimStatusParams,
|
|
80
|
-
)
|
|
81
|
-
from .clearinghouse_check_eligibility_response import (
|
|
82
|
-
ClearinghouseCheckEligibilityResponse as ClearinghouseCheckEligibilityResponse,
|
|
83
|
-
)
|
|
84
43
|
from .document_transform_json_to_html_response import (
|
|
85
44
|
DocumentTransformJsonToHTMLResponse as DocumentTransformJsonToHTMLResponse,
|
|
86
45
|
)
|
|
87
|
-
from .workflow_run_resume_when_complete_params import (
|
|
88
|
-
WorkflowRunResumeWhenCompleteParams as WorkflowRunResumeWhenCompleteParams,
|
|
89
|
-
)
|
|
90
|
-
from .workflow_run_resume_when_complete_response import (
|
|
91
|
-
WorkflowRunResumeWhenCompleteResponse as WorkflowRunResumeWhenCompleteResponse,
|
|
92
|
-
)
|
|
93
|
-
from .clearinghouse_calculate_patient_cost_params import (
|
|
94
|
-
ClearinghouseCalculatePatientCostParams as ClearinghouseCalculatePatientCostParams,
|
|
95
|
-
)
|
|
96
|
-
from .clearinghouse_coordination_of_benefits_params import (
|
|
97
|
-
ClearinghouseCoordinationOfBenefitsParams as ClearinghouseCoordinationOfBenefitsParams,
|
|
98
|
-
)
|
|
@@ -27,12 +27,31 @@ class DocumentExtractParams(TypedDict, total=False):
|
|
|
27
27
|
response_json_schema: Required[Annotated[Dict[str, object], PropertyInfo(alias="responseJsonSchema")]]
|
|
28
28
|
"""A JSON schema defining the structure of the desired extraction output."""
|
|
29
29
|
|
|
30
|
-
model: Literal[
|
|
30
|
+
model: Literal[
|
|
31
|
+
"reasoning-3-mini",
|
|
32
|
+
"reasoning-3",
|
|
33
|
+
"base-5",
|
|
34
|
+
"base-5-mini",
|
|
35
|
+
"base-5-nano",
|
|
36
|
+
"base-4.1",
|
|
37
|
+
"base-4.1-mini",
|
|
38
|
+
"base-4.1-nano",
|
|
39
|
+
"base-5.2",
|
|
40
|
+
"base-5.2-chat-latest",
|
|
41
|
+
"gemini-3-pro",
|
|
42
|
+
"gemini-3-flash",
|
|
43
|
+
"gemini-2.5-pro",
|
|
44
|
+
"gemini-2.5-flash",
|
|
45
|
+
"gemini-2.5-flash-lite",
|
|
46
|
+
]
|
|
31
47
|
"""The model to use for extraction."""
|
|
32
48
|
|
|
33
49
|
ocr_enhance: Annotated[OcrEnhance, PropertyInfo(alias="ocrEnhance")]
|
|
34
50
|
"""OCR enhancement configuration for figure and text analysis."""
|
|
35
51
|
|
|
52
|
+
ocr_quality: Annotated[Literal["high", "low"], PropertyInfo(alias="ocrQuality")]
|
|
53
|
+
"""OCR quality setting"""
|
|
54
|
+
|
|
36
55
|
priority: Literal["interactive", "non-interactive"]
|
|
37
56
|
"""The priority of the extraction task. Non-interactive is lower priority."""
|
|
38
57
|
|
|
@@ -12,9 +12,6 @@ from .format_create_pdf_params import FormatCreatePdfParams as FormatCreatePdfPa
|
|
|
12
12
|
from .format_create_pdf_response import FormatCreatePdfResponse as FormatCreatePdfResponse
|
|
13
13
|
from .template_render_document_params import TemplateRenderDocumentParams as TemplateRenderDocumentParams
|
|
14
14
|
from .template_render_document_response import TemplateRenderDocumentResponse as TemplateRenderDocumentResponse
|
|
15
|
-
from .pdf_template_retrieve_metadata_response import (
|
|
16
|
-
PdfTemplateRetrieveMetadataResponse as PdfTemplateRetrieveMetadataResponse,
|
|
17
|
-
)
|
|
18
15
|
from .template_generate_document_async_params import (
|
|
19
16
|
TemplateGenerateDocumentAsyncParams as TemplateGenerateDocumentAsyncParams,
|
|
20
17
|
)
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.3
|
|
2
2
|
Name: samplehc
|
|
3
|
-
Version: 0.
|
|
3
|
+
Version: 0.19.0
|
|
4
4
|
Summary: The official Python library for the Sample Healthcare API
|
|
5
5
|
Project-URL: Homepage, https://github.com/samplehc/samplehc-python
|
|
6
6
|
Project-URL: Repository, https://github.com/samplehc/samplehc-python
|
|
@@ -67,10 +67,10 @@ client = SampleHealthcare(
|
|
|
67
67
|
api_key=os.environ.get("SAMPLEHC_API_KEY"), # This is the default and can be omitted
|
|
68
68
|
)
|
|
69
69
|
|
|
70
|
-
response = client.
|
|
71
|
-
|
|
72
|
-
params=[{}],
|
|
70
|
+
response = client.v2.async_results.sleep(
|
|
71
|
+
delay=1,
|
|
73
72
|
)
|
|
73
|
+
print(response.async_result_id)
|
|
74
74
|
```
|
|
75
75
|
|
|
76
76
|
While you can provide an `api_key` keyword argument,
|
|
@@ -93,10 +93,10 @@ client = AsyncSampleHealthcare(
|
|
|
93
93
|
|
|
94
94
|
|
|
95
95
|
async def main() -> None:
|
|
96
|
-
response = await client.
|
|
97
|
-
|
|
98
|
-
params=[{}],
|
|
96
|
+
response = await client.v2.async_results.sleep(
|
|
97
|
+
delay=1,
|
|
99
98
|
)
|
|
99
|
+
print(response.async_result_id)
|
|
100
100
|
|
|
101
101
|
|
|
102
102
|
asyncio.run(main())
|
|
@@ -129,10 +129,10 @@ async def main() -> None:
|
|
|
129
129
|
api_key=os.environ.get("SAMPLEHC_API_KEY"), # This is the default and can be omitted
|
|
130
130
|
http_client=DefaultAioHttpClient(),
|
|
131
131
|
) as client:
|
|
132
|
-
response = await client.
|
|
133
|
-
|
|
134
|
-
params=[{}],
|
|
132
|
+
response = await client.v2.async_results.sleep(
|
|
133
|
+
delay=1,
|
|
135
134
|
)
|
|
135
|
+
print(response.async_result_id)
|
|
136
136
|
|
|
137
137
|
|
|
138
138
|
asyncio.run(main())
|
|
@@ -182,9 +182,8 @@ from samplehc import SampleHealthcare
|
|
|
182
182
|
client = SampleHealthcare()
|
|
183
183
|
|
|
184
184
|
try:
|
|
185
|
-
client.
|
|
186
|
-
|
|
187
|
-
params=[{}],
|
|
185
|
+
client.v2.async_results.sleep(
|
|
186
|
+
delay=1,
|
|
188
187
|
)
|
|
189
188
|
except samplehc.APIConnectionError as e:
|
|
190
189
|
print("The server could not be reached")
|
|
@@ -228,9 +227,8 @@ client = SampleHealthcare(
|
|
|
228
227
|
)
|
|
229
228
|
|
|
230
229
|
# Or, configure per-request:
|
|
231
|
-
client.with_options(max_retries=5).
|
|
232
|
-
|
|
233
|
-
params=[{}],
|
|
230
|
+
client.with_options(max_retries=5).v2.async_results.sleep(
|
|
231
|
+
delay=1,
|
|
234
232
|
)
|
|
235
233
|
```
|
|
236
234
|
|
|
@@ -254,9 +252,8 @@ client = SampleHealthcare(
|
|
|
254
252
|
)
|
|
255
253
|
|
|
256
254
|
# Override per-request:
|
|
257
|
-
client.with_options(timeout=5.0).
|
|
258
|
-
|
|
259
|
-
params=[{}],
|
|
255
|
+
client.with_options(timeout=5.0).v2.async_results.sleep(
|
|
256
|
+
delay=1,
|
|
260
257
|
)
|
|
261
258
|
```
|
|
262
259
|
|
|
@@ -298,14 +295,13 @@ The "raw" Response object can be accessed by prefixing `.with_raw_response.` to
|
|
|
298
295
|
from samplehc import SampleHealthcare
|
|
299
296
|
|
|
300
297
|
client = SampleHealthcare()
|
|
301
|
-
response = client.
|
|
302
|
-
|
|
303
|
-
params=[{}],
|
|
298
|
+
response = client.v2.async_results.with_raw_response.sleep(
|
|
299
|
+
delay=1,
|
|
304
300
|
)
|
|
305
301
|
print(response.headers.get('X-My-Header'))
|
|
306
302
|
|
|
307
|
-
|
|
308
|
-
print(
|
|
303
|
+
async_result = response.parse() # get the object that `v2.async_results.sleep()` would have returned
|
|
304
|
+
print(async_result.async_result_id)
|
|
309
305
|
```
|
|
310
306
|
|
|
311
307
|
These methods return an [`APIResponse`](https://github.com/samplehc/samplehc-python/tree/main/src/samplehc/_response.py) object.
|
|
@@ -319,9 +315,8 @@ The above interface eagerly reads the full response body when you make the reque
|
|
|
319
315
|
To stream the response body, use `.with_streaming_response` instead, which requires a context manager and only reads the response body once you call `.read()`, `.text()`, `.json()`, `.iter_bytes()`, `.iter_text()`, `.iter_lines()` or `.parse()`. In the async client, these are async methods.
|
|
320
316
|
|
|
321
317
|
```python
|
|
322
|
-
with client.
|
|
323
|
-
|
|
324
|
-
params=[{}],
|
|
318
|
+
with client.v2.async_results.with_streaming_response.sleep(
|
|
319
|
+
delay=1,
|
|
325
320
|
) as response:
|
|
326
321
|
print(response.headers.get("X-My-Header"))
|
|
327
322
|
|