Skip to content

Commit 995972b

Browse files
committed
feat: guided-tour, long-form tasks, onboarding, notifications
2 parents a691dbe + bf5a3e7 commit 995972b

77 files changed

Lines changed: 6693 additions & 4540 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

src/client/app/api/settings/complete-profile/route.js

Lines changed: 0 additions & 33 deletions
This file was deleted.
Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
import { NextResponse } from "next/server"
2+
import { withAuth } from "@lib/api-utils"
3+
4+
const appServerUrl =
5+
process.env.NEXT_PUBLIC_ENVIRONMENT === "selfhost"
6+
? process.env.INTERNAL_APP_SERVER_URL
7+
: process.env.NEXT_PUBLIC_APP_SERVER_URL
8+
9+
export const GET = withAuth(async function GET(request, { authHeader }) {
10+
try {
11+
const response = await fetch(`${appServerUrl}/api/user/properties`, {
12+
method: "GET",
13+
headers: { "Content-Type": "application/json", ...authHeader },
14+
cache: "no-store"
15+
})
16+
17+
const data = await response.json()
18+
if (!response.ok) {
19+
throw new Error(
20+
data.detail || "Failed to fetch user properties from backend"
21+
)
22+
}
23+
24+
return NextResponse.json(data, {
25+
headers: { "Cache-Control": "no-store, max-age=0" }
26+
})
27+
} catch (error) {
28+
console.error("API Error in /user/properties:", error)
29+
return NextResponse.json(
30+
{ message: "Internal Server Error", error: error.message },
31+
{ status: 500 }
32+
)
33+
}
34+
})

0 commit comments

Comments
 (0)