diff --git a/actions/adminGetAssociation.ts b/actions/adminGetAssociation.ts index 16ae8a3..48b58ef 100644 --- a/actions/adminGetAssociation.ts +++ b/actions/adminGetAssociation.ts @@ -18,7 +18,7 @@ const getAssociation = async ( ): Promise => { try { const response = await fetch( - `http://development.eba-93ecmjzh.us-east-1.elasticbeanstalk.com/associations/admin/${id}`, + `https://service.ecanna.com.br/associations/admin/${id}`, { method: "GET", headers: { diff --git a/actions/adminGetAssociationUsers.ts b/actions/adminGetAssociationUsers.ts index 4a97be6..8887118 100644 --- a/actions/adminGetAssociationUsers.ts +++ b/actions/adminGetAssociationUsers.ts @@ -35,15 +35,13 @@ const getAssociation = async ( _req: Request, ): Promise => { try { - let url = - `http://development.eba-93ecmjzh.us-east-1.elasticbeanstalk.com/profile/admin`; + let url = `https://service.ecanna.com.br/profile/admin`; if (params) { const query = `?limit=${params.limit}&page=${params.page}${ params.email && `&email=${params.email}` }`; - url = - `http://development.eba-93ecmjzh.us-east-1.elasticbeanstalk.com/profile/admin${query}`; + url = `https://service.ecanna.com.br/profile/admin${query}`; } const response = await fetch(url, { diff --git a/actions/adminGetOrders.ts b/actions/adminGetOrders.ts index ea1a671..c00844f 100644 --- a/actions/adminGetOrders.ts +++ b/actions/adminGetOrders.ts @@ -52,15 +52,13 @@ const adminGetOrders = async ( { token, params }: Props, _req: Request, ): Promise => { - let url = - `http://development.eba-93ecmjzh.us-east-1.elasticbeanstalk.com/admin/orders/`; + let url = `https://service.ecanna.com.br/admin/orders/`; if (params) { const query = `?limit=${params.limit}&page=${params.page}${ params.status && `&status=${params.status}` }`; - url = - `http://development.eba-93ecmjzh.us-east-1.elasticbeanstalk.com/admin/orders${query}`; + url = `https://service.ecanna.com.br/admin/orders${query}`; } try { diff --git a/actions/adminUpdateAssociation.ts b/actions/adminUpdateAssociation.ts index 1b919d9..a9ce438 100644 --- a/actions/adminUpdateAssociation.ts +++ b/actions/adminUpdateAssociation.ts @@ -17,7 +17,7 @@ const getAssociation = async ( ): Promise => { try { const response = await fetch( - `http://development.eba-93ecmjzh.us-east-1.elasticbeanstalk.com/associations/admin/${id}`, + `https://service.ecanna.com.br/associations/admin/${id}`, { method: "PUT", body: JSON.stringify(body), diff --git a/actions/changePassword.ts b/actions/changePassword.ts index f6f0714..42b2fae 100644 --- a/actions/changePassword.ts +++ b/actions/changePassword.ts @@ -12,7 +12,7 @@ const changePassword = async ( ): Promise => { try { const response = await fetch( - "http://development.eba-93ecmjzh.us-east-1.elasticbeanstalk.com/auth/change-password", + "https://service.ecanna.com.br/auth/change-password", { method: "PUT", body: JSON.stringify(body), diff --git a/actions/changeSubscription.ts b/actions/changeSubscription.ts index 089e7c3..99dd56b 100644 --- a/actions/changeSubscription.ts +++ b/actions/changeSubscription.ts @@ -28,7 +28,7 @@ const changeSubscription = async ( delete params.token; try { const response = await fetch( - "http://development.eba-93ecmjzh.us-east-1.elasticbeanstalk.com/checkout/upgrade", + "https://service.ecanna.com.br/checkout/upgrade", { method: "POST", headers: { diff --git a/actions/checkout.ts b/actions/checkout.ts index a7c3bf4..c4f1b85 100644 --- a/actions/checkout.ts +++ b/actions/checkout.ts @@ -36,16 +36,13 @@ const checkout = async ( _req: Request, ): Promise => { try { - const response = await fetch( - "http://development.eba-93ecmjzh.us-east-1.elasticbeanstalk.com/checkout", - { - method: "POST", - headers: { - "Content-Type": "application/json", - }, - body: JSON.stringify(props), + const response = await fetch("https://service.ecanna.com.br/checkout", { + method: "POST", + headers: { + "Content-Type": "application/json", }, - ); + body: JSON.stringify(props), + }); const res = await response.json(); return res; diff --git a/actions/checkoutv2.ts b/actions/checkoutv2.ts index 8a7a90c..6300828 100644 --- a/actions/checkoutv2.ts +++ b/actions/checkoutv2.ts @@ -33,17 +33,14 @@ const checkoutv2 = async ( console.log({ params }); try { - const response = await fetch( - "http://development.eba-93ecmjzh.us-east-1.elasticbeanstalk.com/checkout/v2", - { - method: "POST", - headers: { - "Content-Type": "application/json", - Authorization: props.token || "", - }, - body: JSON.stringify(params), + const response = await fetch("https://service.ecanna.com.br/checkout/v2", { + method: "POST", + headers: { + "Content-Type": "application/json", + Authorization: props.token || "", }, - ); + body: JSON.stringify(params), + }); const res = await response.json(); return res; diff --git a/actions/cognitoAdminSignIn.ts b/actions/cognitoAdminSignIn.ts index 33a0966..4635d99 100644 --- a/actions/cognitoAdminSignIn.ts +++ b/actions/cognitoAdminSignIn.ts @@ -9,7 +9,7 @@ const signInCognito = async ( ): Promise => { try { const response = await fetch( - "http://development.eba-93ecmjzh.us-east-1.elasticbeanstalk.com/admin/sign-in", + "https://service.ecanna.com.br/admin/sign-in", { method: "POST", headers: { diff --git a/actions/cognitoSignIn.ts b/actions/cognitoSignIn.ts index 15dec72..b63aa80 100644 --- a/actions/cognitoSignIn.ts +++ b/actions/cognitoSignIn.ts @@ -8,19 +8,16 @@ const signInCognito = async ( _req: Request, ): Promise => { try { - const response = await fetch( - "http://development.eba-93ecmjzh.us-east-1.elasticbeanstalk.com/auth/sign-in", - { - method: "POST", - headers: { - "Content-Type": "application/json", - }, - body: JSON.stringify({ - email: props.email, - password: props.password, - }), + const response = await fetch("https://service.ecanna.com.br/auth/sign-in", { + method: "POST", + headers: { + "Content-Type": "application/json", }, - ); + body: JSON.stringify({ + email: props.email, + password: props.password, + }), + }); const res = await response.json(); return res; diff --git a/actions/cognitoSignUp.ts b/actions/cognitoSignUp.ts index b1511dd..57aae32 100644 --- a/actions/cognitoSignUp.ts +++ b/actions/cognitoSignUp.ts @@ -10,21 +10,18 @@ const signUpCognito = async ( _req: Request, ): Promise => { try { - const response = await fetch( - "http://development.eba-93ecmjzh.us-east-1.elasticbeanstalk.com/auth", - { - method: "POST", - headers: { - "Content-Type": "application/json", - }, - body: JSON.stringify({ - email: props.email, - password: props.password, - name: props.name, - cpf: props.cpf, - }), + const response = await fetch("https://service.ecanna.com.br/auth", { + method: "POST", + headers: { + "Content-Type": "application/json", }, - ); + body: JSON.stringify({ + email: props.email, + password: props.password, + name: props.name, + cpf: props.cpf, + }), + }); const res = await response.json(); return res; diff --git a/actions/confirmCognitoSignup.ts b/actions/confirmCognitoSignup.ts index 3ad6085..d8cd8d8 100644 --- a/actions/confirmCognitoSignup.ts +++ b/actions/confirmCognitoSignup.ts @@ -9,7 +9,7 @@ const confirmCognitoSignup = async ( ): Promise => { try { const response = await fetch( - "http://development.eba-93ecmjzh.us-east-1.elasticbeanstalk.com/auth/confirm-signup", + "https://service.ecanna.com.br/auth/confirm-signup", { method: "POST", headers: { diff --git a/actions/confirmForgotPassword.ts b/actions/confirmForgotPassword.ts index 767f62a..881f223 100644 --- a/actions/confirmForgotPassword.ts +++ b/actions/confirmForgotPassword.ts @@ -10,7 +10,7 @@ const confirmForgotPassword = async ( ): Promise => { try { const response = await fetch( - "http://development.eba-93ecmjzh.us-east-1.elasticbeanstalk.com/auth/forgot-password/confirm", + "https://service.ecanna.com.br/auth/forgot-password/confirm", { method: "POST", headers: { diff --git a/actions/deleteAssociationDocument.ts b/actions/deleteAssociationDocument.ts index 391ff1f..b9bdf1b 100644 --- a/actions/deleteAssociationDocument.ts +++ b/actions/deleteAssociationDocument.ts @@ -10,7 +10,7 @@ const deleteAssociationDocument = async ( console.log({ docId: props.docId }); try { const response = await fetch( - `http://development.eba-93ecmjzh.us-east-1.elasticbeanstalk.com/documents/association/${props.docId}`, + `https://service.ecanna.com.br/documents/association/${props.docId}`, { method: "DELETE", headers: { diff --git a/actions/deleteDocument.ts b/actions/deleteDocument.ts index f726c2f..6d0ff86 100644 --- a/actions/deleteDocument.ts +++ b/actions/deleteDocument.ts @@ -10,7 +10,7 @@ const deleteDocument = async ( console.log({ docId: props.docId }); try { const response = await fetch( - `http://development.eba-93ecmjzh.us-east-1.elasticbeanstalk.com/documents/${props.docId}`, + `https://service.ecanna.com.br/documents/${props.docId}`, { method: "DELETE", headers: { diff --git a/actions/forgotPassword.ts b/actions/forgotPassword.ts index 83c7e41..50c9356 100644 --- a/actions/forgotPassword.ts +++ b/actions/forgotPassword.ts @@ -8,7 +8,7 @@ const forgotPassword = async ( ): Promise => { try { const response = await fetch( - "http://development.eba-93ecmjzh.us-east-1.elasticbeanstalk.com/auth/forgot-password", + "https://service.ecanna.com.br/auth/forgot-password", { method: "POST", headers: { diff --git a/actions/getAssociation.ts b/actions/getAssociation.ts index 4b4a89b..cdbc0f0 100644 --- a/actions/getAssociation.ts +++ b/actions/getAssociation.ts @@ -8,7 +8,7 @@ const getAssociation = async ( ): Promise => { try { const response = await fetch( - `http://development.eba-93ecmjzh.us-east-1.elasticbeanstalk.com/associations/${id}`, + `https://service.ecanna.com.br/associations/${id}`, { method: "GET", headers: { diff --git a/actions/getAssociationDocs.ts b/actions/getAssociationDocs.ts index 6e428fd..24f8b10 100644 --- a/actions/getAssociationDocs.ts +++ b/actions/getAssociationDocs.ts @@ -9,7 +9,7 @@ const getDocs = async ( ): Promise => { try { const response = await fetch( - `http://development.eba-93ecmjzh.us-east-1.elasticbeanstalk.com/documents/association/${associationId}`, + `https://service.ecanna.com.br/documents/association/${associationId}`, { method: "GET", headers: { diff --git a/actions/getCardProduct.ts b/actions/getCardProduct.ts index 91634ec..d748a1a 100644 --- a/actions/getCardProduct.ts +++ b/actions/getCardProduct.ts @@ -1,7 +1,7 @@ const getPlans = async (_req: Request): Promise => { try { const response = await fetch( - "http://development.eba-93ecmjzh.us-east-1.elasticbeanstalk.com/products/cards", + "https://service.ecanna.com.br/products/cards", { method: "GET", headers: { diff --git a/actions/getCids.ts b/actions/getCids.ts index 114337c..53cee00 100644 --- a/actions/getCids.ts +++ b/actions/getCids.ts @@ -9,7 +9,7 @@ const getCids = async ( ): Promise => { try { const response = await fetch( - `http://development.eba-93ecmjzh.us-east-1.elasticbeanstalk.com/cids?name=${term}`, + `https://service.ecanna.com.br/cids?name=${term}`, { method: "GET", headers: { diff --git a/actions/getDocs.ts b/actions/getDocs.ts index 2a30021..9d22ec7 100644 --- a/actions/getDocs.ts +++ b/actions/getDocs.ts @@ -7,16 +7,13 @@ const getDocs = async ( _req: Request, ): Promise => { try { - const response = await fetch( - "http://development.eba-93ecmjzh.us-east-1.elasticbeanstalk.com/documents", - { - method: "GET", - headers: { - "Content-Type": "application/json", - Authorization: token, - }, + const response = await fetch("https://service.ecanna.com.br/documents", { + method: "GET", + headers: { + "Content-Type": "application/json", + Authorization: token, }, - ); + }); const res = await response.json(); return res; diff --git a/actions/getPlans.ts b/actions/getPlans.ts index 1a3794d..f9eb994 100644 --- a/actions/getPlans.ts +++ b/actions/getPlans.ts @@ -1,7 +1,7 @@ const getPlans = async (_req: Request): Promise => { try { const response = await fetch( - "http://development.eba-93ecmjzh.us-east-1.elasticbeanstalk.com/products/subscriptions", + "https://service.ecanna.com.br/products/subscriptions", { method: "GET", headers: { diff --git a/actions/getProfile.ts b/actions/getProfile.ts index 0cff427..87fac19 100644 --- a/actions/getProfile.ts +++ b/actions/getProfile.ts @@ -7,16 +7,13 @@ const getUser = async ( _req: Request, ): Promise => { try { - const response = await fetch( - "http://development.eba-93ecmjzh.us-east-1.elasticbeanstalk.com/profile", - { - method: "GET", - headers: { - "Content-Type": "application/json", - Authorization: token, - }, + const response = await fetch("https://service.ecanna.com.br/profile", { + method: "GET", + headers: { + "Content-Type": "application/json", + Authorization: token, }, - ); + }); const res = await response.json(); return res; diff --git a/actions/getUser.ts b/actions/getUser.ts index b431d1b..adecdce 100644 --- a/actions/getUser.ts +++ b/actions/getUser.ts @@ -7,16 +7,13 @@ const getUser = async ( _req: Request, ): Promise => { try { - const response = await fetch( - "http://development.eba-93ecmjzh.us-east-1.elasticbeanstalk.com/auth/me", - { - method: "GET", - headers: { - "Content-Type": "application/json", - Authorization: token, - }, + const response = await fetch("https://service.ecanna.com.br/auth/me", { + method: "GET", + headers: { + "Content-Type": "application/json", + Authorization: token, }, - ); + }); const res = await response.json(); return res; diff --git a/actions/getUserAdmin.ts b/actions/getUserAdmin.ts index 99bd063..be30278 100644 --- a/actions/getUserAdmin.ts +++ b/actions/getUserAdmin.ts @@ -7,16 +7,13 @@ const getUser = async ( _req: Request, ): Promise => { try { - const response = await fetch( - "http://development.eba-93ecmjzh.us-east-1.elasticbeanstalk.com/v1/admin/me", - { - method: "GET", - headers: { - "Content-Type": "application/json", - Authorization: token, - }, + const response = await fetch("https://service.ecanna.com.br/v1/admin/me", { + method: "GET", + headers: { + "Content-Type": "application/json", + Authorization: token, }, - ); + }); const res = await response.json(); return res; diff --git a/actions/getUserOrders.ts b/actions/getUserOrders.ts index a598b15..e79613b 100644 --- a/actions/getUserOrders.ts +++ b/actions/getUserOrders.ts @@ -47,16 +47,13 @@ const getUserOrders = async ( _req: Request, ): Promise => { try { - const response = await fetch( - "http://development.eba-93ecmjzh.us-east-1.elasticbeanstalk.com/orders/", - { - method: "GET", - headers: { - "Content-Type": "application/json", - Authorization: token, - }, + const response = await fetch("https://service.ecanna.com.br/orders/", { + method: "GET", + headers: { + "Content-Type": "application/json", + Authorization: token, }, - ); + }); const res = await response.json(); return res; diff --git a/actions/resendConfirmationCode.ts b/actions/resendConfirmationCode.ts index 424f1b5..fde4395 100644 --- a/actions/resendConfirmationCode.ts +++ b/actions/resendConfirmationCode.ts @@ -8,7 +8,7 @@ const resendConfirmationCode = async ( ): Promise => { try { const response = await fetch( - "http://development.eba-93ecmjzh.us-east-1.elasticbeanstalk.com/auth/send-confirmation-code", + "https://service.ecanna.com.br/auth/send-confirmation-code", { method: "POST", headers: { diff --git a/actions/signOut.ts b/actions/signOut.ts index 6529a1a..924a9d2 100644 --- a/actions/signOut.ts +++ b/actions/signOut.ts @@ -8,7 +8,7 @@ const signOut = async ( ): Promise => { try { const response = await fetch( - "http://development.eba-93ecmjzh.us-east-1.elasticbeanstalk.com/auth/sign-out", + "https://service.ecanna.com.br/auth/sign-out", { method: "POST", headers: { diff --git a/actions/updateProfile.ts b/actions/updateProfile.ts index b5da60a..be0c669 100644 --- a/actions/updateProfile.ts +++ b/actions/updateProfile.ts @@ -11,17 +11,14 @@ const getUser = async ( _req: Request, ): Promise => { try { - const response = await fetch( - "http://development.eba-93ecmjzh.us-east-1.elasticbeanstalk.com/profile", - { - method: "PUT", - body: JSON.stringify(body), - headers: { - "Content-Type": "application/json", - Authorization: token, - }, + const response = await fetch("https://service.ecanna.com.br/profile", { + method: "PUT", + body: JSON.stringify(body), + headers: { + "Content-Type": "application/json", + Authorization: token, }, - ); + }); const res = await response.json(); return res; diff --git a/actions/updateUserData.ts b/actions/updateUserData.ts index a735ad1..2945635 100644 --- a/actions/updateUserData.ts +++ b/actions/updateUserData.ts @@ -39,7 +39,7 @@ const updateUserData = async ( try { const responseUpdateProfile = await fetch( - "http://development.eba-93ecmjzh.us-east-1.elasticbeanstalk.com/profile", + "https://service.ecanna.com.br/profile", { method: "PUT", body: JSON.stringify(updateProfileBody), @@ -55,7 +55,7 @@ const updateUserData = async ( console.log({ resProfile }); const responseUpdateCognito = await fetch( - "http://development.eba-93ecmjzh.us-east-1.elasticbeanstalk.com/auth/me", + "https://service.ecanna.com.br/auth/me", { method: "PUT", body: JSON.stringify(updateCognitoUserBody), diff --git a/actions/uploadFile.ts b/actions/uploadFile.ts index 6059840..f35281c 100644 --- a/actions/uploadFile.ts +++ b/actions/uploadFile.ts @@ -19,17 +19,14 @@ const uploadFile = async ( ): Promise => { console.log({ dataBody: data }); try { - const response = await fetch( - "http://development.eba-93ecmjzh.us-east-1.elasticbeanstalk.com/files", - { - method: "POST", - body: JSON.stringify(data), - headers: { - "Content-Type": "multipart/form-data;", - // Authorization: token, - }, + const response = await fetch("https://service.ecanna.com.br/files", { + method: "POST", + body: JSON.stringify(data), + headers: { + "Content-Type": "multipart/form-data;", + // Authorization: token, }, - ); + }); const res = await response.json(); return res; diff --git a/components/ui/AdminNewDocModal.tsx b/components/ui/AdminNewDocModal.tsx index 644764b..309a3ae 100644 --- a/components/ui/AdminNewDocModal.tsx +++ b/components/ui/AdminNewDocModal.tsx @@ -43,12 +43,10 @@ const AdminNewDocModal = ( let url = ""; if (createType === "user") { - url = - "http://development.eba-93ecmjzh.us-east-1.elasticbeanstalk.com/documents/admin/user"; + url = "https://service.ecanna.com.br/documents/admin/user"; formData.append("user", userToAdminCreateDoc.value._id); } else if (createType === "association") { - url = - "http://development.eba-93ecmjzh.us-east-1.elasticbeanstalk.com/documents/admin/association"; + url = "https://service.ecanna.com.br/documents/admin/association"; formData.append("association", associationToAdminCreateDoc.value._id); } diff --git a/components/ui/AssociationAdmin.tsx b/components/ui/AssociationAdmin.tsx index dd27466..76844b0 100644 --- a/components/ui/AssociationAdmin.tsx +++ b/components/ui/AssociationAdmin.tsx @@ -119,7 +119,7 @@ function MyAccount() { let accessToken = ""; if (IS_BROWSER) { - accessToken = localStorage.getItem("AdminAccessToken") || ""; + accessToken = localStorage.getItem("AccessToken") || ""; } try { @@ -148,7 +148,7 @@ function MyAccount() { let accessToken = ""; if (IS_BROWSER) { - accessToken = localStorage.getItem("AdminAccessToken") || ""; + accessToken = localStorage.getItem("AccessToken") || ""; } if (file) { @@ -158,7 +158,7 @@ function MyAccount() { try { const response = await fetch( - "http://development.eba-93ecmjzh.us-east-1.elasticbeanstalk.com/files", + "https://service.ecanna.com.br/files", { method: "POST", body: formData, @@ -183,7 +183,7 @@ function MyAccount() { let associationAdmin = ""; if (IS_BROWSER) { - accessToken = localStorage.getItem("AdminAccessToken") || ""; + accessToken = localStorage.getItem("AccessToken") || ""; associationAdmin = localStorage.getItem("AssociationAdmin") || ""; } @@ -236,7 +236,7 @@ function MyAccount() { let associationAdmin = ""; if (IS_BROWSER) { - accessToken = localStorage.getItem("AdminAccessToken") || ""; + accessToken = localStorage.getItem("AccessToken") || ""; associationAdmin = localStorage.getItem("AssociationAdmin") || ""; } @@ -267,7 +267,7 @@ function MyAccount() { let associationAdmin = ""; if (IS_BROWSER) { - accessToken = localStorage.getItem("AdminAccessToken") || ""; + accessToken = localStorage.getItem("AccessToken") || ""; associationAdmin = localStorage.getItem("AssociationAdmin") || ""; } setIsLoadingUsers(true); diff --git a/components/ui/ChoosePlanSignup.tsx b/components/ui/ChoosePlanSignup.tsx index d0da74e..29b462e 100644 --- a/components/ui/ChoosePlanSignup.tsx +++ b/components/ui/ChoosePlanSignup.tsx @@ -12,7 +12,7 @@ function ConfirmSignup() { useEffect(() => { try { const params = fetch( - `http://development.eba-93ecmjzh.us-east-1.elasticbeanstalk.com/v1/products/subscriptions`, + `https://service.ecanna.com.br/v1/products/subscriptions`, ).then(async (r) => { const c = await r.json(); console.log({ plans: c.docs }); diff --git a/components/ui/MyAccount.tsx b/components/ui/MyAccount.tsx index a9e6514..492027c 100644 --- a/components/ui/MyAccount.tsx +++ b/components/ui/MyAccount.tsx @@ -86,7 +86,7 @@ function MyAccount() { }); const params = fetch( - `http://development.eba-93ecmjzh.us-east-1.elasticbeanstalk.com/v1/products/subscriptions`, + `https://service.ecanna.com.br/v1/products/subscriptions`, ).then(async (r) => { const c = await r.json(); console.log({ plans: c.docs }); diff --git a/components/ui/MyDocs.tsx b/components/ui/MyDocs.tsx index defddbf..f1c5b9c 100644 --- a/components/ui/MyDocs.tsx +++ b/components/ui/MyDocs.tsx @@ -203,7 +203,7 @@ const NewDocModal = ({ onFinishCreate }: { onFinishCreate: () => void }) => { try { const response = await fetch( - "http://development.eba-93ecmjzh.us-east-1.elasticbeanstalk.com/documents", + "https://service.ecanna.com.br/documents", { method: "POST", body: formData, diff --git a/components/ui/MyInfo.tsx b/components/ui/MyInfo.tsx index 77c5ec6..520e9ec 100644 --- a/components/ui/MyInfo.tsx +++ b/components/ui/MyInfo.tsx @@ -120,7 +120,7 @@ function MyInfo() { try { const response = await fetch( - "http://development.eba-93ecmjzh.us-east-1.elasticbeanstalk.com/files", + "https://service.ecanna.com.br/files", { method: "POST", body: formData, diff --git a/loaders/getPublicProfile.ts b/loaders/getPublicProfile.ts index 9d77baa..09c6d03 100644 --- a/loaders/getPublicProfile.ts +++ b/loaders/getPublicProfile.ts @@ -40,8 +40,7 @@ const getPublicProfile = async ( ): Promise => { try { const response = await fetch( - "http://development.eba-93ecmjzh.us-east-1.elasticbeanstalk.com/auth/public/" + - slug, + "https://service.ecanna.com.br/auth/public/" + slug, ); const res = await response.json();