code: def make_pagination_args(
      limit: int = 200,
      offset: int = 0,
      pages: api.PageOpts = api.PageOpts.all,
      supports_reverse: bool = False,
  ) -> List[declarative_argparse.Arg]:
      if pages not in PAGE_CHOICES:
          raise NotImplementedError
  
      res = [
          declarative_argparse.Arg(
              "--limit",
              type=int,
              default=limit,
              help="Maximum items per page of results",
          ),
          declarative_argparse.Arg(
              "--offset",
              type=int,
              default=offset,
              help="Number of items to skip before starting page of results",
          ),
          declarative_argparse.Arg(
              "--pages",
              type=api.PageOpts,
              choices=PAGE_CHOICES,
              default=pages.value,
              help="when set to 'all', fetch all available data; when '1', fetch a single page",
          ),
      ]
  
      if supports_reverse:
          res += [
              declarative_argparse.Arg(
                  "--reverse",
                  default=False,
                  action="store_true",
                  help="Reverse the requested order of results.",
              ),
          ]
  
      return res
  
file_path: determined/harness/determined/cli/_util.py
imports: import argparse
  import functools
  import sys
  from typing import Any, Callable, Dict, List, Sequence
  import termcolor
  from determined.cli import errors, render
  from determined.common import api, declarative_argparse, util
  from determined.common.api import authentication, bindings, certs
  from determined.experimental import client
label_desc: Use image node_id 1 for calling a global function with example usage: make_pagination_args(limit, offset, pages, supports_reverse) and returns: res