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.1.8.tar.gz (12.3 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.1.8-py3-none-any.whl (15.3 kB view details)

Uploaded Python 3

File details

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

File metadata

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

File hashes

Hashes for fractal_model_api-0.1.8.tar.gz
Algorithm Hash digest
SHA256 612823e274bdd4e06501a6921e270245dce0ec4671782a799ea7025f468575c1
MD5 3d8e2e2da22170e52477b82c783319a5
BLAKE2b-256 25fd0950a741ca34f0f0b8b5d28ab9fe2684eb4f1d81584c201a96bf610f16ff

See more details on using hashes here.

File details

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

File metadata

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

File hashes

Hashes for fractal_model_api-0.1.8-py3-none-any.whl
Algorithm Hash digest
SHA256 fcfa5a2f6597df18242db47df0d32717e40e7bee3f00af215d855fea217a3b3c
MD5 b9e050fefb28aa08abfa09ce26e033f9
BLAKE2b-256 d097439a746109a260df74de003a5f4a55c905aae9403b3f25e1a07196ee2587

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