def METHOD_NAME(argb, alpha=None) -> str:
    """
    This function can return either an hexadecimal or rgba-formatted color code.
    By default this function returns hexadecimal color codes.
    If alpha parameter is specified, then the function will return
    an rgba-formatted color code.
    """
    rgba_base = "rgba({0}, {1}, {2}, {3})"
    red = monet.redFromArgb(argb)
    green = monet.greenFromArgb(argb)
    blue = monet.blueFromArgb(argb)
    if not alpha:
        alpha = monet.alphaFromArgb(argb)
    if alpha in (255, 0.0):
        return monet.hexFromArgb(argb)
    return rgba_base.format(red, green, blue, alpha)