'Get a list of categories in which things are currently saved.
See also: [/api/save](#POST_api_save).'

@require_oauth2_scope('save')
@json_validate(VUser())
@api_doc(api_section.links_and_comments)
def GET_saved_categories(self, responder):

    if (not c.user.gold):
        abort(403)
    categories = LinkSavesByCategory.get_saved_categories(c.user)
    categories += CommentSavesByCategory.get_saved_categories(c.user)
    categories = sorted(set(categories), key=(lambda name: name.lower()))
    categories = [dict(category=category) for category in categories]
    return {'categories': categories}
