From d45295a786b51e66d62d1f3c9734667f64540784 Mon Sep 17 00:00:00 2001 From: linsto Date: Wed, 18 Oct 2023 01:08:55 +0800 Subject: [PATCH] feat: add license content --- .github/workflows/test.yml | 29 --- .licenserc.json | 20 ++ LICENSE | 222 ++++++++++++++++-- binance/coinmfutures/account/client.go | 17 ++ binance/coinmfutures/account/client_test.go | 17 ++ binance/coinmfutures/account/types/account.go | 17 ++ binance/coinmfutures/account/types/balance.go | 17 ++ .../coinmfutures/account/types/leverage.go | 17 ++ binance/coinmfutures/account/types/margin.go | 17 ++ binance/coinmfutures/account/types/order.go | 17 ++ .../coinmfutures/account/types/position.go | 17 ++ .../account/types/position_mode.go | 17 ++ .../coinmfutures/account/types/response.go | 17 ++ binance/coinmfutures/account/types/trade.go | 17 ++ binance/coinmfutures/marketdata/client.go | 17 ++ .../coinmfutures/marketdata/client_test.go | 17 ++ .../marketdata/types/book_ticker.go | 17 ++ .../marketdata/types/exchange_info.go | 17 ++ .../marketdata/types/funding_rate.go | 17 ++ .../coinmfutures/marketdata/types/klines.go | 17 ++ .../marketdata/types/mark_price.go | 17 ++ .../marketdata/types/open_interest.go | 17 ++ .../marketdata/types/orderbook.go | 17 ++ .../marketdata/types/price_ticker.go | 17 ++ .../coinmfutures/marketdata/types/trades.go | 17 ++ binance/coinmfutures/utils/client.go | 17 ++ binance/coinmfutures/utils/request.go | 17 ++ binance/coinmfutures/utils/vars.go | 17 ++ .../coinmfutures/websocketmarket/client.go | 19 +- .../websocketmarket/client_test.go | 17 ++ .../coinmfutures/websocketmarket/events.go | 17 ++ .../websocketmarket/subscriptions.go | 17 ++ .../coinmfutures/websocketmarket/topics.go | 19 +- binance/coinmfutures/websocketmarket/types.go | 19 +- binance/coinmfutures/websocketmarket/vars.go | 17 ++ binance/europeanoptions/account/client.go | 17 ++ .../europeanoptions/account/client_test.go | 17 ++ .../account/types/account_info.go | 17 ++ .../account/types/exercise_records.go | 17 ++ .../account/types/funding_flow.go | 17 ++ .../europeanoptions/account/types/order.go | 31 ++- .../europeanoptions/account/types/position.go | 17 ++ .../europeanoptions/account/types/trade.go | 17 ++ binance/europeanoptions/marketdata/client.go | 17 ++ .../europeanoptions/marketdata/client_test.go | 17 ++ .../marketdata/types/exchange_info.go | 17 ++ .../europeanoptions/marketdata/types/index.go | 17 ++ .../marketdata/types/klines.go | 19 +- .../marketdata/types/mark_price.go | 17 ++ .../marketdata/types/open_interest.go | 17 ++ .../marketdata/types/orderbook.go | 17 ++ .../marketdata/types/ticker.go | 17 ++ .../marketdata/types/trades.go | 17 ++ binance/europeanoptions/utils/client.go | 17 ++ binance/europeanoptions/utils/request.go | 17 ++ binance/europeanoptions/utils/vars.go | 17 ++ .../europeanoptions/websocketmarket/client.go | 19 +- .../websocketmarket/client_test.go | 17 ++ .../europeanoptions/websocketmarket/events.go | 17 ++ .../websocketmarket/subscriptions.go | 17 ++ .../europeanoptions/websocketmarket/topics.go | 17 ++ .../europeanoptions/websocketmarket/types.go | 17 ++ .../europeanoptions/websocketmarket/vars.go | 17 ++ .../websocketuserdata/client.go | 19 +- .../websocketuserdata/client_test.go | 17 ++ .../websocketuserdata/events.go | 17 ++ .../websocketuserdata/listenkey.go | 17 ++ .../websocketuserdata/subscriptions.go | 17 ++ .../websocketuserdata/types.go | 17 ++ .../europeanoptions/websocketuserdata/vars.go | 17 ++ binance/portfoliomargin/rest/client.go | 17 ++ binance/portfoliomargin/rest/client_test.go | 17 ++ binance/portfoliomargin/rest/types/balance.go | 17 ++ binance/portfoliomargin/utils/client.go | 17 ++ binance/portfoliomargin/utils/request.go | 17 ++ binance/portfoliomargin/utils/vars.go | 17 ++ .../portfoliomargin/websocketuserdata/vars.go | 17 ++ binance/spot/margin/client.go | 17 ++ binance/spot/margin/client_test.go | 17 ++ binance/spot/margin/types/interest_history.go | 17 ++ binance/spot/marketdata/client.go | 17 ++ binance/spot/marketdata/client_test.go | 17 ++ binance/spot/marketdata/types/agg_trades.go | 17 ++ .../spot/marketdata/types/average_price.go | 17 ++ binance/spot/marketdata/types/book_ticker.go | 17 ++ .../spot/marketdata/types/exchange_info.go | 19 +- binance/spot/marketdata/types/klines.go | 17 ++ binance/spot/marketdata/types/orderbook.go | 19 +- binance/spot/marketdata/types/server_time.go | 17 ++ binance/spot/marketdata/types/ticker.go | 17 ++ binance/spot/marketdata/types/ticker_price.go | 17 ++ binance/spot/marketdata/types/trades.go | 17 ++ binance/spot/spotaccount/client.go | 17 ++ binance/spot/spotaccount/client_test.go | 17 ++ .../spot/spotaccount/types/account_info.go | 19 +- binance/spot/spotaccount/types/oco.go | 18 +- binance/spot/spotaccount/types/order.go | 17 ++ binance/spot/spotaccount/types/trade_list.go | 17 ++ binance/spot/subaccount/client.go | 17 ++ binance/spot/subaccount/client_test.go | 17 ++ .../types/sub_account_transfer_history.go | 17 ++ binance/spot/utils/client.go | 17 ++ binance/spot/utils/request.go | 17 ++ binance/spot/utils/vars.go | 17 ++ binance/spot/wallet/client.go | 17 ++ binance/spot/wallet/client_test.go | 17 ++ binance/spot/wallet/types/all_coins_Info.go | 17 ++ binance/spot/wallet/types/api_restrictions.go | 17 ++ binance/spot/wallet/types/asset_detail.go | 17 ++ binance/spot/wallet/types/funding_wallet.go | 17 ++ binance/spot/wallet/types/system_status.go | 17 ++ binance/spot/wallet/types/trade_fee.go | 17 ++ .../spot/wallet/types/universal_transfer.go | 17 ++ binance/spot/wallet/types/user_asset.go | 17 ++ binance/spot/websocketmarket/client.go | 19 +- binance/spot/websocketmarket/client_test.go | 17 ++ binance/spot/websocketmarket/events.go | 17 ++ binance/spot/websocketmarket/subscriptions.go | 17 ++ binance/spot/websocketmarket/topics.go | 17 ++ .../spot/websocketmarket/types/messages.go | 17 ++ binance/spot/websocketmarket/vars.go | 17 ++ binance/usdmfutures/account/client.go | 17 ++ binance/usdmfutures/account/client_test.go | 17 ++ binance/usdmfutures/account/types/account.go | 17 ++ binance/usdmfutures/account/types/balance.go | 17 ++ binance/usdmfutures/account/types/leverage.go | 17 ++ binance/usdmfutures/account/types/margin.go | 17 ++ .../usdmfutures/account/types/multi_asset.go | 17 ++ binance/usdmfutures/account/types/order.go | 17 ++ binance/usdmfutures/account/types/position.go | 17 ++ .../account/types/position_mode.go | 17 ++ binance/usdmfutures/account/types/response.go | 17 ++ binance/usdmfutures/account/types/trade.go | 17 ++ binance/usdmfutures/marketdata/client.go | 17 ++ binance/usdmfutures/marketdata/client_test.go | 17 ++ .../marketdata/types/agg_trades.go | 17 ++ .../marketdata/types/book_ticker.go | 17 ++ .../marketdata/types/exchange_info.go | 17 ++ .../marketdata/types/funding_rate.go | 17 ++ .../usdmfutures/marketdata/types/klines.go | 17 ++ .../marketdata/types/mark_price.go | 17 ++ .../marketdata/types/open_interest_hist.go | 17 ++ .../usdmfutures/marketdata/types/orderbook.go | 17 ++ .../marketdata/types/ticker_price.go | 17 ++ .../usdmfutures/marketdata/types/trades.go | 17 ++ binance/usdmfutures/utils/client.go | 17 ++ binance/usdmfutures/utils/request.go | 17 ++ binance/usdmfutures/utils/vars.go | 17 ++ binance/usdmfutures/websocketmarket/client.go | 19 +- .../websocketmarket/client_test.go | 17 ++ binance/usdmfutures/websocketmarket/events.go | 17 ++ .../websocketmarket/subscriptions.go | 17 ++ binance/usdmfutures/websocketmarket/topics.go | 17 ++ .../websocketmarket/types/messages.go | 17 ++ binance/usdmfutures/websocketmarket/vars.go | 17 ++ binance/utils/normalization.go | 17 ++ binance/utils/types.go | 17 ++ binance/utils/websocket_response.go | 18 +- bitfinex/restauth/api.go | 17 ++ bitfinex/restauth/client.go | 17 ++ bitfinex/restauth/client_test.go | 17 ++ bitfinex/restpub/api.go | 17 ++ bitfinex/restpub/client.go | 17 ++ bitfinex/restpub/client_test.go | 17 ++ bitfinex/utils/nonce.go | 17 ++ deribit/rest/client.go | 17 ++ deribit/rest/private_api_test.go | 17 ++ deribit/rest/private_req.go | 17 ++ deribit/rest/public_api_test.go | 17 ++ deribit/rest/public_req.go | 17 ++ deribit/rest/types/account/account_summary.go | 17 ++ deribit/rest/types/account/position.go | 17 ++ deribit/rest/types/account/transaction_log.go | 17 ++ deribit/rest/types/auth/auth.go | 17 ++ deribit/rest/types/marketdata/book_summary.go | 17 ++ deribit/rest/types/marketdata/currency.go | 17 ++ .../types/marketdata/get_contract_size.go | 17 ++ .../rest/types/marketdata/get_funding_rate.go | 17 ++ deribit/rest/types/marketdata/get_index.go | 17 ++ .../rest/types/marketdata/get_order_book.go | 17 ++ .../marketdata/get_tradingview_chart_data.go | 17 ++ deribit/rest/types/marketdata/instrument.go | 17 ++ deribit/rest/types/marketdata/ticker.go | 17 ++ deribit/rest/types/marketdata/trade.go | 17 ++ deribit/rest/types/supporting/test.go | 17 ++ deribit/rest/types/trading/buy.go | 17 ++ deribit/rest/types/trading/cancel.go | 17 ++ deribit/rest/types/trading/close_position.go | 17 ++ deribit/rest/types/trading/get_open_orders.go | 17 ++ deribit/rest/types/trading/get_user_trades.go | 17 ++ deribit/rest/types/trading/order.go | 17 ++ deribit/rest/types/trading/sell.go | 17 ++ deribit/rest/types/trading/settlement.go | 17 ++ deribit/rest/types/trading/trade.go | 17 ++ deribit/rest/types/types.go | 17 ++ deribit/rest/vars.go | 17 ++ mexc/contract/account/client.go | 17 ++ mexc/contract/account/client_test.go | 17 ++ mexc/contract/account/types/assets.go | 17 ++ mexc/contract/account/types/leverage.go | 17 ++ mexc/contract/account/types/order.go | 19 +- mexc/contract/account/types/positions.go | 17 ++ mexc/contract/account/types/types.go | 17 ++ mexc/contract/marketdata/client.go | 17 ++ mexc/contract/marketdata/client_test.go | 17 ++ .../marketdata/types/contract_details.go | 17 ++ mexc/contract/marketdata/types/server_time.go | 17 ++ mexc/contract/marketdata/types/ticker.go | 17 ++ mexc/contract/utils/client.go | 17 ++ mexc/contract/utils/request.go | 17 ++ mexc/contract/utils/vars.go | 17 ++ mexc/spot/marketdata/client.go | 17 ++ mexc/spot/marketdata/client_test.go | 17 ++ mexc/spot/marketdata/types/agg_trades.go | 17 ++ mexc/spot/marketdata/types/average_price.go | 17 ++ mexc/spot/marketdata/types/book_ticker.go | 17 ++ mexc/spot/marketdata/types/exchange_info.go | 17 ++ mexc/spot/marketdata/types/klines.go | 17 ++ mexc/spot/marketdata/types/orderbook.go | 19 +- mexc/spot/marketdata/types/server_time.go | 17 ++ mexc/spot/marketdata/types/symbols.go | 17 ++ mexc/spot/marketdata/types/ticker.go | 17 ++ mexc/spot/marketdata/types/ticker_price.go | 17 ++ mexc/spot/marketdata/types/trades.go | 17 ++ mexc/spot/spotaccount/client.go | 17 ++ mexc/spot/spotaccount/client_test.go | 23 +- mexc/spot/spotaccount/types/account_info.go | 17 ++ mexc/spot/spotaccount/types/transfer.go | 17 ++ mexc/spot/utils/client.go | 17 ++ mexc/spot/utils/request.go | 17 ++ mexc/spot/utils/vars.go | 17 ++ mexc/utils/normalization.go | 17 ++ mexc/utils/types.go | 17 ++ mexc/utils/websocket_response.go | 18 +- okx/publicdata/client.go | 17 ++ okx/publicdata/client_test.go | 17 ++ okx/publicdata/types/instrument.go | 17 ++ okx/tradingaccount/client.go | 17 ++ okx/tradingaccount/client_test.go | 17 ++ okx/tradingaccount/types/balance.go | 17 ++ okx/utils/request.go | 17 ++ okx/utils/rest.go | 17 ++ okx/utils/vars.go | 17 ++ woox/rest/client.go | 17 ++ woox/rest/private_api_test.go | 17 ++ woox/rest/private_req.go | 17 ++ woox/rest/public_api_test.go | 17 ++ woox/rest/public_req.go | 17 ++ woox/rest/types/private_account_info.go | 17 ++ woox/rest/types/private_account_mode.go | 17 ++ woox/rest/types/private_asset_history.go | 17 ++ woox/rest/types/private_balances.go | 17 ++ woox/rest/types/private_ip_restriction.go | 17 ++ woox/rest/types/private_leverage.go | 17 ++ woox/rest/types/private_order_cancel.go | 17 ++ woox/rest/types/private_order_get.go | 17 ++ woox/rest/types/private_order_send.go | 17 ++ woox/rest/types/private_position.go | 17 ++ woox/rest/types/private_subaccount.go | 17 ++ woox/rest/types/private_trade.go | 17 ++ woox/rest/types/private_transfer_asset.go | 17 ++ woox/rest/types/public_funding_rate.go | 17 ++ woox/rest/types/public_futures_info.go | 17 ++ woox/rest/types/public_info.go | 17 ++ woox/rest/types/public_kline.go | 17 ++ woox/rest/types/public_market_trades.go | 17 ++ woox/rest/types/public_orderbook.go | 17 ++ woox/rest/types/public_token.go | 17 ++ woox/rest/types/types.go | 17 ++ woox/rest/vars.go | 17 ++ woox/websocket/client.go | 19 +- woox/websocket/client_test.go | 17 ++ woox/websocket/events.go | 17 ++ woox/websocket/subscriptions.go | 17 ++ woox/websocket/topics.go | 17 ++ woox/websocket/types/public.go | 17 ++ woox/websocket/types/types.go | 17 ++ woox/websocket/vars.go | 17 ++ 278 files changed, 4919 insertions(+), 78 deletions(-) delete mode 100644 .github/workflows/test.yml create mode 100644 .licenserc.json diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml deleted file mode 100644 index 607ba0a..0000000 --- a/.github/workflows/test.yml +++ /dev/null @@ -1,29 +0,0 @@ -name: Test - -on: - push: - branches: ["main"] - pull_request: - branches: ["main"] - -env: - GO_VERSION: "1.21" - -jobs: - build: - runs-on: ubuntu-latest - steps: - - name: Set up Go - uses: actions/setup-go@v4 - with: - go-version: ${{ env.GO_VERSION }} - - - uses: actions/checkout@v3 - - - name: Test - run: go test -v ./... - - - name: Upload coverage reports to Codecov - uses: codecov/codecov-action@v3 - env: - CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} diff --git a/.licenserc.json b/.licenserc.json new file mode 100644 index 0000000..1dca999 --- /dev/null +++ b/.licenserc.json @@ -0,0 +1,20 @@ +{ + "**/*.go": [ + "/*", + "* Copyright (c) 2023, LinstoHu", + "* All rights reserved.", + "*", + "* Licensed under the Apache License, Version 2.0 (the \"License\");", + "* you may not use this file except in compliance with the License.", + "* You may obtain a copy of the License at", + "*", + "* http://www.apache.org/licenses/LICENSE-2.0", + "*", + "* Unless required by applicable law or agreed to in writing, software", + "* distributed under the License is distributed on an \"AS IS\" BASIS,", + "* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.", + "* See the License for the specific language governing permissions and", + "* limitations under the License.", + "*/" + ] +} diff --git a/LICENSE b/LICENSE index f52cddb..f49a4e1 100644 --- a/LICENSE +++ b/LICENSE @@ -1,21 +1,201 @@ -MIT License - -Copyright (c) 2023 Linsto Hu - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. \ No newline at end of file + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright [yyyy] [name of copyright owner] + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. \ No newline at end of file diff --git a/binance/coinmfutures/account/client.go b/binance/coinmfutures/account/client.go index 5259e73..136b716 100644 --- a/binance/coinmfutures/account/client.go +++ b/binance/coinmfutures/account/client.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package account import ( diff --git a/binance/coinmfutures/account/client_test.go b/binance/coinmfutures/account/client_test.go index e699b11..3c7d5f7 100644 --- a/binance/coinmfutures/account/client_test.go +++ b/binance/coinmfutures/account/client_test.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package account import ( diff --git a/binance/coinmfutures/account/types/account.go b/binance/coinmfutures/account/types/account.go index cd47ff9..6d23006 100644 --- a/binance/coinmfutures/account/types/account.go +++ b/binance/coinmfutures/account/types/account.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type Account struct { diff --git a/binance/coinmfutures/account/types/balance.go b/binance/coinmfutures/account/types/balance.go index fa9fe15..f25704c 100644 --- a/binance/coinmfutures/account/types/balance.go +++ b/binance/coinmfutures/account/types/balance.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type Balance struct { diff --git a/binance/coinmfutures/account/types/leverage.go b/binance/coinmfutures/account/types/leverage.go index 6273932..767e5d4 100644 --- a/binance/coinmfutures/account/types/leverage.go +++ b/binance/coinmfutures/account/types/leverage.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types import ( diff --git a/binance/coinmfutures/account/types/margin.go b/binance/coinmfutures/account/types/margin.go index 1b72a37..01ce656 100644 --- a/binance/coinmfutures/account/types/margin.go +++ b/binance/coinmfutures/account/types/margin.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types import ( diff --git a/binance/coinmfutures/account/types/order.go b/binance/coinmfutures/account/types/order.go index 308747d..3e29edd 100644 --- a/binance/coinmfutures/account/types/order.go +++ b/binance/coinmfutures/account/types/order.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types import ( diff --git a/binance/coinmfutures/account/types/position.go b/binance/coinmfutures/account/types/position.go index a4e4198..b0e1227 100644 --- a/binance/coinmfutures/account/types/position.go +++ b/binance/coinmfutures/account/types/position.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types import ( diff --git a/binance/coinmfutures/account/types/position_mode.go b/binance/coinmfutures/account/types/position_mode.go index c0287f6..cc19199 100644 --- a/binance/coinmfutures/account/types/position_mode.go +++ b/binance/coinmfutures/account/types/position_mode.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types import ( diff --git a/binance/coinmfutures/account/types/response.go b/binance/coinmfutures/account/types/response.go index cb2f066..9f7fbe0 100644 --- a/binance/coinmfutures/account/types/response.go +++ b/binance/coinmfutures/account/types/response.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type Response struct { diff --git a/binance/coinmfutures/account/types/trade.go b/binance/coinmfutures/account/types/trade.go index fd4cf1c..8e12131 100644 --- a/binance/coinmfutures/account/types/trade.go +++ b/binance/coinmfutures/account/types/trade.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types import ( diff --git a/binance/coinmfutures/marketdata/client.go b/binance/coinmfutures/marketdata/client.go index 0f2a8a0..3ad5903 100644 --- a/binance/coinmfutures/marketdata/client.go +++ b/binance/coinmfutures/marketdata/client.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package marketdata import ( diff --git a/binance/coinmfutures/marketdata/client_test.go b/binance/coinmfutures/marketdata/client_test.go index 17ef520..5524a1f 100644 --- a/binance/coinmfutures/marketdata/client_test.go +++ b/binance/coinmfutures/marketdata/client_test.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package marketdata import ( diff --git a/binance/coinmfutures/marketdata/types/book_ticker.go b/binance/coinmfutures/marketdata/types/book_ticker.go index ff841f6..f7131d6 100644 --- a/binance/coinmfutures/marketdata/types/book_ticker.go +++ b/binance/coinmfutures/marketdata/types/book_ticker.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetBookTickerParam struct { diff --git a/binance/coinmfutures/marketdata/types/exchange_info.go b/binance/coinmfutures/marketdata/types/exchange_info.go index f3fc014..23142e5 100644 --- a/binance/coinmfutures/marketdata/types/exchange_info.go +++ b/binance/coinmfutures/marketdata/types/exchange_info.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type ExchangeInfo struct { diff --git a/binance/coinmfutures/marketdata/types/funding_rate.go b/binance/coinmfutures/marketdata/types/funding_rate.go index b997b6f..cc8dca6 100644 --- a/binance/coinmfutures/marketdata/types/funding_rate.go +++ b/binance/coinmfutures/marketdata/types/funding_rate.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetFundingRateParam struct { diff --git a/binance/coinmfutures/marketdata/types/klines.go b/binance/coinmfutures/marketdata/types/klines.go index a82fc91..7f5901a 100644 --- a/binance/coinmfutures/marketdata/types/klines.go +++ b/binance/coinmfutures/marketdata/types/klines.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type Kline struct { diff --git a/binance/coinmfutures/marketdata/types/mark_price.go b/binance/coinmfutures/marketdata/types/mark_price.go index 60753f4..8521d2b 100644 --- a/binance/coinmfutures/marketdata/types/mark_price.go +++ b/binance/coinmfutures/marketdata/types/mark_price.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetMarkPriceParam struct { diff --git a/binance/coinmfutures/marketdata/types/open_interest.go b/binance/coinmfutures/marketdata/types/open_interest.go index 1a856e9..4977f36 100644 --- a/binance/coinmfutures/marketdata/types/open_interest.go +++ b/binance/coinmfutures/marketdata/types/open_interest.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types import ( diff --git a/binance/coinmfutures/marketdata/types/orderbook.go b/binance/coinmfutures/marketdata/types/orderbook.go index bfc9af5..4908bb5 100644 --- a/binance/coinmfutures/marketdata/types/orderbook.go +++ b/binance/coinmfutures/marketdata/types/orderbook.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetOrderbookParams struct { diff --git a/binance/coinmfutures/marketdata/types/price_ticker.go b/binance/coinmfutures/marketdata/types/price_ticker.go index 50ad7a7..d13d5bf 100644 --- a/binance/coinmfutures/marketdata/types/price_ticker.go +++ b/binance/coinmfutures/marketdata/types/price_ticker.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetPriceTickerParam struct { diff --git a/binance/coinmfutures/marketdata/types/trades.go b/binance/coinmfutures/marketdata/types/trades.go index 958c16b..f6e5681 100644 --- a/binance/coinmfutures/marketdata/types/trades.go +++ b/binance/coinmfutures/marketdata/types/trades.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetTradeParams struct { diff --git a/binance/coinmfutures/utils/client.go b/binance/coinmfutures/utils/client.go index ebfbd50..d9a58c6 100644 --- a/binance/coinmfutures/utils/client.go +++ b/binance/coinmfutures/utils/client.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cmutils import ( diff --git a/binance/coinmfutures/utils/request.go b/binance/coinmfutures/utils/request.go index 54c5ad3..3b18528 100644 --- a/binance/coinmfutures/utils/request.go +++ b/binance/coinmfutures/utils/request.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cmutils import ( diff --git a/binance/coinmfutures/utils/vars.go b/binance/coinmfutures/utils/vars.go index 95891e7..87e0b79 100644 --- a/binance/coinmfutures/utils/vars.go +++ b/binance/coinmfutures/utils/vars.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cmutils var ( diff --git a/binance/coinmfutures/websocketmarket/client.go b/binance/coinmfutures/websocketmarket/client.go index 14459a8..dc2ca53 100644 --- a/binance/coinmfutures/websocketmarket/client.go +++ b/binance/coinmfutures/websocketmarket/client.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package websocketmarket import ( @@ -124,7 +141,7 @@ func (u *CoinMarginedMarketStreamClient) reconnect() { u.setIsConnected(false) - u.logger.Info(fmt.Sprintf("disconnect, then reconnect...")) + u.logger.Info("disconnect, then reconnect...") time.Sleep(1 * time.Second) diff --git a/binance/coinmfutures/websocketmarket/client_test.go b/binance/coinmfutures/websocketmarket/client_test.go index 2ab0588..56eb422 100644 --- a/binance/coinmfutures/websocketmarket/client_test.go +++ b/binance/coinmfutures/websocketmarket/client_test.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package websocketmarket import ( diff --git a/binance/coinmfutures/websocketmarket/events.go b/binance/coinmfutures/websocketmarket/events.go index ad0b16e..328450e 100644 --- a/binance/coinmfutures/websocketmarket/events.go +++ b/binance/coinmfutures/websocketmarket/events.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package websocketmarket import "github.com/chuckpreslar/emission" diff --git a/binance/coinmfutures/websocketmarket/subscriptions.go b/binance/coinmfutures/websocketmarket/subscriptions.go index da7bd8f..bfc6f53 100644 --- a/binance/coinmfutures/websocketmarket/subscriptions.go +++ b/binance/coinmfutures/websocketmarket/subscriptions.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package websocketmarket import ( diff --git a/binance/coinmfutures/websocketmarket/topics.go b/binance/coinmfutures/websocketmarket/topics.go index e7acd62..143100f 100644 --- a/binance/coinmfutures/websocketmarket/topics.go +++ b/binance/coinmfutures/websocketmarket/topics.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package websocketmarket import ( @@ -57,7 +74,7 @@ func (c *CoinMarginedMarketStreamClient) GetPairMarketPriceTopic(param *PairMark } type KlineTopicParam struct { - Symbol string `validate:"required"` + Symbol string `validate:"required"` Interval cmutils.KlineInterval `validate:"required,oneof=1m 3m 5m 15m 30m 1h 2h 4h 6h 8h 12h 1d 3d 1w 1M"` } diff --git a/binance/coinmfutures/websocketmarket/types.go b/binance/coinmfutures/websocketmarket/types.go index c933314..edde3a6 100644 --- a/binance/coinmfutures/websocketmarket/types.go +++ b/binance/coinmfutures/websocketmarket/types.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package websocketmarket import ( @@ -82,7 +99,7 @@ type LiquidationOrder struct { OriginalQuantity string `json:"q"` Price string `json:"p"` AveragePrice string `json:"ap"` - OrderStatus cmutils.OrderStatus `json:"X"` + OrderStatus cmutils.OrderStatus `json:"X"` LastFilledQuantity string `json:"l"` FilledAccumulatedQuantity string `json:"z"` TradeTime int64 `json:"T"` diff --git a/binance/coinmfutures/websocketmarket/vars.go b/binance/coinmfutures/websocketmarket/vars.go index bb4cdce..c102f46 100644 --- a/binance/coinmfutures/websocketmarket/vars.go +++ b/binance/coinmfutures/websocketmarket/vars.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package websocketmarket var ( diff --git a/binance/europeanoptions/account/client.go b/binance/europeanoptions/account/client.go index 194bf94..bc7fc80 100644 --- a/binance/europeanoptions/account/client.go +++ b/binance/europeanoptions/account/client.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package account import ( diff --git a/binance/europeanoptions/account/client_test.go b/binance/europeanoptions/account/client_test.go index f7709fc..bc4dedc 100644 --- a/binance/europeanoptions/account/client_test.go +++ b/binance/europeanoptions/account/client_test.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package account import ( diff --git a/binance/europeanoptions/account/types/account_info.go b/binance/europeanoptions/account/types/account_info.go index c0557f2..9ef2401 100644 --- a/binance/europeanoptions/account/types/account_info.go +++ b/binance/europeanoptions/account/types/account_info.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type AccountInfo struct { diff --git a/binance/europeanoptions/account/types/exercise_records.go b/binance/europeanoptions/account/types/exercise_records.go index 3f17296..cdd974d 100644 --- a/binance/europeanoptions/account/types/exercise_records.go +++ b/binance/europeanoptions/account/types/exercise_records.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types import ( diff --git a/binance/europeanoptions/account/types/funding_flow.go b/binance/europeanoptions/account/types/funding_flow.go index 4c2be5f..0bb5ede 100644 --- a/binance/europeanoptions/account/types/funding_flow.go +++ b/binance/europeanoptions/account/types/funding_flow.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types import ( diff --git a/binance/europeanoptions/account/types/order.go b/binance/europeanoptions/account/types/order.go index 874a683..4802c4d 100644 --- a/binance/europeanoptions/account/types/order.go +++ b/binance/europeanoptions/account/types/order.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types import ( @@ -31,17 +48,17 @@ type Order struct { } type NewOrderParam struct { - Symbol string `url:"symbol" validate:"required"` + Symbol string `url:"symbol" validate:"required"` Side eoutils.OrderSide `url:"side" validate:"required,oneof=BUY SELL"` Type eoutils.OrderType `url:"type" validate:"required"` - Quantity float64 `url:"quantity" validate:"required"` - Price float64 `url:"price,omitempty" validate:"omitempty"` + Quantity float64 `url:"quantity" validate:"required"` + Price float64 `url:"price,omitempty" validate:"omitempty"` TimeInForce eoutils.TimeInForce `url:"timeInForce,omitempty" validate:"omitempty"` - ReduceOnly bool `url:"reduceOnly,omitempty" validate:"omitempty"` - PostOnly bool `url:"postOnly,omitempty" validate:"omitempty"` + ReduceOnly bool `url:"reduceOnly,omitempty" validate:"omitempty"` + PostOnly bool `url:"postOnly,omitempty" validate:"omitempty"` NewOrderRespType eoutils.NewOrderRespType `url:"newOrderRespType,omitempty" validate:"omitempty"` - ClientOrderID string `url:"clientOrderId,omitempty" validate:"omitempty"` - IsMmp bool `url:"isMmp,omitempty" validate:"omitempty"` + ClientOrderID string `url:"clientOrderId,omitempty" validate:"omitempty"` + IsMmp bool `url:"isMmp,omitempty" validate:"omitempty"` } type NewOrderParams struct { diff --git a/binance/europeanoptions/account/types/position.go b/binance/europeanoptions/account/types/position.go index a72c4e6..65e0398 100644 --- a/binance/europeanoptions/account/types/position.go +++ b/binance/europeanoptions/account/types/position.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types import ( diff --git a/binance/europeanoptions/account/types/trade.go b/binance/europeanoptions/account/types/trade.go index c3ef3ad..84e1262 100644 --- a/binance/europeanoptions/account/types/trade.go +++ b/binance/europeanoptions/account/types/trade.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types import ( diff --git a/binance/europeanoptions/marketdata/client.go b/binance/europeanoptions/marketdata/client.go index b12f38c..3c879c1 100644 --- a/binance/europeanoptions/marketdata/client.go +++ b/binance/europeanoptions/marketdata/client.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package marketdata import ( diff --git a/binance/europeanoptions/marketdata/client_test.go b/binance/europeanoptions/marketdata/client_test.go index d833445..e42a110 100644 --- a/binance/europeanoptions/marketdata/client_test.go +++ b/binance/europeanoptions/marketdata/client_test.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package marketdata import ( diff --git a/binance/europeanoptions/marketdata/types/exchange_info.go b/binance/europeanoptions/marketdata/types/exchange_info.go index 2d01879..2d728f1 100644 --- a/binance/europeanoptions/marketdata/types/exchange_info.go +++ b/binance/europeanoptions/marketdata/types/exchange_info.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type ExchangeInfo struct { diff --git a/binance/europeanoptions/marketdata/types/index.go b/binance/europeanoptions/marketdata/types/index.go index cbc54a7..52c231f 100644 --- a/binance/europeanoptions/marketdata/types/index.go +++ b/binance/europeanoptions/marketdata/types/index.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetUnderlyingIndexPriceParams struct { diff --git a/binance/europeanoptions/marketdata/types/klines.go b/binance/europeanoptions/marketdata/types/klines.go index 8901aca..fd869d7 100644 --- a/binance/europeanoptions/marketdata/types/klines.go +++ b/binance/europeanoptions/marketdata/types/klines.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type Kline struct { @@ -13,4 +30,4 @@ type Kline struct { Amount string `json:"amount"` OpenTime int64 `json:"openTime"` CloseTime int64 `json:"closeTime"` -} \ No newline at end of file +} diff --git a/binance/europeanoptions/marketdata/types/mark_price.go b/binance/europeanoptions/marketdata/types/mark_price.go index 476e995..84f56fd 100644 --- a/binance/europeanoptions/marketdata/types/mark_price.go +++ b/binance/europeanoptions/marketdata/types/mark_price.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetMarkPriceParam struct { diff --git a/binance/europeanoptions/marketdata/types/open_interest.go b/binance/europeanoptions/marketdata/types/open_interest.go index d1c9d1c..36c57dc 100644 --- a/binance/europeanoptions/marketdata/types/open_interest.go +++ b/binance/europeanoptions/marketdata/types/open_interest.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetOpenInterestParam struct { diff --git a/binance/europeanoptions/marketdata/types/orderbook.go b/binance/europeanoptions/marketdata/types/orderbook.go index 69c66d8..03244ab 100644 --- a/binance/europeanoptions/marketdata/types/orderbook.go +++ b/binance/europeanoptions/marketdata/types/orderbook.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetOrderbookParams struct { diff --git a/binance/europeanoptions/marketdata/types/ticker.go b/binance/europeanoptions/marketdata/types/ticker.go index cf7f6f0..93f5a9e 100644 --- a/binance/europeanoptions/marketdata/types/ticker.go +++ b/binance/europeanoptions/marketdata/types/ticker.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetTickerPriceParam struct { diff --git a/binance/europeanoptions/marketdata/types/trades.go b/binance/europeanoptions/marketdata/types/trades.go index bd4fc86..08f90a7 100644 --- a/binance/europeanoptions/marketdata/types/trades.go +++ b/binance/europeanoptions/marketdata/types/trades.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetTradeParams struct { diff --git a/binance/europeanoptions/utils/client.go b/binance/europeanoptions/utils/client.go index b5a6592..48dacf7 100644 --- a/binance/europeanoptions/utils/client.go +++ b/binance/europeanoptions/utils/client.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package eoutils import ( diff --git a/binance/europeanoptions/utils/request.go b/binance/europeanoptions/utils/request.go index ec8d9c7..e83c6d1 100644 --- a/binance/europeanoptions/utils/request.go +++ b/binance/europeanoptions/utils/request.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package eoutils import ( diff --git a/binance/europeanoptions/utils/vars.go b/binance/europeanoptions/utils/vars.go index 5b2e871..95a6c3d 100644 --- a/binance/europeanoptions/utils/vars.go +++ b/binance/europeanoptions/utils/vars.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package eoutils var ( diff --git a/binance/europeanoptions/websocketmarket/client.go b/binance/europeanoptions/websocketmarket/client.go index b38fd32..21b2497 100644 --- a/binance/europeanoptions/websocketmarket/client.go +++ b/binance/europeanoptions/websocketmarket/client.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package websocketmarket import ( @@ -124,7 +141,7 @@ func (o *OptionsMarketStreamClient) reconnect() { o.setIsConnected(false) - o.logger.Info(fmt.Sprintf("disconnect, then reconnect...")) + o.logger.Info("disconnect, then reconnect...") time.Sleep(1 * time.Second) diff --git a/binance/europeanoptions/websocketmarket/client_test.go b/binance/europeanoptions/websocketmarket/client_test.go index 138fbdb..58fde97 100644 --- a/binance/europeanoptions/websocketmarket/client_test.go +++ b/binance/europeanoptions/websocketmarket/client_test.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package websocketmarket import ( diff --git a/binance/europeanoptions/websocketmarket/events.go b/binance/europeanoptions/websocketmarket/events.go index 6320b26..29b4ebd 100644 --- a/binance/europeanoptions/websocketmarket/events.go +++ b/binance/europeanoptions/websocketmarket/events.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package websocketmarket import "github.com/chuckpreslar/emission" diff --git a/binance/europeanoptions/websocketmarket/subscriptions.go b/binance/europeanoptions/websocketmarket/subscriptions.go index 8cbe592..af331ff 100644 --- a/binance/europeanoptions/websocketmarket/subscriptions.go +++ b/binance/europeanoptions/websocketmarket/subscriptions.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package websocketmarket import ( diff --git a/binance/europeanoptions/websocketmarket/topics.go b/binance/europeanoptions/websocketmarket/topics.go index a6c259c..1c466e0 100644 --- a/binance/europeanoptions/websocketmarket/topics.go +++ b/binance/europeanoptions/websocketmarket/topics.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package websocketmarket import ( diff --git a/binance/europeanoptions/websocketmarket/types.go b/binance/europeanoptions/websocketmarket/types.go index 46bd769..00a4920 100644 --- a/binance/europeanoptions/websocketmarket/types.go +++ b/binance/europeanoptions/websocketmarket/types.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package websocketmarket type Trade struct { diff --git a/binance/europeanoptions/websocketmarket/vars.go b/binance/europeanoptions/websocketmarket/vars.go index 30b17f3..e45e23d 100644 --- a/binance/europeanoptions/websocketmarket/vars.go +++ b/binance/europeanoptions/websocketmarket/vars.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package websocketmarket var ( diff --git a/binance/europeanoptions/websocketuserdata/client.go b/binance/europeanoptions/websocketuserdata/client.go index 36b4b44..bb6d467 100644 --- a/binance/europeanoptions/websocketuserdata/client.go +++ b/binance/europeanoptions/websocketuserdata/client.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package websocketuserdata import ( @@ -177,7 +194,7 @@ func (o *OptionsUserDataStreamClient) reconnect() { o.setIsConnected(false) - o.logger.Info(fmt.Sprintf("disconnect, then reconnect...")) + o.logger.Info("disconnect, then reconnect...") close(o.heartCancel) diff --git a/binance/europeanoptions/websocketuserdata/client_test.go b/binance/europeanoptions/websocketuserdata/client_test.go index 2c0f409..485fac0 100644 --- a/binance/europeanoptions/websocketuserdata/client_test.go +++ b/binance/europeanoptions/websocketuserdata/client_test.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package websocketuserdata import ( diff --git a/binance/europeanoptions/websocketuserdata/events.go b/binance/europeanoptions/websocketuserdata/events.go index 3ac3931..0a3daff 100644 --- a/binance/europeanoptions/websocketuserdata/events.go +++ b/binance/europeanoptions/websocketuserdata/events.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package websocketuserdata import "github.com/chuckpreslar/emission" diff --git a/binance/europeanoptions/websocketuserdata/listenkey.go b/binance/europeanoptions/websocketuserdata/listenkey.go index ce1b4f2..abd1d32 100644 --- a/binance/europeanoptions/websocketuserdata/listenkey.go +++ b/binance/europeanoptions/websocketuserdata/listenkey.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package websocketuserdata import ( diff --git a/binance/europeanoptions/websocketuserdata/subscriptions.go b/binance/europeanoptions/websocketuserdata/subscriptions.go index cadabe7..d3b4c15 100644 --- a/binance/europeanoptions/websocketuserdata/subscriptions.go +++ b/binance/europeanoptions/websocketuserdata/subscriptions.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package websocketuserdata import ( diff --git a/binance/europeanoptions/websocketuserdata/types.go b/binance/europeanoptions/websocketuserdata/types.go index b6981dc..46f4392 100644 --- a/binance/europeanoptions/websocketuserdata/types.go +++ b/binance/europeanoptions/websocketuserdata/types.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package websocketuserdata type AccountData struct { diff --git a/binance/europeanoptions/websocketuserdata/vars.go b/binance/europeanoptions/websocketuserdata/vars.go index 8883ac9..0ced330 100644 --- a/binance/europeanoptions/websocketuserdata/vars.go +++ b/binance/europeanoptions/websocketuserdata/vars.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package websocketuserdata var ( diff --git a/binance/portfoliomargin/rest/client.go b/binance/portfoliomargin/rest/client.go index 0d91feb..8151c9e 100644 --- a/binance/portfoliomargin/rest/client.go +++ b/binance/portfoliomargin/rest/client.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package pmrest import ( diff --git a/binance/portfoliomargin/rest/client_test.go b/binance/portfoliomargin/rest/client_test.go index 9065f57..8d382d7 100644 --- a/binance/portfoliomargin/rest/client_test.go +++ b/binance/portfoliomargin/rest/client_test.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package pmrest import ( diff --git a/binance/portfoliomargin/rest/types/balance.go b/binance/portfoliomargin/rest/types/balance.go index f45f16f..eb472fb 100644 --- a/binance/portfoliomargin/rest/types/balance.go +++ b/binance/portfoliomargin/rest/types/balance.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types import ( diff --git a/binance/portfoliomargin/utils/client.go b/binance/portfoliomargin/utils/client.go index a739855..2c0ab77 100644 --- a/binance/portfoliomargin/utils/client.go +++ b/binance/portfoliomargin/utils/client.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cmutils import ( diff --git a/binance/portfoliomargin/utils/request.go b/binance/portfoliomargin/utils/request.go index e26137d..32c27c6 100644 --- a/binance/portfoliomargin/utils/request.go +++ b/binance/portfoliomargin/utils/request.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cmutils type HTTPRequest struct { diff --git a/binance/portfoliomargin/utils/vars.go b/binance/portfoliomargin/utils/vars.go index 4ce5118..a6136ec 100644 --- a/binance/portfoliomargin/utils/vars.go +++ b/binance/portfoliomargin/utils/vars.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cmutils var ( diff --git a/binance/portfoliomargin/websocketuserdata/vars.go b/binance/portfoliomargin/websocketuserdata/vars.go index afe78a2..d85b852 100644 --- a/binance/portfoliomargin/websocketuserdata/vars.go +++ b/binance/portfoliomargin/websocketuserdata/vars.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package websocketuserdata var ( diff --git a/binance/spot/margin/client.go b/binance/spot/margin/client.go index 7138e87..564b184 100644 --- a/binance/spot/margin/client.go +++ b/binance/spot/margin/client.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package margin import ( diff --git a/binance/spot/margin/client_test.go b/binance/spot/margin/client_test.go index c69650c..71cebd3 100644 --- a/binance/spot/margin/client_test.go +++ b/binance/spot/margin/client_test.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package margin import ( diff --git a/binance/spot/margin/types/interest_history.go b/binance/spot/margin/types/interest_history.go index 49152bc..a7ff659 100644 --- a/binance/spot/margin/types/interest_history.go +++ b/binance/spot/margin/types/interest_history.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types import "github.com/linstohu/nexapi/binance/utils" diff --git a/binance/spot/marketdata/client.go b/binance/spot/marketdata/client.go index 9792674..2313594 100644 --- a/binance/spot/marketdata/client.go +++ b/binance/spot/marketdata/client.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package marketdata import ( diff --git a/binance/spot/marketdata/client_test.go b/binance/spot/marketdata/client_test.go index 051b733..d2293b8 100644 --- a/binance/spot/marketdata/client_test.go +++ b/binance/spot/marketdata/client_test.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package marketdata import ( diff --git a/binance/spot/marketdata/types/agg_trades.go b/binance/spot/marketdata/types/agg_trades.go index 24f6453..6048dab 100644 --- a/binance/spot/marketdata/types/agg_trades.go +++ b/binance/spot/marketdata/types/agg_trades.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetAggTradesParam struct { diff --git a/binance/spot/marketdata/types/average_price.go b/binance/spot/marketdata/types/average_price.go index c125513..f1e371b 100644 --- a/binance/spot/marketdata/types/average_price.go +++ b/binance/spot/marketdata/types/average_price.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetAvgPriceParam struct { diff --git a/binance/spot/marketdata/types/book_ticker.go b/binance/spot/marketdata/types/book_ticker.go index 0aba007..6c0afab 100644 --- a/binance/spot/marketdata/types/book_ticker.go +++ b/binance/spot/marketdata/types/book_ticker.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetBookTickerForSymbolParam struct { diff --git a/binance/spot/marketdata/types/exchange_info.go b/binance/spot/marketdata/types/exchange_info.go index 3af36c9..3e459b7 100644 --- a/binance/spot/marketdata/types/exchange_info.go +++ b/binance/spot/marketdata/types/exchange_info.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetExchangeInfoParam struct { @@ -19,7 +36,7 @@ type ExchangeInfo struct { IntervalNum int `json:"intervalNum"` Limit int `json:"limit"` } `json:"rateLimits"` - Symbols []struct { + Symbols []struct { Symbol string `json:"symbol"` Status string `json:"status"` BaseAsset string `json:"baseAsset"` diff --git a/binance/spot/marketdata/types/klines.go b/binance/spot/marketdata/types/klines.go index c138df2..108b80f 100644 --- a/binance/spot/marketdata/types/klines.go +++ b/binance/spot/marketdata/types/klines.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types import ( diff --git a/binance/spot/marketdata/types/orderbook.go b/binance/spot/marketdata/types/orderbook.go index cdd6e7e..eb554c4 100644 --- a/binance/spot/marketdata/types/orderbook.go +++ b/binance/spot/marketdata/types/orderbook.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetOrderbookParams struct { @@ -6,7 +23,7 @@ type GetOrderbookParams struct { } type Orderbook struct { - LastUpdateID int64 `json:"lastUpdateId"` + LastUpdateID int64 `json:"lastUpdateId"` Bids [][]string `json:"bids"` Asks [][]string `json:"asks"` } diff --git a/binance/spot/marketdata/types/server_time.go b/binance/spot/marketdata/types/server_time.go index bda1061..6838532 100644 --- a/binance/spot/marketdata/types/server_time.go +++ b/binance/spot/marketdata/types/server_time.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type ServerTime struct { diff --git a/binance/spot/marketdata/types/ticker.go b/binance/spot/marketdata/types/ticker.go index 3ff5fde..ca8541b 100644 --- a/binance/spot/marketdata/types/ticker.go +++ b/binance/spot/marketdata/types/ticker.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetTickerForSymbolParam struct { diff --git a/binance/spot/marketdata/types/ticker_price.go b/binance/spot/marketdata/types/ticker_price.go index 6681a39..e297967 100644 --- a/binance/spot/marketdata/types/ticker_price.go +++ b/binance/spot/marketdata/types/ticker_price.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetTickerPriceForSymbolParam struct { diff --git a/binance/spot/marketdata/types/trades.go b/binance/spot/marketdata/types/trades.go index 511b879..270de79 100644 --- a/binance/spot/marketdata/types/trades.go +++ b/binance/spot/marketdata/types/trades.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetTradeParams struct { diff --git a/binance/spot/spotaccount/client.go b/binance/spot/spotaccount/client.go index f12e981..d554740 100644 --- a/binance/spot/spotaccount/client.go +++ b/binance/spot/spotaccount/client.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package spotaccount import ( diff --git a/binance/spot/spotaccount/client_test.go b/binance/spot/spotaccount/client_test.go index 0b3431f..a10ec7e 100644 --- a/binance/spot/spotaccount/client_test.go +++ b/binance/spot/spotaccount/client_test.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package spotaccount import ( diff --git a/binance/spot/spotaccount/types/account_info.go b/binance/spot/spotaccount/types/account_info.go index 5a24fa4..36ea5cd 100644 --- a/binance/spot/spotaccount/types/account_info.go +++ b/binance/spot/spotaccount/types/account_info.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type AccountInfo struct { @@ -24,4 +41,4 @@ type AccountInfo struct { Locked string `json:"locked"` } `json:"balances"` Permissions []string `json:"permissions"` -} \ No newline at end of file +} diff --git a/binance/spot/spotaccount/types/oco.go b/binance/spot/spotaccount/types/oco.go index 5bb13ec..1fa8e2b 100644 --- a/binance/spot/spotaccount/types/oco.go +++ b/binance/spot/spotaccount/types/oco.go @@ -1,2 +1,18 @@ -package types +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package types diff --git a/binance/spot/spotaccount/types/order.go b/binance/spot/spotaccount/types/order.go index 0981fb2..04b2305 100644 --- a/binance/spot/spotaccount/types/order.go +++ b/binance/spot/spotaccount/types/order.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types import ( diff --git a/binance/spot/spotaccount/types/trade_list.go b/binance/spot/spotaccount/types/trade_list.go index c1a26d2..eb5f4d4 100644 --- a/binance/spot/spotaccount/types/trade_list.go +++ b/binance/spot/spotaccount/types/trade_list.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types import ( diff --git a/binance/spot/subaccount/client.go b/binance/spot/subaccount/client.go index 324cd9e..74f17c6 100644 --- a/binance/spot/subaccount/client.go +++ b/binance/spot/subaccount/client.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package subaccount import ( diff --git a/binance/spot/subaccount/client_test.go b/binance/spot/subaccount/client_test.go index da34bb3..c335391 100644 --- a/binance/spot/subaccount/client_test.go +++ b/binance/spot/subaccount/client_test.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package subaccount import ( diff --git a/binance/spot/subaccount/types/sub_account_transfer_history.go b/binance/spot/subaccount/types/sub_account_transfer_history.go index 9eceda0..dbe7d1f 100644 --- a/binance/spot/subaccount/types/sub_account_transfer_history.go +++ b/binance/spot/subaccount/types/sub_account_transfer_history.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types import "github.com/linstohu/nexapi/binance/utils" diff --git a/binance/spot/utils/client.go b/binance/spot/utils/client.go index 4f7e03b..efe0299 100644 --- a/binance/spot/utils/client.go +++ b/binance/spot/utils/client.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package spotutils import ( diff --git a/binance/spot/utils/request.go b/binance/spot/utils/request.go index 0fd4d8b..e7cb98b 100644 --- a/binance/spot/utils/request.go +++ b/binance/spot/utils/request.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package spotutils type HTTPRequest struct { diff --git a/binance/spot/utils/vars.go b/binance/spot/utils/vars.go index 4f68a59..d28a88d 100644 --- a/binance/spot/utils/vars.go +++ b/binance/spot/utils/vars.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package spotutils var ( diff --git a/binance/spot/wallet/client.go b/binance/spot/wallet/client.go index 651c5f2..2dd78c4 100644 --- a/binance/spot/wallet/client.go +++ b/binance/spot/wallet/client.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package wallet import ( diff --git a/binance/spot/wallet/client_test.go b/binance/spot/wallet/client_test.go index 29130a4..215cb6c 100644 --- a/binance/spot/wallet/client_test.go +++ b/binance/spot/wallet/client_test.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package wallet import ( diff --git a/binance/spot/wallet/types/all_coins_Info.go b/binance/spot/wallet/types/all_coins_Info.go index 0d0e5d0..79e6f0e 100644 --- a/binance/spot/wallet/types/all_coins_Info.go +++ b/binance/spot/wallet/types/all_coins_Info.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type CoinInfo struct { diff --git a/binance/spot/wallet/types/api_restrictions.go b/binance/spot/wallet/types/api_restrictions.go index c93192f..1bd7804 100644 --- a/binance/spot/wallet/types/api_restrictions.go +++ b/binance/spot/wallet/types/api_restrictions.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type ApiRestrictions struct { diff --git a/binance/spot/wallet/types/asset_detail.go b/binance/spot/wallet/types/asset_detail.go index 35d8f98..2fa3ac1 100644 --- a/binance/spot/wallet/types/asset_detail.go +++ b/binance/spot/wallet/types/asset_detail.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types import "github.com/linstohu/nexapi/binance/utils" diff --git a/binance/spot/wallet/types/funding_wallet.go b/binance/spot/wallet/types/funding_wallet.go index a7169d5..241eba2 100644 --- a/binance/spot/wallet/types/funding_wallet.go +++ b/binance/spot/wallet/types/funding_wallet.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types import "github.com/linstohu/nexapi/binance/utils" diff --git a/binance/spot/wallet/types/system_status.go b/binance/spot/wallet/types/system_status.go index 7e541fd..1f7063c 100644 --- a/binance/spot/wallet/types/system_status.go +++ b/binance/spot/wallet/types/system_status.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type SystemStatus struct { diff --git a/binance/spot/wallet/types/trade_fee.go b/binance/spot/wallet/types/trade_fee.go index d822090..85c8a0c 100644 --- a/binance/spot/wallet/types/trade_fee.go +++ b/binance/spot/wallet/types/trade_fee.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types import "github.com/linstohu/nexapi/binance/utils" diff --git a/binance/spot/wallet/types/universal_transfer.go b/binance/spot/wallet/types/universal_transfer.go index a996a90..eb547af 100644 --- a/binance/spot/wallet/types/universal_transfer.go +++ b/binance/spot/wallet/types/universal_transfer.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types import "github.com/linstohu/nexapi/binance/utils" diff --git a/binance/spot/wallet/types/user_asset.go b/binance/spot/wallet/types/user_asset.go index e1f29ac..c8e0fc6 100644 --- a/binance/spot/wallet/types/user_asset.go +++ b/binance/spot/wallet/types/user_asset.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types import "github.com/linstohu/nexapi/binance/utils" diff --git a/binance/spot/websocketmarket/client.go b/binance/spot/websocketmarket/client.go index 9f326e8..89f3f45 100644 --- a/binance/spot/websocketmarket/client.go +++ b/binance/spot/websocketmarket/client.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package websocketmarket import ( @@ -124,7 +141,7 @@ func (m *SpotMarketStreamClient) reconnect() { m.setIsConnected(false) - m.logger.Info(fmt.Sprintf("disconnect, then reconnect...")) + m.logger.Info("disconnect, then reconnect...") time.Sleep(1 * time.Second) diff --git a/binance/spot/websocketmarket/client_test.go b/binance/spot/websocketmarket/client_test.go index f67fa5e..b91bcdd 100644 --- a/binance/spot/websocketmarket/client_test.go +++ b/binance/spot/websocketmarket/client_test.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package websocketmarket import ( diff --git a/binance/spot/websocketmarket/events.go b/binance/spot/websocketmarket/events.go index 3c33abd..d3dbd27 100644 --- a/binance/spot/websocketmarket/events.go +++ b/binance/spot/websocketmarket/events.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package websocketmarket import "github.com/chuckpreslar/emission" diff --git a/binance/spot/websocketmarket/subscriptions.go b/binance/spot/websocketmarket/subscriptions.go index e7c2311..cb550ae 100644 --- a/binance/spot/websocketmarket/subscriptions.go +++ b/binance/spot/websocketmarket/subscriptions.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package websocketmarket import ( diff --git a/binance/spot/websocketmarket/topics.go b/binance/spot/websocketmarket/topics.go index d18b9f2..e1affef 100644 --- a/binance/spot/websocketmarket/topics.go +++ b/binance/spot/websocketmarket/topics.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package websocketmarket import ( diff --git a/binance/spot/websocketmarket/types/messages.go b/binance/spot/websocketmarket/types/messages.go index 4b225a5..e3b809c 100644 --- a/binance/spot/websocketmarket/types/messages.go +++ b/binance/spot/websocketmarket/types/messages.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type AggregateTrade struct { diff --git a/binance/spot/websocketmarket/vars.go b/binance/spot/websocketmarket/vars.go index a17fbac..0cffeac 100644 --- a/binance/spot/websocketmarket/vars.go +++ b/binance/spot/websocketmarket/vars.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package websocketmarket var ( diff --git a/binance/usdmfutures/account/client.go b/binance/usdmfutures/account/client.go index 7072b29..e802fda 100644 --- a/binance/usdmfutures/account/client.go +++ b/binance/usdmfutures/account/client.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package account import ( diff --git a/binance/usdmfutures/account/client_test.go b/binance/usdmfutures/account/client_test.go index 64593f3..64bc709 100644 --- a/binance/usdmfutures/account/client_test.go +++ b/binance/usdmfutures/account/client_test.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package account import ( diff --git a/binance/usdmfutures/account/types/account.go b/binance/usdmfutures/account/types/account.go index 6be1652..5527459 100644 --- a/binance/usdmfutures/account/types/account.go +++ b/binance/usdmfutures/account/types/account.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type Account struct { diff --git a/binance/usdmfutures/account/types/balance.go b/binance/usdmfutures/account/types/balance.go index 3d11894..da29eaa 100644 --- a/binance/usdmfutures/account/types/balance.go +++ b/binance/usdmfutures/account/types/balance.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type Balance struct { diff --git a/binance/usdmfutures/account/types/leverage.go b/binance/usdmfutures/account/types/leverage.go index c53b873..ce5ca59 100644 --- a/binance/usdmfutures/account/types/leverage.go +++ b/binance/usdmfutures/account/types/leverage.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types import ( diff --git a/binance/usdmfutures/account/types/margin.go b/binance/usdmfutures/account/types/margin.go index 1b72a37..01ce656 100644 --- a/binance/usdmfutures/account/types/margin.go +++ b/binance/usdmfutures/account/types/margin.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types import ( diff --git a/binance/usdmfutures/account/types/multi_asset.go b/binance/usdmfutures/account/types/multi_asset.go index 44b94f7..94380a4 100644 --- a/binance/usdmfutures/account/types/multi_asset.go +++ b/binance/usdmfutures/account/types/multi_asset.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types import ( diff --git a/binance/usdmfutures/account/types/order.go b/binance/usdmfutures/account/types/order.go index c3b1605..4bdeb85 100644 --- a/binance/usdmfutures/account/types/order.go +++ b/binance/usdmfutures/account/types/order.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types import ( diff --git a/binance/usdmfutures/account/types/position.go b/binance/usdmfutures/account/types/position.go index d78df8f..e959c6e 100644 --- a/binance/usdmfutures/account/types/position.go +++ b/binance/usdmfutures/account/types/position.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types import ( diff --git a/binance/usdmfutures/account/types/position_mode.go b/binance/usdmfutures/account/types/position_mode.go index c0287f6..cc19199 100644 --- a/binance/usdmfutures/account/types/position_mode.go +++ b/binance/usdmfutures/account/types/position_mode.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types import ( diff --git a/binance/usdmfutures/account/types/response.go b/binance/usdmfutures/account/types/response.go index cb2f066..9f7fbe0 100644 --- a/binance/usdmfutures/account/types/response.go +++ b/binance/usdmfutures/account/types/response.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type Response struct { diff --git a/binance/usdmfutures/account/types/trade.go b/binance/usdmfutures/account/types/trade.go index 6c88ed1..f4ce666 100644 --- a/binance/usdmfutures/account/types/trade.go +++ b/binance/usdmfutures/account/types/trade.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types import ( diff --git a/binance/usdmfutures/marketdata/client.go b/binance/usdmfutures/marketdata/client.go index 11a5eb8..2b93ebe 100644 --- a/binance/usdmfutures/marketdata/client.go +++ b/binance/usdmfutures/marketdata/client.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package marketdata import ( diff --git a/binance/usdmfutures/marketdata/client_test.go b/binance/usdmfutures/marketdata/client_test.go index 475a730..f1ab264 100644 --- a/binance/usdmfutures/marketdata/client_test.go +++ b/binance/usdmfutures/marketdata/client_test.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package marketdata import ( diff --git a/binance/usdmfutures/marketdata/types/agg_trades.go b/binance/usdmfutures/marketdata/types/agg_trades.go index a64f6cd..e2d9610 100644 --- a/binance/usdmfutures/marketdata/types/agg_trades.go +++ b/binance/usdmfutures/marketdata/types/agg_trades.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetAggTradesParam struct { diff --git a/binance/usdmfutures/marketdata/types/book_ticker.go b/binance/usdmfutures/marketdata/types/book_ticker.go index b74944b..56dbc30 100644 --- a/binance/usdmfutures/marketdata/types/book_ticker.go +++ b/binance/usdmfutures/marketdata/types/book_ticker.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetBookTickerForSymbolParam struct { diff --git a/binance/usdmfutures/marketdata/types/exchange_info.go b/binance/usdmfutures/marketdata/types/exchange_info.go index 884a7f8..0c8c78a 100644 --- a/binance/usdmfutures/marketdata/types/exchange_info.go +++ b/binance/usdmfutures/marketdata/types/exchange_info.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types import ( diff --git a/binance/usdmfutures/marketdata/types/funding_rate.go b/binance/usdmfutures/marketdata/types/funding_rate.go index 5a357e2..116d285 100644 --- a/binance/usdmfutures/marketdata/types/funding_rate.go +++ b/binance/usdmfutures/marketdata/types/funding_rate.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetFundingRateParam struct { diff --git a/binance/usdmfutures/marketdata/types/klines.go b/binance/usdmfutures/marketdata/types/klines.go index 08a74a0..8f941d4 100644 --- a/binance/usdmfutures/marketdata/types/klines.go +++ b/binance/usdmfutures/marketdata/types/klines.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types import ( diff --git a/binance/usdmfutures/marketdata/types/mark_price.go b/binance/usdmfutures/marketdata/types/mark_price.go index c5b824b..adaf254 100644 --- a/binance/usdmfutures/marketdata/types/mark_price.go +++ b/binance/usdmfutures/marketdata/types/mark_price.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetMarkPriceParam struct { diff --git a/binance/usdmfutures/marketdata/types/open_interest_hist.go b/binance/usdmfutures/marketdata/types/open_interest_hist.go index 73c2105..9ba5b04 100644 --- a/binance/usdmfutures/marketdata/types/open_interest_hist.go +++ b/binance/usdmfutures/marketdata/types/open_interest_hist.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetOpenInterestHistParam struct { diff --git a/binance/usdmfutures/marketdata/types/orderbook.go b/binance/usdmfutures/marketdata/types/orderbook.go index 7026551..0f1ed95 100644 --- a/binance/usdmfutures/marketdata/types/orderbook.go +++ b/binance/usdmfutures/marketdata/types/orderbook.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetOrderbookParams struct { diff --git a/binance/usdmfutures/marketdata/types/ticker_price.go b/binance/usdmfutures/marketdata/types/ticker_price.go index d49d4aa..7d8c44b 100644 --- a/binance/usdmfutures/marketdata/types/ticker_price.go +++ b/binance/usdmfutures/marketdata/types/ticker_price.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetTickerPriceParam struct { diff --git a/binance/usdmfutures/marketdata/types/trades.go b/binance/usdmfutures/marketdata/types/trades.go index 99f3c82..fe9366e 100644 --- a/binance/usdmfutures/marketdata/types/trades.go +++ b/binance/usdmfutures/marketdata/types/trades.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetTradeParams struct { diff --git a/binance/usdmfutures/utils/client.go b/binance/usdmfutures/utils/client.go index 2c63497..fd4bceb 100644 --- a/binance/usdmfutures/utils/client.go +++ b/binance/usdmfutures/utils/client.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package umutils import ( diff --git a/binance/usdmfutures/utils/request.go b/binance/usdmfutures/utils/request.go index f5fa815..0aba47b 100644 --- a/binance/usdmfutures/utils/request.go +++ b/binance/usdmfutures/utils/request.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package umutils type HTTPRequest struct { diff --git a/binance/usdmfutures/utils/vars.go b/binance/usdmfutures/utils/vars.go index 73ef55c..3ed9164 100644 --- a/binance/usdmfutures/utils/vars.go +++ b/binance/usdmfutures/utils/vars.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package umutils var ( diff --git a/binance/usdmfutures/websocketmarket/client.go b/binance/usdmfutures/websocketmarket/client.go index 0526a52..50bb307 100644 --- a/binance/usdmfutures/websocketmarket/client.go +++ b/binance/usdmfutures/websocketmarket/client.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package websocketmarket import ( @@ -124,7 +141,7 @@ func (u *USDMarginedMarketStreamClient) reconnect() { u.setIsConnected(false) - u.logger.Info(fmt.Sprintf("disconnect, then reconnect...")) + u.logger.Info("disconnect, then reconnect...") time.Sleep(1 * time.Second) diff --git a/binance/usdmfutures/websocketmarket/client_test.go b/binance/usdmfutures/websocketmarket/client_test.go index 7e48884..4ea294e 100644 --- a/binance/usdmfutures/websocketmarket/client_test.go +++ b/binance/usdmfutures/websocketmarket/client_test.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package websocketmarket import ( diff --git a/binance/usdmfutures/websocketmarket/events.go b/binance/usdmfutures/websocketmarket/events.go index 90ba905..2d24d5e 100644 --- a/binance/usdmfutures/websocketmarket/events.go +++ b/binance/usdmfutures/websocketmarket/events.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package websocketmarket import "github.com/chuckpreslar/emission" diff --git a/binance/usdmfutures/websocketmarket/subscriptions.go b/binance/usdmfutures/websocketmarket/subscriptions.go index 8e5f368..e09baad 100644 --- a/binance/usdmfutures/websocketmarket/subscriptions.go +++ b/binance/usdmfutures/websocketmarket/subscriptions.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package websocketmarket import ( diff --git a/binance/usdmfutures/websocketmarket/topics.go b/binance/usdmfutures/websocketmarket/topics.go index 3fa2b6a..4c0217e 100644 --- a/binance/usdmfutures/websocketmarket/topics.go +++ b/binance/usdmfutures/websocketmarket/topics.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package websocketmarket import ( diff --git a/binance/usdmfutures/websocketmarket/types/messages.go b/binance/usdmfutures/websocketmarket/types/messages.go index 2581911..db414ec 100644 --- a/binance/usdmfutures/websocketmarket/types/messages.go +++ b/binance/usdmfutures/websocketmarket/types/messages.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types import ( diff --git a/binance/usdmfutures/websocketmarket/vars.go b/binance/usdmfutures/websocketmarket/vars.go index 469a951..6c0f593 100644 --- a/binance/usdmfutures/websocketmarket/vars.go +++ b/binance/usdmfutures/websocketmarket/vars.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package websocketmarket var ( diff --git a/binance/utils/normalization.go b/binance/utils/normalization.go index 869675a..3bb3f7f 100644 --- a/binance/utils/normalization.go +++ b/binance/utils/normalization.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package utils import ( diff --git a/binance/utils/types.go b/binance/utils/types.go index 8873de0..f76f3ba 100644 --- a/binance/utils/types.go +++ b/binance/utils/types.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package utils type DefaultParam struct { diff --git a/binance/utils/websocket_response.go b/binance/utils/websocket_response.go index e4781bb..1c7b266 100644 --- a/binance/utils/websocket_response.go +++ b/binance/utils/websocket_response.go @@ -1,5 +1,21 @@ -package utils +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package utils import ( "encoding/json" diff --git a/bitfinex/restauth/api.go b/bitfinex/restauth/api.go index 4c7c149..a55cda6 100644 --- a/bitfinex/restauth/api.go +++ b/bitfinex/restauth/api.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package bitfinexrestauth import ( diff --git a/bitfinex/restauth/client.go b/bitfinex/restauth/client.go index 1273ab4..ae95cb5 100644 --- a/bitfinex/restauth/client.go +++ b/bitfinex/restauth/client.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package bitfinexrestauth import ( diff --git a/bitfinex/restauth/client_test.go b/bitfinex/restauth/client_test.go index 8be0c41..5e10810 100644 --- a/bitfinex/restauth/client_test.go +++ b/bitfinex/restauth/client_test.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package bitfinexrestauth import ( diff --git a/bitfinex/restpub/api.go b/bitfinex/restpub/api.go index 57ddfdf..d565d25 100644 --- a/bitfinex/restpub/api.go +++ b/bitfinex/restpub/api.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package bitfinexrestpub import ( diff --git a/bitfinex/restpub/client.go b/bitfinex/restpub/client.go index 549df42..c2caaf3 100644 --- a/bitfinex/restpub/client.go +++ b/bitfinex/restpub/client.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package bitfinexrestpub import ( diff --git a/bitfinex/restpub/client_test.go b/bitfinex/restpub/client_test.go index 5784018..52dc943 100644 --- a/bitfinex/restpub/client_test.go +++ b/bitfinex/restpub/client_test.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package bitfinexrestpub import ( diff --git a/bitfinex/utils/nonce.go b/bitfinex/utils/nonce.go index f62471c..c7ebb88 100644 --- a/bitfinex/utils/nonce.go +++ b/bitfinex/utils/nonce.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package utils import ( diff --git a/deribit/rest/client.go b/deribit/rest/client.go index 17b8b32..15b41df 100644 --- a/deribit/rest/client.go +++ b/deribit/rest/client.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package rest import ( diff --git a/deribit/rest/private_api_test.go b/deribit/rest/private_api_test.go index 4434d81..ce2f05d 100644 --- a/deribit/rest/private_api_test.go +++ b/deribit/rest/private_api_test.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package rest import ( diff --git a/deribit/rest/private_req.go b/deribit/rest/private_req.go index 9bc55d8..f4efdb0 100644 --- a/deribit/rest/private_req.go +++ b/deribit/rest/private_req.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package rest import ( diff --git a/deribit/rest/public_api_test.go b/deribit/rest/public_api_test.go index 36189fa..954f44c 100644 --- a/deribit/rest/public_api_test.go +++ b/deribit/rest/public_api_test.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package rest import ( diff --git a/deribit/rest/public_req.go b/deribit/rest/public_req.go index ba123c6..0f8d7ab 100644 --- a/deribit/rest/public_req.go +++ b/deribit/rest/public_req.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package rest import ( diff --git a/deribit/rest/types/account/account_summary.go b/deribit/rest/types/account/account_summary.go index 80bd3bd..b7667aa 100644 --- a/deribit/rest/types/account/account_summary.go +++ b/deribit/rest/types/account/account_summary.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package account type AccountSummary struct { diff --git a/deribit/rest/types/account/position.go b/deribit/rest/types/account/position.go index 086b685..1de6401 100644 --- a/deribit/rest/types/account/position.go +++ b/deribit/rest/types/account/position.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package account type Position struct { diff --git a/deribit/rest/types/account/transaction_log.go b/deribit/rest/types/account/transaction_log.go index d8a4bcc..9b69a1d 100644 --- a/deribit/rest/types/account/transaction_log.go +++ b/deribit/rest/types/account/transaction_log.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package account type TransLog struct { diff --git a/deribit/rest/types/auth/auth.go b/deribit/rest/types/auth/auth.go index 1bfffe6..d4e5c27 100644 --- a/deribit/rest/types/auth/auth.go +++ b/deribit/rest/types/auth/auth.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package auth type AuthParams struct { diff --git a/deribit/rest/types/marketdata/book_summary.go b/deribit/rest/types/marketdata/book_summary.go index 86ced11..b46902b 100644 --- a/deribit/rest/types/marketdata/book_summary.go +++ b/deribit/rest/types/marketdata/book_summary.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package marketdata type BookSummary struct { diff --git a/deribit/rest/types/marketdata/currency.go b/deribit/rest/types/marketdata/currency.go index d42db95..3ef07dc 100644 --- a/deribit/rest/types/marketdata/currency.go +++ b/deribit/rest/types/marketdata/currency.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package marketdata type Currency struct { diff --git a/deribit/rest/types/marketdata/get_contract_size.go b/deribit/rest/types/marketdata/get_contract_size.go index a945ef5..c83923c 100644 --- a/deribit/rest/types/marketdata/get_contract_size.go +++ b/deribit/rest/types/marketdata/get_contract_size.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package marketdata type GetContractSizeParams struct { diff --git a/deribit/rest/types/marketdata/get_funding_rate.go b/deribit/rest/types/marketdata/get_funding_rate.go index a23e6be..37429f9 100644 --- a/deribit/rest/types/marketdata/get_funding_rate.go +++ b/deribit/rest/types/marketdata/get_funding_rate.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package marketdata type GetFundingRateParams struct { diff --git a/deribit/rest/types/marketdata/get_index.go b/deribit/rest/types/marketdata/get_index.go index 29b51d7..ae65a93 100644 --- a/deribit/rest/types/marketdata/get_index.go +++ b/deribit/rest/types/marketdata/get_index.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package marketdata type GetIndexPriceParams struct { diff --git a/deribit/rest/types/marketdata/get_order_book.go b/deribit/rest/types/marketdata/get_order_book.go index d757c49..2f6c87e 100644 --- a/deribit/rest/types/marketdata/get_order_book.go +++ b/deribit/rest/types/marketdata/get_order_book.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package marketdata type GetOrderBookParams struct { diff --git a/deribit/rest/types/marketdata/get_tradingview_chart_data.go b/deribit/rest/types/marketdata/get_tradingview_chart_data.go index 02be351..4683770 100644 --- a/deribit/rest/types/marketdata/get_tradingview_chart_data.go +++ b/deribit/rest/types/marketdata/get_tradingview_chart_data.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package marketdata type GetTradingviewChartDataParams struct { diff --git a/deribit/rest/types/marketdata/instrument.go b/deribit/rest/types/marketdata/instrument.go index 8c62012..f6ae81b 100644 --- a/deribit/rest/types/marketdata/instrument.go +++ b/deribit/rest/types/marketdata/instrument.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package marketdata type Instrument struct { diff --git a/deribit/rest/types/marketdata/ticker.go b/deribit/rest/types/marketdata/ticker.go index a16133d..b0b01ca 100644 --- a/deribit/rest/types/marketdata/ticker.go +++ b/deribit/rest/types/marketdata/ticker.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package marketdata type TickerParams struct { diff --git a/deribit/rest/types/marketdata/trade.go b/deribit/rest/types/marketdata/trade.go index 6026e37..33e3df3 100644 --- a/deribit/rest/types/marketdata/trade.go +++ b/deribit/rest/types/marketdata/trade.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package marketdata type Trade struct { diff --git a/deribit/rest/types/supporting/test.go b/deribit/rest/types/supporting/test.go index 337f1e9..9a3170a 100644 --- a/deribit/rest/types/supporting/test.go +++ b/deribit/rest/types/supporting/test.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package supporting type TestResponse struct { diff --git a/deribit/rest/types/trading/buy.go b/deribit/rest/types/trading/buy.go index e4dd2fd..cb398a2 100644 --- a/deribit/rest/types/trading/buy.go +++ b/deribit/rest/types/trading/buy.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package trading type BuyParams struct { diff --git a/deribit/rest/types/trading/cancel.go b/deribit/rest/types/trading/cancel.go index 9466f1b..814f345 100644 --- a/deribit/rest/types/trading/cancel.go +++ b/deribit/rest/types/trading/cancel.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package trading type CancelParams struct { diff --git a/deribit/rest/types/trading/close_position.go b/deribit/rest/types/trading/close_position.go index eaabf3d..e48dbd7 100644 --- a/deribit/rest/types/trading/close_position.go +++ b/deribit/rest/types/trading/close_position.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package trading type ClosePositionParams struct { diff --git a/deribit/rest/types/trading/get_open_orders.go b/deribit/rest/types/trading/get_open_orders.go index aebb0d6..fb16d6d 100644 --- a/deribit/rest/types/trading/get_open_orders.go +++ b/deribit/rest/types/trading/get_open_orders.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package trading type GetOrderStateParams struct { diff --git a/deribit/rest/types/trading/get_user_trades.go b/deribit/rest/types/trading/get_user_trades.go index b2ea547..aeb4594 100644 --- a/deribit/rest/types/trading/get_user_trades.go +++ b/deribit/rest/types/trading/get_user_trades.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package trading type GetUserTradesResponse struct { diff --git a/deribit/rest/types/trading/order.go b/deribit/rest/types/trading/order.go index 3f4ba39..616aeb2 100644 --- a/deribit/rest/types/trading/order.go +++ b/deribit/rest/types/trading/order.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package trading import "strconv" diff --git a/deribit/rest/types/trading/sell.go b/deribit/rest/types/trading/sell.go index e73a8f7..c5c5375 100644 --- a/deribit/rest/types/trading/sell.go +++ b/deribit/rest/types/trading/sell.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package trading type SellParams struct { diff --git a/deribit/rest/types/trading/settlement.go b/deribit/rest/types/trading/settlement.go index 96546c8..19f4c16 100644 --- a/deribit/rest/types/trading/settlement.go +++ b/deribit/rest/types/trading/settlement.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package trading type Settlement struct { diff --git a/deribit/rest/types/trading/trade.go b/deribit/rest/types/trading/trade.go index 3a3282e..0aeced6 100644 --- a/deribit/rest/types/trading/trade.go +++ b/deribit/rest/types/trading/trade.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package trading type Trade struct { diff --git a/deribit/rest/types/types.go b/deribit/rest/types/types.go index 8f19199..d25bb96 100644 --- a/deribit/rest/types/types.go +++ b/deribit/rest/types/types.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types import ( diff --git a/deribit/rest/vars.go b/deribit/rest/vars.go index a5a19ff..d099e75 100644 --- a/deribit/rest/vars.go +++ b/deribit/rest/vars.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package rest const ( diff --git a/mexc/contract/account/client.go b/mexc/contract/account/client.go index 13b253d..71d690f 100644 --- a/mexc/contract/account/client.go +++ b/mexc/contract/account/client.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package account import ( diff --git a/mexc/contract/account/client_test.go b/mexc/contract/account/client_test.go index fb78dc5..3fca630 100644 --- a/mexc/contract/account/client_test.go +++ b/mexc/contract/account/client_test.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package account import ( diff --git a/mexc/contract/account/types/assets.go b/mexc/contract/account/types/assets.go index d5d03bd..9ac67da 100644 --- a/mexc/contract/account/types/assets.go +++ b/mexc/contract/account/types/assets.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetAccountAsset struct { diff --git a/mexc/contract/account/types/leverage.go b/mexc/contract/account/types/leverage.go index a2cba24..17c5d13 100644 --- a/mexc/contract/account/types/leverage.go +++ b/mexc/contract/account/types/leverage.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetLeverageParams struct { diff --git a/mexc/contract/account/types/order.go b/mexc/contract/account/types/order.go index 6a9d724..9a9c8b1 100644 --- a/mexc/contract/account/types/order.go +++ b/mexc/contract/account/types/order.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type NewOrderParam struct { @@ -36,5 +53,3 @@ var ( ) type OpenType = int - -var () diff --git a/mexc/contract/account/types/positions.go b/mexc/contract/account/types/positions.go index 18406ab..a5547eb 100644 --- a/mexc/contract/account/types/positions.go +++ b/mexc/contract/account/types/positions.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetOpenPositionsParams struct { diff --git a/mexc/contract/account/types/types.go b/mexc/contract/account/types/types.go index 69462cf..ef890a7 100644 --- a/mexc/contract/account/types/types.go +++ b/mexc/contract/account/types/types.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type Response struct { diff --git a/mexc/contract/marketdata/client.go b/mexc/contract/marketdata/client.go index bac8bbd..3362ae4 100644 --- a/mexc/contract/marketdata/client.go +++ b/mexc/contract/marketdata/client.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package marketdata import ( diff --git a/mexc/contract/marketdata/client_test.go b/mexc/contract/marketdata/client_test.go index 280cddd..6934cf1 100644 --- a/mexc/contract/marketdata/client_test.go +++ b/mexc/contract/marketdata/client_test.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package marketdata import ( diff --git a/mexc/contract/marketdata/types/contract_details.go b/mexc/contract/marketdata/types/contract_details.go index e1f97ab..d7217ae 100644 --- a/mexc/contract/marketdata/types/contract_details.go +++ b/mexc/contract/marketdata/types/contract_details.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetContractDetailsParams struct { diff --git a/mexc/contract/marketdata/types/server_time.go b/mexc/contract/marketdata/types/server_time.go index fa3b664..10d47d8 100644 --- a/mexc/contract/marketdata/types/server_time.go +++ b/mexc/contract/marketdata/types/server_time.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type Response struct { diff --git a/mexc/contract/marketdata/types/ticker.go b/mexc/contract/marketdata/types/ticker.go index 3dbae74..000d729 100644 --- a/mexc/contract/marketdata/types/ticker.go +++ b/mexc/contract/marketdata/types/ticker.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetTickerForSymbolParam struct { diff --git a/mexc/contract/utils/client.go b/mexc/contract/utils/client.go index b17a8e8..4e58938 100644 --- a/mexc/contract/utils/client.go +++ b/mexc/contract/utils/client.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package ctutils import ( diff --git a/mexc/contract/utils/request.go b/mexc/contract/utils/request.go index 9786711..f8debd9 100644 --- a/mexc/contract/utils/request.go +++ b/mexc/contract/utils/request.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package ctutils type HTTPRequest struct { diff --git a/mexc/contract/utils/vars.go b/mexc/contract/utils/vars.go index 9dac987..3766c42 100644 --- a/mexc/contract/utils/vars.go +++ b/mexc/contract/utils/vars.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package ctutils var ( diff --git a/mexc/spot/marketdata/client.go b/mexc/spot/marketdata/client.go index 81fe0d7..5a4578f 100644 --- a/mexc/spot/marketdata/client.go +++ b/mexc/spot/marketdata/client.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package marketdata import ( diff --git a/mexc/spot/marketdata/client_test.go b/mexc/spot/marketdata/client_test.go index 4c46bb1..de59781 100644 --- a/mexc/spot/marketdata/client_test.go +++ b/mexc/spot/marketdata/client_test.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package marketdata import ( diff --git a/mexc/spot/marketdata/types/agg_trades.go b/mexc/spot/marketdata/types/agg_trades.go index bea2556..eeeae14 100644 --- a/mexc/spot/marketdata/types/agg_trades.go +++ b/mexc/spot/marketdata/types/agg_trades.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetAggTradesParam struct { diff --git a/mexc/spot/marketdata/types/average_price.go b/mexc/spot/marketdata/types/average_price.go index c125513..f1e371b 100644 --- a/mexc/spot/marketdata/types/average_price.go +++ b/mexc/spot/marketdata/types/average_price.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetAvgPriceParam struct { diff --git a/mexc/spot/marketdata/types/book_ticker.go b/mexc/spot/marketdata/types/book_ticker.go index 7913df3..73b6889 100644 --- a/mexc/spot/marketdata/types/book_ticker.go +++ b/mexc/spot/marketdata/types/book_ticker.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetBookTickerParam struct { diff --git a/mexc/spot/marketdata/types/exchange_info.go b/mexc/spot/marketdata/types/exchange_info.go index 325ec0c..fdb6c8d 100644 --- a/mexc/spot/marketdata/types/exchange_info.go +++ b/mexc/spot/marketdata/types/exchange_info.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetExchangeInfoParam struct { diff --git a/mexc/spot/marketdata/types/klines.go b/mexc/spot/marketdata/types/klines.go index d5ad0b5..f332090 100644 --- a/mexc/spot/marketdata/types/klines.go +++ b/mexc/spot/marketdata/types/klines.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types import ( diff --git a/mexc/spot/marketdata/types/orderbook.go b/mexc/spot/marketdata/types/orderbook.go index cdd6e7e..eb554c4 100644 --- a/mexc/spot/marketdata/types/orderbook.go +++ b/mexc/spot/marketdata/types/orderbook.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetOrderbookParams struct { @@ -6,7 +23,7 @@ type GetOrderbookParams struct { } type Orderbook struct { - LastUpdateID int64 `json:"lastUpdateId"` + LastUpdateID int64 `json:"lastUpdateId"` Bids [][]string `json:"bids"` Asks [][]string `json:"asks"` } diff --git a/mexc/spot/marketdata/types/server_time.go b/mexc/spot/marketdata/types/server_time.go index bda1061..6838532 100644 --- a/mexc/spot/marketdata/types/server_time.go +++ b/mexc/spot/marketdata/types/server_time.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type ServerTime struct { diff --git a/mexc/spot/marketdata/types/symbols.go b/mexc/spot/marketdata/types/symbols.go index 7206341..6224737 100644 --- a/mexc/spot/marketdata/types/symbols.go +++ b/mexc/spot/marketdata/types/symbols.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type Symbols struct { diff --git a/mexc/spot/marketdata/types/ticker.go b/mexc/spot/marketdata/types/ticker.go index dbf9f54..04ebef9 100644 --- a/mexc/spot/marketdata/types/ticker.go +++ b/mexc/spot/marketdata/types/ticker.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetTickerForSymbolParam struct { diff --git a/mexc/spot/marketdata/types/ticker_price.go b/mexc/spot/marketdata/types/ticker_price.go index 6038c72..77778d4 100644 --- a/mexc/spot/marketdata/types/ticker_price.go +++ b/mexc/spot/marketdata/types/ticker_price.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetTickerPriceForSymbolParam struct { diff --git a/mexc/spot/marketdata/types/trades.go b/mexc/spot/marketdata/types/trades.go index 511b879..270de79 100644 --- a/mexc/spot/marketdata/types/trades.go +++ b/mexc/spot/marketdata/types/trades.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetTradeParams struct { diff --git a/mexc/spot/spotaccount/client.go b/mexc/spot/spotaccount/client.go index f0b97fb..87e83b5 100644 --- a/mexc/spot/spotaccount/client.go +++ b/mexc/spot/spotaccount/client.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package spotaccount import ( diff --git a/mexc/spot/spotaccount/client_test.go b/mexc/spot/spotaccount/client_test.go index 9b67f0f..c0df433 100644 --- a/mexc/spot/spotaccount/client_test.go +++ b/mexc/spot/spotaccount/client_test.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package spotaccount import ( @@ -37,9 +54,9 @@ func TestTransfer(t *testing.T) { err := cli.Transfer(context.TODO(), types.TransferParam{ FromAccountType: "SPOT", - ToAccountType: "FUTURES", - Asset: "USDT", - Amount: "5", + ToAccountType: "FUTURES", + Asset: "USDT", + Amount: "5", }) assert.Nil(t, err) } diff --git a/mexc/spot/spotaccount/types/account_info.go b/mexc/spot/spotaccount/types/account_info.go index a772a99..4a022f4 100644 --- a/mexc/spot/spotaccount/types/account_info.go +++ b/mexc/spot/spotaccount/types/account_info.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type AccountInfo struct { diff --git a/mexc/spot/spotaccount/types/transfer.go b/mexc/spot/spotaccount/types/transfer.go index 69fcf39..9be0325 100644 --- a/mexc/spot/spotaccount/types/transfer.go +++ b/mexc/spot/spotaccount/types/transfer.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types import "github.com/linstohu/nexapi/mexc/utils" diff --git a/mexc/spot/utils/client.go b/mexc/spot/utils/client.go index 642b486..62dd110 100644 --- a/mexc/spot/utils/client.go +++ b/mexc/spot/utils/client.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package spotutils import ( diff --git a/mexc/spot/utils/request.go b/mexc/spot/utils/request.go index 0336521..269e065 100644 --- a/mexc/spot/utils/request.go +++ b/mexc/spot/utils/request.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package spotutils type HTTPRequest struct { diff --git a/mexc/spot/utils/vars.go b/mexc/spot/utils/vars.go index 4855d3a..1499450 100644 --- a/mexc/spot/utils/vars.go +++ b/mexc/spot/utils/vars.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package spotutils var ( diff --git a/mexc/utils/normalization.go b/mexc/utils/normalization.go index 869675a..3bb3f7f 100644 --- a/mexc/utils/normalization.go +++ b/mexc/utils/normalization.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package utils import ( diff --git a/mexc/utils/types.go b/mexc/utils/types.go index 8873de0..f76f3ba 100644 --- a/mexc/utils/types.go +++ b/mexc/utils/types.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package utils type DefaultParam struct { diff --git a/mexc/utils/websocket_response.go b/mexc/utils/websocket_response.go index e4781bb..1c7b266 100644 --- a/mexc/utils/websocket_response.go +++ b/mexc/utils/websocket_response.go @@ -1,5 +1,21 @@ -package utils +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package utils import ( "encoding/json" diff --git a/okx/publicdata/client.go b/okx/publicdata/client.go index 78acc2b..7a9550c 100644 --- a/okx/publicdata/client.go +++ b/okx/publicdata/client.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package publicdata import ( diff --git a/okx/publicdata/client_test.go b/okx/publicdata/client_test.go index 4a8e263..176d5d6 100644 --- a/okx/publicdata/client_test.go +++ b/okx/publicdata/client_test.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package publicdata import ( diff --git a/okx/publicdata/types/instrument.go b/okx/publicdata/types/instrument.go index cedff9b..bce9065 100644 --- a/okx/publicdata/types/instrument.go +++ b/okx/publicdata/types/instrument.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types import ( diff --git a/okx/tradingaccount/client.go b/okx/tradingaccount/client.go index 34a4500..537596b 100644 --- a/okx/tradingaccount/client.go +++ b/okx/tradingaccount/client.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package publicdata import ( diff --git a/okx/tradingaccount/client_test.go b/okx/tradingaccount/client_test.go index 9e27722..e247b12 100644 --- a/okx/tradingaccount/client_test.go +++ b/okx/tradingaccount/client_test.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package publicdata import ( diff --git a/okx/tradingaccount/types/balance.go b/okx/tradingaccount/types/balance.go index 659d3c0..9ac1ee6 100644 --- a/okx/tradingaccount/types/balance.go +++ b/okx/tradingaccount/types/balance.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types import ( diff --git a/okx/utils/request.go b/okx/utils/request.go index ca11c86..ee5ec57 100644 --- a/okx/utils/request.go +++ b/okx/utils/request.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package okxutils type HTTPRequest struct { diff --git a/okx/utils/rest.go b/okx/utils/rest.go index dae8b78..699bc64 100644 --- a/okx/utils/rest.go +++ b/okx/utils/rest.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package okxutils import ( diff --git a/okx/utils/vars.go b/okx/utils/vars.go index 4a08f5e..5e78e99 100644 --- a/okx/utils/vars.go +++ b/okx/utils/vars.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package okxutils var ( diff --git a/woox/rest/client.go b/woox/rest/client.go index 54ccc5f..82e5ffb 100644 --- a/woox/rest/client.go +++ b/woox/rest/client.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package rest import ( diff --git a/woox/rest/private_api_test.go b/woox/rest/private_api_test.go index 141f14a..a1cc545 100644 --- a/woox/rest/private_api_test.go +++ b/woox/rest/private_api_test.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package rest import ( diff --git a/woox/rest/private_req.go b/woox/rest/private_req.go index f6231ef..1d1036b 100644 --- a/woox/rest/private_req.go +++ b/woox/rest/private_req.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package rest import ( diff --git a/woox/rest/public_api_test.go b/woox/rest/public_api_test.go index b3d9c38..e3d324b 100644 --- a/woox/rest/public_api_test.go +++ b/woox/rest/public_api_test.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package rest import ( diff --git a/woox/rest/public_req.go b/woox/rest/public_req.go index 110f4a1..55eab77 100644 --- a/woox/rest/public_req.go +++ b/woox/rest/public_req.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package rest import ( diff --git a/woox/rest/types/private_account_info.go b/woox/rest/types/private_account_info.go index 17675fe..5fe79bf 100644 --- a/woox/rest/types/private_account_info.go +++ b/woox/rest/types/private_account_info.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetAccountInfo struct { diff --git a/woox/rest/types/private_account_mode.go b/woox/rest/types/private_account_mode.go index 7b28d63..bdfa9e8 100644 --- a/woox/rest/types/private_account_mode.go +++ b/woox/rest/types/private_account_mode.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type UpdateAccountModeParam struct { diff --git a/woox/rest/types/private_asset_history.go b/woox/rest/types/private_asset_history.go index 772633e..5bc6c1d 100644 --- a/woox/rest/types/private_asset_history.go +++ b/woox/rest/types/private_asset_history.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetAssetHisotryParam struct { diff --git a/woox/rest/types/private_balances.go b/woox/rest/types/private_balances.go index e0fda93..852ccc3 100644 --- a/woox/rest/types/private_balances.go +++ b/woox/rest/types/private_balances.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type Balance struct { diff --git a/woox/rest/types/private_ip_restriction.go b/woox/rest/types/private_ip_restriction.go index 48b0444..a99b083 100644 --- a/woox/rest/types/private_ip_restriction.go +++ b/woox/rest/types/private_ip_restriction.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type IPRestriction struct { diff --git a/woox/rest/types/private_leverage.go b/woox/rest/types/private_leverage.go index 1efc755..698663b 100644 --- a/woox/rest/types/private_leverage.go +++ b/woox/rest/types/private_leverage.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type UpdateLeverageSettingParam struct { diff --git a/woox/rest/types/private_order_cancel.go b/woox/rest/types/private_order_cancel.go index 26a6d55..dbbcfea 100644 --- a/woox/rest/types/private_order_cancel.go +++ b/woox/rest/types/private_order_cancel.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type CancelOrderParam struct { diff --git a/woox/rest/types/private_order_get.go b/woox/rest/types/private_order_get.go index 9e1a1f7..97fa487 100644 --- a/woox/rest/types/private_order_get.go +++ b/woox/rest/types/private_order_get.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type Order struct { diff --git a/woox/rest/types/private_order_send.go b/woox/rest/types/private_order_send.go index bef90d4..4f6f845 100644 --- a/woox/rest/types/private_order_send.go +++ b/woox/rest/types/private_order_send.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type SendOrderReq struct { diff --git a/woox/rest/types/private_position.go b/woox/rest/types/private_position.go index 36f6540..11e67ac 100644 --- a/woox/rest/types/private_position.go +++ b/woox/rest/types/private_position.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type V1Position struct { diff --git a/woox/rest/types/private_subaccount.go b/woox/rest/types/private_subaccount.go index 11289a7..38c630c 100644 --- a/woox/rest/types/private_subaccount.go +++ b/woox/rest/types/private_subaccount.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type SubAccounts struct { diff --git a/woox/rest/types/private_trade.go b/woox/rest/types/private_trade.go index ac03c03..66da648 100644 --- a/woox/rest/types/private_trade.go +++ b/woox/rest/types/private_trade.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type Trade struct { diff --git a/woox/rest/types/private_transfer_asset.go b/woox/rest/types/private_transfer_asset.go index 635e751..21d62dd 100644 --- a/woox/rest/types/private_transfer_asset.go +++ b/woox/rest/types/private_transfer_asset.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type TransferAssetParam struct { diff --git a/woox/rest/types/public_funding_rate.go b/woox/rest/types/public_funding_rate.go index 6f634cb..911d46e 100644 --- a/woox/rest/types/public_funding_rate.go +++ b/woox/rest/types/public_funding_rate.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type FundingRates struct { diff --git a/woox/rest/types/public_futures_info.go b/woox/rest/types/public_futures_info.go index ae38cd0..a2a26d2 100644 --- a/woox/rest/types/public_futures_info.go +++ b/woox/rest/types/public_futures_info.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type FuturesInfo struct { diff --git a/woox/rest/types/public_info.go b/woox/rest/types/public_info.go index 5c6e154..601c9ab 100644 --- a/woox/rest/types/public_info.go +++ b/woox/rest/types/public_info.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type SymbolInfo struct { diff --git a/woox/rest/types/public_kline.go b/woox/rest/types/public_kline.go index cc6df7f..3c8ac01 100644 --- a/woox/rest/types/public_kline.go +++ b/woox/rest/types/public_kline.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetKlineParam struct { diff --git a/woox/rest/types/public_market_trades.go b/woox/rest/types/public_market_trades.go index eb14c20..99ac515 100644 --- a/woox/rest/types/public_market_trades.go +++ b/woox/rest/types/public_market_trades.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetMarketTradesParam struct { diff --git a/woox/rest/types/public_orderbook.go b/woox/rest/types/public_orderbook.go index 791e21b..9a6f5ec 100644 --- a/woox/rest/types/public_orderbook.go +++ b/woox/rest/types/public_orderbook.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type GetOrderbookParam struct { diff --git a/woox/rest/types/public_token.go b/woox/rest/types/public_token.go index b2ca2f9..e6109bc 100644 --- a/woox/rest/types/public_token.go +++ b/woox/rest/types/public_token.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type Tokens struct { diff --git a/woox/rest/types/types.go b/woox/rest/types/types.go index a82310f..f281a89 100644 --- a/woox/rest/types/types.go +++ b/woox/rest/types/types.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type HTTPRequest struct { diff --git a/woox/rest/vars.go b/woox/rest/vars.go index 6c2d3a2..17a0434 100644 --- a/woox/rest/vars.go +++ b/woox/rest/vars.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package rest const ( diff --git a/woox/websocket/client.go b/woox/websocket/client.go index f0f203f..0bb8312 100644 --- a/woox/websocket/client.go +++ b/woox/websocket/client.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package websocket import ( @@ -135,7 +152,7 @@ func (w *WooXWebsocketClient) reconnect() { w.setIsConnected(false) - w.logger.Info(fmt.Sprintf("disconnect, then reconnect...")) + w.logger.Info("disconnect, then reconnect...") close(w.heartCancel) diff --git a/woox/websocket/client_test.go b/woox/websocket/client_test.go index 915b478..cac0845 100644 --- a/woox/websocket/client_test.go +++ b/woox/websocket/client_test.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package websocket import ( diff --git a/woox/websocket/events.go b/woox/websocket/events.go index e371a70..24fb54a 100644 --- a/woox/websocket/events.go +++ b/woox/websocket/events.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package websocket import "github.com/chuckpreslar/emission" diff --git a/woox/websocket/subscriptions.go b/woox/websocket/subscriptions.go index ec16671..611fcba 100644 --- a/woox/websocket/subscriptions.go +++ b/woox/websocket/subscriptions.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package websocket import ( diff --git a/woox/websocket/topics.go b/woox/websocket/topics.go index 3a806e3..32c1c74 100644 --- a/woox/websocket/topics.go +++ b/woox/websocket/topics.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package websocket import ( diff --git a/woox/websocket/types/public.go b/woox/websocket/types/public.go index 70c490a..c7a2abe 100644 --- a/woox/websocket/types/public.go +++ b/woox/websocket/types/public.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types type Orderbook struct { diff --git a/woox/websocket/types/types.go b/woox/websocket/types/types.go index e0d10df..20b0fbd 100644 --- a/woox/websocket/types/types.go +++ b/woox/websocket/types/types.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package types import ( diff --git a/woox/websocket/vars.go b/woox/websocket/vars.go index 8037dd4..34961b3 100644 --- a/woox/websocket/vars.go +++ b/woox/websocket/vars.go @@ -1,3 +1,20 @@ +/* + * Copyright (c) 2023, LinstoHu + * All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package websocket var (