RestAPI.com provides serverless functions that execute custom JavaScript code in response to events, on schedules, or via HTTP endpoints.
Function Types
| Type | Trigger | Use Case |
|---|
| Trigger | Data changes (POST, PUT, PATCH, DELETE) | Validate, transform, sync data |
| Timer | Scheduled intervals | Background jobs, cleanup, reports |
| Invocable | HTTP requests to custom endpoints | Custom APIs, webhooks, integrations |
Quick Comparison
| Feature | Trigger | Timer | Invocable |
|---|
| Automatic execution | On data change | On schedule | Manual (HTTP call) |
| Collection monitoring | Yes | No | No |
| Custom HTTP endpoint | No | No | Yes |
| Access control | Via execution context | Via execution context | Role-based per method |
Action Types
Functions can execute two types of actions:
| Action | Description |
|---|
| JavaScript | Custom code executed in serverless containers |
| External Endpoint | Call an external webhook/HTTP endpoint |
In This Section