docs: def get_package_formats():
      """Get the list of available package formats and parameters."""
      # pylint: disable=fixme
      # HACK: This obviously isn't great, and it is subject to change as
      # the API changes, but it'll do for now as a interim method of
      # introspection to get the parameters we need.
      def get_parameters(cls):
          """Build parameters for a package format."""
          params = {}
  
          # Create a dummy instance so we can check if a parameter is required.
          # As with the rest of this function, this is obviously hacky. We'll
          # figure out a way to pull this information in from the API later.
          dummy_kwargs = {k: "dummy" for k in cls.swagger_types}
          instance = cls(**dummy_kwargs)
  
          for k, v in six.iteritems(cls.swagger_types):
              attr = getattr(cls, k)
              docs = attr.__doc__.strip().split("\n")
              doc = (docs[1] if docs[1] else docs[0]).strip()
  
              try:
                  setattr(instance, k, None)
                  required = False
              except ValueError:
                  required = True
  
              params[cls.attribute_map.get(k)] = {
                  "type": v,
                  "help": doc,
                  "required": required,
              }
  
          return params
  
      return {
          key.replace("PackagesUpload", "").lower(): get_parameters(cls)
          for key, cls in inspect.getmembers(cloudsmith_api.models)
          if key.startswith("PackagesUpload")
      }