Easily customizable Social image (or Open graph image) generator

fancycard

Easily customizable Social image (or Open graph image) generator
Built with Go, Gin, GoQuery and Chromedp

Build & Run

Simply, Clone this repo, build and run with Go Toolchain.
You can get Go Toolchain from here.
You will also need Chrome or Chromium installed on your system to make this program work properly.

git clone https://github.com/sukso96100/fancycard.git
cd fancycard
go build -o fancycard .
./fancycard

Render Social image

Pass all required data via URL

Build a URL using /url API with following format, Then place URL in your webpage as Open Graph Protocol Image meta tag or Twitter card Image meta tag

https://
   
    /url?
    template=
    
     
    &
     
    
   
  • : Address of fancycard server where fancycard instance is hosted (e.g. fancycard.app.com)
  • : Path or URL to tempalte writtn in HTML and Go Template syntax
    • Built in templates: simple.html
    • Remote template URL: e.g. https://raw.githubusercontent.com/sukso96100/fancycard/main/tmpl/templates/simple.html
  • : Key of the parameter that the template requires
    • e.g. Title, Date, Author, Img...
    • Check template file for what template requires
  • : Value for template parameter
    • e.g. Hello world

Example usage

... ">
<html>
    <head>
        
        <meta property="og:image" content="https://
  
   /url?template=
   
    &
    
   
  " />
        
        <meta name="twitter:image" content="https://
  
   /url?template=
   
    &
    
   
  " />
    head>
...
html>

Let fancycard to scrap required data from your website

Instead of building super-long URL, Use /meta API, And put required data as meta tags with name="fancycard: " attributes.

Example usage

... ">
<html>
    <head>
        
        <meta property="og:image" content="https://
  
   /meta?url=
   
  " />
        
        <meta name="twitter:image" content="https://
  
   /meta?url=
   
  " />

        

        
        <meta name="fancycard:template" content="simple.html" />

        
        <meta name="fancycard:
  " content="
  " />
        <meta name="fancycard:Title" content="Hello world!" />
    head>
...
html>

License

MIT License

Similar Resources

simple but poweful mosaic picture generator

simple but poweful mosaic picture generator

MOSAIC MAN simple but poweful mosaic picture generator it's completely free with a highly customizable mosaic server RESULT Ex1 RESULT Ex2 OPTIONS til

Jul 18, 2022

A festive Christmas tree GIF generator implemented using only Golang standard library code

A festive Christmas tree GIF generator implemented using only Golang standard library code

Christmas Tree GIF Generator A festive Christmas tree GIF generator implemented

Feb 4, 2022

A generator of cats/birds/mobilizon pictures optimised to generate or random avatars, or defined avatar from a "seed"

A generator of cats/birds/mobilizon pictures optimised to generate or random avatars, or defined avatar from a "seed". A derivation by David Revoy from the original MonsterID by Andreas Gohr's.

Feb 7, 2022

Find out where you fall on the Open-Source Character Alignment Chart

gitaligned Find out where you fall on the Open-Source Character Alignment Chart Binaries available in releases. If you prefer to install from source,

Dec 28, 2022

Open-in-linear - A tool provides a shortcut to opening a linear issue in the desktop app or browser

This tool provides a shortcut to opening a linear issue in the desktop app or browser.

Jan 25, 2022

Image processing algorithms in pure Go

Image processing algorithms in pure Go

bild A collection of parallel image processing algorithms in pure Go. The aim of this project is simplicity in use and development over absolute high

Jan 6, 2023

Go package for fast high-level image processing powered by libvips C library

bimg Small Go package for fast high-level image processing using libvips via C bindings, providing a simple programmatic API. bimg was designed to be

Jan 2, 2023

Image processing library and rendering toolkit for Go.

blend Image processing library and rendering toolkit for Go. (WIP) Installation: This library is compatible with Go1. go get github.com/phrozen/blend

Nov 11, 2022

Decode embedded EXIF meta data from image files.

goexif Provides decoding of basic exif and tiff encoded data. Still in alpha - no guarantees. Suggestions and pull requests are welcome. Functionality

Dec 17, 2022
darkroom - An image proxy with changeable storage backends and image processing engines with focus on speed and resiliency.
darkroom - An image proxy with changeable storage backends and image processing engines with focus on speed and resiliency.

Darkroom - Yet Another Image Proxy Introduction Darkroom combines the storage backend and the image processor and acts as an Image Proxy on your image

Dec 6, 2022
An API which allows you to upload an image and responds with the same image, stripped of EXIF data

strip-metadata This is an API which allows you to upload an image and responds with the same image, stripped of EXIF data. How to run You need to have

Nov 25, 2021
Imgpreview - Tiny image previews for HTML while the original image is loading
Imgpreview - Tiny image previews for HTML while the original image is loading

imgpreview This is a Go program that generates tiny blurry previews for images t

May 22, 2022
Draw graphs through GO MOD GRAPH output
Draw graphs through GO MOD GRAPH output

go-mod-graph-chart build chart by go mod graph output Install $ go get -u github.com/PaulXu-cn/go-mod-graph-chart/gmchart Usage

Dec 14, 2022
A (very) simple graph package that utilizes the Generics features in Go 1.18

A (very) simple graph package that utilizes the Generics features in Go 1.18

May 11, 2022
Cgo bindings to PulseAudio's Simple API, for easily playing or capturing raw audio.

pulse-simple Cgo bindings to PulseAudio's Simple API, for easily playing or capturing raw audio. The full Simple API is supported, including channel m

Dec 17, 2022
Super fast static photo and video gallery generator (written in Go and HTML/CSS/native JS)

fastgallery Fast static photo and video gallery generator Super fast (written in Go and C, concurrent, uses fastest image/video libraries, 4-8 times f

Dec 4, 2022
OpenGL binding generator for Go

GoGL GoGL is an OpenGL binding generator for Go. No external dependencies like GLEW are needed. Install the OpenGL bindings For example, OpenGL 2.1 bi

Dec 25, 2022
An avatar generator for Go.

Cameron An avatar generator for Go. Oh, by the way, the name of this project came from the Avatar's director James Cameron. Features Identicon Install

Dec 25, 2022
A Free 8-Bit Sprite Generator. Create 256 variants from a single template .PNG
A Free 8-Bit Sprite Generator.  Create 256 variants from a single template .PNG

BitSprite A Free 8-Bit Sprite Generator. What? BitSprite is a program that creates variants of an image across total sprite sheet of the resultant ima

Sep 20, 2022