Technical Indicator API Guide技术指标 API 指南

Free RSI API
Data, Limits & Python
免费 RSI API
数据、限制与 Python 接入

Find a free RSI API, inspect its Relative Strength Index values, then verify symbols, intervals, periods, timestamps, quotas, and usage terms before integration.

寻找可免费调用的 RSI API,检查相对强弱指数数值与计算参数,
并在接入前核对标的、周期、时间戳、额度与使用条款。

How to use a free RSI API: inputs, endpoint request, RSI JSON fields, validation, and caching 如何使用免费 RSI API:输入参数、接口调用、RSI JSON 字段、数据验证与缓存

TL;DR概览

Bounded-oscillator job

Retrieve a 0–100 momentum oscillator for overextension, mean-reversion context, regime analysis, and price-versus-RSI divergence.

Smoothing convention

Preserve lookback, Wilder or alternative smoothing, input price, seed method, interval, adjustment policy, and edge-case behavior.

Strategy boundary

The API should return a measurement; overbought and oversold thresholds belong to the application and vary by trend, volatility, and asset.

Where QVeris helps

QVeris helps agents discover technical-analysis capabilities and inspect their required inputs before calling them.

有界振荡指标任务

获取 0–100 动量振荡值,用于过度延伸、均值回归背景、市场状态分析和价格与 RSI 背离。

平滑方法

保存回看长度、Wilder 或其他平滑、输入价格、初始值方法、周期、复权政策和边界处理。

策略边界

API 应返回测量值;超买超卖阈值属于应用策略,并会随趋势、波动率和资产变化。

QVeris 如何帮助

QVeris 可帮助 Agent 发现技术分析能力、检查输入输出,再决定是否调用。

Free RSI API response fields and parameters免费 RSI API 的响应字段与参数

An RSI indicator API returns a momentum oscillator, normally on a 0–100 scale, derived from average gains and losses over a lookback period. Fourteen periods is common, but interval, price series, smoothing, precision, and warm-up behavior differ. Treat each provider’s documentation as authoritative.

RSI 技术指标 API 通常根据一个回看周期内的平均上涨与平均下跌计算 0–100 区间的动量振荡值。14 周期较常见,但时间间隔、价格序列、平滑方法、精度和预热期处理各不相同,应以供应商文档为准。

Confirm Wilder smoothing or another variant

Many services say “RSI” but use Wilder’s recursive averages, simple rolling averages, or a library-specific seed. Parameter length alone is not enough to reproduce the oscillator.

Test boundary behavior after one-sided moves

Check how the API handles zero average loss, zero average gain, flat prices, and insufficient history. Valid implementations may return 100, 0, 50, or null in specific edge states.

Treat 70 and 30 as context, not universal orders

Overbought and oversold thresholds depend on trend, volatility, interval, and asset. The API should return the measurement; strategy rules belong in your application and must be tested separately.

Preserve price source and completed-bar status

Record close versus adjusted close, interval, lookback, smoothing, timezone, and whether the current bar is final. Divergence analysis is meaningless if price and RSI use different timestamps.

Define divergence without hindsight

Bullish or bearish divergence requires explicit pivot rules, a comparison window, minimum price and RSI separation, and a confirmation time. If the application waits for future bars to confirm a pivot, label the signal at the time it became knowable—not at the earlier turning point—or a backtest will contain look-ahead bias.

Keep intervals independent

A 14-period RSI on one-minute bars is not interchangeable with the same period on hourly or daily bars. Store interval and session with every value, resample from a documented boundary, and do not join multi-timeframe signals until all contributing candles were complete at the decision timestamp.

Choose API output or local calculation deliberately

A direct endpoint is convenient for a few symbols and fixed parameters. Local calculation can be cheaper and more reproducible when you already retrieve OHLCV bars, need many periods, or want exact control over smoothing and seeding. Compare data rights and bar-call costs as part of the decision.

确认 Wilder 平滑还是其他变体

很多服务都叫 RSI,但实际可能使用 Wilder 递归平均、简单滚动平均或库特有初始值。只有回看周期不足以复现振荡指标。

测试单边行情后的边界行为

检查平均跌幅为零、平均涨幅为零、价格不变和历史不足时的处理。不同有效实现可能在特定边界返回 100、0、50 或空值。

把 70 和 30 当作背景,而不是通用指令

超买超卖阈值取决于趋势、波动率、周期和资产。API 应返回测量值,策略规则应由应用单独定义并验证。

保留价格源与 K线完成状态

记录收盘或复权收盘、周期、回看长度、平滑、时区和当前 K线是否完成。价格与 RSI 时间戳不一致时,背离分析没有意义。

定义不含事后信息的背离

判断看涨或看跌背离,需要明确拐点规则、比较窗口、价格与 RSI 的最小差异和确认时间。如果必须等待后续 K 线才能确认拐点,信号时间应记录为真正可知的时刻,而不是更早的转折点,否则回测会产生未来数据泄漏。

不同周期必须独立处理

一分钟 K 线上的 14 周期 RSI,与小时线或日线上的同参数指标不可互换。每个数值都要保存周期和交易时段,按照有文档的边界重采样;只有参与计算的所有 K 线在决策时点都已完成,才能组合多周期信号。

明确选择 API 结果还是本地计算

只处理少量标的和固定参数时,直接指标端点更方便。若已经获取 OHLCV K 线、需要多种周期,或希望精确控制平滑与初始值,本地计算通常更经济且更易复现。判断时还要纳入数据权利和 K 线调用成本。

How to compare free technical indicator APIs如何比较免费技术指标 API

Requirement要求What to inspect检查内容Why it matters为什么重要Failure signal风险信号
Endpoint access端点权限Is RSI included in the free tier, demo, or paid plan?RSI 属于免费层、演示还是付费端点?A free key may not unlock every indicator.免费密钥可能无法调用全部指标。Pricing and docs disagree.价格页与文档不一致。
Fields字段RSI value, timestamp, symbol, interval, metadata.RSI 数值、时间戳、标的、周期与元数据。Determines whether the response answers the task.决定响应能否直接满足任务。Only a chart or opaque score.只提供图表或不透明评分。
Parameters参数Symbol, interval, time period, and series type.标的、时间间隔、回看周期与价格序列类型。Makes output reproducible and comparable.使输出可复现、可比较。Undocumented fixed defaults.固定默认值却没有说明。
Quota & rights额度与许可Request weights, 429 behavior, caching, display, storage.请求权重、429 行为、缓存、展示与存储许可。Defines safe polling and permitted use.决定安全轮询方式与允许用途。“Unlimited” without written terms.宣称“不限量”却无书面条款。

Free RSI API options versus calculating RSI locally免费 RSI 接口与本地计算方案怎么选

A documented RSI endpoint is convenient, but it is not automatically the cheapest or most reproducible choice. If the application already retrieves completed OHLCV bars, calculating RSI locally avoids an extra request per symbol and gives full control over smoothing, seeding, and revisions. A provider endpoint is more attractive when you need only a few values, want one normalized response across asset classes, or do not want to maintain indicator code.

有文档的 RSI 端点调用方便,但不一定成本最低,也不一定最容易复现。如果应用本来就会获取已完成的 OHLCV K 线,本地计算可以避免为每个标的额外调用一次接口,并能完全控制平滑、初始值和历史修订。若只需要少量数值、希望多个资产类别使用统一响应,或不想维护指标代码,服务商端点更有吸引力。

Option to test候选方案Documented capability文档能力Best fit适用场景Free-tier question免费层需确认
Alpha Vantage RSIThe official RSI function accepts symbol, interval, period, and series type, supports equities plus FX or crypto symbols, and returns JSON or CSV.官方 RSI 函数支持标的、周期、回看长度和价格序列类型参数,可用于股票、外汇或加密货币,并返回 JSON 或 CSV。A few direct indicator lookups across several asset classes with explicit parameters.跨多个资产类别进行少量、参数明确的指标查询。A free API key is available, but freshness, request limits, underlying bar entitlement, and commercial use must be checked for the intended interval.虽然可以申请免费 API Key,但仍需按目标周期确认数据时效、请求限制、底层 K 线权限和商业用途。
Twelve Data RSITwelve Data documents a dedicated RSI endpoint for a specified instrument and period within its technical-indicator API family.Twelve Data 在技术指标 API 中提供针对指定金融工具和周期的 RSI 端点。Applications already using Twelve Data symbols and time-series conventions for multiple markets.已经采用 Twelve Data 代码和时间序列规则、覆盖多个市场的应用。Verify whether RSI is included in the current free plan, its credit weight, batch behavior, available intervals, and source-market delay.确认当前免费套餐是否包含 RSI、端点消耗额度、批量行为、可用周期和底层市场延迟。
Financial Modeling Prep RSIFMP publishes a stable Relative Strength Index endpoint under its technical-indicators API.FMP 在技术指标 API 中公开了稳定版 Relative Strength Index 端点。Teams that already use FMP security identifiers and want indicator output beside other financial datasets.已使用 FMP 证券标识,并希望把技术指标与其他金融数据放在同一数据体系中的团队。Do not infer access from the public documentation page. Confirm the current subscription tier, historical depth, interval coverage, quota, and data license.公开文档页不等于免费可调用;必须确认当前套餐、历史深度、周期覆盖、额度和数据许可。
Local calculation from OHLCV基于 OHLCV 本地计算Compute gains and losses from a controlled close series, seed the initial averages, and apply Wilder's recursive smoothing under your own versioned implementation.使用受控收盘价序列计算涨跌幅,初始化平均涨跌并在自有版本化实现中应用 Wilder 递归平滑。Large universes, many parameter sets, research reproducibility, and workflows that already license the source bars.大规模证券池、多参数组合、强调研究复现性,以及已经拥有底层 K 线许可的流程。The bars are not automatically free to store or redistribute. Preserve their source, adjustment policy, completed-bar state, and license.底层 K 线并不会自动获得免费存储或再分发权;仍需保存来源、复权政策、K 线完成状态和许可。

Use a numerical fixture to prove two RSI implementations agree用固定数值样本验证两套 RSI 实现是否一致

Save at least 40 completed closes containing a flat segment, a one-direction run, a gap, and one adjusted-price event. Request a 14-period close-based RSI from the provider, then recalculate the same timestamps locally. Compare the first non-null timestamp, seed window, rounding, and every later value within a documented tolerance. If disagreement begins only after a corporate action or session gap, investigate the price series and adjustment rules before blaming the formula.

保存至少 40 根已完成的收盘价,其中应包含横盘区间、单边走势、缺失周期和一次复权事件。向服务商请求基于收盘价的 14 周期 RSI,再对完全相同的时间戳进行本地复算。比较首个非空值的时间、初始窗口、舍入规则,以及此后每个数值是否落在预先记录的容差内。如果差异只在公司行动或交易时段缺口后出现,应先检查价格序列和复权规则,而不是直接判断公式错误。

Decision rule: use the direct API when it passes the fixture, its quota covers the complete polling workload, and its bar rights match the product. Calculate locally when the same licensed OHLCV already powers several indicators or when exact reproducibility matters more than one-call convenience.

判断规则:若直接端点能够通过固定样本、额度足以覆盖完整轮询任务,并且底层行情权利符合产品用途,可以直接采用;若同一套已授权 OHLCV 还要计算多种指标,或精确复现比一次调用更重要,则更适合本地计算。

RSI API for Python: a safe integration pathPython 获取 RSI 数据:安全接入步骤

Use a small local implementation as a numerical fixture for the provider response. The function below applies Wilder’s recursive smoothing, preserves the warm-up rows as None, and defines the flat, all-gain, and all-loss boundaries explicitly.

可以使用一份精简的本地实现作为供应商响应的数值基准。下面的函数采用 Wilder 递归平滑,把预热区间保留为 None,并明确处理横盘、全部上涨和全部下跌三种边界状态。

def wilder_rsi(closes: list[float], period: int = 14) -> list[float | None]:
    if period < 2:
        raise ValueError("period must be at least 2")
    if any(value is None or value <= 0 for value in closes):
        raise ValueError("closes must contain positive completed-bar values")
    if len(closes) < period + 1:
        return [None] * len(closes)

    changes = [current - previous for previous, current in zip(closes, closes[1:])]
    gains = [max(change, 0.0) for change in changes]
    losses = [max(-change, 0.0) for change in changes]
    average_gain = sum(gains[:period]) / period
    average_loss = sum(losses[:period]) / period
    values: list[float | None] = [None] * period

    def score(gain: float, loss: float) -> float:
        if gain == 0 and loss == 0:
            return 50.0
        if loss == 0:
            return 100.0
        if gain == 0:
            return 0.0
        relative_strength = gain / loss
        return 100.0 - (100.0 / (1.0 + relative_strength))

    values.append(score(average_gain, average_loss))
    for gain, loss in zip(gains[period:], losses[period:]):
        average_gain = ((period - 1) * average_gain + gain) / period
        average_loss = ((period - 1) * average_loss + loss) / period
        values.append(score(average_gain, average_loss))
    return values

Compare like with like. Run the fixture on the provider’s exact completed close series and compare only after matching interval, session, timezone, adjustment mode, period, seed, and rounding. A different first non-null timestamp usually indicates a seed or warm-up difference—not random numerical noise.

只有口径一致才值得比较。基准函数必须使用供应商对应的已完成收盘价序列,并在周期、交易时段、时区、复权方式、回看长度、初始值和舍入规则一致后再比较。首个非空值时间不同,通常意味着初始值或预热规则不同,而不是普通数值误差。

1. Confirm symbol, asset class, and interval

Resolve the instrument and venue first, then choose a supported interval such as daily or one hour. Do not assume the same ticker maps across providers.

2. Send one documented RSI request

Use the provider’s official HTTP or Python example with an API key stored on the server. Inspect the unmodified JSON before writing a mapper.

3. Normalize RSI JSON data

Parse timestamps with timezone awareness, convert numeric strings safely, preserve null warm-up values, and map the RSI value and calculation metadata explicitly.

4. Add rate-limit handling and caching

Respect request weights, back off after 429 responses, cache by completed-bar cadence, and retain provider, parameters, and retrieval timestamps.

5. Recalculate a fixed RSI fixture

Save a short close-price series with flat, rising, falling, and missing intervals. Reproduce the provider's seed and smoothing method independently, compare warm-up rows and timestamps, and set an explicit numeric tolerance. Include one corporate-action date when adjusted stock prices are supported.

6. Monitor for stale or revised values

Track source-bar age, completed-candle status, null rate, quota use, schema changes, and disagreement with the fixture. If the latest RSI is stale or a historical revision changes a prior signal, expose that state rather than silently carrying a value forward.

1. 确认标的、资产类型与周期

先解析证券和交易所,再选择日线或小时等受支持周期,不要假设不同供应商使用相同代码映射。

2. 按官方文档发送 RSI 请求

参考供应商提供的 HTTP 或 Python 示例,将 API 密钥保存在服务端,并先检查未经修改的原始 JSON。

3. 规范化 RSI JSON 数据

按时区解析时间戳,安全转换数值字符串,保留预热期空值,并明确映射 RSI 数值与计算元数据。

4. 添加限流处理与缓存

遵守请求权重,遇到 429 时退避,按已完成 K 线缓存,并记录供应商、计算参数与抓取时间。

5. 用固定 RSI 样本复算

保存一段包含横盘、上涨、下跌与缺失周期的收盘价序列,独立复现供应商的初始值与平滑方法,并比较预热行和时间戳,预先设置明确数值容差。若支持复权股票价格,样本还应包含一个公司行动日期。

6. 监控过期与历史修订

跟踪底层 K 线年龄、收盘状态、空值率、额度消耗、Schema 变化以及与固定样本的偏差。如果最新 RSI 已过期,或历史修订改变了先前信号,应明确暴露状态,不能静默沿用旧值。

Use QVeris to discover RSI API capabilities用 QVeris 发现 RSI API 能力

QVeris is a capability-routing layer, not a market-data vendor and not a promise that a third-party RSI endpoint is free. It can help an agent search for technical-analysis capabilities, inspect inputs and outputs, and call a selected tool under that tool’s documented terms.

QVeris 是能力路由层,不是行情供应商,也不承诺第三方 RSI 端点免费。它可以帮助 Agent 搜索技术分析能力、检查输入输出,并遵循目标工具的公开条款进行调用。

  • Open the QVeris tool details for RSI and technical-indicator capabilities.
  • Inspect symbols, intervals, calculation parameters, response schema, provider identity, and limitations before calling.
  • Use the QVeris documentation to connect the selected capability to an agent workflow.
  • 打开 QVeris 技术指标工具详情,核对 RSI 参数与返回结果。
  • 调用前检查标的、周期、计算参数、响应结构、供应商身份和公开限制。
  • 参考 QVeris 文档,把选定能力接入 Agent 工作流。

Free RSI API FAQ免费 RSI API 常见问题

Is there a free API for RSI data?

Yes. Some providers offer free tiers or demos for pre-calculated RSI. Check the current pricing and endpoint documentation because a free key may exclude the RSI function.

What does an RSI API return?

A useful response normally includes timestamps and RSI values, plus metadata for symbol, interval, series type, and time period. Inspect ordering, precision, and null warm-up rows.

How do I get RSI data in Python?

Send an authenticated HTTP request with a symbol and interval, parse the JSON, convert numeric strings safely, preserve timestamps, and handle rate limits and errors.

Can I get real-time RSI data from a free API?

Possibly, but source-market entitlements and free-plan rules vary. Verify the underlying bar timestamp and documented delay instead of inferring freshness from response speed.

有免费的 RSI API 吗?

部分供应商为预计算 RSI 提供免费层或试用额度,但免费密钥可能不包含该端点,因此应同时检查最新价格页和接口文档。

RSI 接口会返回什么?

常见字段包括时间戳与 RSI 数值,并附带标的、时间间隔、价格序列和回看周期等元数据;还应检查数据顺序、精度与预热期空值。

如何用 Python 获取 RSI 数据?

携带密钥、标的和周期发送 HTTP 请求,解析 JSON,安全转换数值,保留时间戳,并处理限流与错误。

免费接口能返回实时 RSI 吗?

有可能,但取决于底层行情权限和免费层规则。应检查 K 线时间戳与官方延迟说明,不要仅凭接口响应速度判断数据是否实时。

Authoritative references and next steps参考资料与接入下一步