Skip to content
Docs
Get API key
News

News Streaming

Use the Trading Economics API streaming to obtain live news.

The streaming service uses WebSockets, which provide a bidirectional, full-duplex communications channel that operates over HTTP through a single TCP/IP socket connection. At its core, the WebSocket protocol facilitates message passing between a client and server. You can connect to our streaming service using the examples listed below. You need to subscribe to one or more instruments.

Get live news

Subscribe to news streaming data

Python
import tradingeconomics as te
import json
te.login('you_private_key')

def on_message(ws, message):
    print(json.loads(message))

te.subscribe('news')
te.run(on_message)
titledescriptioncountrycategoryurlimportancetopic
Australia Markit Services PMI Slows Down“The IHS Markit Australia Services PMI decreased to 53.4 in February 2021, down from…”AustraliaServices Sentiment/australia/services-sentiment2news
Australia Composite PMI Revised Downwardly“The IHS Markit Australia Composite PMI decreased to 53.7 in February 2021, down from…”AustraliaComposite PMI/australia/composite-pmi1news
“NZX Tops 12,400”“New Zealand’s main stock index rose above the 12,400 level on Wednesday, extending…”New ZealandStock Market/new-zealand/stock-market1news

Response fields

FieldTypeDescriptionExample
titlestringTitle“French 10-Year Bond Yield Approaches 1-Month High”
descriptionstringdescription“description”
countrystringcountry“The yield on the French 10-year OAT rose to 2.9% in mid-April…”
categorystringcategory“Government Bond 10Y”
urlstringurl“/france/government-bond-yield”
importancenumberLowest 0 to 3 highest3
topicstringTopic subscribed“news”