Loading...
async function AssignTask(managerId, taskId) try console log( taskId: #{taskId} console.log managerId: ${managerId}
const headers Authorization Content-Type
Bearer #{process env FBCCommerceKey}` application/json
const properties "hubspot Owner_id" managerId
const SimplePublicObjectInput properties
try await axios.patch( https: [api.hubspot.com/crm/v3/objects/tasks/S{taskId} JSON.stringify ( SimplePublicobjectInput) , headers
catch (e} message HTTP request failed console error (JSON.stringify(e.response, null, 2)) console-error(e)
catch (e) console error Error AssignTask:
e);