Skip to main content

CalcTree Python Client

GitHub Workflow Status

The CalcTree Python Client is a Python library that provides a convenient interface for interacting with the CalcTree API. It allows you to perform calculations using CalcTree's powerful calculation engine.

Installation

You can install the CalcTree Python Client using pip:

pip install calctree

Getting Started

To use the CalcTree Python Client, you need to obtain an API key from CalcTree. Once you have your API key, you can initialize the client and start running calculations.

Remember to replace YOUR_API_KEY with your actual API key, YOUR_PAGE_ID with the ID of the page you want to run calculations on, and YOUR_PARAM_NAME with the name of the parameter you want to set the value for.

import json

from calctree.client import CalcTreeClient

client = CalcTreeClient('YOUR_API_KEY')

res = client.run_calculation("YOUR_PAGE_ID",
                             [{"name": "YOUR_PARAM_NAME", "formula": "1000"}]
                             )

print("Result as a dictionary:")
print(result.to_dict())

print("Value of param 'cylinder_radius':")
print(result.get_param_value("cylinder_radius"))

print("List of params:")
print(result.get_params())

print("List of values:")
print(result.get_values())

Metadata

Release files for calctree 0.2.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for calctree 0.2.3
File Size Uploaded Provenance
calctree-0.2.3.tar.gz 3.6 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for calctree 0.2.3
File Interpreter ABI Platform
calctree-0.2.3-py3-none-any.whl Python 3 none any Details

Total release size: 8.2 kB

Release files / calctree-0.2.3.tar.gz

Download URL calctree-0.2.3.tar.gz
Size 3.6 kB
Tags Source
SHA-256 checksum
How to use checksums
c511fc20243a7f625a34562bf92f26e59e4a6d5b978b6bc84a4b4c80dc65e948
BLAKE2b-256 checksum
How to use checksums
5d8469efbd120c9d918ba0af73d41789d924093acb2905e230df63b71972e970
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.8.2 CPython/3.11.7 Darwin/23.4.0

Release files / calctree-0.2.3-py3-none-any.whl

Download URL calctree-0.2.3-py3-none-any.whl
Size 4.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
bd3c85d361e2fc75e99fffa2c1ad284a2bfd87065d17cbbe8051c7de9ad45ebb
BLAKE2b-256 checksum
How to use checksums
aabf1ef0060a909cfe356009a4cf337335562e04d1238bd700d570eb341cb07d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.8.2 CPython/3.11.7 Darwin/23.4.0

Security for calctree 0.2.3

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page