getIncomeStatements API

The getIncomeStatements API provides access to public company financial Income statements based on symbol.

All APIs

Contact Us to Get Access

Inputs

symbols required

A symbol or code that identifies a financial instrument. Multiple symbols separated by a comma may be used.

Type
list (A comma or semi-colon delimited string.) 
Example
IBM,AAPL,GOOG 

frequency required

The frequency of financial statement reporting, either Quarterly ("Quarter") or Annually ("Annual").

Type
enum (A type which includes a list of valid possible values.) 
Example
Quarter 

Valid Values:
Quarter, Annual

count optional

The number of Quarterly or Annual periods of financial statements to return.

Type
int (A numeric type defining a whole number. (example: 2)) 
Example
Default

rawData optional

Return raw data, otherwise sales, costs, expenses, tax, and income data is displayed in thousands.

Type
int (A numeric type defining a whole number. (example: 2)) 
Example

Outputs

Name / Requirement
Description
Type
symbol
always returned
A symbol or code that identifies a financial instrument.
string
A sequence of characters. (example: GOOG)
date
always returned
The date of the financial statement.
date
A date in the format of YYYY-MM-DD.
sales
always returned
Total revenue or sales for the Income Statement period.
double
A numeric type defining a number with fractional parts. (example: 2.14)
costGoods
always returned
The cost of goods sold.
double
A numeric type defining a number with fractional parts. (example: 2.14)
grossProfit
always returned
Sales less the cost of goods sold.
double
A numeric type defining a number with fractional parts. (example: 2.14)
operatingExpenses
always returned
Expenses related to operating the business.
double
A numeric type defining a number with fractional parts. (example: 2.14)
operatingIncome
always returned
Gross profit less operating expenses.
double
A numeric type defining a number with fractional parts. (example: 2.14)
interestExpense
always returned
The cost incurred by an entity for borrowed funds.
double
A numeric type defining a number with fractional parts. (example: 2.14)
otherIncomeExpenses
always returned
Income or expenses not related to normal business operations.
double
A numeric type defining a number with fractional parts. (example: 2.14)
preTaxIncome
always returned
Operating income net other income or expenses.
double
A numeric type defining a number with fractional parts. (example: 2.14)
incomeTax
always returned
The tax on the company's income.
double
A numeric type defining a number with fractional parts. (example: 2.14)
netIncome
always returned
Net income less all expenses and tax.
double
A numeric type defining a number with fractional parts. (example: 2.14)
basicEpsContOp
always returned
Income from continuing operations divided by the number of shares outstanding.
double
A numeric type defining a number with fractional parts. (example: 2.14)
basicEpsTotalOp
always returned
Net income divided by the number of shares outstanding.
double
A numeric type defining a number with fractional parts. (example: 2.14)
dilutedEpsContOp
always returned
Income from continuing operations divided by the number of diluted shares outstanding.
double
A numeric type defining a number with fractional parts. (example: 2.14)
dilutedEpsBNRI
always returned
Diluted EPS Before Non-Recurring Items
double
A numeric type defining a number with fractional parts. (example: 2.14)
dilutedEpsTotalOp
always returned
Net income divided by the number of diluted shares outstanding.
double
A numeric type defining a number with fractional parts. (example: 2.14)
ebitda
always returned
Earnings before interest, depreciation and amortization.
double
A numeric type defining a number with fractional parts. (example: 2.14)

Status Code Responses

200
OK
Success
400
Bad Request
The request was invalid, please see the message for more information.
500
Internal Server Error
Something is not working correctly, please contact support.


JSON

GET

GET https://ondemand.websol.barchart.com/getIncomeStatements.json?apikey=<YOUR API KEY>&symbols=IBM%2CAAPL%2CGOOG&frequency=Quarter&count=1&rawData=1
Host: ondemand.websol.barchart.com

POST

POST https://ondemand.websol.barchart.com/getIncomeStatements.json
Host: ondemand.websol.barchart.com
Content-Type: application/x-www-form-urlencoded
Content-Length: length

apikey=<YOUR API KEY>&symbols=IBM%2CAAPL%2CGOOG&frequency=Quarter&count=1&rawData=1

Response

{
    "status": {
        "code": 200,
        "message": "Success."
    },
    "results": [
        {
            "symbol": "IBM",
            "date": "2017-09-30",
            "sales": 19153000000,
            "costGoods": 10353000000,
            "grossProfit": 8800000000,
            "operatingExpenses": 5990000000,
            "operatingIncome": 2810000000,
            "interestExpense": 168000000,
            "otherIncomeExpenses": 423000000,
            "preTaxIncome": 3065000000,
            "incomeTax": 339000000,
            "netIncome": 2726000000,
            "basicEpsContOp": 2.93,
            "basicEpsTotalOp": 2.93,
            "dilutedEpsContOp": 2.92,
            "dilutedEpsBNRI": null,
            "dilutedEpsTotalOp": 2.92,
            "ebitda": 3986000000
        },
        {
            "symbol": "AAPL",
            "date": "2017-09-30",
            "sales": 52579000000,
            "costGoods": 32648000000,
            "grossProfit": 19931000000,
            "operatingExpenses": 6811000000,
            "operatingIncome": 13120000000,
            "interestExpense": 0,
            "otherIncomeExpenses": 797000000,
            "preTaxIncome": 13917000000,
            "incomeTax": 3203000000,
            "netIncome": 10714000000,
            "basicEpsContOp": 2.1026,
            "basicEpsTotalOp": 2.1,
            "dilutedEpsContOp": 2.0871,
            "dilutedEpsBNRI": null,
            "dilutedEpsTotalOp": 2.08,
            "ebitda": 15604000000
        },
        {
            "symbol": "GOOG",
            "date": "2017-09-30",
            "sales": 27772000000,
            "costGoods": 11148000000,
            "grossProfit": 16624000000,
            "operatingExpenses": 8842000000,
            "operatingIncome": 7782000000,
            "interestExpense": 0,
            "otherIncomeExpenses": 197000000,
            "preTaxIncome": 7979000000,
            "incomeTax": 1247000000,
            "netIncome": 6732000000,
            "basicEpsContOp": 9.7075,
            "basicEpsTotalOp": 9.71,
            "dilutedEpsContOp": 8.9665,
            "dilutedEpsBNRI": null,
            "dilutedEpsTotalOp": 9.57,
            "ebitda": 9543000000
        }
    ]
}

XML

GET

GET https://ondemand.websol.barchart.com/getIncomeStatements.xml?apikey=<YOUR API KEY>&symbols=IBM%2CAAPL%2CGOOG&frequency=Quarter&count=1&rawData=1
Host: ondemand.websol.barchart.com

POST

POST https://ondemand.websol.barchart.com/getIncomeStatements.xml
Host: ondemand.websol.barchart.com
Content-Type: application/x-www-form-urlencoded
Content-Length: length

apikey=<YOUR API KEY>&symbols=IBM%2CAAPL%2CGOOG&frequency=Quarter&count=1&rawData=1

Response


<?xml version="1.0" encoding="utf-8"?>
 <getIncomeStatements>
  <status>
   <code>200</code>
   <message>Success.</message>
  </status>
  <item>
   <symbol>IBM</symbol>
   <date>2017-09-30</date>
   <sales>19153000000</sales>
   <costGoods>10353000000</costGoods>
   <grossProfit>8800000000</grossProfit>
   <operatingExpenses>5990000000</operatingExpenses>
   <operatingIncome>2810000000</operatingIncome>
   <interestExpense>168000000</interestExpense>
   <otherIncomeExpenses>423000000</otherIncomeExpenses>
   <preTaxIncome>3065000000</preTaxIncome>
   <incomeTax>339000000</incomeTax>
   <netIncome>2726000000</netIncome>
   <basicEpsContOp>2.93</basicEpsContOp>
   <basicEpsTotalOp>2.93</basicEpsTotalOp>
   <dilutedEpsContOp>2.92</dilutedEpsContOp>
   <dilutedEpsBNRI></dilutedEpsBNRI>
   <dilutedEpsTotalOp>2.92</dilutedEpsTotalOp>
   <ebitda>3986000000</ebitda>
  </item>
  <item>
   <symbol>AAPL</symbol>
   <date>2017-09-30</date>
   <sales>52579000000</sales>
   <costGoods>32648000000</costGoods>
   <grossProfit>19931000000</grossProfit>
   <operatingExpenses>6811000000</operatingExpenses>
   <operatingIncome>13120000000</operatingIncome>
   <interestExpense>0</interestExpense>
   <otherIncomeExpenses>797000000</otherIncomeExpenses>
   <preTaxIncome>13917000000</preTaxIncome>
   <incomeTax>3203000000</incomeTax>
   <netIncome>10714000000</netIncome>
   <basicEpsContOp>2.1026</basicEpsContOp>
   <basicEpsTotalOp>2.1</basicEpsTotalOp>
   <dilutedEpsContOp>2.0871</dilutedEpsContOp>
   <dilutedEpsBNRI></dilutedEpsBNRI>
   <dilutedEpsTotalOp>2.08</dilutedEpsTotalOp>
   <ebitda>15604000000</ebitda>
  </item>
  <item>
   <symbol>GOOG</symbol>
   <date>2017-09-30</date>
   <sales>27772000000</sales>
   <costGoods>11148000000</costGoods>
   <grossProfit>16624000000</grossProfit>
   <operatingExpenses>8842000000</operatingExpenses>
   <operatingIncome>7782000000</operatingIncome>
   <interestExpense>0</interestExpense>
   <otherIncomeExpenses>197000000</otherIncomeExpenses>
   <preTaxIncome>7979000000</preTaxIncome>
   <incomeTax>1247000000</incomeTax>
   <netIncome>6732000000</netIncome>
   <basicEpsContOp>9.7075</basicEpsContOp>
   <basicEpsTotalOp>9.71</basicEpsTotalOp>
   <dilutedEpsContOp>8.9665</dilutedEpsContOp>
   <dilutedEpsBNRI></dilutedEpsBNRI>
   <dilutedEpsTotalOp>9.57</dilutedEpsTotalOp>
   <ebitda>9543000000</ebitda>
  </item>
 </getIncomeStatements>

CSV

GET

GET https://ondemand.websol.barchart.com/getIncomeStatements.csv?apikey=<YOUR API KEY>&symbols=IBM%2CAAPL%2CGOOG&frequency=Quarter&count=1&rawData=1
Host: ondemand.websol.barchart.com

POST

POST https://ondemand.websol.barchart.com/getIncomeStatements.csv
Host: ondemand.websol.barchart.com
Content-Type: application/x-www-form-urlencoded
Content-Length: length

apikey=<YOUR API KEY>&symbols=IBM%2CAAPL%2CGOOG&frequency=Quarter&count=1&rawData=1

Response

symbol,date,sales,costGoods,grossProfit,operatingExpenses,operatingIncome,interestExpense,otherIncomeExpenses,preTaxIncome,incomeTax,netIncome,basicEpsContOp,basicEpsTotalOp,dilutedEpsContOp,dilutedEpsBNRI,dilutedEpsTotalOp,ebitda
"IBM","2017-09-30","19153000000","10353000000","8800000000","5990000000","2810000000","168000000","423000000","3065000000","339000000","2726000000","2.93","2.93","2.92","","2.92","3986000000"
"AAPL","2017-09-30","52579000000","32648000000","19931000000","6811000000","13120000000","0","797000000","13917000000","3203000000","10714000000","2.1026","2.1","2.0871","","2.08","15604000000"
"GOOG","2017-09-30","27772000000","11148000000","16624000000","8842000000","7782000000","0","197000000","7979000000","1247000000","6732000000","9.7075","9.71","8.9665","","9.57","9543000000"


PHP

<?php

$ondemand = new SoapClient('https://ondemand.websol.barchart.com/service?wsdl');

$params = [
    'symbols' => 'IBM,AAPL,GOOG',
    'frequency' => 'Quarter',
    'count' => '1',
    'rawData' => '1',
];

$result = $ondemand->getIncomeStatements($params);
var_dump($result);

Classic ASP

Dim ondemand
Dim result

Set ondemand = Server.CreateObject("MSSOAP.SoapClient30")
ondemand.ClientProperty("ServerHTTPRequest") = True
ondemand.MSSoapInit("https://ondemand.websol.barchart.com/service?wsdl")

Set result = ondemand.getIncomeStatements("IBM,AAPL,GOOG", "Quarter", "1", "1")

Perl

use SOAP::Lite;
use SOAP::WSDL;

my $ondemand = SOAP::Lite
    -> service('https://ondemand.websol.barchart.com/service?wsdl');

my $result = $ondemand->getIncomeStatements('IBM,AAPL,GOOG', 'Quarter', '1', '1');

print $result;

Python

from suds.client import Client
ondemand = Client('https://ondemand.websol.barchart.com/service?wsdl')

result = client.service.getIncomeStatements('IBM,AAPL,GOOG', 'Quarter', '1', '1')

print result

Ruby

require 'savon'

ondemand = Savon.client(wsdl: 'https://ondemand.websol.barchart.com/service?wsdl')

response = ondemand.call(
    :getIncomeStatements,
    message: {
        symbols: 'IBM,AAPL,GOOG',
        frequency: 'Quarter',
        count: '1',
        rawData: '1',
    }
)

response.body