2026-08-25 16:40:18 +08:00
|
|
|
package sdk
|
|
|
|
|
|
|
|
|
|
import "context"
|
|
|
|
|
|
|
|
|
|
func (c *Client) ExtData(ctx context.Context, extdataname, stockcode string, deviation int) (any, error) {
|
2026-08-25 18:59:18 +08:00
|
|
|
return c.postField(ctx, "/api/ext/ext_data", map[string]any{
|
|
|
|
|
"extdataname": extdataname, "stockcode": stockcode, "deviation": deviation,
|
|
|
|
|
}, "value")
|
2026-08-25 16:40:18 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
func (c *Client) ExtDataRank(ctx context.Context, extdataname, stockcode string, deviation int) (any, error) {
|
2026-08-25 18:59:18 +08:00
|
|
|
return c.postField(ctx, "/api/ext/ext_data_rank", map[string]any{
|
|
|
|
|
"extdataname": extdataname, "stockcode": stockcode, "deviation": deviation,
|
|
|
|
|
}, "rank")
|
2026-08-25 16:40:18 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
func (c *Client) GetFactorValue(ctx context.Context, factorname, stockcode string, deviation int) (any, error) {
|
2026-08-25 18:59:18 +08:00
|
|
|
return c.postField(ctx, "/api/ext/get_factor_value", map[string]any{
|
|
|
|
|
"factorname": factorname, "stockcode": stockcode, "deviation": deviation,
|
|
|
|
|
}, "value")
|
2026-08-25 16:40:18 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
func (c *Client) GetFactorRank(ctx context.Context, factorname, stockcode string, deviation int) (any, error) {
|
2026-08-25 18:59:18 +08:00
|
|
|
return c.postField(ctx, "/api/ext/get_factor_rank", map[string]any{
|
|
|
|
|
"factorname": factorname, "stockcode": stockcode, "deviation": deviation,
|
|
|
|
|
}, "rank")
|
2026-08-25 16:40:18 +08:00
|
|
|
}
|