{"id":20556438,"url":"https://github.com/flagsmith/flagsmith-opengraph","last_synced_at":"2025-12-03T18:02:24.970Z","repository":{"id":239304167,"uuid":"798871691","full_name":"Flagsmith/flagsmith-opengraph","owner":"Flagsmith","description":"Generates markdown and images about Flagsmith feature flags","archived":false,"fork":false,"pushed_at":"2024-05-14T16:40:56.000Z","size":237,"stargazers_count":0,"open_issues_count":1,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-01-16T18:26:04.519Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://flagsmith-opengraph.vercel.app","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Flagsmith.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-05-10T16:42:32.000Z","updated_at":"2024-05-14T16:41:00.000Z","dependencies_parsed_at":"2024-05-12T16:00:40.834Z","dependency_job_id":null,"html_url":"https://github.com/Flagsmith/flagsmith-opengraph","commit_stats":null,"previous_names":["flagsmith/flagsmith-opengraph"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Flagsmith%2Fflagsmith-opengraph","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Flagsmith%2Fflagsmith-opengraph/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Flagsmith%2Fflagsmith-opengraph/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Flagsmith%2Fflagsmith-opengraph/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Flagsmith","download_url":"https://codeload.github.com/Flagsmith/flagsmith-opengraph/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":242163854,"owners_count":20082224,"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":[],"created_at":"2024-11-16T03:27:44.979Z","updated_at":"2025-12-03T18:02:24.913Z","avatar_url":"https://github.com/Flagsmith.png","language":"TypeScript","readme":"[![Feature Flag, Remote Config and A/B Testing platform, Flagsmith](https://raw.githubusercontent.com/Flagsmith/flagsmith/main/static-files/hero.png)](https://flagsmith.com/)\n\nGenerates an SVG Image preview of feature states in a project using Vercel's [Santori](https://github.com/vercel/satori) project.\n\n\n## Generating an image:\n\nAn image url can be generated by converting an array of items to JWT.\n\n```\nexport type Item = {\n    feature_state_value?: string | number;\n    segment_name?: string;\n    environment_name: string;\n    feature_value: boolean;\n}\n\nconst items: Item[] = [{\n      \"feature_state_value\": \"Green\",\n      \"environment_name\": \"Production\",\n      \"feature_value\": true\n}]\n\nconst url = `https://flagsmith-opengraph.vercel.app/?t=${jwtEncode({payload:items})}\n\nreturn (\u003cimg src={url}/\u003e)\n```\n\n\nResult:\n\n![image](https://flagsmith-opengraph.vercel.app/api/image?t=eyJhbGciOiJIUzI1NiJ9.eyJwYXlsb2FkIjpbeyJmZWF0dXJlX3N0YXRlX3ZhbHVlIjoiR3JlZW4iLCJlbnZpcm9ubWVudF9uYW1lIjoiUHJvZHVjdGlvbiIsImZlYXR1cmVfdmFsdWUiOnRydWV9XX0.WFP3PNZvWTC7xSVIFp9Ws7vW69kaOEkyAhkb7qQW3Hs)\n\n\n## Generating a URL via post request\n\nAlternatively, you can post to the following in order to get a base64 encoded SVG.\n\n```\ncurl --location 'https://flagsmith-opengraph.vercel.app/api/image/base64' \\\n--header 'Content-Type: application/json' \\\n--data '[\n    {\n      \"feature_state_value\": \"Blue\",\n      \"environment_name\": \"Development\",\n      \"feature_value\": true\n    }\n  ]'\n```\n\nSee a demo:\nhttps://flagsmith-opengraph.vercel.app/\n\n\n\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fflagsmith%2Fflagsmith-opengraph","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fflagsmith%2Fflagsmith-opengraph","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fflagsmith%2Fflagsmith-opengraph/lists"}