def avatar_url_as(self, *, format=None, size=<NUM_LIT>):
if self.avatar is None:<EOL><INDENT>return Asset(self._state, '<STR_LIT>')<EOL><DEDENT>if not utils.valid_icon_size(size):<EOL><INDENT>raise InvalidArgument("<STR_LIT>")<EOL><DEDENT>format = format or '<STR_LIT>'<EOL>if format not in ('<STR_LIT>', '<STR_LIT>', '<STR_LIT>'):<EOL><INDENT>raise InvalidArgument("<STR_LIT>")<EOL><DEDENT>url = '<STR_LIT>'.format(self, format, size)<EOL>return Asset(self._state, url)<EOL>
Returns a friendly URL version of the avatar the webhook has.

        If the webhook does not have a traditional avatar, their default
        avatar URL is returned instead.

        The format must be one of 'jpeg', 'jpg', or 'png'.
        The size must be a power of 2 between 16 and 1024.

        Parameters
        -----------
        format: Optional[:class:`str`]
            The format to attempt to convert the avatar to.
            If the format is ``None``, then it is equivalent to png.
        size: :class:`int`
            The size of the image to display.

        Raises
        ------
        InvalidArgument
            Bad image format passed to ``format`` or invalid ``size``.

        Returns
        --------
        :class:`Asset`
            The resulting CDN asset.