Adding retrieve function, updated package.json