Closed Bug 1001161 Opened 12 years ago Closed 12 years ago

ImageURL of systems/issuers/programs is not returned from getBadge method in badgekit-api-client

Categories

(Webmaker Graveyard :: Badges, defect)

x86
macOS
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED WONTFIX

People

(Reporter: kate, Assigned: erik)

References

Details

(Whiteboard: [webmakerbadges][launch][june13])

Let's add that so we can have an issuer avatar
Blocks: 1000971
Summary: Issuer URL is not returned from getBadge method in badgekit-api-client → ImageURL of systems/issuers/programs is not returned from getBadge method in badgekit-api-client
So, this turns out to be a pretty universal issue with all of BadgeKit API's endpoints, and I think in most cases it falls more into the realm of questionable design than actual bug. Basically, the badge endpoints (and many other endpoints) generally return the full data associated with the object you requested, as well as more basic data of associated objects (in this case, that means full data of the badge requested, as well as abbreviated data of the system/issuer/program that the badge belongs to). What's unintuitive is that imageUrls are not currently part of that "abbreviated" data. Almost certainly they should be, but it's a pretty invasive change to make it happen universally without some changes to our ORM component. I mention all of this only to explain why this is probably not a same-day fix. What IS both unquestionably a bug (and quickly fixable) is that issuer.imageUrl is showing up at all (even as null) in the data returned. It shouldn't be, and I'll get a fix in for that shortly, but the larger issue here should probably remain open for now. For the time being, a call to getIssuer() (via badgekit-api-client) to fetch the full issuer data (including image data) should get you what you need, hopefully without too much pain and suffering.
Status: NEW → ASSIGNED
Whiteboard: webmakerbadges, mvp → webmakerbadges, followup
Whiteboard: webmakerbadges, followup → webmakerbadges, followup [allhands]
Whiteboard: webmakerbadges, followup [allhands] → webmakerbadges, followup2
Whiteboard: webmakerbadges, followup2 → [webmakerbadges][followup2]
Whiteboard: [webmakerbadges][followup2] → [webmakerbadges][launch]
Whiteboard: [webmakerbadges][launch] → [webmakerbadges][launch][june13]
We don't really need this
Status: ASSIGNED → RESOLVED
Closed: 12 years ago
Resolution: --- → WONTFIX
You need to log in before you can comment on or make changes to this bug.