Skip to main content

Turnkey SDK Types

Generated type definitions for the Turnkey API based on the OpenAPI specification.

Why Pydantic?

This package uses Pydantic models to handle field name conflicts with Python keywords. For example, some Turnkey API requests include a from field (like v1EthSendTransactionIntent), which is a reserved keyword in Python.

Pydantic's Field aliasing allows us to:

  • Use from_ in Python code (avoiding syntax errors)
  • Automatically serialize to from when making API requests to Turnkey
class v1EthSendTransactionIntent(TurnkeyBaseModel):
    from_: str = Field(alias="from")
    # ... other fields

Installation

pip install -e .

Or install from the repository root:

pip install -e packages/sdk-types

Usage

from turnkey_sdk_types import (
    # Generated types will be available here
    # Example: CreateApiKeyRequest, CreateApiKeyResponse, etc.
)

Code Generation

This package uses code generation to create type definitions from the OpenAPI specification located in schema/public_api.swagger.json.

Generate Types

To regenerate the types:

cd packages/sdk-types
python scripts/generate.py

Development Setup

Install with dev dependencies to access code generation tools:

pip install -e ".[dev]"

Structure

sdk-types/
├── src/
│   └── turnkey_sdk_types/
│       ├── __init__.py        # Package exports
│       ├── types.py           # RequestType, SignedRequest (not generated)
│       ├── errors.py          # TurnkeyError, TurnkeyNetworkError (not generated)
│       └── generated/         # Auto-generated from OpenAPI spec
│           └── types.py       
├── scripts/
│   └── generate.py           # Code generation script
├── pyproject.toml
└── README.md

Requirements

  • Python >= 3.8

Development

Generated Types

The types in generated/types.py are automatically created from the OpenAPI specification at schema/public_api.swagger.json. These include all request/response models like v1EthSendTransactionIntent, CreateWalletBody, etc.

Important: Never edit files in src/turnkey_sdk_types/generated/ manually. They will be overwritten on the next generation run.

Non-Generated Types

Files outside the generated/ directory are maintained as part of the SDK and are not auto-generated:

  • types.py - Core SDK types like RequestType, SignedRequest
  • errors.py - Error classes like TurnkeyError, TurnkeyNetworkError

Metadata

Release files for turnkey-sdk-types 0.2.0

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

Source distribution (sdist)

Source distribution for turnkey-sdk-types 0.2.0
File Size Uploaded Provenance Actions
turnkey_sdk_types-0.2.0.tar.gz 88.5 kB With provenance Details for turnkey_sdk_types-0.2.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for turnkey-sdk-types 0.2.0
File Interpreter ABI Platform Actions
turnkey_sdk_types-0.2.0-py3-none-any.whl Python 3 none any Details for turnkey_sdk_types-0.2.0-py3-none-any.whl

Total release size: 175.5 kB

Release files / turnkey_sdk_types-0.2.0.tar.gz

Download URL turnkey_sdk_types-0.2.0.tar.gz
Size 88.5 kB
Tags Source
SHA-256 checksum
How to use checksums
7e0272360707d87bae91f7b52908f786258df9a35335f084d50b18e521a03091
BLAKE2b-256 checksum
How to use checksums
eab5b1af531a68757b17195d87c83967c7c1362d0f07480fbf7de990b57da7bf
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.7

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 19, 2026.

Transparency log

Release files / turnkey_sdk_types-0.2.0-py3-none-any.whl

Download URL turnkey_sdk_types-0.2.0-py3-none-any.whl
Size 87.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
ca20332d1f076632e61a875603f461ea89612b91d6b2c77907fe0a7f1a920818
BLAKE2b-256 checksum
How to use checksums
b5f73c67115dbbfcdabf8e66187dece7007f709014f4ed8512e783b7ef7e95c6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.7

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 19, 2026.

Transparency log

Security for turnkey-sdk-types 0.2.0

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.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for turnkey_sdk_types-0.2.0.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 19, 2026.

Transparency log

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