akshare 1.16.49__py3-none-any.whl → 1.16.51__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
akshare/__init__.py CHANGED
@@ -3058,9 +3058,11 @@ amac_manager_cancelled_info # 中国证券投资基金业协会-信息公示-诚
3058
3058
  1.16.47 fix: fix stock_hsgt_stock_statistics_em interface
3059
3059
  1.16.48 fix: fix stock_individual_basic_info_xq interface
3060
3060
  1.16.49 fix: fix index_zh_a_hist_min_em interface
3061
+ 1.16.50 fix: fix futures_inventory_99 interface
3062
+ 1.16.51 fix: fix stock_individual_basic_info_xq interface
3061
3063
  """
3062
3064
 
3063
- __version__ = "1.16.49"
3065
+ __version__ = "1.16.51"
3064
3066
  __author__ = "AKFamily"
3065
3067
 
3066
3068
  import sys
@@ -63,11 +63,12 @@ def futures_inventory_99(symbol: str = "豆一") -> pd.DataFrame:
63
63
  url = "https://centerapi.fx168api.com/app/qh/api/stock/trend"
64
64
  headers = {
65
65
  "Content-Type": "application/json;charset=UTF-8",
66
- "_pcc": "UA0+njHjAu6S+x0zm3/mS0dfA/bI6hXykkXo+zcU0fnYA3BDzyOhtyzP6rhHrxGHJHbC5PReeQsE0mUqas"
67
- "osFnO5vMV+esXjRG/PpE7ob4ghzm8A+qNd0MC+mag1ov+aHMrbmfzRn0poqRHG2X7Cm+BfDMtWRU7P//2QvlbDtLg=",
66
+ "_pcc": "hETmls1NpL1IyIXZ9gvqY6OlNkEbubzrds3DFH3FsVji+P68lhdgcwW/nIksenplYqUWWqpFigd2ZZMDE/8gDnFthohx"
67
+ "w9cQHAfT2LLYZbuvxS+Zb23EolKGY8/C5pGMcNaW34IVrjVX6ppreh7ARBHYLGxcrCU2rZZCyY4W3HU=",
68
68
  "user-agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) "
69
69
  "Chrome/58.0.3029.110 Safari/537.3",
70
70
  "referer": "https://www.99qh.com",
71
+ "origin": "https://www.99qh.com",
71
72
  }
72
73
  params = {
73
74
  "productId": product_id,
@@ -90,5 +91,5 @@ def futures_inventory_99(symbol: str = "豆一") -> pd.DataFrame:
90
91
 
91
92
 
92
93
  if __name__ == "__main__":
93
- futures_inventory_99_df = futures_inventory_99(symbol="a")
94
+ futures_inventory_99_df = futures_inventory_99(symbol="ag")
94
95
  print(futures_inventory_99_df)
akshare/stock/stock_xq.py CHANGED
@@ -44,7 +44,7 @@ def stock_individual_spot_xq(
44
44
  :rtype: pandas.DataFrame
45
45
  """
46
46
  session = requests.Session()
47
- xq_a_token = token or "afb2d000c59b0e6fa5539ff13798ca8e64330985"
47
+ xq_a_token = token or "cc9943aa6d41f0ae420f49b428f2f90a472b070a"
48
48
  headers = {
49
49
  "cookie": f"xq_a_token={xq_a_token};",
50
50
  "User-Agent": "Mozilla/5.0 (iPhone; CPU iPhone OS 16_6 like Mac OS X) AppleWebKit/605.1.15 "
@@ -1,18 +1,21 @@
1
1
  # -*- coding:utf-8 -*-
2
2
  # !/usr/bin/env python
3
3
  """
4
- Date: 2023/10/11 15:30
4
+ Date: 2025/3/19 15:30
5
5
  Desc: 新股和风险警示股
6
6
  新浪-行情中心-沪深股市-次新股
7
- http://vip.stock.finance.sina.com.cn/mkt/#new_stock
7
+ https://vip.stock.finance.sina.com.cn/mkt/#new_stock
8
8
  东方财富网-行情中心-沪深个股-风险警示板
9
9
  https://quote.eastmoney.com/center/gridlist.html#st_board
10
10
  """
11
+
11
12
  import math
12
13
 
13
14
  import pandas as pd
14
15
  import requests
15
16
 
17
+ from akshare.utils.func import fetch_paginated_data
18
+
16
19
 
17
20
  def stock_zh_a_st_em() -> pd.DataFrame:
18
21
  """
@@ -21,88 +24,87 @@ def stock_zh_a_st_em() -> pd.DataFrame:
21
24
  :return: 风险警示板
22
25
  :rtype: pandas.DataFrame
23
26
  """
24
- url = 'http://40.push2.eastmoney.com/api/qt/clist/get'
27
+ url = "https://40.push2.eastmoney.com/api/qt/clist/get"
25
28
  params = {
26
- 'pn': '1',
27
- 'pz': '2000',
28
- 'po': '1',
29
- 'np': '1',
30
- 'ut': 'bd1d9ddb04089700cf9c27f6f7426281',
31
- 'fltt': '2',
32
- 'invt': '2',
33
- 'fid': 'f3',
34
- 'fs': 'm:0 f:4,m:1 f:4',
35
- 'fields': 'f2,f3,f4,f5,f6,f7,f8,f9,f10,f12,f13,f14,f15,f16,f17,f18,f20,f21,f23,f24,f25,f22,f11,f62,f128,f136,f115,f152',
36
- '_': '1631107510188',
29
+ "pn": "1",
30
+ "pz": "100",
31
+ "po": "1",
32
+ "np": "1",
33
+ "ut": "bd1d9ddb04089700cf9c27f6f7426281",
34
+ "fltt": "2",
35
+ "invt": "2",
36
+ "fid": "f3",
37
+ "fs": "m:0 f:4,m:1 f:4",
38
+ "fields": "f2,f3,f4,f5,f6,f7,f8,f9,f10,f12,f13,f14,f15,f16,f17,f18,f20,"
39
+ "f21,f23,f24,f25,f22,f11,f62,f128,f136,f115,f152",
40
+ "_": "1631107510188",
37
41
  }
38
- r = requests.get(url, params=params)
39
- data_json = r.json()
40
- temp_df = pd.DataFrame(data_json['data']['diff'])
41
- temp_df.reset_index(inplace=True)
42
- temp_df['index'] = range(1, len(temp_df)+1)
42
+ temp_df = fetch_paginated_data(url, params)
43
43
  temp_df.columns = [
44
- '序号',
45
- '最新价',
46
- '涨跌幅',
47
- '涨跌额',
48
- '成交量',
49
- '成交额',
50
- '振幅',
51
- '换手率',
52
- '市盈率-动态',
53
- '量比',
54
- '_',
55
- '代码',
56
- '_',
57
- '名称',
58
- '最高',
59
- '最低',
60
- '今开',
61
- '昨收',
62
- '_',
63
- '_',
64
- '_',
65
- '市净率',
66
- '_',
67
- '_',
68
- '_',
69
- '_',
70
- '_',
71
- '_',
72
- '_',
73
- '_',
74
- '_',
44
+ "序号",
45
+ "最新价",
46
+ "涨跌幅",
47
+ "涨跌额",
48
+ "成交量",
49
+ "成交额",
50
+ "振幅",
51
+ "换手率",
52
+ "市盈率-动态",
53
+ "量比",
54
+ "_",
55
+ "代码",
56
+ "_",
57
+ "名称",
58
+ "最高",
59
+ "最低",
60
+ "今开",
61
+ "昨收",
62
+ "_",
63
+ "_",
64
+ "_",
65
+ "市净率",
66
+ "_",
67
+ "_",
68
+ "_",
69
+ "_",
70
+ "_",
71
+ "_",
72
+ "_",
73
+ "_",
74
+ "_",
75
75
  ]
76
- temp_df = temp_df[[
77
- '序号',
78
- '代码',
79
- '名称',
80
- '最新价',
81
- '涨跌幅',
82
- '涨跌额',
83
- '成交量',
84
- '成交额',
85
- '振幅',
86
- '最高',
87
- '最低',
88
- '今开',
89
- '昨收',
90
- '量比',
91
- '换手率',
92
- '市盈率-动态',
93
- '市净率',
94
- ]]
95
- temp_df['最新价'] = pd.to_numeric(temp_df['最新价'], errors="coerce")
96
- temp_df['涨跌幅'] = pd.to_numeric(temp_df['涨跌幅'], errors="coerce")
97
- temp_df['涨跌额'] = pd.to_numeric(temp_df['涨跌额'], errors="coerce")
98
- temp_df['成交量'] = pd.to_numeric(temp_df['成交量'], errors="coerce")
99
- temp_df['成交额'] = pd.to_numeric(temp_df['成交额'], errors="coerce")
100
- temp_df['振幅'] = pd.to_numeric(temp_df['振幅'], errors="coerce")
101
- temp_df['最高'] = pd.to_numeric(temp_df['最高'], errors="coerce")
102
- temp_df['最低'] = pd.to_numeric(temp_df['最低'], errors="coerce")
103
- temp_df['今开'] = pd.to_numeric(temp_df['今开'], errors="coerce")
104
- temp_df['量比'] = pd.to_numeric(temp_df['量比'], errors="coerce")
105
- temp_df['换手率'] = pd.to_numeric(temp_df['换手率'], errors="coerce")
76
+ temp_df = temp_df[
77
+ [
78
+ "序号",
79
+ "代码",
80
+ "名称",
81
+ "最新价",
82
+ "涨跌幅",
83
+ "涨跌额",
84
+ "成交量",
85
+ "成交额",
86
+ "振幅",
87
+ "最高",
88
+ "最低",
89
+ "今开",
90
+ "昨收",
91
+ "量比",
92
+ "换手率",
93
+ "市盈率-动态",
94
+ "市净率",
95
+ ]
96
+ ]
97
+ temp_df["最新价"] = pd.to_numeric(temp_df["最新价"], errors="coerce")
98
+ temp_df["涨跌幅"] = pd.to_numeric(temp_df["涨跌幅"], errors="coerce")
99
+ temp_df["涨跌额"] = pd.to_numeric(temp_df["涨跌额"], errors="coerce")
100
+ temp_df["成交量"] = pd.to_numeric(temp_df["成交量"], errors="coerce")
101
+ temp_df["成交额"] = pd.to_numeric(temp_df["成交额"], errors="coerce")
102
+ temp_df["振幅"] = pd.to_numeric(temp_df["振幅"], errors="coerce")
103
+ temp_df["最高"] = pd.to_numeric(temp_df["最高"], errors="coerce")
104
+ temp_df["最低"] = pd.to_numeric(temp_df["最低"], errors="coerce")
105
+ temp_df["今开"] = pd.to_numeric(temp_df["今开"], errors="coerce")
106
+ temp_df["量比"] = pd.to_numeric(temp_df["量比"], errors="coerce")
107
+ temp_df["换手率"] = pd.to_numeric(temp_df["换手率"], errors="coerce")
106
108
  return temp_df
107
109
 
108
110
 
@@ -113,195 +115,193 @@ def stock_zh_a_new_em() -> pd.DataFrame:
113
115
  :return: 新股
114
116
  :rtype: pandas.DataFrame
115
117
  """
116
- url = 'http://40.push2.eastmoney.com/api/qt/clist/get'
118
+ url = "https://40.push2.eastmoney.com/api/qt/clist/get"
117
119
  params = {
118
- 'pn': '1',
119
- 'pz': '2000',
120
- 'po': '1',
121
- 'np': '1',
122
- 'ut': 'bd1d9ddb04089700cf9c27f6f7426281',
123
- 'fltt': '2',
124
- 'invt': '2',
125
- 'fid': 'f26',
126
- 'fs': 'm:0 f:8,m:1 f:8',
127
- 'fields': 'f2,f3,f4,f5,f6,f7,f8,f9,f10,f12,f13,f14,f15,f16,f17,f18,f20,f21,f23,f24,f25,f22,f11,f62,f128,f136,f115,f152',
128
- '_': '1631107510188',
120
+ "pn": "1",
121
+ "pz": "100",
122
+ "po": "1",
123
+ "np": "1",
124
+ "ut": "bd1d9ddb04089700cf9c27f6f7426281",
125
+ "fltt": "2",
126
+ "invt": "2",
127
+ "fid": "f26",
128
+ "fs": "m:0 f:8,m:1 f:8",
129
+ "fields": "f2,f3,f4,f5,f6,f7,f8,f9,f10,f12,f13,f14,f15,f16,f17,f18,"
130
+ "f20,f21,f23,f24,f25,f22,f11,f62,f128,f136,f115,f152",
131
+ "_": "1631107510188",
129
132
  }
130
- r = requests.get(url, params=params)
131
- data_json = r.json()
132
- temp_df = pd.DataFrame(data_json['data']['diff'])
133
- temp_df.reset_index(inplace=True)
134
- temp_df['index'] = range(1, len(temp_df)+1)
133
+ temp_df = fetch_paginated_data(url, params)
135
134
  temp_df.columns = [
136
- '序号',
137
- '最新价',
138
- '涨跌幅',
139
- '涨跌额',
140
- '成交量',
141
- '成交额',
142
- '振幅',
143
- '换手率',
144
- '市盈率-动态',
145
- '量比',
146
- '_',
147
- '代码',
148
- '_',
149
- '名称',
150
- '最高',
151
- '最低',
152
- '今开',
153
- '昨收',
154
- '_',
155
- '_',
156
- '_',
157
- '市净率',
158
- '_',
159
- '_',
160
- '_',
161
- '_',
162
- '_',
163
- '_',
164
- '_',
165
- '_',
166
- '_',
135
+ "序号",
136
+ "最新价",
137
+ "涨跌幅",
138
+ "涨跌额",
139
+ "成交量",
140
+ "成交额",
141
+ "振幅",
142
+ "换手率",
143
+ "市盈率-动态",
144
+ "量比",
145
+ "_",
146
+ "代码",
147
+ "_",
148
+ "名称",
149
+ "最高",
150
+ "最低",
151
+ "今开",
152
+ "昨收",
153
+ "_",
154
+ "_",
155
+ "_",
156
+ "市净率",
157
+ "_",
158
+ "_",
159
+ "_",
160
+ "_",
161
+ "_",
162
+ "_",
163
+ "_",
164
+ "_",
165
+ "_",
167
166
  ]
168
- temp_df = temp_df[[
169
- '序号',
170
- '代码',
171
- '名称',
172
- '最新价',
173
- '涨跌幅',
174
- '涨跌额',
175
- '成交量',
176
- '成交额',
177
- '振幅',
178
- '最高',
179
- '最低',
180
- '今开',
181
- '昨收',
182
- '量比',
183
- '换手率',
184
- '市盈率-动态',
185
- '市净率',
186
- ]]
187
- temp_df['最新价'] = pd.to_numeric(temp_df['最新价'], errors="coerce")
188
- temp_df['涨跌幅'] = pd.to_numeric(temp_df['涨跌幅'], errors="coerce")
189
- temp_df['涨跌额'] = pd.to_numeric(temp_df['涨跌额'], errors="coerce")
190
- temp_df['成交量'] = pd.to_numeric(temp_df['成交量'], errors="coerce")
191
- temp_df['成交额'] = pd.to_numeric(temp_df['成交额'], errors="coerce")
192
- temp_df['振幅'] = pd.to_numeric(temp_df['振幅'], errors="coerce")
193
- temp_df['最高'] = pd.to_numeric(temp_df['最高'], errors="coerce")
194
- temp_df['最低'] = pd.to_numeric(temp_df['最低'], errors="coerce")
195
- temp_df['今开'] = pd.to_numeric(temp_df['今开'], errors="coerce")
196
- temp_df['量比'] = pd.to_numeric(temp_df['量比'], errors="coerce")
197
- temp_df['换手率'] = pd.to_numeric(temp_df['换手率'], errors="coerce")
167
+ temp_df = temp_df[
168
+ [
169
+ "序号",
170
+ "代码",
171
+ "名称",
172
+ "最新价",
173
+ "涨跌幅",
174
+ "涨跌额",
175
+ "成交量",
176
+ "成交额",
177
+ "振幅",
178
+ "最高",
179
+ "最低",
180
+ "今开",
181
+ "昨收",
182
+ "量比",
183
+ "换手率",
184
+ "市盈率-动态",
185
+ "市净率",
186
+ ]
187
+ ]
188
+ temp_df["最新价"] = pd.to_numeric(temp_df["最新价"], errors="coerce")
189
+ temp_df["涨跌幅"] = pd.to_numeric(temp_df["涨跌幅"], errors="coerce")
190
+ temp_df["涨跌额"] = pd.to_numeric(temp_df["涨跌额"], errors="coerce")
191
+ temp_df["成交量"] = pd.to_numeric(temp_df["成交量"], errors="coerce")
192
+ temp_df["成交额"] = pd.to_numeric(temp_df["成交额"], errors="coerce")
193
+ temp_df["振幅"] = pd.to_numeric(temp_df["振幅"], errors="coerce")
194
+ temp_df["最高"] = pd.to_numeric(temp_df["最高"], errors="coerce")
195
+ temp_df["最低"] = pd.to_numeric(temp_df["最低"], errors="coerce")
196
+ temp_df["今开"] = pd.to_numeric(temp_df["今开"], errors="coerce")
197
+ temp_df["量比"] = pd.to_numeric(temp_df["量比"], errors="coerce")
198
+ temp_df["换手率"] = pd.to_numeric(temp_df["换手率"], errors="coerce")
198
199
  return temp_df
199
200
 
200
201
 
201
202
  def stock_zh_a_stop_em() -> pd.DataFrame:
202
203
  """
203
204
  东方财富网-行情中心-沪深个股-两网及退市
204
- http://quote.eastmoney.com/center/gridlist.html#staq_net_board
205
+ https://quote.eastmoney.com/center/gridlist.html#staq_net_board
205
206
  :return: 两网及退市
206
207
  :rtype: pandas.DataFrame
207
208
  """
208
- url = 'http://40.push2.eastmoney.com/api/qt/clist/get'
209
+ url = "https://40.push2.eastmoney.com/api/qt/clist/get"
209
210
  params = {
210
- 'pn': '1',
211
- 'pz': '2000',
212
- 'po': '1',
213
- 'np': '1',
214
- 'ut': 'bd1d9ddb04089700cf9c27f6f7426281',
215
- 'fltt': '2',
216
- 'invt': '2',
217
- 'fid': 'f3',
218
- 'fs': 'm:0 s:3',
219
- 'fields': 'f2,f3,f4,f5,f6,f7,f8,f9,f10,f12,f13,f14,f15,f16,f17,f18,f20,f21,f23,f24,f25,f22,f11,f62,f128,f136,f115,f152',
220
- '_': '1631107510188',
211
+ "pn": "1",
212
+ "pz": "100",
213
+ "po": "1",
214
+ "np": "1",
215
+ "ut": "bd1d9ddb04089700cf9c27f6f7426281",
216
+ "fltt": "2",
217
+ "invt": "2",
218
+ "fid": "f3",
219
+ "fs": "m:0 s:3",
220
+ "fields": "f2,f3,f4,f5,f6,f7,f8,f9,f10,f12,f13,f14,f15,f16,f17,"
221
+ "f18,f20,f21,f23,f24,f25,f22,f11,f62,f128,f136,f115,f152",
222
+ "_": "1631107510188",
221
223
  }
222
- r = requests.get(url, params=params)
223
- data_json = r.json()
224
- temp_df = pd.DataFrame(data_json['data']['diff'])
225
- temp_df.reset_index(inplace=True)
226
- temp_df['index'] = range(1, len(temp_df)+1)
224
+ temp_df = fetch_paginated_data(url, params)
227
225
  temp_df.columns = [
228
- '序号',
229
- '最新价',
230
- '涨跌幅',
231
- '涨跌额',
232
- '成交量',
233
- '成交额',
234
- '振幅',
235
- '换手率',
236
- '市盈率-动态',
237
- '量比',
238
- '_',
239
- '代码',
240
- '_',
241
- '名称',
242
- '最高',
243
- '最低',
244
- '今开',
245
- '昨收',
246
- '_',
247
- '_',
248
- '_',
249
- '市净率',
250
- '_',
251
- '_',
252
- '_',
253
- '_',
254
- '_',
255
- '_',
256
- '_',
257
- '_',
258
- '_',
226
+ "序号",
227
+ "最新价",
228
+ "涨跌幅",
229
+ "涨跌额",
230
+ "成交量",
231
+ "成交额",
232
+ "振幅",
233
+ "换手率",
234
+ "市盈率-动态",
235
+ "量比",
236
+ "_",
237
+ "代码",
238
+ "_",
239
+ "名称",
240
+ "最高",
241
+ "最低",
242
+ "今开",
243
+ "昨收",
244
+ "_",
245
+ "_",
246
+ "_",
247
+ "市净率",
248
+ "_",
249
+ "_",
250
+ "_",
251
+ "_",
252
+ "_",
253
+ "_",
254
+ "_",
255
+ "_",
256
+ "_",
257
+ ]
258
+ temp_df = temp_df[
259
+ [
260
+ "序号",
261
+ "代码",
262
+ "名称",
263
+ "最新价",
264
+ "涨跌幅",
265
+ "涨跌额",
266
+ "成交量",
267
+ "成交额",
268
+ "振幅",
269
+ "最高",
270
+ "最低",
271
+ "今开",
272
+ "昨收",
273
+ "量比",
274
+ "换手率",
275
+ "市盈率-动态",
276
+ "市净率",
277
+ ]
259
278
  ]
260
- temp_df = temp_df[[
261
- '序号',
262
- '代码',
263
- '名称',
264
- '最新价',
265
- '涨跌幅',
266
- '涨跌额',
267
- '成交量',
268
- '成交额',
269
- '振幅',
270
- '最高',
271
- '最低',
272
- '今开',
273
- '昨收',
274
- '量比',
275
- '换手率',
276
- '市盈率-动态',
277
- '市净率',
278
- ]]
279
- temp_df['最新价'] = pd.to_numeric(temp_df['最新价'], errors="coerce")
280
- temp_df['涨跌幅'] = pd.to_numeric(temp_df['涨跌幅'], errors="coerce")
281
- temp_df['涨跌额'] = pd.to_numeric(temp_df['涨跌额'], errors="coerce")
282
- temp_df['成交量'] = pd.to_numeric(temp_df['成交量'], errors="coerce")
283
- temp_df['成交额'] = pd.to_numeric(temp_df['成交额'], errors="coerce")
284
- temp_df['振幅'] = pd.to_numeric(temp_df['振幅'], errors="coerce")
285
- temp_df['最高'] = pd.to_numeric(temp_df['最高'], errors="coerce")
286
- temp_df['最低'] = pd.to_numeric(temp_df['最低'], errors="coerce")
287
- temp_df['今开'] = pd.to_numeric(temp_df['今开'], errors="coerce")
288
- temp_df['量比'] = pd.to_numeric(temp_df['量比'], errors="coerce")
289
- temp_df['换手率'] = pd.to_numeric(temp_df['换手率'], errors="coerce")
279
+ temp_df["最新价"] = pd.to_numeric(temp_df["最新价"], errors="coerce")
280
+ temp_df["涨跌幅"] = pd.to_numeric(temp_df["涨跌幅"], errors="coerce")
281
+ temp_df["涨跌额"] = pd.to_numeric(temp_df["涨跌额"], errors="coerce")
282
+ temp_df["成交量"] = pd.to_numeric(temp_df["成交量"], errors="coerce")
283
+ temp_df["成交额"] = pd.to_numeric(temp_df["成交额"], errors="coerce")
284
+ temp_df["振幅"] = pd.to_numeric(temp_df["振幅"], errors="coerce")
285
+ temp_df["最高"] = pd.to_numeric(temp_df["最高"], errors="coerce")
286
+ temp_df["最低"] = pd.to_numeric(temp_df["最低"], errors="coerce")
287
+ temp_df["今开"] = pd.to_numeric(temp_df["今开"], errors="coerce")
288
+ temp_df["量比"] = pd.to_numeric(temp_df["量比"], errors="coerce")
289
+ temp_df["换手率"] = pd.to_numeric(temp_df["换手率"], errors="coerce")
290
290
  return temp_df
291
291
 
292
292
 
293
293
  def stock_zh_a_new() -> pd.DataFrame:
294
294
  """
295
295
  新浪财经-行情中心-沪深股市-次新股
296
- http://vip.stock.finance.sina.com.cn/mkt/#new_stock
296
+ https://vip.stock.finance.sina.com.cn/mkt/#new_stock
297
297
  :return: 次新股行情数据
298
298
  :rtype: pandas.DataFrame
299
299
  """
300
- url = "http://vip.stock.finance.sina.com.cn/quotes_service/api/json_v2.php/Market_Center.getHQNodeStockCount"
300
+ url = "https://vip.stock.finance.sina.com.cn/quotes_service/api/json_v2.php/Market_Center.getHQNodeStockCount"
301
301
  params = {"node": "new_stock"}
302
302
  r = requests.get(url, params=params)
303
303
  total_page = math.ceil(int(r.json()) / 80)
304
- url = "http://vip.stock.finance.sina.com.cn/quotes_service/api/json_v2.php/Market_Center.getHQNodeData"
304
+ url = "https://vip.stock.finance.sina.com.cn/quotes_service/api/json_v2.php/Market_Center.getHQNodeData"
305
305
  big_df = pd.DataFrame()
306
306
  for page in range(1, total_page + 1):
307
307
  params = {
@@ -332,9 +332,9 @@ def stock_zh_a_new() -> pd.DataFrame:
332
332
  "turnoverratio",
333
333
  ]
334
334
  ]
335
- big_df['open'] = pd.to_numeric(big_df['open'])
336
- big_df['high'] = pd.to_numeric(big_df['high'])
337
- big_df['low'] = pd.to_numeric(big_df['low'])
335
+ big_df["open"] = pd.to_numeric(big_df["open"])
336
+ big_df["high"] = pd.to_numeric(big_df["high"])
337
+ big_df["low"] = pd.to_numeric(big_df["low"])
338
338
  return big_df
339
339
 
340
340
 
@@ -1,10 +1,11 @@
1
1
  #!/usr/bin/env python
2
2
  # -*- coding:utf-8 -*-
3
3
  """
4
- Date: 2023/4/5 22:05
4
+ Date: 2025/3/19 15:30
5
5
  Desc: 乐咕乐股-股债利差
6
6
  https://legulegu.com/stockdata/equity-bond-spread
7
7
  """
8
+
8
9
  import pandas as pd
9
10
  import requests
10
11
 
@@ -24,11 +25,11 @@ def stock_ebs_lg() -> pd.DataFrame:
24
25
  r = requests.get(
25
26
  url,
26
27
  params=params,
27
- **get_cookie_csrf(url="https://legulegu.com/stockdata/equity-bond-spread")
28
+ **get_cookie_csrf(url="https://legulegu.com/stockdata/equity-bond-spread"),
28
29
  )
29
30
  data_json = r.json()
30
31
  temp_df = pd.DataFrame(data_json["data"])
31
- temp_df["date"] = pd.to_datetime(temp_df["date"]).dt.date
32
+ temp_df["date"] = pd.to_datetime(temp_df["date"], errors="coerce").dt.date
32
33
  temp_df.rename(
33
34
  columns={
34
35
  "date": "日期",
@@ -46,7 +47,7 @@ def stock_ebs_lg() -> pd.DataFrame:
46
47
  "股债利差均线",
47
48
  ]
48
49
  ]
49
- temp_df['日期'] = pd.to_datetime(temp_df['日期']).dt.date
50
+ temp_df["日期"] = pd.to_datetime(temp_df["日期"], errors="coerce").dt.date
50
51
  temp_df["沪深300指数"] = pd.to_numeric(temp_df["沪深300指数"], errors="coerce")
51
52
  temp_df["股债利差"] = pd.to_numeric(temp_df["股债利差"], errors="coerce")
52
53
  temp_df["股债利差均线"] = pd.to_numeric(temp_df["股债利差均线"], errors="coerce")
@@ -1,13 +1,14 @@
1
1
  #!/usr/bin/env python
2
2
  # -*- coding:utf-8 -*-
3
3
  """
4
- Date: 2023/4/7 15:22
4
+ Date: 2025/3/18 15:00
5
5
  Desc: 东方财富网-数据中心-年报季报-分红送配
6
6
  https://data.eastmoney.com/yjfp/
7
7
  """
8
8
 
9
9
  import pandas as pd
10
10
  import requests
11
+
11
12
  from akshare.utils.tqdm import get_tqdm
12
13
 
13
14
 
@@ -1,7 +1,7 @@
1
1
  # !/usr/bin/env python
2
2
  # -*- coding:utf-8 -*-
3
3
  """
4
- Date: 2025/3/16 11:00
4
+ Date: 2025/3/19 15:00
5
5
  Desc: 雪球-个股-公司概况-公司简介
6
6
  https://xueqiu.com/snowman/S/SH601127/detail#/GSJJ
7
7
  """
@@ -27,7 +27,7 @@ def stock_individual_basic_info_xq(
27
27
  :return: 公司简介
28
28
  :rtype: pandas.DataFrame
29
29
  """
30
- xq_a_token = token or "afb2d000c59b0e6fa5539ff13798ca8e64330985"
30
+ xq_a_token = token or "cc9943aa6d41f0ae420f49b428f2f90a472b070a"
31
31
  url = "https://stock.xueqiu.com/v5/stock/f10/cn/company.json"
32
32
  params = {
33
33
  "symbol": symbol,
@@ -56,7 +56,7 @@ def stock_individual_basic_info_us_xq(
56
56
  :return: 公司简介
57
57
  :rtype: pandas.DataFrame
58
58
  """
59
- xq_a_token = token or "afb2d000c59b0e6fa5539ff13798ca8e64330985"
59
+ xq_a_token = token or "cc9943aa6d41f0ae420f49b428f2f90a472b070a"
60
60
  url = "https://stock.xueqiu.com/v5/stock/f10/us/company.json"
61
61
  params = {
62
62
  "symbol": symbol,
@@ -85,7 +85,7 @@ def stock_individual_basic_info_hk_xq(
85
85
  :return: 公司简介
86
86
  :rtype: pandas.DataFrame
87
87
  """
88
- xq_a_token = token or "afb2d000c59b0e6fa5539ff13798ca8e64330985"
88
+ xq_a_token = token or "cc9943aa6d41f0ae420f49b428f2f90a472b070a"
89
89
  url = "https://stock.xueqiu.com/v5/stock/f10/hk/company.json"
90
90
  params = {
91
91
  "symbol": symbol,
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.2
2
2
  Name: akshare
3
- Version: 1.16.49
3
+ Version: 1.16.51
4
4
  Summary: AKShare is an elegant and simple financial data interface library for Python, built for human beings!
5
5
  Home-page: https://github.com/akfamily/akshare
6
6
  Author: AKFamily
@@ -1,4 +1,4 @@
1
- akshare/__init__.py,sha256=6nJ9nfWi6pwaK7LYj36H7tSitK_wpQyP5FI8WtiXL0Y,191390
1
+ akshare/__init__.py,sha256=TqJTpZCmzhcqCCvs2w3WiJq0itrK3kEbmkDuTgW1mig,191496
2
2
  akshare/datasets.py,sha256=rKuRNZrqi6IMsZ9nyvO3Rx02js0tH3zMLjz8HQNAoPQ,963
3
3
  akshare/exceptions.py,sha256=WEJjIhSmJ_xXNW6grwV4nufE_cfmmyuhmueVGiN1VAg,878
4
4
  akshare/request.py,sha256=HtFFf9MhfEibR-ETWe-1Tts6ELU4VKSqA-ghaXjegQM,4252
@@ -119,7 +119,7 @@ akshare/futures/futures_hf_em.py,sha256=eCksGjWRRWXUT61ulzc2UifjTQzC8BNOKqKq7JB2
119
119
  akshare/futures/futures_hist_em.py,sha256=Q8I20qRjp2ujiJMCCNBvTHXmrIth22p2k6KpvbkC3dk,6472
120
120
  akshare/futures/futures_hq_sina.py,sha256=HZBAve1yxp1fnwgEy_2CqVoniTXRkt8KI3REt0N0TiY,9575
121
121
  akshare/futures/futures_index_ccidx.py,sha256=_kgWioCOpFNn8WUcL5qKHGb3rUHzrbrx2AszprKpBh4,4460
122
- akshare/futures/futures_inventory_99.py,sha256=2KPoa0UQ3qQhR9hdIoEapc1TGZek5ojSY8qr6BUtopM,3354
122
+ akshare/futures/futures_inventory_99.py,sha256=xjrGBtoPg3JiqpAWOpQ54yEMUm9jIgbp2HSY62E2qWM,3397
123
123
  akshare/futures/futures_inventory_em.py,sha256=xbWcILKJpwdC2629U5CZ8TF-xhxlYYhf6qgFyreton4,2680
124
124
  akshare/futures/futures_news_shmet.py,sha256=1epZ3MwDc-T2n1ie4SSDfvUaBiMpSL0Q_xb2VoZ_llU,2465
125
125
  akshare/futures/futures_roll_yield.py,sha256=RiwN0yYwzYy8zGhmTopBwJ37aUQ7Llwh3eQRzn0apaE,6135
@@ -280,9 +280,9 @@ akshare/stock/stock_us_js.py,sha256=wwZpRvVHqjxwd0cb2O5vtRW8Zw90Kdl5O4XNwoevN64,
280
280
  akshare/stock/stock_us_pink.py,sha256=BX7-tG4Zs0k2vSYGxHH0Yob-moD6AAu2a-ytZpxgIRQ,3065
281
281
  akshare/stock/stock_us_sina.py,sha256=D4fhJgpmvnlVoeSV2wQQ7H6lig8h6vaJp71o88dZhDg,8200
282
282
  akshare/stock/stock_weibo_nlp.py,sha256=eM7ofsNSrKiYeS0g38Qj9CxT6dkJZrn_pmziIiTqp4U,3286
283
- akshare/stock/stock_xq.py,sha256=vkOblh7FYHyUysux0kt7XKUCdJfcjAL3k-5Aftgx5rI,4641
283
+ akshare/stock/stock_xq.py,sha256=mPBVg2zA4XkTVAUXeZx8c3nzchm4D1AaMBbC-g87yLQ,4641
284
284
  akshare/stock/stock_zh_a_sina.py,sha256=ZobGnFMIR67ENk05ocqIkeiItLlgK67dW8ZjLdDss3s,18862
285
- akshare/stock/stock_zh_a_special.py,sha256=RRXkeZtRWm_maIPWgxvhBdX6eNybECjhSuEesZHRFJI,10294
285
+ akshare/stock/stock_zh_a_special.py,sha256=VInvKbA6u_hJjjUKj7I5pG9rqt3kSZzJrZNfVs2Fqas,10169
286
286
  akshare/stock/stock_zh_a_tick_tx.py,sha256=TJUAWLKAeoLEaVVJQlj0t-1smZGoAO0X0rPsUPVhZZ4,2131
287
287
  akshare/stock/stock_zh_ah_tx.py,sha256=1DfvP1xF9G4jDnqlacZiYIMWZBujxW9Kycre3yr6MhM,9212
288
288
  akshare/stock/stock_zh_b_sina.py,sha256=-sd0wG4zETsgrJSXivww4YieXfnVMNSfh3phsX_XBBc,16058
@@ -309,9 +309,9 @@ akshare/stock_feature/stock_congestion_lg.py,sha256=iTEcmL0HoSqWGfxv_gSM-qA4O23a
309
309
  akshare/stock_feature/stock_cyq_em.py,sha256=bLy01IqlPDbaqcLdAf3ClVQQHF0YB_NxQ-p-Y9Oc0Z8,10961
310
310
  akshare/stock_feature/stock_disclosure_cninfo.py,sha256=1Eje6abqk6HNOlpCueGnaR_r1-aqTv2f51h4QAHCQzo,10661
311
311
  akshare/stock_feature/stock_dxsyl_em.py,sha256=9d5tfHCB9Ls1FQdyOCElZt8YF5ltKwPa4AvnXL8u48o,18789
312
- akshare/stock_feature/stock_ebs_lg.py,sha256=rnFbOHnZPZUJ3K7-QdTZXqbIFazL1wSkTvn4Mpwn7bI,1750
312
+ akshare/stock_feature/stock_ebs_lg.py,sha256=ZjAIBc-HWOwpGkjGeDYT05o3lkCs6Vk6jdoMOHDpT88,1787
313
313
  akshare/stock_feature/stock_esg_sina.py,sha256=NKHbyYtuSgYubko1jDWgW0qQFTTcEVEtKA0kasHsahc,11544
314
- akshare/stock_feature/stock_fhps_em.py,sha256=85gfdMP3OtA3wsEGlB2RkdHiOEZjFff1ls5x1oWSQPQ,9469
314
+ akshare/stock_feature/stock_fhps_em.py,sha256=Ex355qj1j_EfuM7ImObuFJoUUqpXO73a-zXaDJMKVuU,9471
315
315
  akshare/stock_feature/stock_fhps_ths.py,sha256=NosH1xyT1Pif4T9tchdtJTBEpe6g1Wq2kjvxJDsZD_Y,1805
316
316
  akshare/stock_feature/stock_fund_flow.py,sha256=cqBqsFrzwmuLP3k3wYQzvW085QUUfHZ4nBW8Zx7egkQ,18669
317
317
  akshare/stock_feature/stock_gddh_em.py,sha256=N4sH_qF7LZvMs46t7eGtbnahNrEBQPDk6tRSP_1ModM,3563
@@ -361,7 +361,7 @@ akshare/stock_feature/stock_zh_vote_baidu.py,sha256=SsSNnCq7PDFMzWFcPFcC_MSc9rua
361
361
  akshare/stock_feature/stock_ztb_em.py,sha256=hMi0NSlBs-qEid3oXKOAempZSItNApPDQKvcsdtF8j8,18141
362
362
  akshare/stock_feature/ths.js,sha256=AWPkHf3L2Il1UUL0F5qDqNn1dfU0OlZBNUbMf8AmI3Y,39664
363
363
  akshare/stock_fundamental/__init__.py,sha256=jiXoO9OXiMxB0wHaPQkuxNckYuoFKtzuhZL1ytnE2nQ,82
364
- akshare/stock_fundamental/stock_basic_info_xq.py,sha256=STouJ7UJzmTVmEg13Cyh9xyelpGz-Kmk8udjYhZ6RZo,3602
364
+ akshare/stock_fundamental/stock_basic_info_xq.py,sha256=PJveGTe3NG5F5owYdLFbpC6e0HhNil00G5OhDYlz06A,3602
365
365
  akshare/stock_fundamental/stock_finance_hk_em.py,sha256=cCiaWX6ZyKe4W2H9qe-ttpMeVMWp6tHdvnjhRuYQhl8,7017
366
366
  akshare/stock_fundamental/stock_finance_sina.py,sha256=432EjGHWFtG0L32PNSC_HWpVLDntabNt9koyUtNG77E,30718
367
367
  akshare/stock_fundamental/stock_finance_ths.py,sha256=nS9bt_hzklzh7pBTCH1PjOa69OUcNZ41Z_zSHiz9Y1U,11527
@@ -391,8 +391,8 @@ akshare/utils/token_process.py,sha256=K4rGXjh_tgugbRcyOK2h2x0jP3PT65IIK7nxhUKhOe
391
391
  akshare/utils/tqdm.py,sha256=MuPNwcswkOGjwWQOMWXi9ZvQ_RmW4obCWRj2i7HM7FE,847
392
392
  tests/__init__.py,sha256=gNzhlO0UPjFq6Ieb38kaVIODXv4cTDByrdohAZnDYt4,82
393
393
  tests/test_func.py,sha256=j1MGYbZI2if2j_LY1S4FLsf4qfq4NwVqD5wmRlv5Log,832
394
- akshare-1.16.49.dist-info/LICENSE,sha256=mmSZCPgfHiVw34LXuFArd-SUgQtBJ_QsIlh-kWlDHfs,1073
395
- akshare-1.16.49.dist-info/METADATA,sha256=JGdzRUVgyDGXGuBnA7Hr7_aPNOU2wCVimRppAqcffI8,13685
396
- akshare-1.16.49.dist-info/WHEEL,sha256=52BFRY2Up02UkjOa29eZOS2VxUrpPORXg1pkohGGUS8,91
397
- akshare-1.16.49.dist-info/top_level.txt,sha256=jsf9ZzZPmHaISTVumQPsAw7vv7Yv-PdEVW70SMEelQQ,14
398
- akshare-1.16.49.dist-info/RECORD,,
394
+ akshare-1.16.51.dist-info/LICENSE,sha256=mmSZCPgfHiVw34LXuFArd-SUgQtBJ_QsIlh-kWlDHfs,1073
395
+ akshare-1.16.51.dist-info/METADATA,sha256=W5hocZgQqKqqqNs4d-s-2S4bJWSdVBnMwOX_TEgA9I4,13685
396
+ akshare-1.16.51.dist-info/WHEEL,sha256=beeZ86-EfXScwlR_HKu4SllMC9wUEj_8Z_4FJ3egI2w,91
397
+ akshare-1.16.51.dist-info/top_level.txt,sha256=jsf9ZzZPmHaISTVumQPsAw7vv7Yv-PdEVW70SMEelQQ,14
398
+ akshare-1.16.51.dist-info/RECORD,,
@@ -1,5 +1,5 @@
1
1
  Wheel-Version: 1.0
2
- Generator: setuptools (76.0.0)
2
+ Generator: setuptools (76.1.0)
3
3
  Root-Is-Purelib: true
4
4
  Tag: py3-none-any
5
5