refactored migrations code
Api layout changes as per builder template
fixed merge conflicts
updated schema.rb file
refactored code + basic api format for pictures