...
ECMWF makes available a GRIB decoding library (grib_apiecCodes) for the benefit of the WMO community. grib_api ecCodes can be freely downloaded from here and the documentation can be found here.
grib_api ecCodes provides a simplified access to GRIB2 headers through a set of virtual keys documented here.
...