koishi-plugin-stock 2.1.9 → 2.2.0

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.
@@ -145,18 +145,24 @@ class StockCommands {
145
145
  }
146
146
  // 映射策略名称到API端点
147
147
  const strategyMap = {
148
- 'N型': 'dx',
149
- '填坑': 'tk',
150
- '少妇': 'sf',
151
- '突破': 'tp',
152
- '补票': 'bp',
153
- '少妇pro': 'sfpro',
154
- '1': 'dx',
155
- '2': 'tk',
156
- '3': 'sf',
157
- '4': 'tp',
158
- '5': 'bp',
159
- '6': 'sfpro'
148
+ 'N型': 'n_shape',
149
+ 'n_shape': 'n_shape',
150
+ '1': 'n_shape',
151
+ '填坑': 'fill_pit',
152
+ 'fill_pit': 'fill_pit',
153
+ '2': 'fill_pit',
154
+ '少妇': 'young_woman',
155
+ 'young_woman': 'young_woman',
156
+ '3': 'young_woman',
157
+ '突破': 'breakthrough',
158
+ 'breakthrough': 'breakthrough',
159
+ '4': 'breakthrough',
160
+ '补票': 'ticket',
161
+ 'ticket': 'ticket',
162
+ '5': 'ticket',
163
+ '少妇pro': 'young_woman_pro',
164
+ 'young_woman_pro': 'young_woman_pro',
165
+ '6': 'young_woman_pro'
160
166
  };
161
167
  const apiEndpoint = strategyMap[strategy];
162
168
  if (!apiEndpoint) {
@@ -164,7 +170,7 @@ class StockCommands {
164
170
  }
165
171
  try {
166
172
  // 使用带重试机制的HTTP请求
167
- const responseText = await httpRequestWithRetry(ctx, `https://stock.svip886.com/api/dyq_${apiEndpoint}`, {
173
+ const responseText = await httpRequestWithRetry(ctx, `https://stock.svip886.com/api/dyq_select/${apiEndpoint}`, {
168
174
  responseType: 'text'
169
175
  });
170
176
  return `🎯 选股结果 (${strategy}): \n\n${responseText}`;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "koishi-plugin-stock",
3
- "version": "2.1.9",
3
+ "version": "2.2.0",
4
4
  "description": "A Koishi plugin that fetches stock data and provides market analysis, including active market cap, stock alerts, limit-up board, stock selection features, and heart method card drawing with configurable blacklists for each command.",
5
5
  "main": "lib/index.js",
6
6
  "typings": "lib/index.d.ts",