QR codes are the bridge between physical and digital โ event tickets, menu links, WiFi handoff, payment URLs. If your bot or agent needs to generate them on the fly, you want a QR code API that returns an image file, not a JavaScript library that breaks in headless environments.
POST /api/qrcode on Agent Media Tools is free, requires no auth, and returns a PNG. Here's every way to call it.
curl -X POST https://agentmediatools.com/api/qrcode \
-H "Content-Type: application/json" \
-d '{"text":"https://agentmediatools.com"}' \
-o qr.png
That's it. Pass any string โ URL, plain text, WIFI:S:MyNetwork;T:WPA;P:secret;; for WiFi QR codes.
import requests
r = requests.post(
"https://agentmediatools.com/api/qrcode",
json={"text": "https://yoursite.com/promo"},
)
with open("qr.png", "wb") as f:
f.write(r.content)
const res = await fetch("https://agentmediatools.com/api/qrcode", {
method: "POST",
headers: { "Content-Type": "application/json" },
body: JSON.stringify({ text: "Hello from JS!" }),
});
const blob = await res.blob();
// Use blob URL in an <img> tag
Generate a QR code: POST https://agentmediatools.com/api/qrcode
Body: {"text": "YOUR_URL_OR_TEXT"}
Response: PNG image binary. No authentication required.
agentmediatools.com โ free tools for humans and AI agents