Home/Offers/Trading & Capital Markets/Portfolio Risk Analytics API

Trading & Capital Markets

Portfolio Risk Analytics API

Your users can see what they own. They usually cannot see what they are actually exposed to, or what happens to it when markets behave badly.

  • Wealth platforms
  • Robo-advisors
  • Banks
  • Portfolio management software

What your customers would see

example interface
Mockup of the Portfolio Risk interfacewealth.yourplatform.com/portfolioPlatformOverviewExploreAlertsAPI keysUsageSettingsPortfolio RiskAccountPortfolio risk profile63risk scoreModerate-highRisk contribution by factorweightedGlobal equity81%US dollar9%Duration7%Credit spread2%Commodity1%Stress scenario resultsliveSCENARIOESTIMATED CHANGEWORST HOLDINGSEVERITYGlobal financial crisis 2008−39.1%Tech ETFsevereCovid crash 2020−22.6%Travel fundhighRate shock 2022−11.8%Long bondmoderateEuro crisis 2011−16.4%EU bankshigh

MockupIllustrative mockup of the interface we would build. Figures shown are examples, not results from a live deployment.

The problem this solves

A holdings list is not a risk picture. Two portfolios with identical asset allocations can carry very different exposures depending on what sits inside the funds, how correlated the positions have become, and how much of the apparent diversification disappears precisely when markets fall.

Most retail wealth platforms show allocation pie charts and a risk score derived from a questionnaire the user filled in once. That satisfies a compliance requirement without telling anyone anything useful about the portfolio in front of them.

Proper portfolio analytics is well-established quantitative work: look through funds to underlying exposures, decompose returns into factors, test against historical stress periods, and measure how concentration and correlation shift over time. The reason platforms do not ship it is that it needs reference data and quantitative engineering, not that the methods are unsettled.

Who buys this

Wealth platforms, Robo-advisors, Banks, Portfolio management software

What the API returns

What comes back

  • Look-through exposure analysis to underlying holdings inside funds and ETFs
  • Factor decomposition across equity, rate, credit, currency and commodity factors
  • Historical stress tests against named market episodes
  • Correlation analysis including how correlations behave in falling markets
  • Concentration measures by position, sector, geography and issuer
  • Volatility and drawdown statistics with contribution attribution
  • Currency exposure including unintended exposure through foreign holdings
  • Scenario analysis for user-defined shocks

Endpoints

MethodPathReturns
POST/v1/portfolio/analyseFull risk analysis for a portfolio
POST/v1/portfolio/stressRun named or custom stress scenarios
POST/v1/portfolio/factorsFactor exposure decomposition
POST/v1/portfolio/lookthroughUnderlying exposures inside funds
POST/v1/portfolio/compareCompare two portfolios on the same measures
GET/v1/scenariosAvailable stress scenarios and their definitions

Request and response

illustrative

Request

{
  "positions": [
    { "identifier": "US0378331005", "quantity": 140 },
    { "identifier": "IE00B4L5Y983", "quantity": 820 },
    { "identifier": "US912828YS26", "quantity": 15000 }
  ],
  "base_currency": "EUR",
  "scenarios": ["gfc_2008", "covid_2020", "rates_2022"]
}

Response

{
  "portfolio_value": 284120.40,
  "base_currency": "EUR",
  "risk": {
    "annualised_volatility": 0.141,
    "max_drawdown_5y": -0.284,
    "effective_positions": 11.3,
    "concentration_hhi": 0.094
  },
  "factors": [
    { "factor": "global_equity", "exposure": 0.72, "contribution_to_risk": 0.81 },
    { "factor": "duration",      "exposure": 0.19, "contribution_to_risk": 0.07 },
    { "factor": "usd",           "exposure": 0.44, "contribution_to_risk": 0.09 }
  ],
  "stress_tests": [
    { "scenario": "gfc_2008",  "estimated_change": -0.391 },
    { "scenario": "covid_2020","estimated_change": -0.226 },
    { "scenario": "rates_2022","estimated_change": -0.118 }
  ],
  "concentration_warnings": [
    { "type": "sector", "label": "Technology", "weight": 0.38 }
  ]
}

Where the data comes from

Instrument reference dataIdentifiers, classifications and corporate actions, licensed from a reference data provider
Fund holdings disclosuresPublished fund and ETF holdings, which make look-through analysis possible
Historical price seriesLong histories for factor estimation and stress testing — the depth matters more than the breadth here
Factor return seriesEither licensed or constructed from the underlying price history
FX ratesCurrent and historical, for base-currency conversion and currency exposure
Your portfolio dataPositions and quantities, sent per request or synchronised on a schedule
On data licensing. Being allowed to read a dataset does not automatically mean you may redistribute it, resell it through an API, or train a model on it. Before any build starts we check the licence, terms and derived-data rules of every source, and we design around the ones that do not permit your intended use. Where a commercial licence is required, that cost is identified during discovery rather than discovered later.

The intelligence layer

The difference between a demo and a service is mostly in this section. These are the parts that keep the answer trustworthy once real traffic is hitting it.

  • Look-through decomposition that resolves funds to underlying holdings before any exposure is computed
  • Factor models estimated over multiple horizons, because exposures measured over one window are unstable
  • Historical scenario replay using actual observed moves rather than hypothetical shocks
  • Correlation estimation that separates calm-period and stress-period behaviour
  • Shrinkage estimators for covariance, since sample covariance is unreliable for large portfolios
  • Risk contribution attribution so a user can see which holding drives the number
  • Explicit confidence bounds — a stress estimate is a range, and presenting a point estimate is misleading
  • Validation against realised portfolio outcomes over held-out periods

What it changes for the business

Compliance evidence

Documented, repeatable risk analysis supports suitability obligations in a way a questionnaire does not.

Advice conversations

Advisers get a concrete picture to discuss rather than an allocation chart.

Premium tier

Portfolio analytics is a feature users will pay to unlock on self-directed platforms.

Earlier intervention

Concentration warnings surface problems before a market event makes them expensive.

How it fits into your product

How it embeds

  • Stateless REST: send positions, receive analysis, store nothing on our side if you prefer
  • Batch endpoints for overnight analysis across your whole client base
  • Chart-ready output for factor, stress and concentration visualisations
  • PDF report generation for adviser and client-facing documents
  • Deployment inside your infrastructure where holdings cannot leave
  • Scenario definitions you can extend with your own house views

Included in every build

  • Authentication, scoped API keys and per-customer rate limiting
  • Input validation with predictable, documented error responses
  • Versioned endpoints so your integration never breaks without notice
  • Request and response logging for audit and dispute resolution
  • Latency, error-rate and usage monitoring with alerting
  • OpenAPI specification, sandbox environment and client examples
  • Backups, failover design and a documented recovery procedure
  • An agreed support arrangement once the service is live

How we would build it

about 20 weeks
1

Discovery and feasibility

Weeks 1–3

This one depends heavily on data access, so we start by proving the sources exist, can be licensed for your use, and actually carry the signal the model needs. If they do not, you find out here.

2

Architecture and baseline model

Weeks 4–6

A written architecture and a baseline model measured against a holdout period, so you know what accuracy you are buying before the full build starts.

3

Production build

Weeks 7–16

Data pipelines, model training and serving, historical archive, validation harness, API, security, monitoring and documentation.

4

Validation and integration

Weeks 17–20

Backtesting against held-out history, accuracy reporting your team can audit, integration support and an agreed retraining cadence.

Commercial models

There is no fixed price list, because the cost is driven by data complexity, integration count, model requirements, request volume and the support level you need. Scope is agreed in writing before development starts.

Fixed-scope prototype

A defined slice of the service, built and priced as one piece of work. The usual first step when the business case needs proving internally.

Fixed-price build

An agreed scope against a written architecture, delivered for an agreed price. Best when the requirements are already clear.

Build then retainer

We build the service, then operate and improve it under a monthly agreement covering monitoring, updates and model maintenance.

White-label product

The service runs under your brand, your domain and your pricing, with MLPivot invisible to your customers.

Questions buyers ask

Is this investment advice?

No. The API returns measurements and scenario estimates. It does not recommend buying or selling anything. How you present it, and whether your presentation constitutes advice in your jurisdiction, is a question for your compliance team — and we will build to the constraints they set.

How accurate are the stress tests?

They are estimates with real uncertainty, and the API returns ranges rather than point values for that reason. A historical replay tells you what a portfolio with these exposures would have done in that episode, which is informative but not a forecast. We would resist presenting them as predictions.

Do you need full look-through holdings?

It materially improves the analysis, and for fund-heavy portfolios it is close to essential — without it you are analysing the label rather than the contents. Where disclosures are stale or unavailable the API flags the affected portion rather than silently approximating.

What portfolio sizes does this handle?

From a handful of positions to several thousand. Large portfolios use the batch endpoints; the covariance work is the part that scales non-linearly and is handled accordingly.

Can we add our own scenarios?

Yes. House view scenarios can be defined as factor shocks or as historical windows, and run alongside the standard set.

Want this built for your platform?

Tell us what your product does today and what you want another system to be able to ask it. We will come back with an approach, a scope and a price.