fal 0.11.1__tar.gz → 0.11.3__tar.gz
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.
Potentially problematic release.
This version of fal might be problematic. Click here for more details.
- {fal-0.11.1 → fal-0.11.3}/PKG-INFO +40 -3
- fal-0.11.3/README.md +43 -0
- fal-0.11.1/openapi-fal-rest/openapi_fal_rest/api/usage/get_gateway_request_stats.py → fal-0.11.3/openapi-fal-rest/openapi_fal_rest/api/admin/get_usage_per_user.py +17 -17
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/api/admin/handle_user_lock.py +6 -2
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/api/applications/get_status_applications_app_user_id_app_alias_or_id_status_get.py +6 -2
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/api/billing/delete_payment_method.py +9 -3
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/api/billing/get_setup_intent_key.py +6 -2
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/api/billing/get_user_price.py +6 -2
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/api/billing/get_user_spending.py +6 -2
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/api/billing/handle_stripe_webhook.py +21 -7
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/api/billing/upcoming_invoice.py +6 -2
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/api/billing/update_customer_budget.py +6 -2
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/api/files/check_dir_hash.py +9 -3
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/api/files/delete.py +6 -2
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/api/files/download.py +6 -2
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/api/files/file_exists.py +6 -2
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/api/files/upload_from_url.py +6 -2
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/api/files/upload_local_file.py +9 -3
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/api/keys/create_key.py +6 -2
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/api/keys/delete_key.py +6 -2
- fal-0.11.1/openapi-fal-rest/openapi_fal_rest/api/usage/get_request_stats_by_time.py → fal-0.11.3/openapi-fal-rest/openapi_fal_rest/api/requests/requests.py +33 -18
- fal-0.11.3/openapi-fal-rest/openapi_fal_rest/api/storage/get_file_link.py +200 -0
- fal-0.11.3/openapi-fal-rest/openapi_fal_rest/api/storage/initiate_upload.py +172 -0
- fal-0.11.3/openapi-fal-rest/openapi_fal_rest/api/tokens/create_token.py +170 -0
- fal-0.11.3/openapi-fal-rest/openapi_fal_rest/api/usage/__init__.py +0 -0
- fal-0.11.3/openapi-fal-rest/openapi_fal_rest/api/usage/get_gateway_request_stats.py +247 -0
- fal-0.11.3/openapi-fal-rest/openapi_fal_rest/api/usage/get_gateway_request_stats_by_time.py +270 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/api/usage/per_machine_usage_details.py +3 -1
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/models/__init__.py +18 -0
- fal-0.11.3/openapi-fal-rest/openapi_fal_rest/models/body_create_token.py +68 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/models/body_upload_file.py +4 -1
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/models/body_upload_local_file.py +4 -1
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/models/gateway_stats_by_time.py +27 -27
- fal-0.11.3/openapi-fal-rest/openapi_fal_rest/models/gateway_usage_stats.py +147 -0
- fal-0.11.3/openapi-fal-rest/openapi_fal_rest/models/get_gateway_request_stats_by_time_response_get_gateway_request_stats_by_time.py +80 -0
- fal-0.11.3/openapi-fal-rest/openapi_fal_rest/models/initiate_upload_info.py +64 -0
- fal-0.11.3/openapi-fal-rest/openapi_fal_rest/models/presigned_upload_url.py +64 -0
- fal-0.11.3/openapi-fal-rest/openapi_fal_rest/models/request_io.py +112 -0
- fal-0.11.3/openapi-fal-rest/openapi_fal_rest/models/request_io_json_input.py +43 -0
- fal-0.11.3/openapi-fal-rest/openapi_fal_rest/models/request_io_json_output.py +43 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/models/stats_timeframe.py +1 -0
- fal-0.11.3/openapi-fal-rest/openapi_fal_rest/models/usage_per_user.py +71 -0
- {fal-0.11.1 → fal-0.11.3}/pyproject.toml +3 -2
- {fal-0.11.1 → fal-0.11.3}/setup.py +8 -5
- {fal-0.11.1 → fal-0.11.3}/src/fal/api.py +51 -19
- {fal-0.11.1 → fal-0.11.3}/src/fal/auth/__init__.py +1 -2
- {fal-0.11.1 → fal-0.11.3}/src/fal/auth/auth0.py +2 -5
- {fal-0.11.1 → fal-0.11.3}/src/fal/cli.py +92 -108
- {fal-0.11.1 → fal-0.11.3}/src/fal/rest_client.py +1 -0
- {fal-0.11.1 → fal-0.11.3}/src/fal/sdk.py +49 -129
- {fal-0.11.1 → fal-0.11.3}/src/fal/sync.py +3 -2
- {fal-0.11.1 → fal-0.11.3}/src/fal/toolkit/file/file.py +6 -5
- {fal-0.11.1 → fal-0.11.3}/src/fal/toolkit/file/providers/gcp.py +4 -1
- fal-0.11.3/src/fal/toolkit/file/providers/r2.py +83 -0
- {fal-0.11.1 → fal-0.11.3}/src/fal/toolkit/file/types.py +1 -1
- {fal-0.11.1 → fal-0.11.3}/src/fal/toolkit/image/image.py +2 -2
- {fal-0.11.1 → fal-0.11.3}/src/fal/toolkit/utils/download_utils.py +1 -1
- fal-0.11.1/README.md +0 -7
- fal-0.11.1/openapi-fal-rest/openapi_fal_rest/api/application/get_status_application_status_user_id_alias_get.py +0 -177
- fal-0.11.1/openapi-fal-rest/openapi_fal_rest/models/gateway_usage_stats.py +0 -120
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/__init__.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/api/__init__.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/api/admin/__init__.py +0 -0
- {fal-0.11.1/openapi-fal-rest/openapi_fal_rest/api/application → fal-0.11.3/openapi-fal-rest/openapi_fal_rest/api/applications}/__init__.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/api/applications/app_metadata.py +0 -0
- {fal-0.11.1/openapi-fal-rest/openapi_fal_rest/api/applications → fal-0.11.3/openapi-fal-rest/openapi_fal_rest/api/billing}/__init__.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/api/billing/get_user_details.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/api/billing/get_user_invoices.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/api/billing/get_user_payment_methods.py +0 -0
- {fal-0.11.1/openapi-fal-rest/openapi_fal_rest/api/billing → fal-0.11.3/openapi-fal-rest/openapi_fal_rest/api/files}/__init__.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/api/files/list_directory.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/api/files/list_root.py +0 -0
- {fal-0.11.1/openapi-fal-rest/openapi_fal_rest/api/files → fal-0.11.3/openapi-fal-rest/openapi_fal_rest/api/health}/__init__.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/api/health/check.py +0 -0
- {fal-0.11.1/openapi-fal-rest/openapi_fal_rest/api/health → fal-0.11.3/openapi-fal-rest/openapi_fal_rest/api/keys}/__init__.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/api/keys/list_keys.py +0 -0
- {fal-0.11.1/openapi-fal-rest/openapi_fal_rest/api/keys → fal-0.11.3/openapi-fal-rest/openapi_fal_rest/api/logs}/__init__.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/api/logs/list_since.py +0 -0
- {fal-0.11.1/openapi-fal-rest/openapi_fal_rest/api/logs → fal-0.11.3/openapi-fal-rest/openapi_fal_rest/api/requests}/__init__.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/api/storage/__init__.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/api/storage/upload_file.py +0 -0
- {fal-0.11.1/openapi-fal-rest/openapi_fal_rest/api/usage → fal-0.11.3/openapi-fal-rest/openapi_fal_rest/api/tokens}/__init__.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/api/usage/get_custom_usage_per_machine.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/api/usage/get_shared_usage_per_app.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/api/usage/get_usage_records.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/api/usage/per_machine_usage.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/client.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/errors.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/models/app_metadata_response_app_metadata.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/models/customer_details.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/models/file_spec.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/models/grouped_usage_detail.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/models/handle_stripe_webhook_response_handle_stripe_webhook.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/models/hash_check.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/models/http_validation_error.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/models/invoice.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/models/invoice_item.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/models/key_scope.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/models/log_entry.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/models/log_entry_labels.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/models/new_user_key.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/models/payment_method.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/models/persisted_usage_record.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/models/persisted_usage_record_meta.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/models/run_type.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/models/status.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/models/status_health.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/models/uploaded_file_result.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/models/url_file_upload.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/models/usage_per_machine_type.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/models/usage_run_detail.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/models/user_key_info.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/models/validation_error.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/py.typed +0 -0
- {fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/types.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/src/fal/__init__.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/src/fal/_serialization.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/src/fal/apps.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/src/fal/auth/local.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/src/fal/console/__init__.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/src/fal/console/icons.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/src/fal/console/ux.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/src/fal/env.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/src/fal/exceptions/__init__.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/src/fal/exceptions/_base.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/src/fal/exceptions/auth.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/src/fal/exceptions/handlers.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/src/fal/flags.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/src/fal/logging/__init__.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/src/fal/logging/datadog.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/src/fal/logging/isolate.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/src/fal/logging/style.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/src/fal/logging/trace.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/src/fal/logging/user.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/src/fal/toolkit/__init__.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/src/fal/toolkit/exceptions.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/src/fal/toolkit/file/__init__.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/src/fal/toolkit/file/providers/fal.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/src/fal/toolkit/image/__init__.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/src/fal/toolkit/mainify.py +0 -0
- {fal-0.11.1 → fal-0.11.3}/src/fal/toolkit/utils/__init__.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: fal
|
|
3
|
-
Version: 0.11.
|
|
3
|
+
Version: 0.11.3
|
|
4
4
|
Summary: fal is an easy-to-use Serverless Python Framework
|
|
5
5
|
Author: Features & Labels
|
|
6
6
|
Author-email: hello@fal.ai
|
|
@@ -12,6 +12,7 @@ Classifier: Programming Language :: Python :: 3.10
|
|
|
12
12
|
Classifier: Programming Language :: Python :: 3.11
|
|
13
13
|
Requires-Dist: attrs (>=21.3.0)
|
|
14
14
|
Requires-Dist: auth0-python (>=4.1.0,<5.0.0)
|
|
15
|
+
Requires-Dist: boto3 (>=1.33.8,<2.0.0)
|
|
15
16
|
Requires-Dist: click (>=8.1.3,<9.0.0)
|
|
16
17
|
Requires-Dist: colorama (>=0.4.6,<0.5.0)
|
|
17
18
|
Requires-Dist: datadog-api-client (==2.12.0)
|
|
@@ -21,7 +22,7 @@ Requires-Dist: grpc-interceptor (>=0.15.0,<0.16.0)
|
|
|
21
22
|
Requires-Dist: grpcio (>=1.50.0,<2.0.0)
|
|
22
23
|
Requires-Dist: httpx (>=0.15.4,<0.25.0)
|
|
23
24
|
Requires-Dist: importlib-metadata (>=4.4) ; python_version < "3.10"
|
|
24
|
-
Requires-Dist: isolate-proto (
|
|
25
|
+
Requires-Dist: isolate-proto (>=0.2.1,<0.3.0)
|
|
25
26
|
Requires-Dist: isolate[build] (>=0.12.3,<1.0)
|
|
26
27
|
Requires-Dist: opentelemetry-api (>=1.15.0,<2.0.0)
|
|
27
28
|
Requires-Dist: opentelemetry-sdk (>=1.15.0,<2.0.0)
|
|
@@ -43,5 +44,41 @@ fal is a serverless Python runtime that lets you run and scale code in the cloud
|
|
|
43
44
|
|
|
44
45
|
With fal, you can build pipelines, serve ML models and scale them up to many users. You scale down to 0 when you don't use any resources.
|
|
45
46
|
|
|
46
|
-
|
|
47
|
+
## Quickstart
|
|
48
|
+
|
|
49
|
+
First, you need to install the `fal` package. You can do so using pip:
|
|
50
|
+
```shell
|
|
51
|
+
pip install fal
|
|
52
|
+
```
|
|
53
|
+
|
|
54
|
+
Then you need to authenticate:
|
|
55
|
+
```shell
|
|
56
|
+
fal auth login
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
You can also use fal keys that you can get from [our dashboard](https://fal.ai/dashboard/keys).
|
|
60
|
+
|
|
61
|
+
Now can use the fal package in your Python scripts as follows:
|
|
62
|
+
|
|
63
|
+
```py
|
|
64
|
+
import fal
|
|
65
|
+
|
|
66
|
+
@fal.function(
|
|
67
|
+
"virtualenv",
|
|
68
|
+
requirements=["pyjokes"],
|
|
69
|
+
)
|
|
70
|
+
def tell_joke() -> str:
|
|
71
|
+
import pyjokes
|
|
72
|
+
|
|
73
|
+
joke = pyjokes.get_joke()
|
|
74
|
+
return joke
|
|
75
|
+
|
|
76
|
+
print("Joke from the clouds: ", tell_joke())
|
|
77
|
+
```
|
|
78
|
+
|
|
79
|
+
A new virtual environment will be created by fal in the cloud and the set of requirements that we passed will be installed as soon as this function is called. From that point on, our code will be executed as if it were running locally, and the joke prepared by the pyjokes library will be returned.
|
|
80
|
+
|
|
81
|
+
## Next steps
|
|
82
|
+
|
|
83
|
+
If you would like to find out more about the capabilities of fal, check out to the [docs](https://fal.ai/docs). You can learn more about persistent storage, function caches and deploying your functions as API endpoints.
|
|
47
84
|
|
fal-0.11.3/README.md
ADDED
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
# fal
|
|
2
|
+
|
|
3
|
+
fal is a serverless Python runtime that lets you run and scale code in the cloud with no infra management.
|
|
4
|
+
|
|
5
|
+
With fal, you can build pipelines, serve ML models and scale them up to many users. You scale down to 0 when you don't use any resources.
|
|
6
|
+
|
|
7
|
+
## Quickstart
|
|
8
|
+
|
|
9
|
+
First, you need to install the `fal` package. You can do so using pip:
|
|
10
|
+
```shell
|
|
11
|
+
pip install fal
|
|
12
|
+
```
|
|
13
|
+
|
|
14
|
+
Then you need to authenticate:
|
|
15
|
+
```shell
|
|
16
|
+
fal auth login
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
You can also use fal keys that you can get from [our dashboard](https://fal.ai/dashboard/keys).
|
|
20
|
+
|
|
21
|
+
Now can use the fal package in your Python scripts as follows:
|
|
22
|
+
|
|
23
|
+
```py
|
|
24
|
+
import fal
|
|
25
|
+
|
|
26
|
+
@fal.function(
|
|
27
|
+
"virtualenv",
|
|
28
|
+
requirements=["pyjokes"],
|
|
29
|
+
)
|
|
30
|
+
def tell_joke() -> str:
|
|
31
|
+
import pyjokes
|
|
32
|
+
|
|
33
|
+
joke = pyjokes.get_joke()
|
|
34
|
+
return joke
|
|
35
|
+
|
|
36
|
+
print("Joke from the clouds: ", tell_joke())
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
A new virtual environment will be created by fal in the cloud and the set of requirements that we passed will be installed as soon as this function is called. From that point on, our code will be executed as if it were running locally, and the joke prepared by the pyjokes library will be returned.
|
|
40
|
+
|
|
41
|
+
## Next steps
|
|
42
|
+
|
|
43
|
+
If you would like to find out more about the capabilities of fal, check out to the [docs](https://fal.ai/docs). You can learn more about persistent storage, function caches and deploying your functions as API endpoints.
|
|
@@ -6,8 +6,8 @@ import httpx
|
|
|
6
6
|
|
|
7
7
|
from ... import errors
|
|
8
8
|
from ...client import Client
|
|
9
|
-
from ...models.gateway_usage_stats import GatewayUsageStats
|
|
10
9
|
from ...models.http_validation_error import HTTPValidationError
|
|
10
|
+
from ...models.usage_per_user import UsagePerUser
|
|
11
11
|
from ...types import UNSET, Response
|
|
12
12
|
|
|
13
13
|
|
|
@@ -17,7 +17,7 @@ def _get_kwargs(
|
|
|
17
17
|
start_time: datetime.datetime,
|
|
18
18
|
end_time: datetime.datetime,
|
|
19
19
|
) -> Dict[str, Any]:
|
|
20
|
-
url = "{}/
|
|
20
|
+
url = "{}/admin/users/usage".format(client.base_url)
|
|
21
21
|
|
|
22
22
|
headers: Dict[str, str] = client.get_headers()
|
|
23
23
|
cookies: Dict[str, Any] = client.get_cookies()
|
|
@@ -46,12 +46,12 @@ def _get_kwargs(
|
|
|
46
46
|
|
|
47
47
|
def _parse_response(
|
|
48
48
|
*, client: Client, response: httpx.Response
|
|
49
|
-
) -> Optional[Union[HTTPValidationError, List["
|
|
49
|
+
) -> Optional[Union[HTTPValidationError, List["UsagePerUser"]]]:
|
|
50
50
|
if response.status_code == HTTPStatus.OK:
|
|
51
51
|
response_200 = []
|
|
52
52
|
_response_200 = response.json()
|
|
53
53
|
for response_200_item_data in _response_200:
|
|
54
|
-
response_200_item =
|
|
54
|
+
response_200_item = UsagePerUser.from_dict(response_200_item_data)
|
|
55
55
|
|
|
56
56
|
response_200.append(response_200_item)
|
|
57
57
|
|
|
@@ -68,7 +68,7 @@ def _parse_response(
|
|
|
68
68
|
|
|
69
69
|
def _build_response(
|
|
70
70
|
*, client: Client, response: httpx.Response
|
|
71
|
-
) -> Response[Union[HTTPValidationError, List["
|
|
71
|
+
) -> Response[Union[HTTPValidationError, List["UsagePerUser"]]]:
|
|
72
72
|
return Response(
|
|
73
73
|
status_code=HTTPStatus(response.status_code),
|
|
74
74
|
content=response.content,
|
|
@@ -82,8 +82,8 @@ def sync_detailed(
|
|
|
82
82
|
client: Client,
|
|
83
83
|
start_time: datetime.datetime,
|
|
84
84
|
end_time: datetime.datetime,
|
|
85
|
-
) -> Response[Union[HTTPValidationError, List["
|
|
86
|
-
"""Get
|
|
85
|
+
) -> Response[Union[HTTPValidationError, List["UsagePerUser"]]]:
|
|
86
|
+
"""Get Usage Per User
|
|
87
87
|
|
|
88
88
|
Args:
|
|
89
89
|
start_time (datetime.datetime):
|
|
@@ -94,7 +94,7 @@ def sync_detailed(
|
|
|
94
94
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
95
95
|
|
|
96
96
|
Returns:
|
|
97
|
-
Response[Union[HTTPValidationError, List['
|
|
97
|
+
Response[Union[HTTPValidationError, List['UsagePerUser']]]
|
|
98
98
|
"""
|
|
99
99
|
|
|
100
100
|
kwargs = _get_kwargs(
|
|
@@ -116,8 +116,8 @@ def sync(
|
|
|
116
116
|
client: Client,
|
|
117
117
|
start_time: datetime.datetime,
|
|
118
118
|
end_time: datetime.datetime,
|
|
119
|
-
) -> Optional[Union[HTTPValidationError, List["
|
|
120
|
-
"""Get
|
|
119
|
+
) -> Optional[Union[HTTPValidationError, List["UsagePerUser"]]]:
|
|
120
|
+
"""Get Usage Per User
|
|
121
121
|
|
|
122
122
|
Args:
|
|
123
123
|
start_time (datetime.datetime):
|
|
@@ -128,7 +128,7 @@ def sync(
|
|
|
128
128
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
129
129
|
|
|
130
130
|
Returns:
|
|
131
|
-
Union[HTTPValidationError, List['
|
|
131
|
+
Union[HTTPValidationError, List['UsagePerUser']]
|
|
132
132
|
"""
|
|
133
133
|
|
|
134
134
|
return sync_detailed(
|
|
@@ -143,8 +143,8 @@ async def asyncio_detailed(
|
|
|
143
143
|
client: Client,
|
|
144
144
|
start_time: datetime.datetime,
|
|
145
145
|
end_time: datetime.datetime,
|
|
146
|
-
) -> Response[Union[HTTPValidationError, List["
|
|
147
|
-
"""Get
|
|
146
|
+
) -> Response[Union[HTTPValidationError, List["UsagePerUser"]]]:
|
|
147
|
+
"""Get Usage Per User
|
|
148
148
|
|
|
149
149
|
Args:
|
|
150
150
|
start_time (datetime.datetime):
|
|
@@ -155,7 +155,7 @@ async def asyncio_detailed(
|
|
|
155
155
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
156
156
|
|
|
157
157
|
Returns:
|
|
158
|
-
Response[Union[HTTPValidationError, List['
|
|
158
|
+
Response[Union[HTTPValidationError, List['UsagePerUser']]]
|
|
159
159
|
"""
|
|
160
160
|
|
|
161
161
|
kwargs = _get_kwargs(
|
|
@@ -175,8 +175,8 @@ async def asyncio(
|
|
|
175
175
|
client: Client,
|
|
176
176
|
start_time: datetime.datetime,
|
|
177
177
|
end_time: datetime.datetime,
|
|
178
|
-
) -> Optional[Union[HTTPValidationError, List["
|
|
179
|
-
"""Get
|
|
178
|
+
) -> Optional[Union[HTTPValidationError, List["UsagePerUser"]]]:
|
|
179
|
+
"""Get Usage Per User
|
|
180
180
|
|
|
181
181
|
Args:
|
|
182
182
|
start_time (datetime.datetime):
|
|
@@ -187,7 +187,7 @@ async def asyncio(
|
|
|
187
187
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
188
188
|
|
|
189
189
|
Returns:
|
|
190
|
-
Union[HTTPValidationError, List['
|
|
190
|
+
Union[HTTPValidationError, List['UsagePerUser']]
|
|
191
191
|
"""
|
|
192
192
|
|
|
193
193
|
return (
|
|
@@ -38,7 +38,9 @@ def _get_kwargs(
|
|
|
38
38
|
}
|
|
39
39
|
|
|
40
40
|
|
|
41
|
-
def _parse_response(
|
|
41
|
+
def _parse_response(
|
|
42
|
+
*, client: Client, response: httpx.Response
|
|
43
|
+
) -> Optional[Union[HTTPValidationError, str]]:
|
|
42
44
|
if response.status_code == HTTPStatus.OK:
|
|
43
45
|
response_200 = cast(str, response.json())
|
|
44
46
|
return response_200
|
|
@@ -52,7 +54,9 @@ def _parse_response(*, client: Client, response: httpx.Response) -> Optional[Uni
|
|
|
52
54
|
return None
|
|
53
55
|
|
|
54
56
|
|
|
55
|
-
def _build_response(
|
|
57
|
+
def _build_response(
|
|
58
|
+
*, client: Client, response: httpx.Response
|
|
59
|
+
) -> Response[Union[HTTPValidationError, str]]:
|
|
56
60
|
return Response(
|
|
57
61
|
status_code=HTTPStatus(response.status_code),
|
|
58
62
|
content=response.content,
|
|
@@ -33,7 +33,9 @@ def _get_kwargs(
|
|
|
33
33
|
}
|
|
34
34
|
|
|
35
35
|
|
|
36
|
-
def _parse_response(
|
|
36
|
+
def _parse_response(
|
|
37
|
+
*, client: Client, response: httpx.Response
|
|
38
|
+
) -> Optional[Union[HTTPValidationError, Status]]:
|
|
37
39
|
if response.status_code == HTTPStatus.OK:
|
|
38
40
|
response_200 = Status.from_dict(response.json())
|
|
39
41
|
|
|
@@ -48,7 +50,9 @@ def _parse_response(*, client: Client, response: httpx.Response) -> Optional[Uni
|
|
|
48
50
|
return None
|
|
49
51
|
|
|
50
52
|
|
|
51
|
-
def _build_response(
|
|
53
|
+
def _build_response(
|
|
54
|
+
*, client: Client, response: httpx.Response
|
|
55
|
+
) -> Response[Union[HTTPValidationError, Status]]:
|
|
52
56
|
return Response(
|
|
53
57
|
status_code=HTTPStatus(response.status_code),
|
|
54
58
|
content=response.content,
|
{fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/api/billing/delete_payment_method.py
RENAMED
|
@@ -14,7 +14,9 @@ def _get_kwargs(
|
|
|
14
14
|
*,
|
|
15
15
|
client: Client,
|
|
16
16
|
) -> Dict[str, Any]:
|
|
17
|
-
url = "{}/billing/payment_methods/{payment_method_id}".format(
|
|
17
|
+
url = "{}/billing/payment_methods/{payment_method_id}".format(
|
|
18
|
+
client.base_url, payment_method_id=payment_method_id
|
|
19
|
+
)
|
|
18
20
|
|
|
19
21
|
headers: Dict[str, str] = client.get_headers()
|
|
20
22
|
cookies: Dict[str, Any] = client.get_cookies()
|
|
@@ -29,7 +31,9 @@ def _get_kwargs(
|
|
|
29
31
|
}
|
|
30
32
|
|
|
31
33
|
|
|
32
|
-
def _parse_response(
|
|
34
|
+
def _parse_response(
|
|
35
|
+
*, client: Client, response: httpx.Response
|
|
36
|
+
) -> Optional[Union[HTTPValidationError, bool]]:
|
|
33
37
|
if response.status_code == HTTPStatus.OK:
|
|
34
38
|
response_200 = cast(bool, response.json())
|
|
35
39
|
return response_200
|
|
@@ -43,7 +47,9 @@ def _parse_response(*, client: Client, response: httpx.Response) -> Optional[Uni
|
|
|
43
47
|
return None
|
|
44
48
|
|
|
45
49
|
|
|
46
|
-
def _build_response(
|
|
50
|
+
def _build_response(
|
|
51
|
+
*, client: Client, response: httpx.Response
|
|
52
|
+
) -> Response[Union[HTTPValidationError, bool]]:
|
|
47
53
|
return Response(
|
|
48
54
|
status_code=HTTPStatus(response.status_code),
|
|
49
55
|
content=response.content,
|
{fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/api/billing/get_setup_intent_key.py
RENAMED
|
@@ -28,7 +28,9 @@ def _get_kwargs(
|
|
|
28
28
|
}
|
|
29
29
|
|
|
30
30
|
|
|
31
|
-
def _parse_response(
|
|
31
|
+
def _parse_response(
|
|
32
|
+
*, client: Client, response: httpx.Response
|
|
33
|
+
) -> Optional[Union[HTTPValidationError, str]]:
|
|
32
34
|
if response.status_code == HTTPStatus.OK:
|
|
33
35
|
response_200 = cast(str, response.json())
|
|
34
36
|
return response_200
|
|
@@ -42,7 +44,9 @@ def _parse_response(*, client: Client, response: httpx.Response) -> Optional[Uni
|
|
|
42
44
|
return None
|
|
43
45
|
|
|
44
46
|
|
|
45
|
-
def _build_response(
|
|
47
|
+
def _build_response(
|
|
48
|
+
*, client: Client, response: httpx.Response
|
|
49
|
+
) -> Response[Union[HTTPValidationError, str]]:
|
|
46
50
|
return Response(
|
|
47
51
|
status_code=HTTPStatus(response.status_code),
|
|
48
52
|
content=response.content,
|
|
@@ -41,7 +41,9 @@ def _get_kwargs(
|
|
|
41
41
|
}
|
|
42
42
|
|
|
43
43
|
|
|
44
|
-
def _parse_response(
|
|
44
|
+
def _parse_response(
|
|
45
|
+
*, client: Client, response: httpx.Response
|
|
46
|
+
) -> Optional[Union[HTTPValidationError, float]]:
|
|
45
47
|
if response.status_code == HTTPStatus.OK:
|
|
46
48
|
response_200 = cast(float, response.json())
|
|
47
49
|
return response_200
|
|
@@ -55,7 +57,9 @@ def _parse_response(*, client: Client, response: httpx.Response) -> Optional[Uni
|
|
|
55
57
|
return None
|
|
56
58
|
|
|
57
59
|
|
|
58
|
-
def _build_response(
|
|
60
|
+
def _build_response(
|
|
61
|
+
*, client: Client, response: httpx.Response
|
|
62
|
+
) -> Response[Union[HTTPValidationError, float]]:
|
|
59
63
|
return Response(
|
|
60
64
|
status_code=HTTPStatus(response.status_code),
|
|
61
65
|
content=response.content,
|
{fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/api/billing/get_user_spending.py
RENAMED
|
@@ -47,7 +47,9 @@ def _get_kwargs(
|
|
|
47
47
|
}
|
|
48
48
|
|
|
49
49
|
|
|
50
|
-
def _parse_response(
|
|
50
|
+
def _parse_response(
|
|
51
|
+
*, client: Client, response: httpx.Response
|
|
52
|
+
) -> Optional[Union[HTTPValidationError, float]]:
|
|
51
53
|
if response.status_code == HTTPStatus.OK:
|
|
52
54
|
response_200 = cast(float, response.json())
|
|
53
55
|
return response_200
|
|
@@ -61,7 +63,9 @@ def _parse_response(*, client: Client, response: httpx.Response) -> Optional[Uni
|
|
|
61
63
|
return None
|
|
62
64
|
|
|
63
65
|
|
|
64
|
-
def _build_response(
|
|
66
|
+
def _build_response(
|
|
67
|
+
*, client: Client, response: httpx.Response
|
|
68
|
+
) -> Response[Union[HTTPValidationError, float]]:
|
|
65
69
|
return Response(
|
|
66
70
|
status_code=HTTPStatus(response.status_code),
|
|
67
71
|
content=response.content,
|
{fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/api/billing/handle_stripe_webhook.py
RENAMED
|
@@ -37,9 +37,13 @@ def _get_kwargs(
|
|
|
37
37
|
|
|
38
38
|
def _parse_response(
|
|
39
39
|
*, client: Client, response: httpx.Response
|
|
40
|
-
) -> Optional[
|
|
40
|
+
) -> Optional[
|
|
41
|
+
Union[HTTPValidationError, HandleStripeWebhookResponseHandleStripeWebhook]
|
|
42
|
+
]:
|
|
41
43
|
if response.status_code == HTTPStatus.OK:
|
|
42
|
-
response_200 = HandleStripeWebhookResponseHandleStripeWebhook.from_dict(
|
|
44
|
+
response_200 = HandleStripeWebhookResponseHandleStripeWebhook.from_dict(
|
|
45
|
+
response.json()
|
|
46
|
+
)
|
|
43
47
|
|
|
44
48
|
return response_200
|
|
45
49
|
if response.status_code == HTTPStatus.UNPROCESSABLE_ENTITY:
|
|
@@ -54,7 +58,9 @@ def _parse_response(
|
|
|
54
58
|
|
|
55
59
|
def _build_response(
|
|
56
60
|
*, client: Client, response: httpx.Response
|
|
57
|
-
) -> Response[
|
|
61
|
+
) -> Response[
|
|
62
|
+
Union[HTTPValidationError, HandleStripeWebhookResponseHandleStripeWebhook]
|
|
63
|
+
]:
|
|
58
64
|
return Response(
|
|
59
65
|
status_code=HTTPStatus(response.status_code),
|
|
60
66
|
content=response.content,
|
|
@@ -67,7 +73,9 @@ def sync_detailed(
|
|
|
67
73
|
*,
|
|
68
74
|
client: Client,
|
|
69
75
|
stripe_signature: Union[Unset, str] = UNSET,
|
|
70
|
-
) -> Response[
|
|
76
|
+
) -> Response[
|
|
77
|
+
Union[HTTPValidationError, HandleStripeWebhookResponseHandleStripeWebhook]
|
|
78
|
+
]:
|
|
71
79
|
"""Handle Stripe Webhook
|
|
72
80
|
|
|
73
81
|
Args:
|
|
@@ -98,7 +106,9 @@ def sync(
|
|
|
98
106
|
*,
|
|
99
107
|
client: Client,
|
|
100
108
|
stripe_signature: Union[Unset, str] = UNSET,
|
|
101
|
-
) -> Optional[
|
|
109
|
+
) -> Optional[
|
|
110
|
+
Union[HTTPValidationError, HandleStripeWebhookResponseHandleStripeWebhook]
|
|
111
|
+
]:
|
|
102
112
|
"""Handle Stripe Webhook
|
|
103
113
|
|
|
104
114
|
Args:
|
|
@@ -122,7 +132,9 @@ async def asyncio_detailed(
|
|
|
122
132
|
*,
|
|
123
133
|
client: Client,
|
|
124
134
|
stripe_signature: Union[Unset, str] = UNSET,
|
|
125
|
-
) -> Response[
|
|
135
|
+
) -> Response[
|
|
136
|
+
Union[HTTPValidationError, HandleStripeWebhookResponseHandleStripeWebhook]
|
|
137
|
+
]:
|
|
126
138
|
"""Handle Stripe Webhook
|
|
127
139
|
|
|
128
140
|
Args:
|
|
@@ -151,7 +163,9 @@ async def asyncio(
|
|
|
151
163
|
*,
|
|
152
164
|
client: Client,
|
|
153
165
|
stripe_signature: Union[Unset, str] = UNSET,
|
|
154
|
-
) -> Optional[
|
|
166
|
+
) -> Optional[
|
|
167
|
+
Union[HTTPValidationError, HandleStripeWebhookResponseHandleStripeWebhook]
|
|
168
|
+
]:
|
|
155
169
|
"""Handle Stripe Webhook
|
|
156
170
|
|
|
157
171
|
Args:
|
|
@@ -29,7 +29,9 @@ def _get_kwargs(
|
|
|
29
29
|
}
|
|
30
30
|
|
|
31
31
|
|
|
32
|
-
def _parse_response(
|
|
32
|
+
def _parse_response(
|
|
33
|
+
*, client: Client, response: httpx.Response
|
|
34
|
+
) -> Optional[Union[HTTPValidationError, Invoice]]:
|
|
33
35
|
if response.status_code == HTTPStatus.OK:
|
|
34
36
|
response_200 = Invoice.from_dict(response.json())
|
|
35
37
|
|
|
@@ -44,7 +46,9 @@ def _parse_response(*, client: Client, response: httpx.Response) -> Optional[Uni
|
|
|
44
46
|
return None
|
|
45
47
|
|
|
46
48
|
|
|
47
|
-
def _build_response(
|
|
49
|
+
def _build_response(
|
|
50
|
+
*, client: Client, response: httpx.Response
|
|
51
|
+
) -> Response[Union[HTTPValidationError, Invoice]]:
|
|
48
52
|
return Response(
|
|
49
53
|
status_code=HTTPStatus(response.status_code),
|
|
50
54
|
content=response.content,
|
{fal-0.11.1 → fal-0.11.3}/openapi-fal-rest/openapi_fal_rest/api/billing/update_customer_budget.py
RENAMED
|
@@ -38,7 +38,9 @@ def _get_kwargs(
|
|
|
38
38
|
}
|
|
39
39
|
|
|
40
40
|
|
|
41
|
-
def _parse_response(
|
|
41
|
+
def _parse_response(
|
|
42
|
+
*, client: Client, response: httpx.Response
|
|
43
|
+
) -> Optional[Union[Any, HTTPValidationError]]:
|
|
42
44
|
if response.status_code == HTTPStatus.OK:
|
|
43
45
|
response_200 = cast(Any, response.json())
|
|
44
46
|
return response_200
|
|
@@ -52,7 +54,9 @@ def _parse_response(*, client: Client, response: httpx.Response) -> Optional[Uni
|
|
|
52
54
|
return None
|
|
53
55
|
|
|
54
56
|
|
|
55
|
-
def _build_response(
|
|
57
|
+
def _build_response(
|
|
58
|
+
*, client: Client, response: httpx.Response
|
|
59
|
+
) -> Response[Union[Any, HTTPValidationError]]:
|
|
56
60
|
return Response(
|
|
57
61
|
status_code=HTTPStatus(response.status_code),
|
|
58
62
|
content=response.content,
|
|
@@ -16,7 +16,9 @@ def _get_kwargs(
|
|
|
16
16
|
client: Client,
|
|
17
17
|
json_body: HashCheck,
|
|
18
18
|
) -> Dict[str, Any]:
|
|
19
|
-
url = "{}/files/dir/check_hash/{target_path}".format(
|
|
19
|
+
url = "{}/files/dir/check_hash/{target_path}".format(
|
|
20
|
+
client.base_url, target_path=target_path
|
|
21
|
+
)
|
|
20
22
|
|
|
21
23
|
headers: Dict[str, str] = client.get_headers()
|
|
22
24
|
cookies: Dict[str, Any] = client.get_cookies()
|
|
@@ -34,7 +36,9 @@ def _get_kwargs(
|
|
|
34
36
|
}
|
|
35
37
|
|
|
36
38
|
|
|
37
|
-
def _parse_response(
|
|
39
|
+
def _parse_response(
|
|
40
|
+
*, client: Client, response: httpx.Response
|
|
41
|
+
) -> Optional[Union[HTTPValidationError, bool]]:
|
|
38
42
|
if response.status_code == HTTPStatus.OK:
|
|
39
43
|
response_200 = cast(bool, response.json())
|
|
40
44
|
return response_200
|
|
@@ -48,7 +52,9 @@ def _parse_response(*, client: Client, response: httpx.Response) -> Optional[Uni
|
|
|
48
52
|
return None
|
|
49
53
|
|
|
50
54
|
|
|
51
|
-
def _build_response(
|
|
55
|
+
def _build_response(
|
|
56
|
+
*, client: Client, response: httpx.Response
|
|
57
|
+
) -> Response[Union[HTTPValidationError, bool]]:
|
|
52
58
|
return Response(
|
|
53
59
|
status_code=HTTPStatus(response.status_code),
|
|
54
60
|
content=response.content,
|
|
@@ -29,7 +29,9 @@ def _get_kwargs(
|
|
|
29
29
|
}
|
|
30
30
|
|
|
31
31
|
|
|
32
|
-
def _parse_response(
|
|
32
|
+
def _parse_response(
|
|
33
|
+
*, client: Client, response: httpx.Response
|
|
34
|
+
) -> Optional[Union[HTTPValidationError, bool]]:
|
|
33
35
|
if response.status_code == HTTPStatus.OK:
|
|
34
36
|
response_200 = cast(bool, response.json())
|
|
35
37
|
return response_200
|
|
@@ -43,7 +45,9 @@ def _parse_response(*, client: Client, response: httpx.Response) -> Optional[Uni
|
|
|
43
45
|
return None
|
|
44
46
|
|
|
45
47
|
|
|
46
|
-
def _build_response(
|
|
48
|
+
def _build_response(
|
|
49
|
+
*, client: Client, response: httpx.Response
|
|
50
|
+
) -> Response[Union[HTTPValidationError, bool]]:
|
|
47
51
|
return Response(
|
|
48
52
|
status_code=HTTPStatus(response.status_code),
|
|
49
53
|
content=response.content,
|
|
@@ -29,7 +29,9 @@ def _get_kwargs(
|
|
|
29
29
|
}
|
|
30
30
|
|
|
31
31
|
|
|
32
|
-
def _parse_response(
|
|
32
|
+
def _parse_response(
|
|
33
|
+
*, client: Client, response: httpx.Response
|
|
34
|
+
) -> Optional[Union[Any, HTTPValidationError]]:
|
|
33
35
|
if response.status_code == HTTPStatus.OK:
|
|
34
36
|
response_200 = cast(Any, response.json())
|
|
35
37
|
return response_200
|
|
@@ -43,7 +45,9 @@ def _parse_response(*, client: Client, response: httpx.Response) -> Optional[Uni
|
|
|
43
45
|
return None
|
|
44
46
|
|
|
45
47
|
|
|
46
|
-
def _build_response(
|
|
48
|
+
def _build_response(
|
|
49
|
+
*, client: Client, response: httpx.Response
|
|
50
|
+
) -> Response[Union[Any, HTTPValidationError]]:
|
|
47
51
|
return Response(
|
|
48
52
|
status_code=HTTPStatus(response.status_code),
|
|
49
53
|
content=response.content,
|
|
@@ -37,7 +37,9 @@ def _get_kwargs(
|
|
|
37
37
|
}
|
|
38
38
|
|
|
39
39
|
|
|
40
|
-
def _parse_response(
|
|
40
|
+
def _parse_response(
|
|
41
|
+
*, client: Client, response: httpx.Response
|
|
42
|
+
) -> Optional[Union[FileSpec, HTTPValidationError]]:
|
|
41
43
|
if response.status_code == HTTPStatus.OK:
|
|
42
44
|
response_200 = FileSpec.from_dict(response.json())
|
|
43
45
|
|
|
@@ -52,7 +54,9 @@ def _parse_response(*, client: Client, response: httpx.Response) -> Optional[Uni
|
|
|
52
54
|
return None
|
|
53
55
|
|
|
54
56
|
|
|
55
|
-
def _build_response(
|
|
57
|
+
def _build_response(
|
|
58
|
+
*, client: Client, response: httpx.Response
|
|
59
|
+
) -> Response[Union[FileSpec, HTTPValidationError]]:
|
|
56
60
|
return Response(
|
|
57
61
|
status_code=HTTPStatus(response.status_code),
|
|
58
62
|
content=response.content,
|
|
@@ -34,7 +34,9 @@ def _get_kwargs(
|
|
|
34
34
|
}
|
|
35
35
|
|
|
36
36
|
|
|
37
|
-
def _parse_response(
|
|
37
|
+
def _parse_response(
|
|
38
|
+
*, client: Client, response: httpx.Response
|
|
39
|
+
) -> Optional[Union[HTTPValidationError, bool]]:
|
|
38
40
|
if response.status_code == HTTPStatus.OK:
|
|
39
41
|
response_200 = cast(bool, response.json())
|
|
40
42
|
return response_200
|
|
@@ -48,7 +50,9 @@ def _parse_response(*, client: Client, response: httpx.Response) -> Optional[Uni
|
|
|
48
50
|
return None
|
|
49
51
|
|
|
50
52
|
|
|
51
|
-
def _build_response(
|
|
53
|
+
def _build_response(
|
|
54
|
+
*, client: Client, response: httpx.Response
|
|
55
|
+
) -> Response[Union[HTTPValidationError, bool]]:
|
|
52
56
|
return Response(
|
|
53
57
|
status_code=HTTPStatus(response.status_code),
|
|
54
58
|
content=response.content,
|
|
@@ -17,7 +17,9 @@ def _get_kwargs(
|
|
|
17
17
|
multipart_data: BodyUploadLocalFile,
|
|
18
18
|
unzip: Union[Unset, None, bool] = False,
|
|
19
19
|
) -> Dict[str, Any]:
|
|
20
|
-
url = "{}/files/file/local/{target_path}".format(
|
|
20
|
+
url = "{}/files/file/local/{target_path}".format(
|
|
21
|
+
client.base_url, target_path=target_path
|
|
22
|
+
)
|
|
21
23
|
|
|
22
24
|
headers: Dict[str, str] = client.get_headers()
|
|
23
25
|
cookies: Dict[str, Any] = client.get_cookies()
|
|
@@ -41,7 +43,9 @@ def _get_kwargs(
|
|
|
41
43
|
}
|
|
42
44
|
|
|
43
45
|
|
|
44
|
-
def _parse_response(
|
|
46
|
+
def _parse_response(
|
|
47
|
+
*, client: Client, response: httpx.Response
|
|
48
|
+
) -> Optional[Union[HTTPValidationError, bool]]:
|
|
45
49
|
if response.status_code == HTTPStatus.OK:
|
|
46
50
|
response_200 = cast(bool, response.json())
|
|
47
51
|
return response_200
|
|
@@ -55,7 +59,9 @@ def _parse_response(*, client: Client, response: httpx.Response) -> Optional[Uni
|
|
|
55
59
|
return None
|
|
56
60
|
|
|
57
61
|
|
|
58
|
-
def _build_response(
|
|
62
|
+
def _build_response(
|
|
63
|
+
*, client: Client, response: httpx.Response
|
|
64
|
+
) -> Response[Union[HTTPValidationError, bool]]:
|
|
59
65
|
return Response(
|
|
60
66
|
status_code=HTTPStatus(response.status_code),
|
|
61
67
|
content=response.content,
|
|
@@ -42,7 +42,9 @@ def _get_kwargs(
|
|
|
42
42
|
}
|
|
43
43
|
|
|
44
44
|
|
|
45
|
-
def _parse_response(
|
|
45
|
+
def _parse_response(
|
|
46
|
+
*, client: Client, response: httpx.Response
|
|
47
|
+
) -> Optional[Union[HTTPValidationError, NewUserKey]]:
|
|
46
48
|
if response.status_code == HTTPStatus.CREATED:
|
|
47
49
|
response_201 = NewUserKey.from_dict(response.json())
|
|
48
50
|
|
|
@@ -57,7 +59,9 @@ def _parse_response(*, client: Client, response: httpx.Response) -> Optional[Uni
|
|
|
57
59
|
return None
|
|
58
60
|
|
|
59
61
|
|
|
60
|
-
def _build_response(
|
|
62
|
+
def _build_response(
|
|
63
|
+
*, client: Client, response: httpx.Response
|
|
64
|
+
) -> Response[Union[HTTPValidationError, NewUserKey]]:
|
|
61
65
|
return Response(
|
|
62
66
|
status_code=HTTPStatus(response.status_code),
|
|
63
67
|
content=response.content,
|