Skip to main content

Simple Python API client for accessing data on the Bureau of Economic Analysis application programming interface.

Project description

Simple BEA Client


pip install beasy


This library is an unofficial Python API client for U.S Bureau of Economic Analysis API.

You can view the developer guide for the API here. This is not the user guide for this client library. However, it will provide useful information on how this library interacts with the API.


Other BEA client libraries exist for accessing the API. However, in my opinion, they are either too complicated or poorly conceived. Therefore, this library is a simple and straightforward client.

If complicated sorting, filtering, or formatting functions are desired, they will be added as utility functions that are not part of the client module.


Currently, the library is designed to return JSON response objects from the BEA API, not XML.

from beasy.beasy import Bea
API_KEY = 'your_api_key'
client = Bea(API_KEY)

Get Dataset List

"...retrieves a list of the datasets currently offered."


Get Parameter List

"...retrieves a list of the parameters(required and optional) for a particular dataset."



Get Parameter Values

"...retrieves a list of the valid values for a particular parameter."



Get Parameter Values Filtered

"...retrieves a list of the valid values for a particular parameter based on other provided parameters."

client.[table_name].getParameterValuesFiltered(targetParameter, **kwargs)

client.Regional.getParameterValuesFiltered('LineCode', 'SAINC1')

Get Data


client.Regional.getData(TableName='CAINC1', LineCode='3', GeoFIPS='DE', Year='2014')

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

beasy-1.0.0.tar.gz (4.2 kB view hashes)

Uploaded source

Built Distribution

beasy-1.0.0-py3-none-any.whl (5.0 kB view hashes)

Uploaded py3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page