You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: module7-cloud-computing/r4.1-cloud-functions/README.md
+31-13Lines changed: 31 additions & 13 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -33,20 +33,37 @@ There are two distinct types of Cloud Functions: HTTP functions and event-driven
33
33
34
34
You invoke HTTP functions from standard HTTP requests. These HTTP requests wait for the response and support handling of common HTTP request methods like GET, PUT, POST, DELETE and OPTIONS. When you use Cloud Functions, a TLS certificate is automatically provisioned for you, so all HTTP functions can be invoked via a secure connection.
35
35
36
-
```js
37
-
constescapeHtml=require("escape-html");
36
+
This is an example using the Firebase SDK for Cloud Functions with an HTTPS trigger through building an endpoint returning the current time.
37
+
The function date returns the current server date. You can pass it a format URL Query parameter to format the date.
38
38
39
-
/**
40
-
* HTTP Cloud Function.
41
-
*
42
-
* @param{Object}req Cloud Function request context.
43
-
* More info: https://expressjs.com/en/api.html#req
44
-
* @param{Object}res Cloud Function response context.
45
-
* More info: https://expressjs.com/en/api.html#res
0 commit comments