Server-side functions

Keep private operations and third-party credentials out of the app.

By Apirex Team · Updated

On this page

When server code is needed

Use server-side work for payment verification, webhooks, protected email sending and operations that use private credentials. A browser or installed app can be inspected; it is not a safe place for a secret.

  1. Connect the project backend and describe the operation.
  2. Specify how the caller is verified and which records it may affect.
  3. Store required private credentials through the connected backend’s secrets interface.
  4. Deploy the function and test the call from the app; inspect logs without exposing credentials.

Webhooks

Verify the provider’s signature and process repeated events idempotently. A public endpoint is not permission to accept unverified payment claims.