kavel

Generate AI images with Kavel from Haxe: one call, no key needed for a first try
https://github.com/hanshs474/kavel-haxe

To install, run:

haxelib install kavel 0.1.0 

See using Haxelib in Haxelib documentation for more information.

README.md

kavel

Kavel is a free AI video generator and AI image generator — 4K clips with sound, and images you can run without an account or a card. This library calls it from Haxe: one static function, standard library only, on every sys target (eval, hl, cpp, neko, python, jvm).

import kavel.Kavel;

trace(Kavel.generate("a paper-cut fox in a moonlit forest"));
// https://cdn.kavel.ai/uploads/…/….webp

No key is needed for a first try: the call runs on Kavel's free allowance.

haxelib install kavel

Past the free allowance

Create an API key on your Kavel account at https://www.kavel.ai/settings/apikeys and pass it (or set KAVEL_API_KEY):

Kavel.generate("isometric tiny greenhouse", Sys.getEnv("KAVEL_API_KEY"), "gpt-image-2");

With a key the call runs on your account: your credits, and the image models your plan includes. Every failure throws KavelError with a readable reason — spent allowance, refused prompt, wrong key or timeout.

More from Kavel

Editing a photo instead of starting from a prompt? Kavel keeps a page per edit — hairstyle, outfit and the rest under AI image tools. Video lives under AI video tools.

MIT licensed.

Contributors
kavel
Version
0.1.0
Published
4 weeks ago
License
MIT

All libraries are free

Every month, more than a thousand developers use Haxelib to find, share, and reuse code — and assemble it in powerful new ways. Enjoy Haxe; It is great!

Explore Haxe

Haxe Manual

Haxe Code Cookbook

Haxe API documentation

You can try Haxe in the browser! try.haxe.org

Join us on GitHub!

Haxe is being developed on GitHub. Feel free to contribute or report issues to our projects.

Haxe on GitHub

⌂