Christina Ng

Do you see white and gold, or black and blue?

I know, I know. The dress has infamously taken the Internet by storm and here at the Mashape office, we’re pretty split as well.¬†Thankfully, we have the perfect way to objectively end the debate! The solution, of course, is to use an API ūüėČ

API to the rescue

First, we took the image of #thedress in blue and black (or white and gold to some of you) and put it through this Image Color Extraction API created by Nijiko.

The dress

Specifically, we used the Retrieve Palette endpoint in order to retrieve the palette of all the colors in the image.

This is an extract of the response we received:

[
    {
        "hex":"#514430",
        "rgb":[
            81,
            68,
            48
        ],
        "rgba":[
            81,
            68,
            48,
            1
        ],
        "hsv":[
            36.36363636363637,
            0.4074074074074074,
            0.3176470588235294
        ],
        "hsl":[
            36.36363636363637,
            0.25581395348837205,
            0.2529411764705882
        ],
        "lab":[
            29.65644117275808,
            2.2258565689314835,
            14.190216744708362
        ],
        "lch":[
            29.65644117275808,
            14.363728232156756,
            81.08530863240726
        ],
        "css":"rgb(81,68,48)"
    },
    {
        "hex":"#3b4860",
        ...
    },
    ...
]

The two colors we were primarily interested in were #3b4860 and #514430, which proves conclusively that the dress is what some call “blue and black”.

Dress color extractor

Our resident Growth Hacker, Montana Flynn also created this dress color extractor which uses the same color extraction API to get you the actual colors of the dress.

Final result from Dress Color Extractor

Final result from Dress Color Extractor

To use the dress color extractor, you’d need your Mashape API key, so definitely head on over to subscribe to the API and retrieve your key.

Dear Internet, now that we’ve solved the debate for you, here’s our piece of advice:

Calm down and use an API

Free stickers available at http://mashape.tictail.com

Oh, and you’re welcome :)

End the debate about #thedress

category:
Share this: