parameters: (query_parameter, default=None)
docstring: Obtains an integer parameter and ensures its type
docstring_summary: Obtains an integer parameter and ensures its type
docstring_tokens: Obtains an integer parameter and ensures its type
function: def get_integer_parameter(query_parameter, default=None):
      """Obtains an integer parameter and ensures its type"""
      param = request.args.get(query_parameter)
      try:
          return int(param) if param is not None else default
      except ValueError:
          abort(400)
function_tokens: def get_integer_parameter ( query_parameter , default = None ) : param = request . args . get ( query_parameter ) try : return int ( param ) if param is not None else default except ValueError : abort ( 400 )