Foreign Key (references) constraint on PostgreSQL Foreign Data Wrapper?
The PostgREST team gave a potential solution: faking the foreign key constraints.

They read the pg_catalog.pg_constraint table to get this information.  The idea was that I could manipulate the search_path and create my own pg_constraint table where I could make the fake foreign keys:



CREATE TABLE pg_constraint (LIKE pg_catalog.pg_constraint);

ALTER ROLE postgrest IN DATABASE p2k SET search_path = public, remote, pg_catalog;


I was able to make such a table, and the query they use gave something reasonable back.  However it seems to fail for some other reason.

It's also hackish and quite a bother to create the information in pg_constraint correctly.  So I probably won't accept this answer, just wanted to put it here because it might work for someone else / some similar use case.