https://github.com/smileychris/recraft-cli
https://github.com/smileychris/recraft-cli
Last synced: 7 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/smileychris/recraft-cli
- Owner: SmileyChris
- Created: 2024-12-05T21:33:32.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2024-12-05T21:34:40.000Z (over 1 year ago)
- Last Synced: 2025-05-08T17:57:09.567Z (about 1 year ago)
- Language: Python
- Size: 17.6 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Recraft CLI
## Installation
```bash
pip install .
```
## Usage
### API Token
The first time you run `generate`, you'll be prompted to set your Recraft API token if it's not already stored.
Alternatively, you can manually set the token:
```bash
recraft token
```
### Generating Images
Generate images using the following command:
```bash
recraft generate "A beautiful landscape" --style realistic_image
```
### Upscaling Images
Upscale an existing image with optional mode selection:
```bash
recraft upscale image.png
recraft upscale image.png --mode generative
```
### Removing Background
Remove the background from an image:
```bash
recraft remove-bg image.png
recraft remove-bg image.png --response-format base64
```
## Features
- Automatic token setup on first use
- Secure token storage using system keychain
- Click-based CLI for easy command handling
- Simple image generation with style options
- Image upscaling with clarity and generative modes
- Background removal with flexible output formats