Postgresql database NOTIFICATION trigger that only returns if some sql is met
You have two options:
1. Do it in the trigger with an IF condition:
if new.site = 'X' then 
  notify ...  
end if;

2. Only fire the trigger if the column contains the value:
create trigger notify_site 
after insert on sites 
for each row 
when (new.site = 'X') 
execute procedure notify_site();



how would I insert the tablename into the json object being returned by the select all?

As documented in the manual the table name is available in the variable TG_RELNAME, so you could just append that to your JSON:
payload := payload || jsonb_build_object('tableName', TG_RELNAME);