docs: def start_archive(self, session_id, has_audio=True, has_video=True, name=None, output_mode=OutputModes.composed, resolution=None):
          """
          Starts archiving an OpenTok session.
  
          Clients must be actively connected to the OpenTok session for you to successfully start
          recording an archive.
  
          You can only record one archive at a time for a given session. You can only record archives
          of sessions that use the OpenTok Media Router (sessions with the media mode set to routed);
          you cannot archive sessions with the media mode set to relayed.
  
          For more information on archiving, see the
          `OpenTok archiving <https://tokbox.com/opentok/tutorials/archiving/>`_ programming guide.
  
          :param String session_id: The session ID of the OpenTok session to archive.
          :param String name: This is the name of the archive. You can use this name
            to identify the archive. It is a property of the Archive object, and it is a property
            of archive-related events in the OpenTok.js library.
          :param Boolean has_audio: if set to True, an audio track will be inserted to the archive.
            has_audio is an optional parameter that is set to True by default. If you set both
            has_audio and has_video to False, the call to the start_archive() method results in
            an error.
          :param Boolean has_video: if set to True, a video track will be inserted to the archive.
            has_video is an optional parameter that is set to True by default.
          :param OutputModes output_mode: Whether all streams in the archive are recorded
            to a single file (OutputModes.composed, the default) or to individual files
            (OutputModes.individual).
          :param String resolution (Optional): The resolution of the archive, either "640x480" (the default)
            or "1280x720". This parameter only applies to composed archives. If you set this
            parameter and set the output_mode parameter to OutputModes.individual, the call to the
            start_archive() method results in an error.
  
          :rtype: The Archive object, which includes properties defining the archive,
            including the archive ID.
          """
          if not isinstance(output_mode, OutputModes):
              raise OpenTokException(u('Cannot start archive, {0} is not a valid output mode').format(output_mode))
  
  
          if resolution and output_mode == OutputModes.individual:
              raise OpenTokException(u('Invalid parameters: Resolution cannot be supplied for individual output mode.'))
  
          payload = {'name': name,
                     'sessionId': session_id,
                     'hasAudio': has_audio,
                     'hasVideo': has_video,
                     'outputMode': output_mode.value,
                     'resolution': resolution,
          }
  
          response = requests.post(self.endpoints.archive_url(), data=json.dumps(payload), headers=self.json_headers(), proxies=self.proxies, timeout=self.timeout)
  
          if response.status_code < 300:
              return Archive(self, response.json())
          elif response.status_code == 403:
              raise AuthError()
          elif response.status_code == 400:
              """
              The HTTP response has a 400 status code in the following cases:
              You do not pass in a session ID or you pass in an invalid session ID.
              No clients are actively connected to the OpenTok session.
              You specify an invalid resolution value.
              The outputMode property is set to "individual" and you set the resolution property and (which is not supported in individual stream archives).
              """
              raise RequestError(response.json().get("message"))
          elif response.status_code == 404:
              raise NotFoundError("Session not found")
          elif response.status_code == 409:
              raise ArchiveError(response.json().get("message"))
          else:
              raise RequestError("An unexpected error occurred", response.status_code)