Auto-fill created_by field

Hi @DMehaffy, I am also trying to populate the created_by and updated_by field from API in strapi but it is not getting populated.

Code : Getting users from /api/users
const getUserDetails = async () => {
await fetch(/api/users, {
method: “GET”
}).then(res => res.json()).then(data => {
if(data.length > 0) {
setUser(data);
} else {
setUser(‘’);
}
});
};

Can these field of created by and updated by be populated from the /api/users collection ? As I was trying to get the users from the “Users” collection and trying to populate the above fields but its not populating any value giving null. Can you please help me on how I can populate the details using API. Any help will be appreciated. Thanks