Authentication
All API requests require an API key passed in the X-API-Key header. Generate and manage keys in your Account Settings.
curl -H "X-API-Key: your_api_key" \ https://api.margin-invest.com/api/v1/scores/AAPL
Rate Limits
API requests are rate-limited per key. When you exceed the limit, responses return status 429 with a Retry-After header indicating when to retry.
- Rate limit headers:
X-RateLimit-Limit,X-RateLimit-Remaining,X-RateLimit-Reset - Limits vary by subscription plan
- Implement exponential backoff for 429 responses
Endpoints
Scores
GET
/api/v1/scores/{ticker}Composite score, factor breakdown, composite percentileGET
/api/v1/scores/{ticker}/historyHistorical score snapshots over timeGET
/api/v1/scores/{ticker}/valuation-auditIntrinsic value calculation audit trailGET
/api/v1/scoresList all scored assets with current scoresBacktesting
GET
/api/v1/backtest/defaultDefault backtest with current scoring parametersPOST
/api/v1/backtest/replayRun custom backtest replay with parameter overridesGET
/api/v1/backtest/shadow-portfolioShadow portfolio tracking real-time picksGET
/api/v1/backtest/teaser/{ticker}Single-asset backtest teaserGET
/api/v1/backtest/portfolio-teaserPortfolio equity curve teaser (public)Institutional (13F)
GET
/api/v1/13f/holdings/{ticker}Institutional holders for a ticker from SEC 13F filingsGET
/api/v1/13f/holdings/{ticker}/historyHistorical institutional holding changesGET
/api/v1/13f/managersList tracked institutional managersGET
/api/v1/13f/managers/{manager_id}/portfolioFull portfolio for a specific managerUniverse & Transparency
GET
/api/v1/universe/funnelSelectivity funnel — how many assets pass each filter stageGET
/api/v1/correlations/showcaseFactor correlation matrix for scored universeGET
/api/v1/governance/transparencyOversight classification and pipeline healthResponse Format & Errors
All responses are JSON. Errors return a standard shape:
{
"detail": "Ticker not found: XYZ"
}401Missing or invalid API key
403Insufficient subscription plan for this endpoint
404Ticker not found or no score available
429Rate limit exceeded — retry after the duration in Retry-After header
500Internal server error — contact support if persistent
SDKs & Support
The API is REST-only. Official client SDKs are not yet available.
- For integration support, contact us at our contact page
- For data handling practices, see our security page