Skip to main content

A Python wrapper to easily retrieve data from the BankFind Suite official API from FDIC in pandas format.

Project description

fdicapi

This repository contains A Python wrapper to easily retrieve data from the BankFind Suite official API from FDIC in pandas format.

Overview

FDIC’s application programming interface (API) lets developers access FDIC’s publically available bank data. There are eight endpoints that the FDIC has exposed to the public:

  • institutions: Returns a list of financial institutions.
  • locations: Returns locations/branches of financial institutions.
  • history: Returns details on structure change events
  • financials: Returns financial information for financial institutions
  • summary: Returns aggregate financial and structure data, subtotaled by year, regarding finanical institutions.
  • failures: Returns details on failed financial institutions.
  • sod: Returns summary of deposits information for institutions
  • demographics: Returns summary of demographic information

Requirements

  • Python 3.9 or higher.
  • Requests
  • Pandas

Installation

pip install fdicapi

Endpoints

get_institutions

Get Financial Institutions.

from fdicapi.structure import get_institutions
df = get_institutions(**kwargs)

Keyword Arguments

Parameter Type Description
filters str The filter for the bank search.
search str Flexible text search against institution records - currently only supporting name search. Search supports text search and fuzzy matching, as opposed to filters that are exact matches.
fields str Comma delimited list of fields to search.
sort_by str Field name by which to sort returned data.
sort_order str Indicator if ascending (ASC) or descending (DESC).
limit int The number of records to return. Default is 10 and maximum is 10,000.
offset int The offset of page to return.

Returns

  • pd.DataFrame: Return a pandas DataFrame of financial institutions.

get_locations

Get Institution Locations.

from fdicapi.structure import get_locations
df = get_locations(**kwargs)

Keyword Arguments

Parameter Type Description
filters str The filter for the location search.
fields str Comma delimited list of fields to search.
sort_by str Field name by which to sort returned data.
sort_order str Indicator if ascending (ASC) or descending (DESC).
limit int The number of records to return. Default is 10 and maximum is 10,000.
offset int The offset of page to return.

Returns

  • pd.DataFrame: Returns locations/branches of financial institutions.

get_history

Get Detail on Structure Change Events.

from fdicapi.history import get_history
df = get_history(**kwargs)

Keyword Arguments

Parameter Type Description
filters str The filter criteria that refines the records returned.
search str Flexible text search against institution records Search supports text search and fuzzy matching, as opposed to filters that are exact matches.
fields str Comma delimited list of fields to search.
sort_by str Field name by which to sort returned data.
sort_order str Indicator if ascending (ASC) or descending (DESC).
limit int The number of records to return. Default is 10 and maximum is 10,000.
offset int The offset of page to return.
agg_by str The field by which data will be aggregated.
agg_term_fields str The field(s) for which aggregations will be counted for each unique term.
agg_limit int The limit on how many aggregated results will be displayed.

Returns

  • pd.DataFrame: Return a pandas DataFrame of financial institutions.

get_financials

Get Financial Information for FDIC Insured Institutions

from fdicapi.financials import get_financials
df = get_financials(**kwargs)

Keyword Arguments

Parameter Type Description
filters str The filter criteria that refines the records returned.
fields str Comma delimited list of fields with quarterly financial data to return.
sort_by str Field name by which to sort returned data.
sort_order str Indicator if ascending (ASC) or descending (DESC).
limit int The number of records to return. Default is 10 and maximum is 10,000.
offset int The offset of page to return.
agg_by str The field by which data will be aggregated.
agg_term_fields str The field(s) for which aggregations will be counted for each unique term.
agg_sum_fields str The field(s) for which aggregations will be summed or aggregated.
agg_limit int The limit on how many aggregated results will be displayed.

Returns

  • pd.DataFrame: Returns financial information for financial institutions,

get_summary

Get Historical Aggregate Data by Year.

from fdicapi.historical import get_summary
df = get_summary(**kwargs)

Keyword Arguments

Parameter Type Description
filters str The filter criteria that refines the records returned.
fields str Comma delimited list of fields with quarterly financial data to return.
sort_by str Field name by which to sort returned data.
sort_order str Indicator if ascending (ASC) or descending (DESC).
limit int The number of records to return. Default is 10 and maximum is 10,000.
offset int The offset of page to return.
agg_by str The field by which data will be aggregated.
agg_term_fields str The field(s) for which aggregations will be counted for each unique term.
agg_sum_fields str The field(s) for which aggregations will be summed or aggregated.
agg_limit int The limit on how many aggregated results will be displayed.
max_value int The field by which the max value is desired.
max_value_by int The field that will be used to determine unique records, similar to a primary key (i.e. CERT, ).

Returns

  • pd.DataFrame: Returns aggregate financial and structure data, subtotaled by year, regarding finanical institutions.

get_failures

Get detail on historical bank failures from 1934 to present.

from fdicapi.failures import get_failures
df = get_failures(**kwargs)

Keyword Arguments

Parameter Type Description
filters str The filter criteria that refines the records returned.
fields str Comma delimited list of fields with quarterly financial data to return.
sort_by str Field name by which to sort returned data.
sort_order str Indicator if ascending (ASC) or descending (DESC).
limit int The number of records to return. Default is 10 and maximum is 10,000.
offset int The offset of page to return.
total_fields str Fields to sum up (in a totals response object). Only numeric columns are valid.
subtotal_fields str The field by which data will be subtotaled (in totals response object). Only categorical values should be used.
agg_by str The field by which data will be aggregated.
agg_term_fields str The field(s) for which aggregations will be counted for each unique term.
agg_sum_fields str The field(s) for which aggregations will be summed or aggregated.
agg_limit int The limit on how many aggregated results will be displayed.

Returns

  • pd.DataFrame: Returns details on failed financial institutions.

get_sod

Get Summary of Deposits Information for FDIC Insured Institutions.

from fdicapi.sod import get_sod
df = get_sod(**kwargs)

Keyword Arguments

Parameter Type Description
filters str The filter criteria that refines the records returned.
fields str Comma delimited list of fields with quarterly financial data to return.
sort_by str Field name by which to sort returned data.
sort_order str Indicator if ascending (ASC) or descending (DESC).
limit int The number of records to return. Default is 10 and maximum is 10,000.
offset int The offset of page to return.
agg_by str The field by which data will be aggregated.
agg_term_fields str The field(s) for which aggregations will be counted for each unique term.
agg_sum_fields str The field(s) for which aggregations will be summed or aggregated.
agg_limit int The limit on how many aggregated results will be displayed.

Returns

  • pd.DataFrame: Returns summary of deposits information for institutions.

get_demographics

Get Summary of Demographic Information.

from fdicapi.demographics import get_demographics
df = get_demographics(**kwargs)

Keyword Arguments

Parameter Type Description
filters str The filter criteria that refines the records returned.

Returns

  • pd.DataFrame: Returns summary of demographic information.

API Documentation

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

fdicapi-0.0.1.tar.gz (7.5 kB view details)

Uploaded Source

Built Distribution

fdicapi-0.0.1-py3-none-any.whl (9.6 kB view details)

Uploaded Python 3

File details

Details for the file fdicapi-0.0.1.tar.gz.

File metadata

  • Download URL: fdicapi-0.0.1.tar.gz
  • Upload date:
  • Size: 7.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.9.20

File hashes

Hashes for fdicapi-0.0.1.tar.gz
Algorithm Hash digest
SHA256 874ee22c082155721f253568f06e8b5510a9eec1c14982f16616851e6735ca87
MD5 74fd55308b667d4c235f0bc4588d51f2
BLAKE2b-256 50c77bc0d90d512e9db364b1ccf238006b0b8a64afb72e5a80dd53346fbde875

See more details on using hashes here.

File details

Details for the file fdicapi-0.0.1-py3-none-any.whl.

File metadata

  • Download URL: fdicapi-0.0.1-py3-none-any.whl
  • Upload date:
  • Size: 9.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.9.20

File hashes

Hashes for fdicapi-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 e35ae8a78299860eebfe083caaa8dd19571edf0ed25d302611e8517e8db129ed
MD5 9271e8b506f00d572e6496e9628436cf
BLAKE2b-256 57469da9dffe61283c208f4a4dc37025b8727928337c48965529869f4dd06a4b

See more details on using hashes here.

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