You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: packages/core/src/routes/google-one-tap/index.openapi.json
+65Lines changed: 65 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -48,6 +48,71 @@
48
48
}
49
49
}
50
50
}
51
+
},
52
+
"/api/google-one-tap/verify": {
53
+
"post": {
54
+
"summary": "Verify Google One Tap ID Token and generate magic link",
55
+
"description": "Verify the Google One Tap ID Token, check if the user exists, and generate a magic link for authentication. If the user exists, generates a login magic link; otherwise, generates a registration magic link.",
56
+
"requestBody": {
57
+
"content": {
58
+
"application/json": {
59
+
"schema": {
60
+
"type": "object",
61
+
"properties": {
62
+
"idToken": {
63
+
"type": "string",
64
+
"description": "The Google ID Token from Google One Tap"
65
+
},
66
+
"redirectUri": {
67
+
"type": "string",
68
+
"format": "uri",
69
+
"description": "Optional redirect URI for the magic link. If not provided, uses the request origin."
70
+
}
71
+
},
72
+
"required": ["idToken"]
73
+
}
74
+
}
75
+
}
76
+
},
77
+
"responses": {
78
+
"200": {
79
+
"description": "The ID Token was verified successfully and magic link was generated.",
80
+
"content": {
81
+
"application/json": {
82
+
"schema": {
83
+
"type": "object",
84
+
"properties": {
85
+
"magicLink": {
86
+
"type": "string",
87
+
"format": "uri",
88
+
"description": "The generated magic link URL for authentication"
89
+
},
90
+
"isNewUser": {
91
+
"type": "boolean",
92
+
"description": "Whether this is a new user (registration) or existing user (login)"
93
+
},
94
+
"email": {
95
+
"type": "string",
96
+
"format": "email",
97
+
"description": "The verified email address from the Google ID Token"
98
+
}
99
+
},
100
+
"required": ["magicLink", "isNewUser", "email"]
101
+
}
102
+
}
103
+
}
104
+
},
105
+
"400": {
106
+
"description": "Invalid ID Token, unverified email, or other validation errors"
107
+
},
108
+
"403": {
109
+
"description": "Access forbidden, either due to CORS restrictions or feature not enabled"
0 commit comments