https://developer.zendesk.com/rest_api/docs/core/apps#list-requirements
774275
def apps_installation_requirements(self, id, **kwargs):
        ""
        api_path = "/api/v2/apps/installations/{id}/requirements.json"
        api_path = api_path.format(id=id)
        return self.call(api_path, **kwargs)
507340
def helper_list(access_token, oid, path):
    '''
    '''
    if oid != "":
        path = ''.join([path, "('", oid, "')"])
    endpoint = ''.join([ams_rest_endpoint, path])
    return do_ams_get(endpoint, path, access_token)
904909
@SuppressWarnings("unused") // called through reflection by RequestServer
  public MetadataV3 listRoutes(int version, MetadataV3 docs) {
    MarkdownBuilder builder = new MarkdownBuilder();
    builder.comment("Preview with http://jbt.github.io/markdown-editor");
    builder.heading1("REST API Routes Table of Contents");
    builder.hline();

    builder.tableHeader("HTTP method", "URI pattern", "Input schema", "Output schema", "Summary");

    docs.routes = new RouteV3[RequestServer.numRoutes()];
    int i = 0;
    for (Route route : RequestServer.routes()) {
      RouteV3 schema = new RouteV3(route);
      docs.routes[i] = schema;

      // ModelBuilder input / output schema hackery
      MetadataV3 look = new MetadataV3();
      look.routes = new RouteV3[1];
      look.routes[0] = schema;
      look.path = route._url;
      look.http_method = route._http_method;
      fetchRoute(version, look);

      schema.input_schema = look.routes[0].input_schema;
      schema.output_schema = look.routes[0].output_schema;

      builder.tableRow(
              route._http_method,
              route._url,
              Handler.getHandlerMethodInputSchema(route._handler_method).getSimpleName(),
              Handler.getHandlerMethodOutputSchema(route._handler_method).getSimpleName(),
              route._summary);
      i++;
    }

    docs.markdown = builder.toString();
    return docs;
  }
981353
def parse_requirements(path):
    
    try:
        print(os.path.join(os.path.dirname(__file__), *path.splitlines()))
        requirements = map(str.strip, local_file(path).splitlines())
    except IOError:
        raise RuntimeError("Couldn't find the `requirements.txt' file :(")

    links = []
    pkgs = []
    for req in requirements:
        if not req:
            continue
        if 'http:' in req or 'https:' in req:
            links.append(req)
            name, version = re.findall("\#egg=([^\-]+)-(.+$)", req)[0]
            pkgs.append('{0}=={1}'.format(name, version))
        else:
            pkgs.append(req)

    return pkgs, links
157293
def get_requirements(
            self, install=True, extras=True, setup=False, tests=False):
        """"""
        requires = []
        if install:
            requires.extend(parse_requirements(
                self.keywords.get('install_requires', ()),
            ))
        if extras:
            for r in self.keywords.get('extras_require', {}).values():
                requires.extend(parse_requirements(r))
        if setup:
            requires.extend(parse_requirements(
                self.keywords.get('setup_requires', ()),
            ))
        if tests:
            requires.extend(parse_requirements(
                self.keywords.get('tests_require', ()),
            ))
        return requires
1370436
def get_required(self, obj):
        """"""
        required = []

        for field_name, field in sorted(obj.fields.items()):
            if field.required:
                required.append(field.name)

        return required or missing
760344
def _requirements_to_dict(rs):
    
    out = []
    added = set([])
    for r in rs:
        if r["class"] == "DockerRequirement" and "docker" not in added:
            added.add("docker")
            out.append({"requirement_type": "docker", "value": r["dockerImageId"]})
        elif r["class"] == "ResourceRequirement":
            if "coresMin" in r and "cpu" not in added:
                added.add("cpu")
                out.append({"requirement_type": "cpu", "value": r["coresMin"]})
            if "ramMin" in r and "memory" not in added:
                added.add("memory")
                out.append({"requirement_type": "memory", "value": "%s MB" % r["ramMin"]})
            if "tmpdirMin" in r and "disks" not in added:
                added.add("disks")
                out.append({"requirement_type": "disks", "value": "local-disk %s HDD" % r["tmpdirMin"]})
    return out
657360
function listItemsController(path) {
    restController.call(this, 'get', path);

    var ctrl = this;

    /**
     * Ignore empty by default on list controller
     * because parameters are most likly for search
     */
    ctrl.ignoreEmptyParams = true;

    /**
     * Method to paginate a mongoose query
     * @param {Integer} total
     * @param {Query} query
     * @param {Integer} [itemsPerPage=50]
     *
     * @return {Query}
     */
    this.paginate = function(total, query, itemsPerPage) {


        var paginate = require('node-paginate-anything');
        var p = paginate(ctrl.req, ctrl.res, total, itemsPerPage || 50);

        if (!p) {
            return query;
        }

        query.limit(p.limit);
        query.skip(p.skip);

        return query;
    };


    /**
     * List controller use this method to output a service as a rest
     * service
     *
     * This default method is paginated
     *
     * @param {apiService} service
     *
     * @return {Promise}
     */
    this.jsonService = function(service) {

        var params = ctrl.getServiceParameters(ctrl.req);

        var promise = service.getResultPromise(params, ctrl.paginate);

        ctrl.outputJsonFromPromise(service, promise);

        return promise;
    };
}
1228614
def get_requirements():
    """"""
    with open(os.path.join(topdir, 'requirements.txt')) as fin:
        lines = fin.readlines()
    lines = [line.strip() for line in lines]
    return lines
739049
def list_apis(awsclient):
    """"""
    client_api = awsclient.get_client('apigateway')

    apis = client_api.get_rest_apis()['items']

    for api in apis:
        print(json2table(api))
262843
def get_list(client, list_id):
    '''  '''
    endpoint = '/'.join([client.api.Endpoints.LISTS, str(list_id)])
    response = client.authenticated_request(endpoint)
    return response.json()
1004392
def _requirements(self):
        
        return {'memory': getattr(self, 'memory', None),
                'cores': getattr(self, 'cores', None),
                'disk': getattr(self, 'disk', None),
                'preemptable': getattr(self, 'preemptable', None)}
413825
def get_requirements(opts):
    '''  '''

    if opts.dev:
        name = 'requirements_dev.txt'
    elif opts.doc:
        name = 'requirements_doc.txt'
    else:
        name = 'requirements.txt'

    requirements_file = os.path.join(os.path.dirname(__file__), name)
    install_requires = [line.strip().replace('==', '>=') for line in open(requirements_file)
                        if not line.strip().startswith('#') and line.strip() != '']
    return install_requires
528403
function list(appName, callback) {
    commons.get(format('/%s/apps/%s/perms/', deis.version, appName), callback);
  }
1216146
def check_app_requirement(specs)
      missing = []
      specs.each do |spec|
        if wagon = wagon_class(spec)
          unless wagon.app_requirement.satisfied_by?(Wagons.app_version)
            missing << "#{spec} requires application version #{wagon.app_requirement}"
          end
        end
      end

      missing
    end
389202
def getRequiredAttrs(self):
        
        required = []
        for type_uri, attribute in self.requested_attributes.iteritems():
            if attribute.required:
                required.append(type_uri)

        return required
1120788
def check_requirements():
    
    if not os.path.exists(REQUIREMENTS):
        sys.exit(
            ansi.error() + ' %s is missing. Please check it in.' % ansi.underline(REQUIREMENTS)
        )

    with open(REQUIREMENTS, 'r', encoding='utf-8') as f:
        dependencies = f.readlines()

    vcs = [d for d in dependencies if re.match(r'^(-e )?(git|svn|hg|bzr).*', d)]

    dependencies = list(set(dependencies) - set(vcs))

    missing = []
    try:
        pkg_resources.require(dependencies)
    except (
        pkg_resources.ContextualVersionConflict,
        pkg_resources.DistributionNotFound,
        pkg_resources.VersionConflict
    ) as error:
        missing.append(str(error))
    except pkg_resources.RequirementParseError:
        pass

    if missing:
        missing = ' missing requirement:\n  ' + os.linesep.join(missing)
        if '--env-checked' in sys.argv:
            sys.exit(ansi.error() + missing + '\nRequirement installation failure, please check for errors in:\n $ lore install\n')
        else:
            print(ansi.warning() + missing)
            import lore.__main__
            lore.__main__.install_requirements(None)
            reboot('--env-checked')