{"id":21223070,"url":"https://github.com/nestdotland/og","last_synced_at":"2025-06-21T05:37:53.714Z","repository":{"id":42773632,"uuid":"276100237","full_name":"nestdotland/og","owner":"nestdotland","description":"📸 Open Graph Image Generator","archived":false,"fork":false,"pushed_at":"2023-01-08T01:11:25.000Z","size":1419,"stargazers_count":15,"open_issues_count":4,"forks_count":1,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-05-26T10:28:39.645Z","etag":null,"topics":["nestland","nextjs","open-graph","react"],"latest_commit_sha":null,"homepage":"https://og.nest.land","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/nestdotland.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-06-30T13:02:55.000Z","updated_at":"2024-11-28T17:13:29.000Z","dependencies_parsed_at":"2023-02-08T04:02:00.067Z","dependency_job_id":null,"html_url":"https://github.com/nestdotland/og","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nestdotland%2Fog","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nestdotland%2Fog/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nestdotland%2Fog/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nestdotland%2Fog/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nestdotland","download_url":"https://codeload.github.com/nestdotland/og/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":257046081,"owners_count":22481529,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["nestland","nextjs","open-graph","react"],"created_at":"2024-11-20T22:48:42.910Z","updated_at":"2025-06-21T05:37:48.700Z","avatar_url":"https://github.com/nestdotland.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Nest OG Image Generator\n\nService that dynamically generates [Open Graph](https://ogp.me/) images for [Nest](https://nest.land) that looks something like\n\n\u003cimg width=\"600\" src=\"https://og.nest.land/api/image?layoutName=Pattern\u0026Text=Hello+World\" /\u003e\n\n# ✨ How To Use\n\nUse the generated image URL in the `\u003chead\u003e` of your HTML document as the og:image meta property\n\n```html\n\u003cmeta\n  property=\"og:image\"\n  content=\"https://og.nest.land/api/image?layoutName=Pattern\u0026Text=Hello+World\"\n/\u003e\n```\n\nWhenever this image is requested (e.g. in link previews) the image will be generated on demand.\n\n# 🧐 How It Works\n\nImages are generated through the `/api/image` route. When you hit this route the following happens\n\n- Query params are parsed\n- Layout is looked up in list of layouts using the `layoutName` query param\n- `layout.getCSS` called with all query params\n- `layout.Component` is rendered with all query params as `config` prop\n- HTML page built, rendered with Puppeteer, and screenshot\n- Screenshot returned with a long cache max age\n\n## Layouts\n\nThis service can generate images using multiple _layouts_. A layout is defined as a\n\n- Collection of properties that are user configurable. The UI for these properties is auto genearted\n- Function that takes in layout config and returns CSS needed to render\n- A React component that takes in layout config as a prop\n\n# 🚀 Development\n\nTo start hacking, do the following:\n\n1. [Fork](https://github.com/nestdotland/og/fork) this repo and clone it\n2. Run `yarn` or `npm install` to install all dependencies\n3. Run locally with `yarn dev` and visit [`localhost:3000`](http://localhost:3000)\n\nNow you're ready to start local development!\n\nThe frontend is a [NextJS](https://nextjs.org) site and the image generation happens in an API route.\n\n```\n# Start local development server\nyarn dev\n\n# Build for production\nyarn build\n\n# Start in production\nyarn start\n```\n\n# 🙌 Acknowledgement\n\nCredit where credit is due. This started as a forked repo from [Railway's OG image generator](https://og.railway.app/)\n\n# License\n\nThis project is distributed under [The MIT Licese](./LICENSE)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnestdotland%2Fog","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnestdotland%2Fog","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnestdotland%2Fog/lists"}