Skip to content

Python package for downloading economic data from the International Monetary Fund JSON RESTful API endpoint.

License

Notifications You must be signed in to change notification settings

Promptly-Technologies-LLC/imfp

Repository files navigation

imfp

Tests PyPI Version Code style: black

imfp, by Christopher C. Smith, is a Python package for downloading data from the International Monetary Fund's RESTful JSON API.

📚 Full Documentation

Installation

pip install -q --upgrade imfp

Quick Start

import imfp

# Get list of available databases
databases = imfp.imf_databases()

# Get parameters for a specific database (e.g., PCPS - Primary Commodity Price System)
params = imfp.imf_parameters("PCPS")

# Fetch data with specific parameters
df = imfp.imf_dataset(
    database_id="PCPS",
    freq=["A"],
    start_year=2000,
    end_year=2015
)

Key Features

  • Comprehensive access to IMF's extensive economic databases
  • Parameter discovery
  • Rate limit and bandwidth management
  • Returns data in pandas DataFrames

Contributing

We welcome contributions to improve imfp! Here's how you can help:

  1. If you find a bug, please open an issue
  2. To fix a bug:
    • Fork and clone the repository and open a terminal in the repository directory
    • Install uv with curl -LsSf https://astral.sh/uv/install.sh | sh
    • Install the dependencies with uv sync --extra dev
    • Install a git hook to enforce conventional commits with curl -o- https://raw.githubusercontent.com/tapsellorg/conventional-commits-git-hook/master/scripts/install.sh | sh
    • Create a fix, commit it with an "Angular-style Conventional Commit" message, and push it to your fork
    • Open a pull request to our main branch

Note that if you want to change and/or render the documentation, you will need to install the Quarto CLI tool.

Version incrementing, package building, testing, changelog generation, documentation rendering, publishing to PyPI, and Github release creation is handled automatically by the GitHub Actions workflow based on the commit messages.

About

Python package for downloading economic data from the International Monetary Fund JSON RESTful API endpoint.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Contributors 4

  •  
  •  
  •  
  •  

Languages