After building a function and hosting (for a custom domain), I'm noticing that my POST request is getting processed as a GET in the logs.
This is my firebase.json file
{
"hosting": {
"public": "public",
"ignore": ["firebase.json", "**/.*", "**/node_modules/**"],
"rewrites": [
{
"source": "**",
"function": "myFunc"
}
]
},
"functions": [
{
"source": "functions",
"codebase": "default",
"ignore": ["node_modules", ".git", "firebase-debug.log", "firebase-debug.*.log", "*.local"]
}
]
}
In my logging, I see only GET requests when hitting the rewritten URL, but I'm using postman and when I hit the URL directly (not through the rewrite), it works as expected. It also works as expected when using the local firebase:emulators
.
I discovered from my searching that https://
is required for POST requests.