An API call is your app asking another service for data or action. A webhook is the other service telling your app that something happened. Use APIs when your user needs live data; use webhooks when the event starts outside your app.

Keep secrets out of the frontend. API keys live in server functions or edge functions, not in React code that a browser can read.

Integration prompt
Add a server function that calls [service] API at [endpoint]. It should accept [input] and return [output]. Store the API key in a server-side environment variable, not in the client.