diff --git a/docs/qa/quote.md b/docs/qa/quote.md index 155fd9be..37164a11 100644 --- a/docs/qa/quote.md +++ b/docs/qa/quote.md @@ -114,3 +114,15 @@ message ReconnectRequest { ``` - 开启夜盘行情后,拉取和推送接口都将可以在夜盘交易时段,获取到夜盘盘情。 + +## Q7:OpenApi SDK 中开启夜盘行情 + +- 從環境變數建立 `Config` 對象 + +設定環境變數 `LONGPORT_ENABLE_OVERNIGHT` 為 `true` + +- 從建構函式建立 `Config` 對象 + +```python +config = Config(app_key="your_app_key", app_secret="your_app_secret", access_token="your_access_token", enable_overnight=True) +``` diff --git a/i18n/en/docusaurus-plugin-content-docs/current/qa/quote.md b/i18n/en/docusaurus-plugin-content-docs/current/qa/quote.md index 5ca8ffcd..0137f10f 100644 --- a/i18n/en/docusaurus-plugin-content-docs/current/qa/quote.md +++ b/i18n/en/docusaurus-plugin-content-docs/current/qa/quote.md @@ -95,7 +95,7 @@ A: - CN Market: 09:00:00 CST - SG Market: 08:20:00 CST -## Q6: 如何获取夜盘行情 +## Q6: How to enable Overnight quote A: @@ -114,3 +114,15 @@ message ReconnectRequest { ``` - After turning on the night trading quotations, both the pull and push interfaces will be able to obtain the night trading quotations during the night trading period. + +## Q7:Enable Overnight quote in OpenApi SDK + +- Create `Config` from environment variables + +Set environment variable `LONGPORT_ENABLE_OVERNIGHT` to `true` + +- Create `Config` object from constructor + +```python +config = Config(app_key="your_app_key", app_secret="your_app_secret", access_token="your_access_token", enable_overnight=True) +``` diff --git a/i18n/zh-HK/docusaurus-plugin-content-docs/current/qa/quote.md b/i18n/zh-HK/docusaurus-plugin-content-docs/current/qa/quote.md index c6761613..eca79bc1 100644 --- a/i18n/zh-HK/docusaurus-plugin-content-docs/current/qa/quote.md +++ b/i18n/zh-HK/docusaurus-plugin-content-docs/current/qa/quote.md @@ -114,3 +114,15 @@ message ReconnectRequest { ``` - 開啟夜盤行情後,拉取和推送接口都將可以在夜盤交易時段,取得到夜盤盤情。 + +## Q7:如何開啟夜盤行情 + +- Create `Config` from environment variables + +Set environment variable `LONGPORT_ENABLE_OVERNIGHT` to `true` + +- Create `Config` object from constructor + +```python +config = Config(app_key="your_app_key", app_secret="your_app_secret", access_token="your_access_token", enable_overnight=True) +```