Generate QR code images from text or URL input with size and format options.
Encode input text into a QR code image.
/v1/web-tools:qr-generate/encode5m cache3 paramschecking key…// npm i zpi-sdk
import { ZpiClient } from "zpi-sdk";
const client = new ZpiClient({ apiKey: "zpi_xxxxxxxxxxxxxxxxxxxxxxxx" });
const data = await client.run("web-tools:qr-generate", "encode", {
"data": "https://zpi.web.id",
"size": 500,
"format": "png"
});
console.log(data);/v1/web-tools:qr-generate/encodedatastringrequiredsizenumberoptionalformatenumoptionalcurl -X GET "https://api.zapi.ink/v1/web-tools:qr-generate/encode?data=https%3A%2F%2Fzpi.web.id&size=500&format=png" \
-H "x-api-key: zpi_xxxxxxxxxxxxxxxxxxxxxxxx"{
"ok": true,
"size": 500,
"format": "png",
"imageUrl": "https://api.qrserver.com/v1/create-qr-code/?data=https%3A%2F%2Fzpi.web.id&size=500x500&format=png"
}