./example/build.shkubectl port-forward service/postgrest 30001:3000
kubectl port-forward service/postgrest 30002:8000
schema usage is allowed; therefore, basic information can be queried
curl localhost:30001 | jqbut specific data must have permissions granted
curl localhost:30001/notes | jqUsing the keyserver api key, request a short-lived token
export token=$(curl -H "Authorization: Bearer a-string-secret-at-least-256-bits-long" localhost:30002/peek | jq -r '.access_token')and make a request
curl -H "Authorization: Bearer $token" localhost:30001/notes | jqfirst, obtain a JWT from your OIDC service. The service's JWK must be loaded into the keyserver to verify the token. Then, can view
curl -H "Authorization: Bearer $token" localhost:30001/notes | jqbut not edit
curl -H "Content-Type: application/json" -H "Authorization: Bearer $token" localhost:30001/notes -d '{"note":"meow"}'Now obtain a JWT with the edit role. You can still view
curl -H "Authorization: Bearer $token" localhost:30001/notes | jqbut also edit
curl -H "Content-Type: application/json" -H "Authorization: Bearer $token" localhost:30001/notes -d '{"note":"meow"}'