how to limit amount of rows in jsonb_agg & jsonb_build_object
LIMIT 3 will work just fine if you add it in the right fashion, that is before the rows are aggregated:
SELECT jsonb_agg(jsonb_build_object('me_id', me_id))
FROM (SELECT me_id FROM message LIMIT 3) AS subquery;