code: def xtrim(self, name, maxlen, approximate=True):
          
          pieces = [Token.get_token('MAXLEN')]
          if approximate:
              pieces.append(Token.get_token('~'))
          pieces.append(maxlen)
          return self.execute_command('XTRIM', name, *pieces)
docs: Trims old messages from a stream.
          name: name of the stream.
          maxlen: truncate old stream messages beyond this size
          approximate: actual stream length may be slightly more than maxlen