handlling other attributes of images

Hi, I added some functionlaity to the api, please have a look into the these changes and if you think it is useful then please merge the branch