Add PutWebhookURL function to update user webhook URL

This commit is contained in:
Mo Tarbin 2025-02-11 20:46:58 -05:00
parent d0b1addc6f
commit bf9ffc97f2
2 changed files with 77 additions and 1 deletions

View file

@ -462,6 +462,15 @@ const GetChoresHistory = async (limit, includeMembers) => {
})
return resp.json()
}
const PutWebhookURL = url => {
return Fetch(`/users/webhook`, {
method: 'PUT',
headers: HEADERS(),
body: JSON.stringify({ url }),
})
}
export {
AcceptCircleMemberRequest,
ArchiveChore,
@ -499,6 +508,7 @@ export {
LeaveCircle,
MarkChoreComplete,
PutNotificationTarget,
PutWebhookURL,
RedeemPoints,
RefreshToken,
ResetPassword,