Skip to main content

No project description provided

Project description

fractal-model-api

A small Python client for interactions with the Fractal Model API.

Requirements

  • Python 3.8+
  • Microsoft Excel (Desktop edition):
    • Windows: Excel 2010+
    • macOS: Excel 2016+

Installation

Install the package (and optionally python-dotenv if you prefer using a .env file):

pip install fractal-model-api python-dotenv

Usage

This project does not automatically load a .env file. You must either set the required environment variables on your system or explicitly load the .env file from your script.

  1. Create a file named .env in the project root with your API credentials:
FM_API_KEY=your_api_key_here
FM_API_SECRET=your_api_secret_here

2a. Easiest for non-technical users — add one line to your script to load the .env file (requires python-dotenv):

import asyncio
from dotenv import load_dotenv

load_dotenv()  # loads environment variables from ` .env`

from fractal_model_api import FractalModelAPIClient

async def main():
    client = FractalModelAPIClient()
    optimized = await client.get_optimized_schedule_lt(file_path="path/to/your/input_file")
    print(optimized)

if __name__ == "__main__":
    asyncio.run(main())

2b. Or set environment variables in your terminal before running your script:
For linux:

export FM_API_KEY=your_api_key_here
export FM_API_SECRET=your_api_secret_here
python your_script.py

For Windows (cmd):

set FM_API_KEY=your_api_key_here
set FM_API_SECRET=your_api_secret_here
python your_script.py

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

fractal_model_api-0.2.0.tar.gz (12.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

fractal_model_api-0.2.0-py3-none-any.whl (15.5 kB view details)

Uploaded Python 3

File details

Details for the file fractal_model_api-0.2.0.tar.gz.

File metadata

  • Download URL: fractal_model_api-0.2.0.tar.gz
  • Upload date:
  • Size: 12.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.2.1 CPython/3.13.11 Linux/6.12.63-1-lts

File hashes

Hashes for fractal_model_api-0.2.0.tar.gz
Algorithm Hash digest
SHA256 dbadcad1db275aa88101e2aeb3c376dbad6f699458701466d8b4a4b4460e42bc
MD5 6985811c7c505cc93ad1227966e0a22f
BLAKE2b-256 3487120a14a5bdf1f8b5b0fbcea5b802ff16a42469e27d32dd880bb49e347a12

See more details on using hashes here.

File details

Details for the file fractal_model_api-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: fractal_model_api-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 15.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.2.1 CPython/3.13.11 Linux/6.12.63-1-lts

File hashes

Hashes for fractal_model_api-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 f5f342e1f3885ecde5b7a214cc0bbdae8a9f11cf826a738f0337085e2d334e9b
MD5 911c9dee5271cc5b85128f74b92fad96
BLAKE2b-256 27af1869b9aec99470e726a0d9977d8c3b7940bb3e6c86cbb08868efff312376

See more details on using hashes here.

Supported by

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