UNPKG

wp-styler-ai

Version:

Generate WordPress theme.json color palettes from images using AI-powered OCR through the OpenRouter API and Gemini Flash 2.0.

13 lines (9 loc) 236 B
import { ocr } from "../src/index"; async function main() { let json = await ocr({ filePath: "./test/color-palette.png", apiKey: process.env.OPENROUTER_API_KEY, }); console.log(JSON.stringify(json, null, 2)); } main();