Metadata-Version: 2.5
Name: runapi-typesafe
Version: 0.4.0
Summary: RunAPI TypeSafe SDK for Jev structured decision workflows in JavaScript, Python, Ruby, Go, Java, and PHP
Project-URL: Homepage, https://runapi.ai/models/jev
Project-URL: Documentation, https://runapi.ai/docs/resources/sdks
Project-URL: Source, https://github.com/runapi-ai/typesafe-sdk
Project-URL: Issues, https://github.com/runapi-ai/typesafe-sdk/issues
Project-URL: Changelog, https://github.com/runapi-ai/typesafe-sdk/blob/main/CHANGELOG.md
Project-URL: Release Notes, https://github.com/runapi-ai/typesafe-sdk/releases/tag/python%2Fv0.4.0
Author-email: RunAPI <contact@runapi.ai>
License-Expression: Apache-2.0
License-File: LICENSE
Keywords: api,golang,gradle,java,jev,maven,python,ruby,runapi,runapi-ai,sdk,typesafe,typescript
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Programming Language :: Python :: 3.14
Requires-Python: >=3.10
Requires-Dist: runapi-core~=0.12.0
Description-Content-Type: text/markdown

# TypeSafe Python SDK for RunAPI

The TypeSafe Python SDK is the language-specific package for TypeSafe Jev on RunAPI. Use this package when your application needs typed request builders, calibrated decision answers, and consistent RunAPI errors in Python.

This README is the Python package guide inside the public `typesafe-sdk` repository. For the repository overview, start at `../README.md`; for model details, use https://runapi.ai/models/jev; for API reference, use https://runapi.ai/docs/api/typesafe/system-one; for SDK docs, use https://runapi.ai/docs/resources/sdks.

## Install

```bash
pip install runapi-typesafe
```

## Quick start

```python
from runapi.typesafe import TypesafeClient

client = TypesafeClient()  # reads RUNAPI_API_KEY, or pass api_key="sk-..."
result = client.system_one.run(
    model="jev-latest",
    state={"candidate": "Option A", "context": "Choose the best candidate."},
    questions={
        "recommendation": {
            "type": "choice",
            "instructions": "Which candidate should be selected?",
            "criteria": {"Option A": "The candidate is Option A.", "Option B": "The candidate is Option B."},
        }
    },
)
print(result.answers)
```

`system-one` is synchronous. Call `run` and read `answers` from the response. Keep `RUNAPI_API_KEY` in the environment or your secret manager; never commit API keys.

## Language notes

Use keyword arguments on `client.system_one.run`. `state` may be text or a structured object. `questions` is a map of named Choice, Score, or Noul questions.

## Links

- Model page: https://runapi.ai/models/jev
- SDK docs: https://runapi.ai/docs/resources/sdks
- Product docs: https://runapi.ai/docs/api/typesafe/system-one
- Pricing and rate limits: https://runapi.ai/models/jev/jev-latest
- Provider comparison: https://runapi.ai/providers/typesafe
- Full catalog: https://runapi.ai/models
- Repository: https://github.com/runapi-ai/typesafe-sdk

## License

Licensed under the Apache License, Version 2.0.
