Updated API so that upload media objects works