Skip to content

Accern/accern-python

Repository files navigation

Accern for Python

https://raw.githubusercontent.com/Accern/accern-python/master/docs/_static/accern.png

pypi circleci sphinx

A python library to consume Accern's V4 REST API for Titan streaming/historical data.

Overview

Accern is a fast-growing NYC startup that is disrupting the way quantitative hedge funds can gain a competitive advantage using news and social media data. It currently has the world’s largest financial news coverage, covering over 1 billion public news websites, blogs, financial documents, and social media websites. Furthermore, Accern derives proprietary analytics from each news story to help quantitative hedge funds make accurate trading decisions.

Accern consolidates multiple news data feeds into one to help drastically reduce costs of both small and large hedge funds. With Accern proprietary data filters, we are able to deliver relevant articles to clients with a 99 percent accuracy rate. Accern’s delivery mechanism is a RESTful API where it delivers derived analytics from news articles, including the original article URLs so quantitative hedge funds can derive their own analytics in-house from the relevant articles.

The Accern library for Python helps users get fast, flexible data structures from Accern's V4 Titan streaming/historical data.

Install

pip install accern

Quick Start

  1. Contact support@accern.com. and inquire about an Accern API token.
  2. To quickly start using the Accern API, create an API instance and pass your token:
from accern import API
token = 'YOUR TOKEN'
Client = API(token)
  1. Pass params to get filtered data and make an API request.
schema = {
    'filters': {
        'entity_ticker': 'AAPL'
    }
}
resp = Client.request(schema)
  1. Accern Historical API will be available in the future releases.

For more information see the full documentation on Read The Docs.

Non default I/O urls

The I/O urls can be changed by defining a config file:

from accern import set_config_file

set_config_file("new-config-file.json")

The expected content of the config file can be found in accern/config.py under CONFIG_DEFAULT.