validation and routes