Skip to main content
A Cloud function does work that shouldn’t run in a visitor’s browser. You decide when you need one, describe the behavior, and test the whole flow. You don’t need to read its code or change its sign-in settings.

Know when you need a Cloud function

Keep layout, form behavior, and result display on the page (the frontend). Ask for a Cloud function when the app needs to:
  • Send an email or notification through an outside service.
  • Call a third-party API that needs a private credential.
  • Check a request or make a protected data change on the server.
Example: A visitor submits a contact form. The page collects the message and shows the result. A Cloud function checks the request, calls the email service with a saved secret, and returns success or an error.
Keep secrets out of the page. Store API keys in secret storage, never in frontend code, browser requests, screenshots, or visible errors. Name the service and secret the function should use. Don’t move a key into the page to fix a failed request.

Describe the flow you want

Tell Enter what should happen, not how to set up sign-in checks. Cover four parts. Copy and adapt this example:
Describe input, access, success, and failure in project chat.

Describe input, access, success, and failure in project chat.

Test the complete flow

  • Submit valid input and confirm the page shows success.
  • Confirm the real result happened, such as an email arriving or data being updated.
  • Submit invalid or incomplete input. The page should show a useful error with no keys or internal details.

Troubleshooting

A function that exists doesn’t prove the page calls it or the service accepts its request. Ask Enter for the complete user flow.
Tell Enter what you did, what you expected, what happened, and the error on the page.
Don’t switch off authentication checks. Ask Enter to review how the page calls the function and fix it safely.

Common questions

Use a Cloud function when your app must handle a private credential, validate a request, or make a protected data change on the server. Keep layout, form behavior, and result display in the frontend.
Save each credential in Cloud Secrets and refer to it by name. Never place the value in frontend code, browser requests, project chat, screenshots, or visible errors.

Keep going

Next: Add and protect Cloud secrets
Your function needs its private key saved safely.

Connect Stripe for app payments

Take payments with a Stripe checkout.

Create, manage, and delete an Enter Cloud instance

Open and manage your Cloud instance.