diff --git a/endpoints/api.py b/endpoints/api.py index 027503f45..a6a69f433 100644 --- a/endpoints/api.py +++ b/endpoints/api.py @@ -70,7 +70,7 @@ def get_route_data(): routes = [] for rule in app.url_map.iter_rules(): if rule.endpoint.startswith('api.'): - endpoint_method = globals()[rule.endpoint[4:]] # Remove api. + endpoint_method = app.view_functions[rule.endpoint] is_internal = '__internal_call' in dir(endpoint_method) is_org_api = '__user_call' in dir(endpoint_method) methods = list(rule.methods.difference(['HEAD', 'OPTIONS']))