XBRLAnalyst Web API
Description
XBRLAnalyst Web API is provided to users of all subscription types of XBRLAnalyst. The API allows to retrieve fundamental and stock market financial information of all public companies that file XBRL reports with the Securities and Exchange Commission (SEC) in the US. All information is provided in the following formats: JSON(default) and XML (you can specify it with “format” parameter).
For Preview purposes, we provide unregistered visitors with open access to the API for companies listed in the S&P100 Index.
Authentication
The XBRLAnalyst Web API uses HTTP Basic Authentication to authenticate users. Your username and password will be the same as your FinDynamics login credentials.
Response Format
Be sure to use the “Accept” header set to “application/json” to ensure JSON results. The API is also capable of returning XML.
Common Parameter Groups
Many endpoints use the same set of parameters for querying reports and companies. To keep things clear, these parameters are documented here, and only referenced in the endpoints that use them.
Company Parameters
Name | Type | Notes |
companyId | string[] | The internal ID of a company. |
cik | string[] | The SEC’s Central Index Key. |
ticker | string[] | The company’s trading symbol. |
clist | string[] | A named list of companies. |
Report Parameters
Name | Type | Notes |
reportId | string[] | The internal ID of a report. |
accessionNumber | string[] | The SEC’s accession number. |
focusYear | integer[] | The focus fiscal year of the report. |
focusPeriod | string[] | The focus fiscal period of the report (cf. Periods). |
docType | string[] | The document type of the report (e.g., “10-Q”). |
Periods
The API accepts the following values as fiscal, calendar, and focus periods:
- “Q1”, “Q2”, “Q3”, and “Q4” for quarters;
- “Q1”, “H1”, “Q3CUM”, and “FY” for cumulative periods;
- “Q1LTM”, “Q2LTM”, “Q3LTM”, and “FY” for Last-Twelve-Months periods.
For calendar periods and focus periods, only quarters and “FY” are supported.
Using the POST Method
Since queries can grow quite large, it is possible to use the POST method for making requests. To do this, the body of the request must be a JSON object with keys that match the parameter names of the endpoint. The “X-HTTP-Method-Override” header must be set to “GET”, and the “Content-Type” header must be “application/json”.
Error Reporting
The API uses HTTP status codes to indicate errors. Often, the error will accompanied by a message in the response body. For example, without authentication, the following request yields the following result with status code 401 “Unauthorized”.
Request
https://xbrlanalyst.findynamics.com/api/v2/facts?ticker=FLWS&concept=tid:GrossProfit
Response
{
“message”: “Requested company is not in the preview list. Unauthorized users only have access to a limited list of companies. Add \”clist=preview\” to limit queries to this list.”
}
Calls
Public Companies
Use:
Retrieve information about individual public company or a clist (company list) of companies.
Example:
https://xbrlanalyst.findynamics.com/api/v2/companies?ticker=wmt
Parameters:
Name | Description |
---|---|
cik | The CIK (central index key) number of a company (e.g., Walmart is “0000104169”). |
ticker | The trading symbol of a company (e.g., “MSFT” for Microsoft). |
clist | A list of companies. |
Financial Reports
Use:
Retrieve information about individual financial report or all reports submitted by the public company to SEC.
Example:
https://xbrlanalyst.findynamics.com/api/v2/reports?ticker=wmt
Parameters:
Name | Description |
---|---|
cik, ticker, clist | See Public Companies. |
accessionNumber | The SEC-assigned accession number. |
focusYear | The focus fiscal year of the accession (corresponds to the DocumentFiscalYearFocus DEI tag). |
focusPeriod | The focus fiscal period of the accession (corresponds to the DocumentFiscalPeriodFocus DEI tag). |
docType | The document type of the accession (corresponds to the DocumentType DEI tag). |
Report Sections
Use:
Retrieve detail information about sections of financial report (Statements and Disclosures)
Example:
https://xbrlanalyst.findynamics.com/api/v2/sections?ticker=wmt&accessionNumber=0001193125-11-083157
Parameters:
Name | Description |
---|---|
cik, ticker, clist | See Public Companies. |
accessionNumber, focusYear, focusPeriod, docType | See Financial Reports. |
networkRole | A number representing the category of the section. For example, 2 represents an income or comprehensive income statement. |
networkOrdinal | The ordinal number of the section relative to list of all sections (sorted by network description). |
networkUri | The extended link role of the section. Together with the accession number, this uniquely identifies a section. |
Financial Facts
Use:
Retrieve one or many financial facts: values of XBRL facts or Normalized Financial Metrics pre-computed by FinDynamics.
Example:
https://xbrlanalyst.findynamics.com/api/v2/facts?ticker=wmt&tid=revenue&fiscalYear=2013&fiscalPeriod=Q1
https://xbrlanalyst.findynamics.com/api/v2/facts?ticker=googl&fiscalYear=2013&fiscalPeriod=FY&concept=Revenues&member=MotorolaMobilityHoldingsIncMember
Parameters:
Name | Description |
---|---|
cik, ticker, clist | See Public Companies. |
tid | The Tid (normalized financial metric) to lookup. |
concept | The XBRL concept of a fact. |
members | XBRL Dimension Members. |
fiscalYear | The fiscal year of a fact. |
fiscalPeriod | The fiscal period of a fact. |
accessionNumber, focusYear, focusPeriod, docType | Additional input parameters limiting the selection of financial facts to specific report(s). For more details, see Financial Reports. |
Normalized Metrics
Use:
Retrieve the normalized metrics (“Tids”) available for use with the Financial Facts call.
Example:
https://xbrlanalyst.findynamics.com/api/v2/tids
Parameters:
Name | Description |
---|---|
tid | The Tid (normalized financial metric) to lookup. |
Market Quotes
Use:
Retrieve End Of Day stock market quotes: prices and trading volume.
Example:
https://xbrlanalyst.findynamics.com/api/v2/marketquotes?ticker=wmt&date=2014-08-07
Parameters:
Name | Description |
---|---|
cik, ticker, clist | See Public Companies. |
date | The date to get the quote from. |
Market Stats
Use:
Retrieve statistical estimates of stock market prices such as average price over a period of time.
Example:
https://xbrlanalyst.findynamics.com/api/v2/marketstats?ticker=wmt&date=2014-08-07&duration=30
Parameters:
Name | Description |
---|---|
cik, ticker, clist | See Public Companies. |
date | The last date for the interval. |
duration | The duration of the interval in days counted backward from the last date of the interval. |