Connected Upload script with API, enabled thumbnail previews, and uploaded the thumbnails to database