Call a Postgres function
POST
/v1/db/{project_id}/rpc/{function}Invokes a PL/pgSQL function. Automatically generated TypeScript types. RLS applied in the function body via SECURITY INVOKER.
This English text was generated automatically from the French original and has not been reviewed yet.
#
Request
Bodysuit
| Parameter | Type | Required | Description |
|---|---|---|---|
function | string | yes | Name of the Postgres function (in your project schema). |
args | object | no | Named arguments passed to the function. Inferred types on the SDK side. |
#
Notes
Engine
Attention
This route only exists for Postgres projects served by PostgREST — it is PostgREST that executes the call. The aura-db service (MongoDB project, or Postgres with PostgREST disabled) does not declare any /rpc/routes.
#
Notes
Security
Attention
By default, functions are created in SECURITY INVOKER. To bypass RLS in a function, use SECURITY DEFINER with caution — document why.
v1.0 · revised Apr 15, 2026