WhatPulse badge/shield

I like WhatPulse and I like badges/shields. So, I asked shields.io to combine the two features together.

See request here: Badge request: WhatPulse · Issue #8356 · badges/shields · GitHub

Example:
Keys

Hey Jerone,

Thanks for submitting that, it’d be cool to have it as a part of the badges project! You can already do it, though. Using the dynamic API they provide, you can conjure up a badge:

https://img.shields.io/badge/dynamic/json?label=Clicks&query=Clicks&url=https%3A%2F%2Fapi.whatpulse.org%2Fuser.php%3Fuser%3D1%26formatted%3Dyes%26format%3Djson&style=for-the-badge

Yeah, I added an example here and in the GitHub issue with real data from my account.

All images there, are clickable to their dynamic urls. I’ve edited the issue to make that clear. Thanks.

@smitmartijn What would you suggest using as colors (label and value)?

Doh! I thought that was photoshopped, I didn’t check the image source.

After reading their contributor guidelines (shields/CONTRIBUTING.md at master · badges/shields · GitHub) - I’m not sure they will add native support for WhatPulse. I’ve subscribed to the issue and if they respond positively, I could help with the code if needed. But, it seems like the dynamic badges already work, I’ll add those to my own GH profile. :wink:

While we don’t have brand style guide, it’d be good to use one of the blue-ish colors we use throughout the client and website. Those are #374856 and #2C5B75. I’d also like to request you use WhatPulse with a capital W and capital P. :slightly_smiling_face:

1 Like

After reading their contributor guidelines (shields/CONTRIBUTING.md at master · badges/shields · GitHub) - I’m not sure they will add native support for WhatPulse.

I updated the issue to add the following paragraph why the dynamic api from shield.io is not enough:

The example badges in the table above are created with the dynamic api from shield.io. This works great for the stats-badges. But for the rank-badges it is missing an dynamic suffix. Right now it’s hardcoded “th” behind the value, for demo purposes. An custom implementation here would be needed to calculate the correct suffix based on the value.

I’ve subscribed to the issue […]

Issues with an thumbs up :+1: usually gets more attention. :wink:

Those are #374856 and #2C5B75

Thanks. Added to the issue. And updated the example badges to have #2C5B75 as the value color. I didn’t change the label color, because I think it would look weird compared to the default color.

I’d also like to request you use WhatPulse with a capital W and capital P.

Fixed :+1: