// tslint:disable:no-console no-magic-numbers import { chevre } from '../../../../lib/index'; async function main() { const personRepo = new chevre.repository.Person({ userPoolId: process.env.COGNITO_USER_POOL_ID }); const username = 'xx'; const profile = await personRepo.getUserAttributes({ username: username }); console.log('profile:', profile); } main() .then(() => { console.log('success!'); }) .catch((error) => { console.error(error); console.log(error.code); });