← All templates

Code Snippet image generator

Pipe-separated lines become a tidy code card with window chrome — pretty snippets for docs and social posts.

Code Snippet template example generated by OpenGraphAPI

Example URL

https://api.opengraphapi.com/v1/card?template=code&title=npm%20i%20-g%20wrangler%7Cwrangler%20login%7Cwrangler%20deploy&brand=quickstart.sh&meta=Shell&bg=mono

Parameters

ParameterRole in this template
titletitle(lines with | separator)
brandbrand(filename)
metameta(language)
bgContent field
bgTheme: midnight, sunset, forest, royal, slate, ocean, mono, rose, amber, paper
api_keyRemoves watermark, raises quota

Typical uses

Use it free — 300 images/day   Read the docs