code: def configure_discover(self, ns, definition):
          
          @self.add_route(ns.singleton_path, Operation.Discover, ns)
          def discover():
              swagger = build_swagger(self.graph, ns, self.find_matching_endpoints(ns))
              g.hide_body = True
              return make_response(swagger)
docs: Register a swagger endpoint for a set of operations.