{"uid":"cap_YHKnQPjRDqUod9_Yvez8G","slug":"market2000-xyz-portfolio-optimizer-b9ac422b","name":"market2000.xyz Portfolio Optimizer","description":"An origin the crawlers already index. We count what AI agents try to buy, what they are refused, and what the AI companies take without sending anyone back. Sold per call in USDC.","url":"https://market2000.xyz/optimize_portfolio","method":"GET","headers":{},"bodySchema":{"type":"object","$schema":"https://json-schema.org/draft/2020-12/schema","required":["input"],"properties":{"input":{"type":"object","required":["type","method","queryParams"],"properties":{"type":{"type":"string","const":"http"},"method":{"enum":["GET","HEAD","DELETE"],"type":"string"},"queryParams":{"type":"object","required":["tickers"],"properties":{"period":{"enum":["6mo","1y","2y","3y","5y"],"type":"string","description":"Historical data window used to estimate returns and covariance (default: 1y)"},"tickers":{"type":"string","description":"Comma-separated list of 2–30 ticker symbols (e.g. 'AAPL,MSFT,NVDA,SPY')"},"objective":{"enum":["max_sharpe","min_volatility","max_return"],"type":"string","description":"Optimization objective (default: max_sharpe)"},"risk_free_rate":{"type":"number","description":"Annual risk-free rate for Sharpe calculation (default: 0.04 = 4%)"}}}}},"output":{"type":"object","required":["type"],"properties":{"type":{"type":"string"},"example":{"type":"object","required":["objective","period","tickers_used","allocation","metrics"],"properties":{"cached":{"type":"boolean"},"period":{"type":"string"},"metrics":{"type":"object","properties":{"sharpe_ratio":{"type":"number"},"annual_volatility":{"type":"number"},"expected_annual_return":{"type":"number"}}},"objective":{"type":"string"},"allocation":{"type":"object","description":"Ticker → optimal weight (0–1)"},"fetched_at":{"type":"string"},"tickers_used":{"type":"array","items":{"type":"string"}},"correlation_matrix":{"type":"object"},"benchmark_equal_weight":{"type":"object"}}}}}}},"responseSchema":{"type":"json","example":{"cached":false,"period":"1y","metrics":{"sharpe_ratio":1.402,"annual_volatility":0.194,"expected_annual_return":0.312},"objective":"max_sharpe","allocation":{"SPY":0.33,"AAPL":0.54,"NVDA":0.13},"fetched_at":"2026-06-07T10:00:00Z","tickers_used":["AAPL","MSFT","NVDA","SPY"],"risk_free_rate":0.04,"benchmark_equal_weight":{"sharpe_ratio":1.08,"annual_volatility":0.213,"expected_annual_return":0.271}}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.05","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"settled","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.05/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.05","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.05","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_CXuhO6Gx7NY4GWPHvyxHi","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.05","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Optimizes a portfolio allocation across given stock tickers to maximize Sharpe ratio or other objectives, returning weights, risk metrics, and benchmark comparisons","exampleAgentPrompt":"Optimize my portfolio across AAPL, MSFT, NVDA, and SPY over the past 1 year to maximize the Sharpe ratio, using a 4% risk-free rate, and tell me what weights to hold along with the expected return and volatility.","exampleUseCases":[{"title":"Rebalance tech-heavy stock portfolio","prompt":"I've got money spread across AAPL, GOOGL, META, AMZN, and TSLA right now and I just want to know if I should rebalance — can you run a Sharpe ratio optimization over the last 2 years and tell me the ideal weights and how that stacks up against just holding them equally?"},{"title":"Minimize volatility across retirement holdings","prompt":"I'm trying to reduce risk in my retirement account which holds SPY, BND, GLD, and VNQ — can you find the portfolio weights that maximize risk-adjusted returns over the past 3 years using a 5% risk-free rate, and show me how that compares to splitting evenly across all four?"},{"title":"Compare optimized vs equal-weight allocation","prompt":"Before I put new money into NVDA, AMD, INTC, and QCOM, can you run a portfolio optimization for me over the last 18 months to see whether an optimized Sharpe ratio allocation actually beats a simple equal-weight split, and what annual return and volatility I'd be looking at either way?"}],"resultDescription":"Returns optimal portfolio allocation weights per ticker, Sharpe ratio, expected annual return, and annual volatility for the optimized portfolio, plus a benchmark equal-weight comparison showing its Sharpe ratio, volatility, and expected return — along with the optimization objective used, period, and risk-free rate assumed.","failureModes":["Invalid or unrecognized ticker symbols — endpoint may return an error or omit the ticker","Insufficient historical data for the requested period — may return partial results or error","Payment failure via x402 — call rejected if USDC payment on Base is not confirmed","Too few tickers provided — optimizer may fail to construct a meaningful portfolio","Network or upstream data provider outage — stale or unavailable price data"],"whenToPreferThis":"Choose this endpoint when you need quantitative mean-variance portfolio optimization (Sharpe-maximizing or similar) for a custom list of tickers with explicit risk metrics output. Prefer it over generic financial data APIs when you want a ready-made allocation recommendation rather than raw price data, and when you need a benchmark equal-weight comparison alongside the optimized result.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-15T00:39:49.814Z","isFirstParty":false}