Skip to content

fix: use Mintlify dynamic thumbnails for API reference OG images#227

Merged
patcapulong merged 3 commits intomainfrom
fix/api-reference-og-images
Feb 25, 2026
Merged

fix: use Mintlify dynamic thumbnails for API reference OG images#227
patcapulong merged 3 commits intomainfrom
fix/api-reference-og-images

Conversation

@patcapulong
Copy link
Contributor

@patcapulong patcapulong commented Feb 25, 2026

Summary

  • Auto-generated OpenAPI API reference pages were showing a blank dotted background as their OG image (no title, no logo) because seo.metatags.og:image in docs.json was set to the raw og-fallback-bg.png, which bypasses Mintlify's dynamic thumbnail generation
  • Replaced the raw og:image meta tag override with Mintlify's thumbnails config, which dynamically generates OG images by overlaying the page title and logo on a dark background
  • All manually authored pages (get started, payouts, ramps, rewards, global p2p, manual API reference pages) are unaffected -- they keep their per-page og:image frontmatter overrides

Test plan

  • Deploy preview and check an auto-generated API reference page (e.g. /api-reference/external-accounts/add-a-new-external-account) -- verify the OG image now shows the page title with light text on the dark background
  • Verify a manual page with per-page og:image (e.g. /api-reference/authentication) still shows the pre-baked og-api-reference.png
  • Verify a non-API page (e.g. /ramps/quickstart) still shows its section-specific OG image
  • Use metatags.io or similar to preview the OG tags on social platforms

Made with Cursor

Mintlify

0 threads from 0 users in Mintlify

  • No unresolved comments

Open in Mintlify Editor

patcapulong and others added 3 commits February 24, 2026 10:12
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Auto-generated OpenAPI pages were showing a blank background as their
OG image because seo.metatags.og:image bypassed Mintlify's dynamic
thumbnail generation. Switch to the thumbnails config so these pages
get dynamically generated OG images with page titles overlaid on a
dark background.

Co-authored-by: Cursor <cursoragent@cursor.com>
@greptile-apps
Copy link
Contributor

greptile-apps bot commented Feb 25, 2026

Greptile Summary

Switches auto-generated OpenAPI API reference pages from a static, blank OG fallback image to Mintlify's dynamic thumbnail system, which overlays the page title and logo onto a dark background. Manually authored pages retain their per-page og:image frontmatter overrides.

  • Replaced seo.metatags OG image override in docs.json with the thumbnails config (background + appearance: "dark")
  • Added og-api-reference-generic.png as the dark-themed background for dynamic thumbnail generation
  • All non-auto-generated pages (get started, payouts, ramps, rewards, global P2P, manual API reference pages) are unaffected since they define og:image in their frontmatter

Confidence Score: 5/5

  • This PR is safe to merge — it's a minimal, well-scoped configuration change with no risk to existing pages.
  • The change is limited to two files: a small JSON config tweak and a new static image asset. All manually authored pages have per-page og:image frontmatter that takes precedence over the global thumbnails config, so they are unaffected. The old og-fallback-bg.png is no longer referenced but remains in the repo (harmless). No code logic, no runtime behavior, no security implications.
  • No files require special attention

Important Files Changed

Filename Overview
mintlify/docs.json Replaces static seo.metatags.og:image (which bypassed Mintlify's dynamic thumbnail generation) with the thumbnails config block. The empty seo: {} is left behind as a no-op placeholder. Per-page og:image frontmatter overrides on manually authored pages are unaffected.
mintlify/images/og/og-api-reference-generic.png New dark-themed background image (dotted pattern on dark background) used by the thumbnails config for Mintlify's dynamic OG image generation. Appropriate dimensions for OG images.

Flowchart

%%{init: {'theme': 'neutral'}}%%
flowchart TD
    A[Page Request] --> B{Has per-page<br/>og:image frontmatter?}
    B -->|Yes| C[Use per-page OG image<br/>e.g. og-ramps.png, og-api-reference.png]
    B -->|No| D{thumbnails config<br/>in docs.json?}
    D -->|Yes - NEW| E[Mintlify dynamic thumbnail<br/>Page title + logo on<br/>og-api-reference-generic.png]
    D -->|No - OLD| F[Static og-fallback-bg.png<br/>Blank dotted background]

    style E fill:#2d6a4f,stroke:#1b4332,color:#fff
    style F fill:#6c757d,stroke:#495057,color:#fff
Loading

Last reviewed commit: 51df43a

@patcapulong
Copy link
Contributor Author

Screenshot 2026-02-24 at 7 13 47 PM Screenshot 2026-02-24 at 7 13 52 PM

lgtm!!!

@patcapulong patcapulong merged commit 4c1da95 into main Feb 25, 2026
6 checks passed
@patcapulong patcapulong deleted the fix/api-reference-og-images branch February 25, 2026 05:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants