Code adapted to the API result