Skip to content
All tool news

Tool desk · Updated daily

Tool news·Netlify·

Netlify Functions Now Support Fetchable Module Interface for Cross-Platform Compatibility.

Netlify Functions add native support for the fetchable module convention used by Deno, Bun, Hono, and Nitro, unifying HTTP and event handlers.

CW

Create With tool desk

1 source checked · 2 min read · 3 sections

ShareLinkedIn
Netlify Functions Now Support Fetchable Module Interface for Cross-Platform Compatibility

Netlify announced that its Functions now support the fetchable module interface convention natively, letting developers reuse code written for Deno, Bun, Hono, or Nitro with minimal changes. The update also unifies how Functions handle web requests and platform events through a single default export.

The fetchable module interface is a standard convention for defining serverless functions that has gained adoption across multiple JavaScript runtimes. By supporting it natively, Netlify eliminates the need to rewrite code when migrating from other platforms or frameworks. Developers can now deploy the same function module to Netlify that they run locally with Bun or serve through Hono, without adapting to a Netlify-specific API.

Unified HTTP and Event Handling

The new interface consolidates two previously separate concerns. A single module can export a fetch handler to respond to HTTP requests and include named event handlers like deploySucceeded, userLogin, or formSubmitted alongside it. This approach reduces boilerplate and keeps related logic in one place.

export default {
  async fetch(request) {
    return new Response('Hello from HTTP');
  },
  async deploySucceeded(event) {
    // Handle deploy event
  }
};

Previously, web handlers and event-driven logic required separate files or configuration. The unified pattern mirrors what developers already use in modern frameworks and runtimes, making Netlify Functions easier to understand and maintain.

Ecosystem Interoperability

Supporting a shared convention means code can move between platforms with less friction. A function written for Deno Deploy or a Hono app can run on Netlify without platform-specific wrappers. This interoperability matters for teams that prototype locally with tools like Bun, then deploy to Netlify without rewriting their serverless logic.

The change also aligns with Netlify's broader push toward AI-native development. As previously covered, the platform has been redesigning its Functions API to be more accessible to AI agents and developers using code generation tools. Standard conventions make it easier for LLMs to generate correct code, since they can rely on patterns already present in training data from Deno, Bun, and other popular runtimes.

Practical Implications

For developers already using Netlify, existing Functions continue to work as before. The fetchable module interface is an optional pattern that becomes available alongside current approaches. Teams migrating from other platforms gain a clearer path: copy the function module, adjust environment variables if needed, and deploy.

The update ships without breaking changes. Netlify's official blog post provides migration examples and explains how the new interface fits into the platform's broader architecture. Developers can start using the fetchable module pattern immediately in new Functions or incrementally refactor existing ones.

This move follows Netlify's recent focus on making its platform more agent-friendly and standards-compliant, including the launch of AXIS to measure API ergonomics for AI tools. By adopting conventions used across the JavaScript ecosystem, Netlify reduces the learning curve for new users and makes its Functions more portable across environments.

Sources

1 checked

How we cover tool news: Create With's tool desk drafts these reports with AI from the sources listed above and checks them against those sources before publishing.

Worth passing on?

ShareLinkedIn

Latest tool news

What else changed this week.

All tool news
VercelDigest

What Vercel Shipped in Late October

Vercel shipped quicker static deployments, four AI Gateway models, more free domain choices and new CLI controls in late October. The changes cover developers testing sites…

Vercel

Vercel Adds Submit_feedback to Its MCP

submitfeedback is a new Vercel MCP tool that lets agents and harnesses send bug reports, friction reports and feature requests directly to the Vercel team. Feedback can include…

The Create With Briefing

Don't watch forty changelogs. Read one email.

Every Tuesday: the tool changes worth knowing, real business use cases, and what's on near you. Free, unsubscribe any time.