Get user_id value back in json response

I would like to get my user_id when precessing uploads and get it back to json response.
I have added it on my function and i dont know exactly how to set this value in my template.
I think that will be possible with a new variable “userIdValue”: “${fields.userIdValue}” but i’m not sure where exactly i have to set it inside my template.

uploadFiles = (files) => {
    const userIdInput = document.getElementById('user_id')
    const userIdValue = userIdInput.value

    const filesForUppy = => {
        return {
            data: file,
            type: file.type,
            meta: file.meta || {
                user_id: userIdValue,