await
should expect a promise, for a callback style async function, you can transform it like:
new Promise((resolve, reject) => browser.post(options, (err, res, body) => resolve(JSON.parse(body))))
For an array, you need to map it to an array of promises, then use Promise.all
to turn it to a 'promise of array', for example:
Promise.all(collection.data.map(item => parseUserProfile(item)))