Skip to Content
ReferenceREST (PostgREST)

REST (PostgREST)

Use this page with Global Geobase context.

What this service is

PostgREST exposes Postgres tables/views as REST resources.

When an agent should use it in a Next.js app

Use for most CRUD reads/writes from server routes or server actions.

Base URL from CLI output

{origin}/rest/v1/

Auth required

  • Browser: anon key with row-level security.
  • Server: service role key for privileged operations.

Minimal request example

curl "${GEOBASE_PROJECT_URL}/rest/v1/my_table?select=*" \ -H "apikey: ${GEOBASE_ANON_KEY}" \ -H "Authorization: Bearer ${GEOBASE_ANON_KEY}"

Human checkpoint

Confirm table policies allow the intended access pattern before shipping.

Last updated on