docs: def list_packages(owner, repo, **kwargs):
      """List packages for a repository."""
      client = get_packages_api()
  
      api_kwargs = {}
      api_kwargs.update(utils.get_page_kwargs(**kwargs))
      api_kwargs.update(utils.get_query_kwargs(**kwargs))
  
      with catch_raise_api_exception():
          data, _, headers = client.packages_list_with_http_info(
              owner=owner, repo=repo, **api_kwargs
          )
  
      ratelimits.maybe_rate_limit(client, headers)
      page_info = PageInfo.from_headers(headers)
      return [x.to_dict() for x in data], page_info