Financial Scores API: Piotroski, Altman Z and Beneish M with every input shown
Piotroski F-score, Altman Z, Beneish M-score and Sloan accruals per fiscal year, computed from XBRL filings with the formula, inputs and accession behind each number.
curl -H "Authorization: Bearer $SECFEED_KEY" \ "https://secfeedapi.com/v1/scores?ticker=AAPL&model=all"
import os, requests
r = requests.get(
"https://secfeedapi.com/v1/scores",
params={'ticker': 'AAPL', 'model': 'all'},
headers={"Authorization": f"Bearer {os.environ['SECFEED_KEY']}"},
)
print(r.json()){
"cik": 320193,
"entity": "Apple Inc.",
"sic": 3571,
"models": [
"piotroski",
"altman"
],
"note": "Scores are published academic statistics computed from the company's XBRL facts. They are not credit ratings, forecasts or advice. Every input carries its tag and source accession; a component with a missing input is null and listed in `missing`.",
"total": 10,
"years": [
{
"fiscalYearEnd": "2026-09-26",
"accessionNos": [
"0000320193-26-000026"
],
"piotroski": {
"score": 9,
"partialScore": 9,
"signalsKnown": 9,
"of": 9,
"missing": [],
"components": [
{
"name": "roaPositive",
"formula": "netIncome / total assets at start of year > 0",
"value": 1,
"inputs": {
"netIncome@2026-09-26": {
"value": 132175000000,
"tag": "NetIncomeLoss",
"accn": "0000320193-26-000026"
},
"assets@2025-09-27": {
"value": 359241000000,
"tag": "Assets",
"accn": "0000320193-26-000026"
}
},
"measure": 0.367928
},
{
"name": "cashFlowPositive",
"formula": "operatingCashFlow > 0",
"value": 1,
"inputs": {
"operatingCashFlow@2026-09-26": {
"value": 145097000000,
"tag": "NetCashProvidedByUsedInOperatingActivities",
"accn": "0000320193-26-000026"
}
},
"measure": 145097000000
}
],
"interpretation": "9 signals, each 1 or 0; the score is shown only when all nine could be computed (partialScore otherwise). Higher means more of the signals are favourable; it is not a rating."
},
"altman": {
"applicable": true,
"variables": {
"X1_workingCapitalToAssets": 0.009744,
"X2_retainedEarningsToAssets": 0.033865,
"X3_operatingIncomeToAssets": 0.390715,
"X4_bookEquityToLiabilities": 0.383283,
"X5_salesToAssets": 1.183627
},
"inputs": {
"assetsCurrent@2026-09-26": {
"value": 173857000000,
"tag": "AssetsCurrent",
...Overview
Accounting quality screens are easy to buy as a bare number and hard to check. Here each score lists its components, the formula, every input with its XBRL tag and the accession of the filing, so an analyst can reproduce it from the 10-K.
Inputs that a company does not report are listed as missing and the component is null: nothing is imputed. Altman uses the book equity variants (Z' and Z'') because SecFeed has no market prices, and says so. Banks, insurers and real estate (SIC 6000 to 6999) are marked not applicable for Altman and Beneish. These are published academic statistics, not credit ratings, forecasts or advice.
What you get
Built for developers who would rather not parse EDGAR.
Piotroski F-score (9 signals), Altman Z' and Z'', Beneish M-score (8 variables) and Sloan accruals.
Every component carries its formula, input values, XBRL tags and source accessions.
A missing input gives a null component and a `missing` list.
Paid plans get the history; trial and free keys get the latest year as a preview.
Endpoints
Authenticate with Authorization: Bearer YOUR_KEY. Responses are JSON.
Accounting quality and distress scores per fiscal year from XBRL: Piotroski F-score, Altman Z' and Z'' (book equity), Beneish M-score (8 variables) and Sloan accruals. Every component shows its formula, inputs, XBRL tags and source accession; missing inputs are listed, never imputed. Statistics, not ratings. Paid plans get up to 10 years; trial and free keys the latest year.
Parameters: ticker | cik, fiscalYear, model (piotroski, altman, beneish, accruals, all)
Response fields
The main fields in every result. The raw filing data is always one level down.
| Field | Meaning |
|---|---|
years[].piotroski.score | 0 to 9, shown only when all nine signals could be computed. |
years[].piotroski.components[] | Each signal with value 1 or 0, measure, formula and inputs. |
years[].altman.zPrime / zDoublePrime | Value, formula, zone and thresholds. |
years[].beneish.value | M-score with the eight variables and the threshold. |
years[].accruals.value | (net income - operating cash flow) / average assets. |
years[].accessionNos | Filings the inputs came from. |
Use cases
- Screening a watchlist for weak earnings quality before reading the filings
- Adding an audit trail to a distress or quality factor in a model
- Checking a vendor's score against the 10-K
FAQ
Why is Altman not the original 1968 formula?
That one needs the market value of equity. SecFeed has no prices, so it serves the published book equity variants Z' and Z''.
Are these ratings?
No. They are academic statistics computed from filings. They are not credit ratings, forecasts or investment advice.
Why is a score null?
The company did not report an input. The missing list names it.
Where does the data come from?
XBRL facts in 10-K, 20-F and 40-F filings on SEC EDGAR. Source: U.S. Securities and Exchange Commission.
Try the Financial Scores API (Piotroski, Altman, Beneish) free
Free key, no card, no sales call.