Files
services/examples/user/read/node/readAccountByUsernameOrEmail.js

13 lines
355 B
JavaScript
Executable File

const { UserService } = require("m3o/user");
// Read an account by id, username or email. Only one need to be specified.
async function readAccountByUsernameOrEmail() {
let userService = new UserService(process.env.MICRO_API_TOKEN);
let rsp = await userService.read({
username: "joe",
});
console.log(rsp);
}
readAccountByUsernameOrEmail();