@ratelimit()
@requires_auth('home')
def home_endpoint():
 response = {}
 if config.INFO:
  info = {}
  info['server'] = 'Eve'
  info['version'] = eve.__version__
  if config.API_VERSION:
   info['api_version'] = config.API_VERSION
  response[config.INFO] = info
 if config.HATEOAS:
  links = []
  for resource in config.DOMAIN.keys():
   internal = config.DOMAIN[resource]['internal_resource']
   if (not resource.endswith(config.VERSIONS)):
    if (not bool(internal)):
     links.append({'href': ('%s' % config.URLS[resource]), 'title': ('%s' % config.DOMAIN[resource]['resource_title'])})
  if (config.SCHEMA_ENDPOINT is not None):
   links.append({'href': ('%s' % config.SCHEMA_ENDPOINT), 'title': ('%s' % config.SCHEMA_ENDPOINT)})
  response[config.LINKS] = {'child': links}
  return send_response(None, (response,))
 else:
  return send_response(None, (response,))

@ ratelimit ( ) @ requires_auth ( 'home' ) def home_endpoint ( ) : response = { } if config . INFO : info = { } info [ 'server' ] = 'Eve' info [ 'version' ] = eve . __version__ if config . API_VERSION : info [ 'api_version' ] = config . API_VERSION response [ config . INFO ] = info if config . HATEOAS : links = [ ] for resource in config . DOMAIN . keys ( ) : internal = config . DOMAIN [ resource ] [ 'internal_resource' ] if ( not resource . endswith ( config . VERSIONS ) ) : if ( not bool ( internal ) ) : links . append ( { 'href' : ( '%s' % config . URLS [ resource ] ) , 'title' : ( '%s' % config . DOMAIN [ resource ] [ 'resource_title' ] ) } ) if ( config . SCHEMA_ENDPOINT is not None ) : links . append ( { 'href' : ( '%s' % config . SCHEMA_ENDPOINT ) , 'title' : ( '%s' % config . SCHEMA_ENDPOINT ) } ) response [ config . LINKS ] = { 'child' : links } return send_response ( None , ( response , ) ) else : return send_response ( None , ( response , ) )
home/api entry point .