Skip to content

fix: route contact API to Netlify function - #36

Merged
kamycoding merged 1 commit into
mainfrom
fix/contact-netlify-routing
Aug 11, 2026
Merged

fix: route contact API to Netlify function#36
kamycoding merged 1 commit into
mainfrom
fix/contact-netlify-routing

Conversation

@kamycoding

Copy link
Copy Markdown
Owner

No description provided.

Copilot AI lite review requested due to automatic review settings August 11, 2026 20:07
@netlify

netlify Bot commented Aug 11, 2026

Copy link
Copy Markdown

Deploy Preview for fanciful-cannoli-268c0c ready!

Name Link
🔨 Latest commit 890574b
🔍 Latest deploy log https://app.netlify.com/projects/fanciful-cannoli-268c0c/deploys/6a7b80ebd0359d0008a053a4
😎 Deploy Preview https://deploy-preview-36--fanciful-cannoli-268c0c.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
🤖 Make changes Run an agent on this branch

To edit notification comments on pull requests, go to your Netlify project configuration.

@kamycoding
kamycoding merged commit 8d0c177 into main Aug 11, 2026
5 checks passed
@kamycoding
kamycoding deleted the fix/contact-netlify-routing branch August 11, 2026 20:08

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adjusts how the /api/contact endpoint is routed in the Netlify deployment by moving the route mapping out of the Netlify Function config and into netlify.toml redirects, while preserving the function’s native rate limiting configuration.

Changes:

  • Remove config.path from the contact Netlify function and update the related unit test expectations.
  • Add a Netlify rewrite redirect mapping /api/contact/.netlify/functions/contact.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.

File Description
netlify/tests/contact.spec.ts Updates test expectations to validate rate limiting config without asserting a path mapping.
netlify/functions/contact.mts Removes config.path, leaving only the native rateLimit configuration.
netlify.toml Adds a redirect/rewrite so /api/contact is served by the contact Netlify function.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

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