This should be :environment_id so match api/hosts/:id with hosts/:id