This is the beginning of my code..
const { onCall } = require("firebase-functions/v2/https");
const { getFirestore, Timestamp } = require("firebase-admin/firestore");
const { initializeApp } = require("firebase-admin/app");
initializeApp();
const db = getFirestore();
exports.registerUser = onCall({ region: "europe-west2" }, async (request) => {
const { auth, data } = request;
if (!auth || !auth.uid) {
return { error: "UNAUTHENTICATED" };
}
I don't understand why it's being registered on firebase as http function (Check the icon and the url in red).
I already delete manually , also deleted via cli...but this persists...is there something on my code that's not correct?
Callable type functions are just a special kind of HTTP function that handles a bunch of stuff automatically by the Firebase SDK. They are ultimately both HTTP triggers as recognized by Google Cloud Platform, and the console cannot distinguish between them, because they differ only by the code that runs in response to the HTTP request.
See also: How do Callable Cloud Functions compare to HTTP functions?
If you find it absolutely necessary to tell them apart in the console, consider filing a feature request with Firebase support, but I suspect this sort of change will never happen (as it's been many years since they've both been available).