👽 Update the service IDs

This commit is contained in:
2025-11-09 14:13:02 +08:00
parent 8f6c5b01c6
commit 0a3e4b75fd
9 changed files with 16 additions and 16 deletions

View File

@@ -71,7 +71,7 @@ async function handleFindAccount() {
error.value = null
try {
challenge.value = await api("/id/auth/challenge", {
challenge.value = await api("/pass/auth/challenge", {
method: "POST",
body: {
platform: 1,
@@ -96,7 +96,7 @@ async function getFactors() {
error.value = null
try {
const availableFactors = await api<SnAuthFactor[]>(
`/id/auth/challenge/${challenge.value.id}/factors`
`/pass/auth/challenge/${challenge.value.id}/factors`
)
factors.value = availableFactors.filter(
(f: SnAuthFactor) => !challenge.value!.blacklistFactors.includes(f.id)
@@ -123,7 +123,7 @@ async function requestVerificationCode() {
try {
await api(
`/id/auth/challenge/${challenge.value.id}/factors/${selectedFactorId.value}`,
`/pass/auth/challenge/${challenge.value.id}/factors/${selectedFactorId.value}`,
{ method: "POST" }
)
} catch (e: unknown) {
@@ -170,7 +170,7 @@ async function handleVerifyFactor() {
error.value = null
try {
challenge.value = await api(`/id/auth/challenge/${challenge.value.id}`, {
challenge.value = await api(`/pass/auth/challenge/${challenge.value.id}`, {
method: "PATCH",
body: {
factor_id: selectedFactorId.value,
@@ -202,7 +202,7 @@ async function exchangeToken() {
error.value = null
try {
// The token endpoint gives the Set-Cookie header
await api<{ token: string }>("/id/auth/token", {
await api<{ token: string }>("/pass/auth/token", {
method: "POST",
body: {
grant_type: "authorization_code",