crypticorn 2.4.5__tar.gz → 2.4.7__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.
- {crypticorn-2.4.5 → crypticorn-2.4.7}/PKG-INFO +13 -2
- {crypticorn-2.4.5 → crypticorn-2.4.7}/README.md +7 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/client.py +1 -1
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/common/auth.py +7 -9
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/common/errors.py +6 -1
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/common/scopes.py +2 -1
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/common/utils.py +15 -5
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/klines/main.py +10 -5
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/metrics/client/models/exchange_mapping.py +4 -2
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/metrics/client/models/trading_status.py +1 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/metrics/main.py +5 -4
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/__init__.py +5 -4
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/api/payments_api.py +17 -17
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/api/products_api.py +49 -48
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/models/__init__.py +5 -4
- crypticorn-2.4.7/crypticorn/pay/client/models/payment.py +112 -0
- crypticorn-2.4.7/crypticorn/pay/client/models/product_create.py +120 -0
- crypticorn-2.4.7/crypticorn/pay/client/models/product_read.py +123 -0
- crypticorn-2.4.7/crypticorn/pay/client/models/product_sub_read.py +103 -0
- crypticorn-2.4.7/crypticorn/pay/client/models/product_update.py +142 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/client/__init__.py +6 -8
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/client/api/__init__.py +1 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/client/api/api_keys_api.py +273 -167
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/client/api/bots_api.py +226 -140
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/client/api/exchanges_api.py +51 -31
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/client/api/futures_trading_panel_api.py +272 -169
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/client/api/notifications_api.py +323 -200
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/client/api/orders_api.py +60 -40
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/client/api/status_api.py +49 -31
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/client/api/strategies_api.py +223 -137
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/client/api/trading_actions_api.py +170 -106
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/client/api_client.py +153 -111
- crypticorn-2.4.7/crypticorn/trade/client/api_response.py +21 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/client/configuration.py +115 -128
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/client/exceptions.py +21 -25
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/client/models/__init__.py +6 -8
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/client/models/action_model.py +54 -108
- crypticorn-2.4.7/crypticorn/trade/client/models/api_error_identifier.py +100 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/client/models/api_error_level.py +11 -9
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/client/models/api_error_type.py +11 -9
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/client/models/bot_model.py +36 -57
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/client/models/bot_status.py +11 -9
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/client/models/exchange.py +9 -7
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/client/models/exchange_key_model.py +34 -44
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/client/models/execution_ids.py +18 -18
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/client/models/futures_balance.py +27 -43
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/client/models/futures_trading_action.py +50 -102
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/client/models/http_validation_error.py +15 -19
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/client/models/margin_mode.py +9 -7
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/client/models/market_type.py +9 -7
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/client/models/notification_model.py +32 -52
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/client/models/order_model.py +72 -112
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/client/models/order_status.py +12 -10
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/client/models/post_futures_action.py +16 -20
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/client/models/strategy_exchange_info.py +16 -15
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/client/models/strategy_model_input.py +33 -61
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/client/models/strategy_model_output.py +33 -61
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/client/models/tpsl.py +25 -39
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/client/models/trading_action_type.py +11 -9
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/client/models/validation_error.py +18 -24
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/client/models/validation_error_loc_inner.py +16 -37
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/client/rest.py +38 -23
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn.egg-info/PKG-INFO +13 -2
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn.egg-info/SOURCES.txt +6 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn.egg-info/requires.txt +6 -1
- {crypticorn-2.4.5 → crypticorn-2.4.7}/pyproject.toml +2 -1
- {crypticorn-2.4.5 → crypticorn-2.4.7}/requirements/dev.txt +3 -0
- crypticorn-2.4.7/requirements/extra.txt +2 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/requirements/main.txt +0 -1
- {crypticorn-2.4.5 → crypticorn-2.4.7}/tests/test_auth_client.py +1 -13
- crypticorn-2.4.7/tests/test_config.py +20 -0
- crypticorn-2.4.5/crypticorn/pay/client/models/payment.py +0 -231
- crypticorn-2.4.5/crypticorn/trade/client/api_response.py +0 -20
- crypticorn-2.4.5/crypticorn/trade/client/models/api_error_identifier.py +0 -104
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/__init__.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/__init__.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/__init__.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/api/__init__.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/api/admin_api.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/api/auth_api.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/api/service_api.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/api/user_api.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/api/wallet_api.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/api_client.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/api_response.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/configuration.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/exceptions.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/models/__init__.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/models/add_wallet200_response.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/models/add_wallet_request.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/models/authorize_user200_response.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/models/authorize_user200_response_auth.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/models/authorize_user_request.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/models/create_api_key200_response.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/models/create_api_key_request.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/models/create_user_request.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/models/get_api_keys200_response_inner.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/models/list_wallets200_response.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/models/list_wallets200_response_balances_inner.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/models/list_wallets200_response_balances_inner_sale_round.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/models/list_wallets200_response_balances_inner_wallet.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/models/list_wallets200_response_balances_inner_wallet_vesting_wallets_inner.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/models/list_wallets200_response_data_inner.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/models/list_wallets200_response_user_value.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/models/logout_default_response.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/models/logout_default_response_issues_inner.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/models/oauth_callback200_response.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/models/oauth_callback200_response_user.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/models/refresh_token_info200_response.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/models/refresh_token_info200_response_user_session.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/models/resend_verification_email_request.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/models/revoke_user_tokens_request.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/models/rotate_tokens200_response.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/models/token_info200_response.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/models/unlink_wallet_request.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/models/update_user_request.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/models/user_reset_password_request.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/models/user_set_password_request.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/models/verify200_response.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/models/verify_email200_response.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/models/verify_email200_response_auth.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/models/verify_email200_response_auth_auth.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/models/verify_email_request.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/models/verify_wallet_request.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/models/wallet_verified200_response.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/models/whoami200_response.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/py.typed +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/client/rest.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/auth/main.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/cli/__init__.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/cli/__main__.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/cli/init.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/cli/templates/__init__.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/cli/templates/auth.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/common/__init__.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/common/enums.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/common/pydantic.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/common/sorter.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/common/urls.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/hive/__init__.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/hive/client/__init__.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/hive/client/api/__init__.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/hive/client/api/data_api.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/hive/client/api/models_api.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/hive/client/api/status_api.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/hive/client/api_client.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/hive/client/api_response.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/hive/client/configuration.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/hive/client/exceptions.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/hive/client/models/__init__.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/hive/client/models/coins.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/hive/client/models/data_download_response.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/hive/client/models/data_info.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/hive/client/models/data_value_value_value_inner.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/hive/client/models/data_version.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/hive/client/models/download_links.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/hive/client/models/evaluation.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/hive/client/models/evaluation_response.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/hive/client/models/feature_size.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/hive/client/models/http_validation_error.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/hive/client/models/model.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/hive/client/models/model_create.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/hive/client/models/model_status.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/hive/client/models/model_update.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/hive/client/models/target.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/hive/client/models/target_type.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/hive/client/models/validation_error.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/hive/client/models/validation_error_loc_inner.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/hive/client/py.typed +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/hive/client/rest.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/hive/main.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/klines/__init__.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/klines/client/__init__.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/klines/client/api/__init__.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/klines/client/api/funding_rates_api.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/klines/client/api/health_check_api.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/klines/client/api/ohlcv_data_api.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/klines/client/api/symbols_api.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/klines/client/api/udf_api.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/klines/client/api_client.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/klines/client/api_response.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/klines/client/configuration.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/klines/client/exceptions.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/klines/client/models/__init__.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/klines/client/models/base_response_health_check_response.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/klines/client/models/base_response_list_funding_rate_response.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/klines/client/models/base_response_list_str.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/klines/client/models/base_response_ohlcv_response.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/klines/client/models/error_response.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/klines/client/models/exchange.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/klines/client/models/funding_rate_response.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/klines/client/models/health_check_response.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/klines/client/models/history_error_response.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/klines/client/models/history_no_data_response.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/klines/client/models/history_success_response.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/klines/client/models/http_validation_error.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/klines/client/models/market.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/klines/client/models/ohlcv_response.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/klines/client/models/resolution.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/klines/client/models/response_get_history_udf_history_get.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/klines/client/models/search_symbol_response.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/klines/client/models/sort_direction.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/klines/client/models/symbol_group_response.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/klines/client/models/symbol_info_response.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/klines/client/models/symbol_type.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/klines/client/models/timeframe.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/klines/client/models/udf_config_response.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/klines/client/models/validation_error.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/klines/client/models/validation_error_loc_inner.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/klines/client/py.typed +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/klines/client/rest.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/metrics/__init__.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/metrics/client/__init__.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/metrics/client/api/__init__.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/metrics/client/api/exchanges_api.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/metrics/client/api/health_check_api.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/metrics/client/api/indicators_api.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/metrics/client/api/logs_api.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/metrics/client/api/marketcap_api.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/metrics/client/api/markets_api.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/metrics/client/api/tokens_api.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/metrics/client/api_client.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/metrics/client/api_response.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/metrics/client/configuration.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/metrics/client/exceptions.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/metrics/client/models/__init__.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/metrics/client/models/base_response_dict.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/metrics/client/models/base_response_health_check_response.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/metrics/client/models/base_response_list_dict.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/metrics/client/models/base_response_list_exchange_mapping.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/metrics/client/models/base_response_list_str.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/metrics/client/models/error_response.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/metrics/client/models/health_check_response.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/metrics/client/models/http_validation_error.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/metrics/client/models/market.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/metrics/client/models/market_type.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/metrics/client/models/severity.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/metrics/client/models/time_interval.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/metrics/client/models/validation_error.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/metrics/client/models/validation_error_loc_inner.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/metrics/client/py.typed +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/metrics/client/rest.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/__init__.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/api/__init__.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/api/now_payments_api.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/api/status_api.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/api_client.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/api_response.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/configuration.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/exceptions.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/models/api_status_res.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/models/body_create_now_invoice.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/models/body_create_product.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/models/body_get_products.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/models/body_handle_now_webhook.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/models/body_update_product.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/models/combined_payment_history.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/models/create_invoice_req.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/models/create_invoice_res.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/models/currency.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/models/estimate_price_req.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/models/estimate_price_res.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/models/get_currencies_res.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/models/get_payment_status_res.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/models/get_payments_list_res.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/models/http_validation_error.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/models/min_amount_req.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/models/min_amount_res.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/models/now_api_status_res.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/models/now_create_invoice_req.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/models/now_create_invoice_res.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/models/now_fee_structure.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/models/now_payment_model.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/models/now_payment_status.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/models/now_webhook_payload.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/models/partial_product_update_model.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/models/payment_status.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/models/product.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/models/product_model.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/models/product_subs_model.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/models/product_update_model.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/models/scope.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/models/services.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/models/unified_payment_model.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/models/validation_error.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/models/validation_error_loc_inner.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/py.typed +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/client/rest.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/pay/main.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/__init__.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/client/models/api_key_model.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/client/py.typed +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn/trade/main.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn.egg-info/dependency_links.txt +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn.egg-info/entry_points.txt +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/crypticorn.egg-info/top_level.txt +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/requirements/test.txt +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/setup.cfg +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/tests/test_enums.py +0 -0
- {crypticorn-2.4.5 → crypticorn-2.4.7}/tests/test_errors.py +0 -0
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.4
|
2
2
|
Name: crypticorn
|
3
|
-
Version: 2.4.
|
3
|
+
Version: 2.4.7
|
4
4
|
Summary: Maximise Your Crypto Trading Profits with AI Predictions
|
5
5
|
Author-email: Crypticorn <timon@crypticorn.com>
|
6
6
|
Project-URL: Homepage, https://crypticorn.com
|
@@ -21,19 +21,23 @@ Requires-Dist: aiohttp<4.0.0,>=3.8.4
|
|
21
21
|
Requires-Dist: aiohttp-retry<3.0.0,>=2.8.3
|
22
22
|
Requires-Dist: pydantic<3.0.0,>=2.0.0
|
23
23
|
Requires-Dist: typing-extensions<5.0.0,>=4.7.1
|
24
|
-
Requires-Dist: pandas<3.0.0,>=2.2.0
|
25
24
|
Requires-Dist: requests<3.0.0,>=2.32.0
|
26
25
|
Requires-Dist: tqdm<5.0.0,>=4.67.0
|
27
26
|
Provides-Extra: dev
|
28
27
|
Requires-Dist: streamlit; extra == "dev"
|
29
28
|
Requires-Dist: httpx; extra == "dev"
|
30
29
|
Requires-Dist: black; extra == "dev"
|
30
|
+
Requires-Dist: ruff; extra == "dev"
|
31
|
+
Requires-Dist: isort; extra == "dev"
|
32
|
+
Requires-Dist: mypy; extra == "dev"
|
31
33
|
Requires-Dist: openapi-generator-cli<8.0.0,>=7.12.0; extra == "dev"
|
32
34
|
Provides-Extra: test
|
33
35
|
Requires-Dist: pytest==8.3.5; extra == "test"
|
34
36
|
Requires-Dist: pytest-asyncio==0.26.0; extra == "test"
|
35
37
|
Requires-Dist: pytest-cov==6.1.1; extra == "test"
|
36
38
|
Requires-Dist: python-dotenv==1.0.1; extra == "test"
|
39
|
+
Provides-Extra: extra
|
40
|
+
Requires-Dist: pandas<3.0.0,>=2.2.0; extra == "extra"
|
37
41
|
|
38
42
|
# What is Crypticorn?
|
39
43
|
|
@@ -49,6 +53,8 @@ cryptocurrency market.
|
|
49
53
|
|
50
54
|
## Installation
|
51
55
|
|
56
|
+
>Python 3.10+ required
|
57
|
+
|
52
58
|
You can install the latest stable version from PyPi:
|
53
59
|
```bash
|
54
60
|
pip install crypticorn
|
@@ -95,7 +101,12 @@ client = ApiClient(base_url=BaseUrl.Prod, api_key="your-api-key")
|
|
95
101
|
asyncio.run(client.pay.models.get_products())
|
96
102
|
asyncio.run(client.close())
|
97
103
|
```
|
104
|
+
...or wrapped in a function
|
105
|
+
async def main():
|
106
|
+
await client.pay.products.get_products()
|
98
107
|
|
108
|
+
asyncio.run(main())
|
109
|
+
asyncio.run(client.close())
|
99
110
|
## Response Types
|
100
111
|
|
101
112
|
There are three different available output formats you can choose from:
|
@@ -12,6 +12,8 @@ cryptocurrency market.
|
|
12
12
|
|
13
13
|
## Installation
|
14
14
|
|
15
|
+
>Python 3.10+ required
|
16
|
+
|
15
17
|
You can install the latest stable version from PyPi:
|
16
18
|
```bash
|
17
19
|
pip install crypticorn
|
@@ -58,7 +60,12 @@ client = ApiClient(base_url=BaseUrl.Prod, api_key="your-api-key")
|
|
58
60
|
asyncio.run(client.pay.models.get_products())
|
59
61
|
asyncio.run(client.close())
|
60
62
|
```
|
63
|
+
...or wrapped in a function
|
64
|
+
async def main():
|
65
|
+
await client.pay.products.get_products()
|
61
66
|
|
67
|
+
asyncio.run(main())
|
68
|
+
asyncio.run(client.close())
|
62
69
|
## Response Types
|
63
70
|
|
64
71
|
There are three different available output formats you can choose from:
|
@@ -9,7 +9,7 @@ from crypticorn.common import (
|
|
9
9
|
Scope,
|
10
10
|
Service,
|
11
11
|
)
|
12
|
-
from fastapi import Depends, HTTPException, Query, status
|
12
|
+
from fastapi import Depends, HTTPException, Query, status, WebSocketException
|
13
13
|
from fastapi.security import (
|
14
14
|
HTTPAuthorizationCredentials,
|
15
15
|
SecurityScopes,
|
@@ -183,7 +183,7 @@ class AuthHandler:
|
|
183
183
|
Verifies the API key and checks if the user scopes are a subset of the API scopes.
|
184
184
|
Use this function if you only want to allow access via the API key.
|
185
185
|
"""
|
186
|
-
return await self.
|
186
|
+
return await self.ws_combined_auth(bearer=None, api_key=api_key, sec=sec)
|
187
187
|
|
188
188
|
async def ws_bearer_auth(
|
189
189
|
self,
|
@@ -194,12 +194,7 @@ class AuthHandler:
|
|
194
194
|
Verifies the bearer token and checks if the user scopes are a subset of the API scopes.
|
195
195
|
Use this function if you only want to allow access via the bearer token.
|
196
196
|
"""
|
197
|
-
|
198
|
-
HTTPAuthorizationCredentials(scheme="Bearer", credentials=bearer)
|
199
|
-
if bearer
|
200
|
-
else None
|
201
|
-
)
|
202
|
-
return await self.bearer_auth(bearer=credentials, sec=sec)
|
197
|
+
return await self.ws_combined_auth(bearer=bearer, api_key=None, sec=sec)
|
203
198
|
|
204
199
|
async def ws_combined_auth(
|
205
200
|
self,
|
@@ -216,4 +211,7 @@ class AuthHandler:
|
|
216
211
|
if bearer
|
217
212
|
else None
|
218
213
|
)
|
219
|
-
|
214
|
+
response = await self.combined_auth(bearer=credentials, api_key=api_key, sec=sec)
|
215
|
+
if isinstance(response, HTTPException):
|
216
|
+
raise WebSocketException(code=status.WS_1008_POLICY_VIOLATION, reason=response.detail)
|
217
|
+
return response
|
@@ -7,7 +7,7 @@ logger = logging.getLogger(__name__)
|
|
7
7
|
|
8
8
|
class Fallback(EnumMeta):
|
9
9
|
"""Fallback to UNKNOWN_ERROR for error codes not yet published to PyPI."""
|
10
|
-
|
10
|
+
|
11
11
|
def __getattr__(cls, name):
|
12
12
|
# Let Pydantic/internal stuff pass silently ! fragile
|
13
13
|
if name.startswith("__"):
|
@@ -100,6 +100,11 @@ class ApiErrorIdentifier(StrEnum):
|
|
100
100
|
UNKNOWN_ERROR = "unknown_error_occurred"
|
101
101
|
URL_NOT_FOUND = "requested_resource_not_found"
|
102
102
|
|
103
|
+
@property
|
104
|
+
def get_error_code(self) -> str:
|
105
|
+
"""Get the corresponding ApiError."""
|
106
|
+
return ApiError[self.value]
|
107
|
+
|
103
108
|
|
104
109
|
class ApiErrorLevel(StrEnum):
|
105
110
|
"""API error levels"""
|
@@ -6,6 +6,7 @@ logger = logging.getLogger("uvicorn")
|
|
6
6
|
|
7
7
|
class Fallback(EnumMeta):
|
8
8
|
"""Fallback to no scope for unknown scopes."""
|
9
|
+
|
9
10
|
# Note: This is a workaround to avoid the AttributeError when an unknown scope is accessed.
|
10
11
|
# As soon as we have stable scopes, we can remove this.
|
11
12
|
|
@@ -19,7 +20,7 @@ class Fallback(EnumMeta):
|
|
19
20
|
return None
|
20
21
|
|
21
22
|
|
22
|
-
class Scope(StrEnum
|
23
|
+
class Scope(StrEnum):
|
23
24
|
"""
|
24
25
|
The permission scopes for the API.
|
25
26
|
"""
|
@@ -1,4 +1,4 @@
|
|
1
|
-
from typing import Any
|
1
|
+
from typing import Any, Union
|
2
2
|
from decimal import Decimal
|
3
3
|
import string
|
4
4
|
import random
|
@@ -9,19 +9,19 @@ from fastapi import status
|
|
9
9
|
from crypticorn.common import ApiError
|
10
10
|
|
11
11
|
|
12
|
-
def throw_if_none(value: Any, message: ApiError) -> None:
|
12
|
+
def throw_if_none(value: Any, message: Union[ApiError, str]) -> None:
|
13
13
|
"""Throws an FastAPI HTTPException if the value is None."""
|
14
14
|
if value is None:
|
15
15
|
raise HTTPException(
|
16
|
-
status_code=status.HTTP_404_NOT_FOUND, detail=message.identifier
|
16
|
+
status_code=status.HTTP_404_NOT_FOUND, detail=message.identifier if isinstance(message, ApiError) else message
|
17
17
|
)
|
18
18
|
|
19
19
|
|
20
|
-
def throw_if_falsy(value: Any, message: ApiError) -> None:
|
20
|
+
def throw_if_falsy(value: Any, message: Union[ApiError, str]) -> None:
|
21
21
|
"""Throws an FastAPI HTTPException if the value is False."""
|
22
22
|
if not value:
|
23
23
|
raise HTTPException(
|
24
|
-
status_code=status.HTTP_400_BAD_REQUEST, detail=message.identifier
|
24
|
+
status_code=status.HTTP_400_BAD_REQUEST, detail=message.identifier if isinstance(message, ApiError) else message
|
25
25
|
)
|
26
26
|
|
27
27
|
|
@@ -50,3 +50,13 @@ def is_equal(
|
|
50
50
|
return Decimal(abs(a - b)) <= max(
|
51
51
|
Decimal(str(rel_tol)) * max(abs(a), abs(b)), Decimal(str(abs_tol))
|
52
52
|
)
|
53
|
+
|
54
|
+
def optional_import(module_name: str, extra_name: str):
|
55
|
+
try:
|
56
|
+
return __import__(module_name)
|
57
|
+
except ImportError as e:
|
58
|
+
extra = f"[{extra_name}]"
|
59
|
+
raise ImportError(
|
60
|
+
f"Optional dependency '{module_name}' is required for this feature. "
|
61
|
+
f"Install it with: pip install crypticorn{extra}"
|
62
|
+
) from e
|
@@ -1,4 +1,4 @@
|
|
1
|
-
|
1
|
+
from __future__ import annotations
|
2
2
|
from crypticorn.klines import (
|
3
3
|
ApiClient,
|
4
4
|
Configuration,
|
@@ -8,6 +8,7 @@ from crypticorn.klines import (
|
|
8
8
|
SymbolsApi,
|
9
9
|
UDFApi,
|
10
10
|
)
|
11
|
+
from crypticorn.common import optional_import
|
11
12
|
|
12
13
|
|
13
14
|
class FundingRatesApiWrapper(FundingRatesApi):
|
@@ -15,7 +16,8 @@ class FundingRatesApiWrapper(FundingRatesApi):
|
|
15
16
|
A wrapper for the FundingRatesApi class.
|
16
17
|
"""
|
17
18
|
|
18
|
-
def get_funding_rates_fmt(self):
|
19
|
+
def get_funding_rates_fmt(self) -> pd.DataFrame:
|
20
|
+
pd = optional_import("pandas", "extra")
|
19
21
|
response = self.funding_rate_funding_rates_symbol_get()
|
20
22
|
return pd.DataFrame(response.json())
|
21
23
|
|
@@ -25,7 +27,8 @@ class OHLCVDataApiWrapper(OHLCVDataApi):
|
|
25
27
|
A wrapper for the OHLCVDataApi class.
|
26
28
|
"""
|
27
29
|
|
28
|
-
def get_ohlcv_data_fmt(self):
|
30
|
+
def get_ohlcv_data_fmt(self) -> pd.DataFrame:
|
31
|
+
pd = optional_import("pandas", "extra")
|
29
32
|
response = self.get_ohlcv_market_timeframe_symbol_get()
|
30
33
|
return pd.DataFrame(response.json())
|
31
34
|
|
@@ -35,7 +38,8 @@ class SymbolsApiWrapper(SymbolsApi):
|
|
35
38
|
A wrapper for the SymbolsApi class.
|
36
39
|
"""
|
37
40
|
|
38
|
-
def get_symbols_fmt(self):
|
41
|
+
def get_symbols_fmt(self) -> pd.DataFrame:
|
42
|
+
pd = optional_import("pandas", "extra")
|
39
43
|
response = self.symbols_symbols_market_get()
|
40
44
|
return pd.DataFrame(response.json())
|
41
45
|
|
@@ -45,7 +49,8 @@ class UDFApiWrapper(UDFApi):
|
|
45
49
|
A wrapper for the UDFApi class.
|
46
50
|
"""
|
47
51
|
|
48
|
-
def get_udf_fmt(self):
|
52
|
+
def get_udf_fmt(self) -> pd.DataFrame:
|
53
|
+
pd = optional_import("pandas", "extra")
|
49
54
|
response = self.get_history_udf_history_get()
|
50
55
|
return pd.DataFrame(response.json())
|
51
56
|
|
@@ -20,6 +20,8 @@ import json
|
|
20
20
|
from datetime import datetime
|
21
21
|
from pydantic import BaseModel, ConfigDict, StrictStr
|
22
22
|
from typing import Any, ClassVar, Dict, List, Optional
|
23
|
+
from crypticorn.metrics.client.models.market_type import MarketType
|
24
|
+
from crypticorn.metrics.client.models.trading_status import TradingStatus
|
23
25
|
from typing import Optional, Set
|
24
26
|
from typing_extensions import Self
|
25
27
|
|
@@ -35,8 +37,8 @@ class ExchangeMapping(BaseModel):
|
|
35
37
|
pair: StrictStr
|
36
38
|
first_trade_timestamp: Optional[datetime]
|
37
39
|
last_trade_timestamp: Optional[datetime]
|
38
|
-
status:
|
39
|
-
market_type: Optional[
|
40
|
+
status: TradingStatus
|
41
|
+
market_type: Optional[MarketType]
|
40
42
|
__properties: ClassVar[List[str]] = [
|
41
43
|
"exchange_name",
|
42
44
|
"symbol",
|
@@ -1,3 +1,4 @@
|
|
1
|
+
from __future__ import annotations
|
1
2
|
from crypticorn.metrics import (
|
2
3
|
ApiClient,
|
3
4
|
Configuration,
|
@@ -10,13 +11,11 @@ from crypticorn.metrics import (
|
|
10
11
|
TokensApi,
|
11
12
|
MarketType,
|
12
13
|
)
|
14
|
+
from crypticorn.common import optional_import
|
13
15
|
from pydantic import StrictStr, StrictInt, Field
|
14
16
|
from typing_extensions import Annotated
|
15
17
|
from typing import Optional
|
16
18
|
|
17
|
-
import pandas as pd
|
18
|
-
|
19
|
-
|
20
19
|
class MetricsClient:
|
21
20
|
"""
|
22
21
|
A client for interacting with the Crypticorn Metrics API.
|
@@ -67,7 +66,8 @@ class MarketcapApiWrapper(MarketcapApi):
|
|
67
66
|
"""
|
68
67
|
Get the marketcap symbols in a pandas dataframe
|
69
68
|
"""
|
70
|
-
|
69
|
+
pd = optional_import("pandas", "extra")
|
70
|
+
response = await self.get_marketcap_symbols(
|
71
71
|
start_timestamp=start_timestamp,
|
72
72
|
end_timestamp=end_timestamp,
|
73
73
|
interval=interval,
|
@@ -96,6 +96,7 @@ class TokensApiWrapper(TokensApi):
|
|
96
96
|
"""
|
97
97
|
Get the tokens in a pandas dataframe
|
98
98
|
"""
|
99
|
+
pd = optional_import("pandas", "extra")
|
99
100
|
response = await self.get_stable_and_wrapped_tokens_without_preload_content(
|
100
101
|
token_type=token_type
|
101
102
|
)
|
@@ -41,13 +41,14 @@ from crypticorn.pay.client.models.now_create_invoice_res import NowCreateInvoice
|
|
41
41
|
from crypticorn.pay.client.models.now_fee_structure import NowFeeStructure
|
42
42
|
from crypticorn.pay.client.models.now_payment_status import NowPaymentStatus
|
43
43
|
from crypticorn.pay.client.models.now_webhook_payload import NowWebhookPayload
|
44
|
+
from crypticorn.pay.client.models.payment import Payment
|
44
45
|
from crypticorn.pay.client.models.payment_status import PaymentStatus
|
45
|
-
from crypticorn.pay.client.models.
|
46
|
-
from crypticorn.pay.client.models.
|
47
|
-
from crypticorn.pay.client.models.
|
46
|
+
from crypticorn.pay.client.models.product_create import ProductCreate
|
47
|
+
from crypticorn.pay.client.models.product_read import ProductRead
|
48
|
+
from crypticorn.pay.client.models.product_sub_read import ProductSubRead
|
49
|
+
from crypticorn.pay.client.models.product_update import ProductUpdate
|
48
50
|
from crypticorn.pay.client.models.scope import Scope
|
49
51
|
from crypticorn.pay.client.models.services import Services
|
50
|
-
from crypticorn.pay.client.models.unified_payment_model import UnifiedPaymentModel
|
51
52
|
from crypticorn.pay.client.models.validation_error import ValidationError
|
52
53
|
from crypticorn.pay.client.models.validation_error_loc_inner import (
|
53
54
|
ValidationErrorLocInner,
|
@@ -19,8 +19,8 @@ from typing_extensions import Annotated
|
|
19
19
|
from pydantic import Field, StrictInt, StrictStr
|
20
20
|
from typing import List, Optional
|
21
21
|
from typing_extensions import Annotated
|
22
|
-
from crypticorn.pay.client.models.
|
23
|
-
from crypticorn.pay.client.models.
|
22
|
+
from crypticorn.pay.client.models.payment import Payment
|
23
|
+
from crypticorn.pay.client.models.product_sub_read import ProductSubRead
|
24
24
|
|
25
25
|
from crypticorn.pay.client.api_client import ApiClient, RequestSerialized
|
26
26
|
from crypticorn.pay.client.api_response import ApiResponse
|
@@ -57,7 +57,7 @@ class PaymentsApi:
|
|
57
57
|
_content_type: Optional[StrictStr] = None,
|
58
58
|
_headers: Optional[Dict[StrictStr, Any]] = None,
|
59
59
|
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
60
|
-
) ->
|
60
|
+
) -> Payment:
|
61
61
|
"""Get Latest Payment From Invoice
|
62
62
|
|
63
63
|
Get the latest payment by a user from an invoice
|
@@ -95,7 +95,7 @@ class PaymentsApi:
|
|
95
95
|
)
|
96
96
|
|
97
97
|
_response_types_map: Dict[str, Optional[str]] = {
|
98
|
-
"200": "
|
98
|
+
"200": "Payment",
|
99
99
|
"422": "HTTPValidationError",
|
100
100
|
}
|
101
101
|
response_data = await self.api_client.call_api(
|
@@ -125,7 +125,7 @@ class PaymentsApi:
|
|
125
125
|
_content_type: Optional[StrictStr] = None,
|
126
126
|
_headers: Optional[Dict[StrictStr, Any]] = None,
|
127
127
|
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
128
|
-
) -> ApiResponse[
|
128
|
+
) -> ApiResponse[Payment]:
|
129
129
|
"""Get Latest Payment From Invoice
|
130
130
|
|
131
131
|
Get the latest payment by a user from an invoice
|
@@ -163,7 +163,7 @@ class PaymentsApi:
|
|
163
163
|
)
|
164
164
|
|
165
165
|
_response_types_map: Dict[str, Optional[str]] = {
|
166
|
-
"200": "
|
166
|
+
"200": "Payment",
|
167
167
|
"422": "HTTPValidationError",
|
168
168
|
}
|
169
169
|
response_data = await self.api_client.call_api(
|
@@ -231,7 +231,7 @@ class PaymentsApi:
|
|
231
231
|
)
|
232
232
|
|
233
233
|
_response_types_map: Dict[str, Optional[str]] = {
|
234
|
-
"200": "
|
234
|
+
"200": "Payment",
|
235
235
|
"422": "HTTPValidationError",
|
236
236
|
}
|
237
237
|
response_data = await self.api_client.call_api(
|
@@ -321,7 +321,7 @@ class PaymentsApi:
|
|
321
321
|
_content_type: Optional[StrictStr] = None,
|
322
322
|
_headers: Optional[Dict[StrictStr, Any]] = None,
|
323
323
|
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
324
|
-
) -> List[
|
324
|
+
) -> List[Payment]:
|
325
325
|
"""Get Payments
|
326
326
|
|
327
327
|
Get the combined payment history for a user across all payment services.
|
@@ -362,7 +362,7 @@ class PaymentsApi:
|
|
362
362
|
)
|
363
363
|
|
364
364
|
_response_types_map: Dict[str, Optional[str]] = {
|
365
|
-
"200": "List[
|
365
|
+
"200": "List[Payment]",
|
366
366
|
"422": "HTTPValidationError",
|
367
367
|
}
|
368
368
|
response_data = await self.api_client.call_api(
|
@@ -400,7 +400,7 @@ class PaymentsApi:
|
|
400
400
|
_content_type: Optional[StrictStr] = None,
|
401
401
|
_headers: Optional[Dict[StrictStr, Any]] = None,
|
402
402
|
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
403
|
-
) -> ApiResponse[List[
|
403
|
+
) -> ApiResponse[List[Payment]]:
|
404
404
|
"""Get Payments
|
405
405
|
|
406
406
|
Get the combined payment history for a user across all payment services.
|
@@ -441,7 +441,7 @@ class PaymentsApi:
|
|
441
441
|
)
|
442
442
|
|
443
443
|
_response_types_map: Dict[str, Optional[str]] = {
|
444
|
-
"200": "List[
|
444
|
+
"200": "List[Payment]",
|
445
445
|
"422": "HTTPValidationError",
|
446
446
|
}
|
447
447
|
response_data = await self.api_client.call_api(
|
@@ -520,7 +520,7 @@ class PaymentsApi:
|
|
520
520
|
)
|
521
521
|
|
522
522
|
_response_types_map: Dict[str, Optional[str]] = {
|
523
|
-
"200": "List[
|
523
|
+
"200": "List[Payment]",
|
524
524
|
"422": "HTTPValidationError",
|
525
525
|
}
|
526
526
|
response_data = await self.api_client.call_api(
|
@@ -609,7 +609,7 @@ class PaymentsApi:
|
|
609
609
|
_content_type: Optional[StrictStr] = None,
|
610
610
|
_headers: Optional[Dict[StrictStr, Any]] = None,
|
611
611
|
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
612
|
-
) -> List[
|
612
|
+
) -> List[ProductSubRead]:
|
613
613
|
"""Get Subscriptions
|
614
614
|
|
615
615
|
Get all subscriptions for a user. Subscriptions are the products a user has subscribed to. Returns both active and inactive subscriptions.
|
@@ -647,7 +647,7 @@ class PaymentsApi:
|
|
647
647
|
)
|
648
648
|
|
649
649
|
_response_types_map: Dict[str, Optional[str]] = {
|
650
|
-
"200": "List[
|
650
|
+
"200": "List[ProductSubRead]",
|
651
651
|
"422": "HTTPValidationError",
|
652
652
|
}
|
653
653
|
response_data = await self.api_client.call_api(
|
@@ -679,7 +679,7 @@ class PaymentsApi:
|
|
679
679
|
_content_type: Optional[StrictStr] = None,
|
680
680
|
_headers: Optional[Dict[StrictStr, Any]] = None,
|
681
681
|
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
682
|
-
) -> ApiResponse[List[
|
682
|
+
) -> ApiResponse[List[ProductSubRead]]:
|
683
683
|
"""Get Subscriptions
|
684
684
|
|
685
685
|
Get all subscriptions for a user. Subscriptions are the products a user has subscribed to. Returns both active and inactive subscriptions.
|
@@ -717,7 +717,7 @@ class PaymentsApi:
|
|
717
717
|
)
|
718
718
|
|
719
719
|
_response_types_map: Dict[str, Optional[str]] = {
|
720
|
-
"200": "List[
|
720
|
+
"200": "List[ProductSubRead]",
|
721
721
|
"422": "HTTPValidationError",
|
722
722
|
}
|
723
723
|
response_data = await self.api_client.call_api(
|
@@ -787,7 +787,7 @@ class PaymentsApi:
|
|
787
787
|
)
|
788
788
|
|
789
789
|
_response_types_map: Dict[str, Optional[str]] = {
|
790
|
-
"200": "List[
|
790
|
+
"200": "List[ProductSubRead]",
|
791
791
|
"422": "HTTPValidationError",
|
792
792
|
}
|
793
793
|
response_data = await self.api_client.call_api(
|