<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: DSP</title>
    <description>The latest articles on DEV Community by DSP (@darksun159).</description>
    <link>https://dev.to/darksun159</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F4207629%2F220a1db9-7307-495e-bf6f-9ca69fc66337.png</url>
      <title>DEV Community: DSP</title>
      <link>https://dev.to/darksun159</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/darksun159"/>
    <language>en</language>
    <item>
      <title>One spec, every size: SpecCard renders social cards from templates kept in code</title>
      <dc:creator>DSP</dc:creator>
      <pubDate>Tue, 10 Nov 2026 15:55:41 +0000</pubDate>
      <link>https://dev.to/darksun159/one-spec-every-size-speccard-renders-social-cards-from-templates-kept-in-code-3k7g</link>
      <guid>https://dev.to/darksun159/one-spec-every-size-speccard-renders-social-cards-from-templates-kept-in-code-3k7g</guid>
      <description>&lt;p&gt;Every post on a blog needs the same small set of images: the OG card for link previews, a square for social feeds, a story format for the vertical surfaces. The usual ways to make them are a design tool and a folder of exports that drift out of date, or an editor-based service where the template lives in someone else's dashboard and the rendering is metered per image, per format, and per scale.&lt;/p&gt;

&lt;p&gt;SpecCard is the API we built for the pipeline-shaped version of that job. The templates are named, versioned code. The request is a JSON spec: template name, text fields, palette or color overrides. The response is finished images, and the same spec always renders to the same bytes.&lt;/p&gt;

&lt;h2&gt;
  
  
  What it does
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;A curated catalog of 10 templates in four families: editorial (headline OG cards, a changelog card, an event card), stat cards, quote cards in serif and sans, and product cards&lt;/li&gt;
&lt;li&gt;Single renders: one template at one size, returned as the image bytes, JPEG by default and PNG on request&lt;/li&gt;
&lt;li&gt;Content packs: one spec rendered at the template's full channel size set (2 to 3 sizes) in a single call, and the pack counts as one request&lt;/li&gt;
&lt;li&gt;Batch: up to 10 single renders in one call, each item independent, so one bad spec returns its own error and never fails the batch&lt;/li&gt;
&lt;li&gt;Named palettes (3 per template, from 9 canonical colorways) with per-slot color overrides, so brand colors travel in the request instead of living in a dashboard&lt;/li&gt;
&lt;li&gt;A self-describing catalog: the API publishes every template's full field schema, limits, palettes, sizes, and a complete working example spec&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Sizes are named and fixed: &lt;code&gt;og&lt;/code&gt; at 1200x630, &lt;code&gt;square&lt;/code&gt; at 1080x1080, &lt;code&gt;story&lt;/code&gt; at 1080x1920, and &lt;code&gt;post&lt;/code&gt; at 1200x1200. Every template declares 2 to 3 of them, and the pack is always the full set.&lt;/p&gt;

&lt;h2&gt;
  
  
  A taste
&lt;/h2&gt;

&lt;p&gt;One spec, rendered at every size its template ships:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl -X POST &lt;span class="s2"&gt;"https://speccard.p.rapidapi.com/v1/render/pack"&lt;/span&gt; \
  -H &lt;span class="s2"&gt;"X-RapidAPI-Key: YOUR_KEY"&lt;/span&gt; \
  -H &lt;span class="s2"&gt;"Content-Type: application/json"&lt;/span&gt; \
  -d &lt;span class="s1"&gt;'{
    "template": "headline-og",
    "data": {
      "brand": "Northstar Ops",
      "category": "Operations",
      "title": "The Hidden Cost of Almost-Right Dates",
      "subtitle": "Why deadline software fails at the exact moment a customer needs certainty.",
      "author": "Maya Chen",
      "date": "Nov 18, 2026",
      "read_time": "7 min read",
      "domain": "northstarops.com"
    }
  }'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The pack endpoint answers with one envelope, one entry per size, each carrying the base64 image plus its byte count and SHA-256:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;"catalog_version"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"catalog.1"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"template"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"headline-og"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"template_version"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"format"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"jpeg"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"kind"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"pack"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"images"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;
    &lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="nl"&gt;"size"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"og"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"width"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;1200&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"height"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;630&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"format"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"jpeg"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
     &lt;span class="nl"&gt;"bytes"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;71234&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"sha256"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"&amp;lt;hex&amp;gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"data"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"&amp;lt;base64&amp;gt;"&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="nl"&gt;"size"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"square"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"width"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;1080&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"height"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;1080&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"format"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"jpeg"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
     &lt;span class="nl"&gt;"bytes"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;84510&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"sha256"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"&amp;lt;hex&amp;gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"data"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"&amp;lt;base64&amp;gt;"&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="p"&gt;]&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;(That example is abridged to two entries; a &lt;code&gt;headline-og&lt;/code&gt; pack always carries all three of its sizes, and the byte counts shown are illustrative.) The hash matters more than it might look: because a pack image is byte-identical to the same spec rendered on its own, a build pipeline can hash a card in CI, diff it in review, and trust a backfill of ten thousand archive posts to produce exactly the cards the templates describe.&lt;/p&gt;

&lt;h2&gt;
  
  
  How it is built
&lt;/h2&gt;

&lt;p&gt;FastAPI on the front, Pillow doing the rendering, and nothing else in the request path. There is no database, no stored state, and no network call at runtime: the fonts (the Noto families, bundled under the SIL Open Font License 1.1 and loaded by explicit file path, never by system fallback) travel with the service, so the deploy artifact renders identically anywhere.&lt;/p&gt;

&lt;p&gt;Determinism is a contract, not a hope. The render path reads no clock, no randomness, and no environment. Each template draws at 2x supersampling and downsamples with Lanczos, and the encoder settings are pinned constants. A shipped template version is never edited in place for a change that alters output bytes; a visual change ships as the next version, the old renderer stays selectable by pinning &lt;code&gt;template_version&lt;/code&gt;, and pack, batch, and error responses carry a &lt;code&gt;catalog_version&lt;/code&gt; stamp naming the catalog that produced them. The prototype that proved this design out rendered the same spec twice and produced identical SHA-256 hashes, and ran a 100-render batch in one process peaking at 78.7 MB of memory, which is why batch-shaped rendering is a normal case here instead of a top-tier feature.&lt;/p&gt;

&lt;p&gt;Text fitting follows a published policy instead of vibes. Text wraps, an unbroken word wider than its box is hard-split, the size steps down until the text fits its line budget, and only then is a final line ellipsized with three ASCII dots. Text never overflows its box or collides with an anchored element, and a field over its published length limit is rejected with a structured error naming the field and the limit, never silently truncated.&lt;/p&gt;

&lt;p&gt;The error vocabulary is a closed set of codes in one shape (&lt;code&gt;{detail, code, catalog_version}&lt;/code&gt;), and registry errors name the offending value and the valid options. An unknown field inside &lt;code&gt;data&lt;/code&gt; is rejected rather than ignored: on an API whose contract is byte-exact rendering, a misspelled field silently falling back to a default would be a quiet lie in image form.&lt;/p&gt;

&lt;h2&gt;
  
  
  What v1 deliberately leaves out
&lt;/h2&gt;

&lt;p&gt;SpecCard v1 is narrow on purpose, and the narrowness is the product. There is no visual editor and no caller-defined layout; the catalog is 10 curated templates with defined fields. There are no caller-supplied photos, logos, or fonts, and no AI imagery; avatars render as initials, and product templates use their own flat illustration. If your workflow starts in a design tool, editor-based services are built for you and good at it. SpecCard is for the workflow that starts in a repository.&lt;/p&gt;

&lt;p&gt;Text is Latin-script at launch. The supported repertoire covers the Latin blocks including Latin Extended and combining marks (Vietnamese renders fine), general punctuation, currency symbols, and arrows. Anything outside it, Cyrillic, CJK, Arabic, and emoji included, is rejected with a 422 &lt;code&gt;unsupported_script&lt;/code&gt; error naming the field and the character. Rejection is the honest option: the alternatives were rendering placeholder boxes under a 200 status, or silently stripping characters out of the caller's words.&lt;/p&gt;

&lt;p&gt;Dates, prices, and metrics in a spec are free text, printed exactly as given. The API does no date parsing, currency formatting, or number localization, and the listing does not pretend otherwise.&lt;/p&gt;

&lt;h2&gt;
  
  
  Pricing
&lt;/h2&gt;

&lt;p&gt;Every endpoint is available on every plan, including the free tier. The catalog, single render, pack, and batch endpoints are all there from the start, with no template held back to force an upgrade. Upgrading simply gets you more requests per month: start free with 100 requests a month on a tier that renews monthly instead of expiring like a trial, move up to Pro at $9/month for 2,000, Ultra at $19/month for 5,000, or Mega at $49/month for 15,000. Paid plans are soft limits with small overages, so a backfill that runs long does not hard-stop halfway through an archive. And remember what a request can carry: a pack renders one spec at every channel size its template ships, for one request. You pay for volume, not for access, and not per format.&lt;/p&gt;

&lt;p&gt;The listing is here: &lt;a href="https://rapidapi.com/darksundarker/api/speccard" rel="noopener noreferrer"&gt;https://rapidapi.com/darksundarker/api/speccard&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Feedback very welcome, especially the "my pipeline needs a template shape you do not have" kind. The catalog is curated and versioned, so the templates it grows will come from exactly that.&lt;/p&gt;

</description>
      <category>api</category>
      <category>python</category>
      <category>fastapi</category>
      <category>webdev</category>
    </item>
    <item>
      <title>The holiday list is free. The date math is the product.</title>
      <dc:creator>DSP</dc:creator>
      <pubDate>Tue, 10 Nov 2026 05:32:13 +0000</pubDate>
      <link>https://dev.to/darksun159/the-holiday-list-is-free-the-date-math-is-the-product-40ch</link>
      <guid>https://dev.to/darksun159/the-holiday-list-is-free-the-date-math-is-the-product-40ch</guid>
      <description>&lt;p&gt;Every team that touches payroll, delivery promises, support SLAs, or renewal dates eventually writes the same fragile function: loop forward a day at a time, skip Saturday and Sunday, check a holiday list, repeat. The holiday list is the easy part. You can get one for free, and you should, because raw lookup was never the hard part.&lt;/p&gt;

&lt;p&gt;The bugs live in the rules around the list. Independence Day falls on a Saturday, so the office actually closes on the Friday, and your loop counts the Friday as a business day. A client's team works a Friday to Saturday weekend. Your own company shuts down between Christmas and New Year, a closure that exists in no public dataset anywhere. And when a customer asks why their deadline landed on Tuesday instead of Monday, "the function said so" is not an answer anyone can audit.&lt;/p&gt;

&lt;p&gt;DayRules is the API we built for that function. It adds, counts, and steps business days across country and exchange calendars, applies the caller's own calendar rules, and explains every date it skips, unless you ask it not to.&lt;/p&gt;

&lt;h2&gt;
  
  
  What it does
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Add or subtract business days (up to plus or minus 10,000), count business days between two dates, find the next or previous business day, and classify a single date with the reason for the verdict&lt;/li&gt;
&lt;li&gt;Holiday lists by country, subdivision, or exchange calendar, by year or range. Subdivisions are real calendars, not decoration: Bavaria is DE-BY, England is GB-ENG, and a Bavarian holiday like Corpus Christi is answered by the subdivision calendar, not the national one&lt;/li&gt;
&lt;li&gt;Custom weekends per request, including a Friday and Saturday weekend or no weekend at all&lt;/li&gt;
&lt;li&gt;Caller-supplied closures and extra holidays, and forced workdays for the dates your team actually worked&lt;/li&gt;
&lt;li&gt;An observed toggle, so observed and substitute holidays are a choice in the request instead of a hidden assumption baked into the data&lt;/li&gt;
&lt;li&gt;Holiday type filters (public, bank, school) where the bundled data supports them&lt;/li&gt;
&lt;li&gt;Batch: up to 100 add, between, and is-business-day operations in one call, and the batch counts as one request&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The bundled dataset serves 250 country calendars and 30 exchange calendars. That number is library coverage, and we label it that way rather than dressing it up as verified coverage: the &lt;code&gt;/v1/countries&lt;/code&gt; endpoint publishes a coverage flag for every calendar, 34 of the 250 country calendars are flagged partial, and any response that touches partial coverage carries a notice. Before launch we spot-checked the 2026 calendars for ten countries (US, GB, DE, FR, JP, CA, AU, IN, BR, ES) against official sources. Every response also carries a &lt;code&gt;data_version&lt;/code&gt; field, currently &lt;code&gt;holidays-0.107+registry.2&lt;/code&gt;, so you always know which dataset produced an answer.&lt;/p&gt;

&lt;h2&gt;
  
  
  A taste
&lt;/h2&gt;

&lt;p&gt;Ask for one business day after Thursday, July 2, 2026, in the US calendar:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl -X POST &lt;span class="s2"&gt;"https://dayrules.p.rapidapi.com/v1/business-days/add"&lt;/span&gt; \
  -H &lt;span class="s2"&gt;"X-RapidAPI-Key: YOUR_KEY"&lt;/span&gt; \
  -H &lt;span class="s2"&gt;"Content-Type: application/json"&lt;/span&gt; \
  -d &lt;span class="s1"&gt;'{"country": "US", "start": "2026-07-02", "days": 1}'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You land on Monday, July 6, and the response shows its work:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;"data_version"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"holidays-0.107+registry.2"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"calendar_id"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"US"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"start"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"2026-07-02"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"days_requested"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"result"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"2026-07-06"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"calendar_days_elapsed"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;4&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"skipped"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;
    &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="nl"&gt;"date"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"2026-07-03"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="nl"&gt;"primary_reason"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"holiday"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="nl"&gt;"reasons"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;
        &lt;span class="p"&gt;{&lt;/span&gt;
          &lt;span class="nl"&gt;"kind"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"holiday"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
          &lt;span class="nl"&gt;"name"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"Independence Day (observed)"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
          &lt;span class="nl"&gt;"type"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"public"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
          &lt;span class="nl"&gt;"observed"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kc"&gt;true&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
          &lt;span class="nl"&gt;"substitute_for"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"2026-07-04"&lt;/span&gt;
        &lt;span class="p"&gt;}&lt;/span&gt;
      &lt;span class="p"&gt;]&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="nl"&gt;"date"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"2026-07-04"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="nl"&gt;"primary_reason"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"holiday"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="nl"&gt;"reasons"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;
        &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nl"&gt;"kind"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"holiday"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"name"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"Independence Day"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"type"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"public"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"observed"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kc"&gt;false&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"substitute_for"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kc"&gt;null&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
        &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nl"&gt;"kind"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"weekend"&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;
      &lt;span class="p"&gt;]&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="nl"&gt;"date"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"2026-07-05"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="nl"&gt;"primary_reason"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"weekend"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="nl"&gt;"reasons"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nl"&gt;"kind"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"weekend"&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="p"&gt;]&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="p"&gt;]&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Friday the 3rd is the observed closure for the Saturday holiday, and the response says exactly that, including what the observed date substitutes for. That explanation is the default behavior of every math endpoint: DayRules explains every date it skips, unless you ask it not to. If you are counting business days across a ten-year range and would rather not ship the list back and forth, set &lt;code&gt;include_skipped&lt;/code&gt; to false and you get skip counts by reason, with a flag in the response saying the detail was suppressed at your request.&lt;/p&gt;

&lt;p&gt;The &lt;code&gt;between&lt;/code&gt; endpoint breaks a range into calendar days, weekend days, holiday days, and closure days alongside the business-day total, so a count is never a bare number you have to take on faith.&lt;/p&gt;

&lt;h2&gt;
  
  
  How it is built
&lt;/h2&gt;

&lt;p&gt;FastAPI, with the calendar logic kept pure and separate from the web layer, and built to deploy on the free tier of Render. The holiday data comes from the python-holidays rule engine, pinned to a fixed version and bundled with the service. That choice is deliberate: the API makes no network calls at runtime, so an answer never depends on a third-party holiday service being awake, and the same request against the same &lt;code&gt;data_version&lt;/code&gt; always returns the same result. Updating the data is one atomic change: raise the pin, regenerate the coverage registry, run the test suite, and the &lt;code&gt;data_version&lt;/code&gt; moves with it.&lt;/p&gt;

&lt;p&gt;The limits, plainly, because every DSP listing has a Limits section and this post should too. The data is planning-grade. It is community-maintained, governments declare one-off holidays that any dataset can lag, and calculated dates can shift. Treat the coverage flags as part of the answer, and verify independently before a date drives a legal filing or a payroll cutoff. Counts are whole days; there is no half-day accounting and no business-hours math. And if all you need is a list of holidays for one country, free lookup services exist and you should use one. What DayRules charges for is the arithmetic, the caller-calendar rules, and the explanation.&lt;/p&gt;

&lt;h2&gt;
  
  
  Pricing
&lt;/h2&gt;

&lt;p&gt;Every endpoint is available on every plan, including the free tier. The countries, holidays, is-business-day, add, between, next, previous, and batch endpoints are all there from the start, with no Pro-only countries and no explanation feature held back to force an upgrade. Upgrading simply gets you more requests per month: start free with 1,500 requests a month (and remember, one request can carry a batch of 100 operations), move up to Pro at $9/month for 60,000, Ultra at $19/month for 300,000, or Mega at $49/month for 1,000,000. Paid plans are soft limits with small overages, so a traffic spike does not hard-stop a production integration in the middle of a payroll run. You pay for volume, not for access.&lt;/p&gt;

&lt;p&gt;The listing is here: &lt;a href="https://rapidapi.com/darksundarker/api/dayrules" rel="noopener noreferrer"&gt;https://rapidapi.com/darksundarker/api/dayrules&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Feedback very welcome, especially the "my calendar has a rule you do not handle" kind. Custom weekends, closures, and forced workdays are in v1 because public calendars cannot know them, and the next rule DayRules learns will probably come from the same place.&lt;/p&gt;

</description>
      <category>api</category>
      <category>python</category>
      <category>fastapi</category>
      <category>dates</category>
    </item>
    <item>
      <title>DigitProof: one API for every check digit, and it fixes the wrong ones</title>
      <dc:creator>DSP</dc:creator>
      <pubDate>Mon, 26 Oct 2026 05:57:40 +0000</pubDate>
      <link>https://dev.to/darksun159/digitproof-one-api-for-every-check-digit-and-it-fixes-the-wrong-ones-3ebm</link>
      <guid>https://dev.to/darksun159/digitproof-one-api-for-every-check-digit-and-it-fixes-the-wrong-ones-3ebm</guid>
      <description>&lt;p&gt;Every codebase I have ever worked in has a graveyard of half-remembered validation rules. The IBAN check is mod-97, but only after you rearrange the string. The ISBN-10 check digit can be the letter X. A VIN has a check digit at position 9, unless it was built for a market that does not use one. Each identifier has its own standard, its own math, and its own way of quietly going wrong.&lt;/p&gt;

&lt;p&gt;DigitProof is my attempt to put all of that in one place. It is a single API that validates nine families of structured identifiers, parses them, and, this is the part I actually wanted, tells you the correct check digit when the one you have is wrong.&lt;/p&gt;

&lt;h2&gt;
  
  
  What it validates
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;IBAN: length and structure for 86 countries, mod-97 check digits, BBAN parsing (bank code, branch code, account number) for 22 countries, SEPA flag, grouped formatting&lt;/li&gt;
&lt;li&gt;LEI: the ISO 17442 format and its mod-97 check digits, with the LOU prefix broken out&lt;/li&gt;
&lt;li&gt;ISIN: country and NSIN structure with the Luhn check digit&lt;/li&gt;
&lt;li&gt;ISBN-10 and ISBN-13, including conversion between them&lt;/li&gt;
&lt;li&gt;GTIN-8, UPC-A, EAN-13, and GTIN-14, detected from length&lt;/li&gt;
&lt;li&gt;VIN: 17 characters, the North American position-9 check digit, make hints and model year decoding&lt;/li&gt;
&lt;li&gt;Payment cards: Luhn, brand detection, and the networks' published test numbers flagged as &lt;code&gt;test_only&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;UUID: version and variant parsing&lt;/li&gt;
&lt;li&gt;EU and GB VAT numbers: per-country formats, with check digits verified where a country defines them&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;It is format and checksum validation only. There are no bank directories or registry lookups behind it, and the listing says so plainly. A valid result means the identifier is well-formed and its math checks out. A related note on cards: the card checks are format and Luhn only, intended for published test numbers and format checks. Please do not send real cardholder data through the API; PCI DSS obligations for real card numbers stay with the caller.&lt;/p&gt;

&lt;h2&gt;
  
  
  A taste
&lt;/h2&gt;

&lt;p&gt;Send a known-good IBAN:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl &lt;span class="nt"&gt;-X&lt;/span&gt; POST &lt;span class="s2"&gt;"https://digitproof.p.rapidapi.com/v1/validate"&lt;/span&gt; &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;-H&lt;/span&gt; &lt;span class="s2"&gt;"X-RapidAPI-Key: YOUR_KEY"&lt;/span&gt; &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;-H&lt;/span&gt; &lt;span class="s2"&gt;"Content-Type: application/json"&lt;/span&gt; &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;-d&lt;/span&gt; &lt;span class="s1"&gt;'{"value": "GB29 NWBK 6016 1331 9268 19"}'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You get back the parsed structure, not just a yes:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"type"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"iban"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"valid"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="kc"&gt;true&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"details"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"country_code"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"GB"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"sepa"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="kc"&gt;true&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"bank_code"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"NWBK"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"branch_code"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"601613"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"account_number"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"31926819"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"formatted"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"GB29 NWBK 6016 1331 9268 19"&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now the interesting part. Change the last digit of that account number and the checksum fails, and instead of a bare &lt;code&gt;false&lt;/code&gt; you get the expected check digits and the corrected identifier:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"valid"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="kc"&gt;false&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"errors"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"code"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"bad_checksum"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"expected_check_digits"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"56"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"actual_check_digits"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"29"&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="p"&gt;],&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"correction"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"GB56NWBK60161331926818"&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;There is also a dedicated check-digit endpoint that computes the digit even when the check position holds a placeholder, auto-detection if you do not know what kind of identifier you are holding (a 13-digit 978 number comes back as both ISBN-13 and GTIN-13), and batch validation for up to 100 identifiers per call.&lt;/p&gt;

&lt;p&gt;One caveat about corrections, and credit where due: a commenter on this post, Brenda Coleman, put it more sharply than my first version did. A correction assumes the mistake is in the check digit. In the example above the mistyped digit was in the account number itself, and the "correction" is simply the check digits that the rest of that (wrong) number implies. If a data digit was the one mistyped, the corrected value is a valid identifier, but not necessarily the one you started with. Treat corrections as candidates to confirm, not as recovered originals. The listing now says the same.&lt;/p&gt;

&lt;h2&gt;
  
  
  How it is built
&lt;/h2&gt;

&lt;p&gt;FastAPI on the free tier of Render, with the validation logic kept pure and separate from the web layer. Every validator runs on published standards and official test vectors, and the test suite caught me three real math bugs before launch, including one in the French VAT key formula. The API is stateless and stores nothing: values are processed in transit and forgotten.&lt;/p&gt;

&lt;h2&gt;
  
  
  Pricing
&lt;/h2&gt;

&lt;p&gt;Every endpoint is available on every plan, including the free tier. The validate, batch, check-digit, and types endpoints are all there from the start, with no Pro-only identifier types and no correction feature held back to force an upgrade. Upgrading simply gets you more requests per month: start free with 150 requests a month (and remember, one request can carry a batch of 100), move up to Pro at $9/month for 5,000, Ultra at $19/month for 20,000, or Mega at $49/month for 100,000. You pay for volume, not for access.&lt;/p&gt;

&lt;p&gt;The listing is here: &lt;a href="https://rapidapi.com/darksundarker/api/digitproof" rel="noopener noreferrer"&gt;https://rapidapi.com/darksundarker/api/digitproof&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Feedback very welcome, especially the "I wish it also validated X" kind. That is how the next identifier on the list gets chosen.&lt;/p&gt;

</description>
      <category>api</category>
      <category>python</category>
      <category>fastapi</category>
      <category>validation</category>
    </item>
    <item>
      <title>SynthForge: fake test data with deterministic seeds, custom schemas, and SQL output</title>
      <dc:creator>DSP</dc:creator>
      <pubDate>Mon, 26 Oct 2026 04:11:47 +0000</pubDate>
      <link>https://dev.to/darksun159/synthforge-fake-test-data-with-deterministic-seeds-custom-schemas-and-sql-output-5ebe</link>
      <guid>https://dev.to/darksun159/synthforge-fake-test-data-with-deterministic-seeds-custom-schemas-and-sql-output-5ebe</guid>
      <description>&lt;p&gt;Seeding a database with &lt;code&gt;user1&lt;/code&gt;, &lt;code&gt;user2&lt;/code&gt;, &lt;code&gt;test@test.com&lt;/code&gt; works right up until your UI has to render a real-looking name, your demo needs 500 believable products, or your test suite needs the &lt;em&gt;same&lt;/em&gt; dataset on every run, not a fresh snowflake each time.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;SynthForge&lt;/strong&gt; is a synthetic data API we built at DSP to fix that. It's live on RapidAPI with a free tier.&lt;/p&gt;

&lt;h2&gt;
  
  
  Predefined generators
&lt;/h2&gt;

&lt;p&gt;Seven generators, up to &lt;strong&gt;1,000 records per call&lt;/strong&gt;: &lt;code&gt;person&lt;/code&gt;, &lt;code&gt;company&lt;/code&gt;, &lt;code&gt;address&lt;/code&gt;, &lt;code&gt;product&lt;/code&gt;, &lt;code&gt;user&lt;/code&gt;, &lt;code&gt;payment-card&lt;/code&gt;, and &lt;code&gt;internet&lt;/code&gt;, covering names, safe emails, phones, job titles, SKUs, prices, usernames, IPs, UUIDs, and the rest of the usual test-data furniture.&lt;/p&gt;

&lt;p&gt;Payment cards deserve a specific mention: numbers come only from the standard public test ranges (Visa &lt;code&gt;4242…&lt;/code&gt;, Mastercard &lt;code&gt;5555…&lt;/code&gt;, Amex, Discover), are Luhn-valid so your validators accept them, and every record is flagged &lt;code&gt;"test_only": true&lt;/code&gt;. They will never work for a real purchase, by design.&lt;/p&gt;

&lt;h2&gt;
  
  
  The headline: bring your own schema
&lt;/h2&gt;

&lt;p&gt;Describe the shape you want using any of &lt;strong&gt;38 field generators&lt;/strong&gt;, and get back exactly that shape:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl &lt;span class="nt"&gt;-X&lt;/span&gt; POST https://synthforge.p.rapidapi.com/v1/generate/schema &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;-H&lt;/span&gt; &lt;span class="s2"&gt;"X-RapidAPI-Key: YOUR_KEY"&lt;/span&gt; &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;-H&lt;/span&gt; &lt;span class="s2"&gt;"Content-Type: application/json"&lt;/span&gt; &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;-d&lt;/span&gt; &lt;span class="s1"&gt;'{"schema": {"id": "uuid", "name": "product_name",
                  "price": "price", "city": "city", "zip": "zip_code"},
       "count": 2, "seed": 7}'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;





&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;[{&lt;/span&gt;&lt;span class="nl"&gt;"id"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"6513270e-269e-4d37-b2a7-4de452e6b438"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"name"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"Premium Lamp"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"price"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"395.03"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"city"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"North Loriville"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"zip"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"48432"&lt;/span&gt;&lt;span class="p"&gt;},&lt;/span&gt;&lt;span class="w"&gt;
 &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="nl"&gt;"id"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"81e74ef5-e8e2-4d94-8ed9-04759531985d"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"name"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"Modular Blender"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"price"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"59.99"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"city"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"North Christopher"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"zip"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"55311"&lt;/span&gt;&lt;span class="p"&gt;}]&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Output formats: &lt;strong&gt;JSON, CSV, or SQL &lt;code&gt;INSERT&lt;/code&gt; statements&lt;/strong&gt;, so generated data can go straight into a seed file.&lt;/p&gt;

&lt;h2&gt;
  
  
  Seeds make it deterministic
&lt;/h2&gt;

&lt;p&gt;Every endpoint accepts a &lt;code&gt;seed&lt;/code&gt;. Same seed, same data, byte for byte, seed 42 on the person generator gives you Margaret Johnson today, tomorrow, and in CI. That's the difference between a flaky fixture and a reliable one.&lt;/p&gt;

&lt;p&gt;Locales are supported where they make sense (&lt;code&gt;en_US&lt;/code&gt;, &lt;code&gt;en_GB&lt;/code&gt;, &lt;code&gt;de_DE&lt;/code&gt;, &lt;code&gt;fr_FR&lt;/code&gt;, &lt;code&gt;es_ES&lt;/code&gt;, &lt;code&gt;ja_JP&lt;/code&gt;), and emails use safe, non-deliverable addresses.&lt;/p&gt;

&lt;h2&gt;
  
  
  Pricing
&lt;/h2&gt;

&lt;p&gt;Every endpoint is available on every plan, including the free tier. All seven predefined generators and the custom schema endpoint are included from the start, with no Pro-only generators and no output format held back to force an upgrade. Upgrading simply gets you more requests per month: start free with 150 requests a month, move up to Pro at $4/month for 5,000, Ultra at $9/month for 20,000, or Mega at $24/month for 500,000. And since a single request can generate up to 1,000 records, even the free tier goes a long way. You pay for volume, not for access.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Try it:&lt;/strong&gt; &lt;a href="https://rapidapi.com/darksundarker/api/synthforge" rel="noopener noreferrer"&gt;https://rapidapi.com/darksundarker/api/synthforge&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;What generator is missing for your use case? That's the v1.1 backlog, and it's being written by whoever asks.&lt;/p&gt;

</description>
      <category>api</category>
      <category>python</category>
      <category>testing</category>
      <category>webdev</category>
    </item>
    <item>
      <title>Messy data in, clean records out: RecordScrub, a data-cleaning API</title>
      <dc:creator>DSP</dc:creator>
      <pubDate>Mon, 26 Oct 2026 04:03:46 +0000</pubDate>
      <link>https://dev.to/darksun159/messy-data-in-clean-records-out-recordscrub-a-data-cleaning-api-3ce7</link>
      <guid>https://dev.to/darksun159/messy-data-in-clean-records-out-recordscrub-a-data-cleaning-api-3ce7</guid>
      <description>&lt;p&gt;Every project eventually inherits the same spreadsheet: emails in three different cases, phone numbers formatted six ways, names like "DOE,  john  michael", and the same customer entered twice. Cleaning it by hand, or with a pile of regexes you don't quite trust, is nobody's favorite afternoon.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;RecordScrub&lt;/strong&gt; is a small API we built at DSP to do that job in one call. It's live on RapidAPI now, with a free tier.&lt;/p&gt;

&lt;h2&gt;
  
  
  What it does
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Email validation &amp;amp; normalization&lt;/strong&gt;, single or batch, with valid/invalid stats and a plain-language reason for every rejection&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Phone normalization to E.164&lt;/strong&gt;, powered by Google's libphonenumber, so &lt;code&gt;(312) 555-0142&lt;/code&gt; becomes &lt;code&gt;+13125550142&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Name normalization&lt;/strong&gt;, &lt;code&gt;"DOE,  john  michael"&lt;/code&gt; → &lt;code&gt;John Michael Doe&lt;/code&gt;, with first/last split out&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;US address normalization&lt;/strong&gt;, state codes, ZIP+4, standardized street suffixes&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Batch record cleaning&lt;/strong&gt;, send CSV-style records, get snake_case keys, per-field cleaning, and exact dedupe on the fields &lt;em&gt;you&lt;/em&gt; choose, with a duplicate report showing what was dropped and why&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Every dropped or altered value comes back with a &lt;code&gt;_warnings&lt;/code&gt; explanation. No silent data loss.&lt;/p&gt;

&lt;h2&gt;
  
  
  A taste
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl &lt;span class="nt"&gt;-X&lt;/span&gt; POST https://record-scrub.p.rapidapi.com/v1/normalize/phone &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;-H&lt;/span&gt; &lt;span class="s2"&gt;"X-RapidAPI-Key: YOUR_KEY"&lt;/span&gt; &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;-H&lt;/span&gt; &lt;span class="s2"&gt;"Content-Type: application/json"&lt;/span&gt; &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;-d&lt;/span&gt; &lt;span class="s1"&gt;'{"phone": "(312) 555-0142"}'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;





&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="nl"&gt;"original"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"(312) 555-0142"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"normalized"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"+13125550142"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
 &lt;/span&gt;&lt;span class="nl"&gt;"valid"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="kc"&gt;true&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"country_code"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"national_format"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"(312) 555-0142"&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;And the batch cleaner, deduplicating on email + phone:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="nl"&gt;"records"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;[{&lt;/span&gt;&lt;span class="nl"&gt;"name"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"John Doe"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"email"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"john@example.com"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
              &lt;/span&gt;&lt;span class="nl"&gt;"phone"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"+13125550142"&lt;/span&gt;&lt;span class="p"&gt;}],&lt;/span&gt;&lt;span class="w"&gt;
 &lt;/span&gt;&lt;span class="nl"&gt;"stats"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="nl"&gt;"received"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"returned"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"duplicates_removed"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;},&lt;/span&gt;&lt;span class="w"&gt;
 &lt;/span&gt;&lt;span class="nl"&gt;"duplicates"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;[{&lt;/span&gt;&lt;span class="nl"&gt;"index"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"duplicate_of"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"record"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"..."&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"..."&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;}}]}&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Two things worth stating plainly, prompted by a comment from Benjamin Fisher below. First, normalization is not verification: a valid result means an email is well-formed, not that a mailbox exists, and a standardized address is formatted, not verified deliverable. Second, on dedupe: matching is exact, on the cleaned values of the fields you choose. When two records normalize to the same key, the first record is kept, and the later one is dropped and listed in the duplicates report with its original index and which record it duplicated, so you can audit a merge before trusting it.&lt;/p&gt;

&lt;h2&gt;
  
  
  How it's built
&lt;/h2&gt;

&lt;p&gt;FastAPI, completely stateless. Requests are processed in transit and &lt;strong&gt;nothing is stored&lt;/strong&gt;, so there's no database to leak from. It runs on a free-tier host, so the first call after a quiet spell can take a few extra seconds while it wakes up; after that it's fast.&lt;/p&gt;

&lt;h2&gt;
  
  
  Pricing
&lt;/h2&gt;

&lt;p&gt;Every endpoint is available on every plan, including the free tier. No feature gates, no Pro-only cleaners, no endpoint held back to force an upgrade. Upgrading simply gets you more requests per month: start free with 100 requests a month, move up to Pro at $10/month for 5,000, and scale from there if your batch volume grows. You pay for volume, not for access.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Try it:&lt;/strong&gt; &lt;a href="https://rapidapi.com/darksundarker/api/record-scrub" rel="noopener noreferrer"&gt;https://rapidapi.com/darksundarker/api/record-scrub&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Feedback very welcome, especially the "I wish it also cleaned X" kind. That's how the v2 list gets written.&lt;/p&gt;

</description>
      <category>api</category>
      <category>python</category>
      <category>fastapi</category>
      <category>webdev</category>
    </item>
  </channel>
</rss>
