Use type to validate urls