gre: update gre.api with explicit types