Ok, but what I can't seem to find is where Rebrickable gets these images from Lego. Lego themselves don't seem to provide any API or downloads from what I can tell.
Yeah I came across that story. It seems a shame that BrickLink did that, especially since their data seems to come from user contributions as well. It seems like the Lego community has become fragmented when it comes to this data. By my counts, BrickLink, Peeron, LUGNET, Rebrickable, BrickSet, BrickOwl, and LDraw all maintain a version of this data. At least Rebrickable has done the work to map a lot of this data. I just wish there was a more official/authoritative source for this data.
Looks like they do. The get_part function returns external_part_ids, which is "Array of related Part IDs used by external systems".