recraft-sdk (0.1.0)

Published 2026-08-02 19:55:16 +00:00 by ldraney

Installation

pip install --index-url  recraft-sdk

About this package

Python SDK wrapping the Recraft image generation API

recraft-sdk

Pytest SDK proving the Recraft API. Validates endpoints against openapi.json with integration tests hitting the live API.

Tech Context

  • Language: Python 3.12+
  • Tests: pytest
  • API Spec: openapi.json (OpenAPI 3.0.3, sourced from Recraft Swagger UI)
  • Credentials: ~/secrets/recraft/credentials.env

Project Structure

recraft-sdk/
  openapi.json       # Recraft external API spec (27 endpoints, 69 schemas)
  tests/             # pytest integration tests
  src/recraft_sdk/   # Thin client wrapping Recraft REST API

Key Endpoints

Endpoint Purpose
POST /v1/images/generations/vector Generate SVG from prompt
POST /v1/images/generations/raster Generate PNG from prompt
POST /v1/images/vectorize Raster to vector conversion
POST /v1/images/clarityUpscale Upscale image
POST /v1/images/removeBackground Remove background

Requirements

Requires Python: >=3.12
Details
PyPI
2026-08-02 19:55:16 +00:00
19
MIT
16 KiB
Assets (2)
Versions (1) View all
0.1.0 2026-08-02