From dff9653181bc3826e015493f80adb17036a7f6f0 Mon Sep 17 00:00:00 2001 From: Justin Edmund Date: Fri, 4 Mar 2022 05:15:28 -0800 Subject: [PATCH] Add endpoint for getting user info --- utils/api.tsx | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/utils/api.tsx b/utils/api.tsx index 3781e275..a86a76d6 100644 --- a/utils/api.tsx +++ b/utils/api.tsx @@ -98,6 +98,11 @@ class Api { } }) } + + userInfo(id: string) { + const resourceUrl = `${this.url}/users/info/${id}` + return axios.get(resourceUrl) + } } const api: Api = new Api({ url: process.env.NEXT_PUBLIC_SIERO_API_URL || 'https://localhost:3000/api/v1'})