Skip to content
Stock Screener

Update Screener Strategy

Overwrites a saved Client strategy with the name and conditions in the request. Use it to save edited conditions or rename a strategy. The request body is the same as Search Stocks by Screener Conditions, must include id and name, and must contain the full conditions rather than only the changes. When you only rename a strategy, still fill market, industry, and filters from the original groups. After success, refresh My Strategies. On failure, the server keeps the original strategy; ask the Client to try again.

POSThttps://api.lbkrs.com/v1/calc/filter/user/strategy/update

Request body application/json

idstringrequired

Strategy ID. Required when you update a strategy; optional for search and create

namestringrequired

Strategy name. Required when you create or update a strategy

typeinteger

Source of the conditions:

  • 0 - From a recommended strategy
  • 1 - From a Client strategy
  • 2 - New conditions
Values
0
1
2
marketstringrequired

Market code, for example US or HK

industrystring

Industry ID from industries[].id of Get Screener Industries, sent as a string. Omit it for all industries

filtersarray<object>required

Filter conditions, excluding market and industry

Child attributes
keystringrequired

Indicator key. Use indicators[].key for a regular or technical indicator, and the selected sub_indicators[].key for an indicator group

minstring

Lower bound; omit it or send an empty string for no lower bound

maxstring

Upper bound; omit it or send an empty string for no upper bound

tech_valuesobject

Technical indicator parameters. Each key is a tech_key and each value is the selected item_value or the value the Client entered. Send it only for technical indicator conditions

returnsarray<string>required

Indicator keys to return. They determine the content and order of indicators in each result. Put filter_prevclose (previous close) and filter_prevchg (change) first, then add the keys of regular and indicator-group conditions. Do not add technical indicators

pageinteger

Page number, starting from 0

sizeinteger

Number of items per page

sort_byinteger

Sort column: the zero-based index of the sort indicator in returns

sort_orderinteger

Sort direction:

  • 0 - Ascending
  • 1 - Descending
Values
0
1

Responses

HTTP 200The request succeeded. A code of 0 means the strategy was updated.
codeintegerrequired

Business status code, 0 indicates success

messagestringrequired

Human-readable result or error message.

Whale Docs