Save image data with badge

We need to configure the rest of the app to use the image data instead
of the image path (endpoint the spits out badge images? data urls?) but
that should be handled in a different pull request.