Skip to main content

No project description provided

Project description

project-logo

FMP-PY

Empower Your Financial Insights with Seamless FMP API Integration

GitHub Actions Workflow Status license last-commit repo-top-language repo-language-count

Developed with the software and tools below.

precommit Poetry Python GitHub%20Actions pandas


Table of Contents

Overview

The fmp-py project offers a comprehensive Python interface for interacting with financial market data, integrating the Financial Modeling Prep (FMP) API to retrieve and analyze diverse financial datasets. It supports functionalities like accessing company information, historical stock prices, financial statements, stock lists, and upgrades/downgrades. The package provides tools for enhanced financial analysis, including data models for price targets and valuations. Its modular structure ensures seamless data retrieval and processing, making it a valuable resource for financial analysts, researchers, and developers aiming to perform in-depth market analysis and informed investment decisions.

Documentation


Features

Feature Description
โš™๏ธ Architecture The project is structured as a Python package for financial data analysis. It integrates with the Financial Modeling Prep API, providing modules for various financial data aspects.
๐Ÿ”ฉ Code Quality The project uses automated tools like pre-commit and ruff for code style and quality enforcement, ensuring consistency and high standards.
๐Ÿ“„ Documentation Documentation is enhanced using sphinx, myst-parser, and sphinx-autoapi, indicating a focus on comprehensive and user-friendly documentation.
๐Ÿ”Œ Integrations Key integration is with the Financial Modeling Prep API, enabling comprehensive access to various financial data points.
๐Ÿงฉ Modularity Codebase is highly modular, with distinct modules for different data aspects like company information, historical data, financial statements, etc., ensuring reusability.
๐Ÿงช Testing Uses requests-mock for API testing and GitHub Actions for CI/CD, ensuring robust testing and continuous integration.
โšก๏ธ Performance Efficient handling and processing of financial data with modules returning results in pandas DataFrame format for speed and usability in analysis.
๐Ÿ›ก๏ธ Security Uses python-dotenv for managing sensitive data, emphasizing secure data handling practices.
๐Ÿ“ฆ Dependencies Utilizes key libraries like pandas for data manipulation, requests for HTTP requests, and pendulum for date handling, among others.
๐Ÿš€ Scalability Designed for efficiency in data retrieval and processing, though specifics on load handling are not detailed, the modular design suggests good scalability potential.

Repository Structure

โ””โ”€โ”€ fmp-py/
    โ”œโ”€โ”€ .github
    โ”‚   โ”œโ”€โ”€ ISSUE_TEMPLATE
    โ”‚   โ”‚   โ”œโ”€โ”€ bug_report.md
    โ”‚   โ”‚   โ”œโ”€โ”€ custom.md
    โ”‚   โ”‚   โ””โ”€โ”€ feature_request.md
    โ”‚   โ””โ”€โ”€ workflows
    โ”‚       โ””โ”€โ”€ test-package.yaml
    โ”œโ”€โ”€ CODE_OF_CONDUCT.md
    โ”œโ”€โ”€ LICENSE
    โ”œโ”€โ”€ README.md
    โ”œโ”€โ”€ SECURITY.md
    โ”œโ”€โ”€ docs
    โ”‚   โ”œโ”€โ”€ Makefile
    โ”‚   โ”œโ”€โ”€ make.bat
    โ”‚   โ”œโ”€โ”€ rtd_requirements.txt
    โ”‚   โ””โ”€โ”€ source
    โ”‚       โ”œโ”€โ”€ conf.py
    โ”‚       โ”œโ”€โ”€ index.md
    โ”‚       โ””โ”€โ”€ notebooks
    โ”‚           โ””โ”€โ”€ usage.ipynb
    โ”œโ”€โ”€ poetry.lock
    โ”œโ”€โ”€ pyproject.toml
    โ”œโ”€โ”€ pytest.ini
    โ”œโ”€โ”€ src
    โ”‚   โ””โ”€โ”€ fmp_py
    โ”‚       โ”œโ”€โ”€ __init__.py
    โ”‚       โ”œโ”€โ”€ fmp_base.py
    โ”‚       โ”œโ”€โ”€ fmp_charts.py
    โ”‚       โ”œโ”€โ”€ fmp_company_information.py
    โ”‚       โ”œโ”€โ”€ fmp_company_search.py
    โ”‚       โ”œโ”€โ”€ fmp_financial_statements.py
    โ”‚       โ”œโ”€โ”€ fmp_historical_data.py
    โ”‚       โ”œโ”€โ”€ fmp_price_targets.py
    โ”‚       โ”œโ”€โ”€ fmp_quote.py
    โ”‚       โ”œโ”€โ”€ fmp_statement_analysis.py
    โ”‚       โ”œโ”€โ”€ fmp_stock_list.py
    โ”‚       โ”œโ”€โ”€ fmp_upgrades_downgrades.py
    โ”‚       โ”œโ”€โ”€ fmp_valuation.py
    โ”‚       โ””โ”€โ”€ models
    โ”‚           โ”œโ”€โ”€ company_information.py
    โ”‚           โ”œโ”€โ”€ price_targets.py
    โ”‚           โ”œโ”€โ”€ quote.py
    โ”‚           โ”œโ”€โ”€ statement_analysis.py
    โ”‚           โ”œโ”€โ”€ upgrades_downgrades.py
    โ”‚           โ””โ”€โ”€ valuation.py
    โ””โ”€โ”€ tests
        โ”œโ”€โ”€ __init__.py
        โ”œโ”€โ”€ test_fmp_company_information.py
        โ”œโ”€โ”€ test_fmp_company_search.py
        โ”œโ”€โ”€ test_fmp_financial_statements.py
        โ”œโ”€โ”€ test_fmp_historical_data.py
        โ”œโ”€โ”€ test_fmp_price_targets.py
        โ”œโ”€โ”€ test_fmp_quote.py
        โ”œโ”€โ”€ test_fmp_statement_analysis.py
        โ”œโ”€โ”€ test_fmp_stock_list.py
        โ”œโ”€โ”€ test_fmp_upgrades_downgrades.py
        โ””โ”€โ”€ test_fmp_valuation.py

Modules

.
File Summary
pyproject.toml Define the projects metadata and dependencies, streamline the build and packaging processes, and set up configuration standards for development and testing. Enhance code quality and documentation through automated tools and enforce consistent coding styles and practices across the repository.
src.fmp_py
File Summary
fmp_upgrades_downgrades.py Retrieve and process stock upgrade and downgrade data from the Financial Modeling Prep API. Provide methods to access consensus data, company-specific gradings, and RSS feed updates, returning results in pandas DataFrame format for easy analysis. Enhance the repositorys capability to handle financial data comprehensively.
fmp_financial_statements.py The code file fmp_company_information.py under the fmp-py repository plays a crucial role in managing and retrieving company information. It is designed to interface with external APIs or databases to fetch detailed corporate data such as governance structures, fundamental descriptions, and key financial metrics. This functionality is critical within the broader architecture of the repository, which focuses on providing comprehensive financial market data through various modules. The fmp_company_information.py integrates seamlessly with other components like financial statements and historical data, ensuring users have access to a holistic suite of financial information.
fmp_company_search.py Facilitate company search functionality on Financial Modeling Prep (FMP) based on various identifiers like ISIN, CUSIP, CIK, ticker, and company name. Offer diverse search capabilities to retrieve detailed company information, ensuring comprehensive and precise data access aligned with the parent repositorys architectural design.
fmp_historical_data.py Retrieve historical stock price data, including daily and intraday data, for specified symbols and date ranges. Provide essential financial metrics and calculations, such as VWAP, to support investment analysis. Integrate efficiently with the Financial Modeling Prep API and ensure data is appropriately formatted and rounded for end-user consumption.
fmp_quote.py This code file is part of the fmp_py repository, a Python package structured for financial data analysis and manipulation. The repository encapsulates various modules focused on different aspects of financial market data. The primary purpose of the repository is to provide a comprehensive toolkit for interacting with financial market data, facilitating tasks such as fetching company information, historical data, financial statements, stock lists, and more.The critical features of the code file include:-Accessing and managing financial market data from multiple perspectives, including company information, historical data, and financial statements.-Supporting data analysis and visualization through various modules that cater to different data types and user needs.-Enabling seamless integration and usage within other projects through a well-defined API, enhancing reproducibility and consistency in financial data handling.Overall, this code file contributes significantly to the broader architecture of the fmp_py repository by offering specialized functionality to handle diverse financial datasets.
fmp_statement_analysis.py Src/fmp_py/fmp_financial_statements.pyThe fmp_financial_statements.pyfile serves as a critical component within thefmp_pydirectory of the repository. It is responsible for handling the retrieval and processing of financial statement data, providing a structured way to access various financial reports such as income statements, balance sheets, and cash flow statements. This functionality is integral to the repository's broader goal of offering comprehensive financial data handling and analysis tools. By enabling efficient access to financial statements, this file supports advanced financial analytics and decision-making processes within the overall architecture.#### Parent Repository:fmp-pyThe fmp-py` repository is designed to provide a Python-based interface for interacting with financial market data. It is structured to facilitate comprehensive data retrieval, processing, and analysis through robust and modular code components. This serves the end goal of allowing users to perform in-depth financial analysis leveraging various data points and insights offered by the repository. The architecture is further supported by thorough documentation, testing workflows, and a focus on community-driven enhancements as indicated by the presence of issue templates and a code of conduct.
fmp_company_information.py Summary of fmp_company_information.pyThe fmp_company_information.py module within the fmp-py repository provides functionalities for retrieving detailed company information. It serves as a crucial component of the parent architecture by enabling users to access comprehensive data about different companies, which includes general information, business summaries, and profiles. This aids in forming a holistic view of the companies being queried, thereby enhancing the repositorys capability to serve as a robust financial data retrieval and analysis tool. This module complements other files in the src/fmp_py directory by focusing specifically on company-centric data and integrating seamlessly with broader financial data functionalities.
fmp_valuation.py The file fmp_company_information.py within the fmp-py repository is primarily responsible for retrieving and managing company-specific data, such as profiles, key metrics, and other relevant details. This functionality is crucial within the broader architecture of the fmp-py project, as it allows users to access and manipulate company information seamlessly. The module integrates with other components like financial statements and historical data modules, facilitating comprehensive financial analysis and research workflows.
fmp_base.py Serve as the foundational API client for interacting with the Financial Modeling Prep service, managing authentication and GET requests. Provide utility for type-safe data cleaning and ensure efficient handling of API sessions.
fmp_stock_list.py Interact with the Financial Modeling Prep API to retrieve various stock lists and related financial data, including available indexes, exchange symbols, symbol changes, and more. The FmpStockList class aggregates these functionalities, providing seamless data access and processing for financial applications within the repositorys architecture.
fmp_charts.py Fmp_stock_list.pyThe fmp_stock_list.pyfile is part of thefmp-pyrepository, which aims to provide a comprehensive Python package for interacting with financial market data. This specific file focuses on retrieving and managing lists of stocks, leveraging the functionalities of the parent repository to facilitate users in accessing up-to-date stock information. It integrates seamlessly with other modules in thesrc/fmp_py` directory, enabling users to fetch stock lists based on various criteria, which can be crucial for tasks like portfolio management, market analysis, and financial research. The file plays an essential role in enhancing the repositorys capability to deliver diverse financial datasets to end-users efficiently.
fmp_price_targets.py Provide comprehensive methods to retrieve price target data from the Financial Modeling Prep API, including consensus, summary, and detailed price targets for a given stock symbol, thereby enhancing investment decision-making capabilities within the fmp-py repositorys financial data analysis framework.
src.fmp_py.models
File Summary
price_targets.py Define data structures for representing price target consensus and summary information, facilitating organized and efficient handling of financial data within the repositorys broader architecture for financial market analysis.
statement_analysis.py Defines data structures essential for financial statement analysis within the parent repository. These structures encapsulate various financial scores, ratios, and key metrics, supporting comprehensive financial evaluations and data manipulation across multiple modules, enhancing the repositorys capability to offer detailed and structured financial insights.
company_information.py Define various data models related to company information, including stock peers, core details, market cap, executive compensation, and overall company profile, which provide structured data representations within the repositorys financial data processing architecture.
quote.py Define multiple data models central for representing various types of financial market quotes, facilitating the retrieval and manipulation of real-time and historical data related to stocks, forex, crypto, and after-market trading within the fmp-py repository architecture. These models underpin the data structure consistency and integrity across the application.
upgrades_downgrades.py Defines an UpgradesDowngrades data model incorporating key attributes related to stock recommendations, such as symbol, buy/sell ratings, and consensus. Functions as a crucial component for organizing and retrieving rating data within the broader architecture of the financial market data repository.
valuation.py Define data structures for managing discounted cash flow and company rating information, essential for valuation analysis within the repositorys financial modeling capabilities. Offer comprehensive attributes for each structure, facilitating detailed and accurate financial assessments and recommendations.
.github.workflows
File Summary
test-package.yaml Facilitate automated testing by configuring the CI/CD pipeline to run tests on the repository. Ensures the codebase remains robust and error-free by triggering test suites whenever changes are pushed, thereby maintaining code integrity and reliability throughout the development lifecycle.

Contributing

Contributions are welcome! Here are several ways you can contribute:

Contributing Guidelines
  1. Fork the Repository: Start by forking the project repository to your github account.
  2. Clone Locally: Clone the forked repository to your local machine using a git client.
    git clone https://github.com/TexasCoding/fmp-py
    
  3. Create a New Branch: Always work on a new branch, giving it a descriptive name.
    git checkout -b new-feature-x
    
  4. Make Your Changes: Develop and test your changes locally.
  5. Commit Your Changes: Commit with a clear message describing your updates.
    git commit -m 'Implemented new feature x.'
    
  6. Push to github: Push the changes to your forked repository.
    git push origin new-feature-x
    
  7. Submit a Pull Request: Create a PR against the original project repository. Clearly describe the changes and their motivations.
  8. Review: Once your PR is reviewed and approved, it will be merged into the main branch. Congratulations on your contribution!
Contributor Graph


License

This project is protected under the MIT License. For more details, refer to the LICENSE file.

Return


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

fmp_py-0.0.13.1.tar.gz (51.0 kB view hashes)

Uploaded Source

Built Distribution

fmp_py-0.0.13.1-py3-none-any.whl (51.5 kB view hashes)

Uploaded Python 3

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