@tempoxyz/id 0.0.1 → 0.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (120) hide show
  1. package/dist/app/server/.vite/manifest.json +65 -65
  2. package/dist/app/server/assets/Grant-D_tun0mF.js.map +1 -1
  3. package/dist/app/server/assets/authorize-DXYo-K2n-B-6vqhvc.js +56 -0
  4. package/dist/app/server/assets/authorize-DXYo-K2n-B-6vqhvc.js.map +1 -0
  5. package/dist/app/server/assets/core-FSS9-r35.js +56 -0
  6. package/dist/app/server/assets/core-FSS9-r35.js.map +1 -0
  7. package/dist/app/server/assets/default-u_dwuiYb-Bby14ucv.js +2 -0
  8. package/dist/app/server/assets/{default-u_dwuiYb-DOrMMcg9.js.map → default-u_dwuiYb-Bby14ucv.js.map} +1 -1
  9. package/dist/app/server/assets/{dist-CoH0hD1s.js → dist-B9KiBJYw.js} +2 -2
  10. package/dist/app/server/assets/{dist-CoH0hD1s.js.map → dist-B9KiBJYw.js.map} +1 -1
  11. package/dist/app/server/assets/{dist-DcICI3fd.js → dist-CU1NXSiz.js} +2 -2
  12. package/dist/app/server/assets/{dist-DcICI3fd.js.map → dist-CU1NXSiz.js.map} +1 -1
  13. package/dist/app/server/assets/dist-CetH4JSY.js +1 -0
  14. package/dist/app/server/assets/{effect-QlVUlMFu-mXPkuQTb.js → effect-QlVUlMFu-Cm-eTtaO.js} +2 -2
  15. package/dist/app/server/assets/{effect-QlVUlMFu-mXPkuQTb.js.map → effect-QlVUlMFu-Cm-eTtaO.js.map} +1 -1
  16. package/dist/app/server/assets/factory-g3i_Ffi5.js +5 -0
  17. package/dist/app/server/assets/{factory-dvoOlKer.js.map → factory-g3i_Ffi5.js.map} +1 -1
  18. package/dist/app/server/assets/get-id-field-BpOAoqqI.js +6 -0
  19. package/dist/app/server/assets/get-id-field-BpOAoqqI.js.map +1 -0
  20. package/dist/app/server/assets/{index-CLddUTqr-CC33CMvS.js → index-CLddUTqr-CmgkbWi9.js} +2 -2
  21. package/dist/app/server/assets/{index-CLddUTqr-CC33CMvS.js.map → index-CLddUTqr-CmgkbWi9.js.map} +1 -1
  22. package/dist/app/server/assets/{index-DZEfthgZ-Ec2MMQ_e.js → index-DZEfthgZ-BnPmps9O.js} +2 -2
  23. package/dist/app/server/assets/{index-DZEfthgZ-Ec2MMQ_e.js.map → index-DZEfthgZ-BnPmps9O.js.map} +1 -1
  24. package/dist/app/server/assets/kysely-adapter-B8VoPArC.js +1 -0
  25. package/dist/app/server/assets/{schema-check-oLqvHR8y.js → schema-check-Bgwl1v0_.js} +2 -2
  26. package/dist/app/server/assets/{schema-check-oLqvHR8y.js.map → schema-check-Bgwl1v0_.js.map} +1 -1
  27. package/dist/app/server/assets/{sury-CWZTCd75-CDaOS2oM.js → sury-CWZTCd75-Bd_PzqCV.js} +2 -2
  28. package/dist/app/server/assets/{sury-CWZTCd75-CDaOS2oM.js.map → sury-CWZTCd75-Bd_PzqCV.js.map} +1 -1
  29. package/dist/app/server/assets/{valibot--1zFm7rT-CIKoH3MS.js → valibot--1zFm7rT-Dd2aEhWG.js} +2 -2
  30. package/dist/app/server/assets/{valibot--1zFm7rT-CIKoH3MS.js.map → valibot--1zFm7rT-Dd2aEhWG.js.map} +1 -1
  31. package/dist/app/server/assets/{valibot-D_HTw1Gn-BdPyLkXt.js → valibot-D_HTw1Gn-C1l3va6F.js} +2 -2
  32. package/dist/app/server/assets/{valibot-D_HTw1Gn-BdPyLkXt.js.map → valibot-D_HTw1Gn-C1l3va6F.js.map} +1 -1
  33. package/dist/app/server/assets/{zod-Bwrt9trS-BezI5Gi1.js → zod-Bwrt9trS-Dry2w0in.js} +2 -2
  34. package/dist/app/server/assets/{zod-Bwrt9trS-BezI5Gi1.js.map → zod-Bwrt9trS-Dry2w0in.js.map} +1 -1
  35. package/dist/app/server/assets/{zod-DSgpEGAE-DZ7M_Q33.js → zod-DSgpEGAE-BZMP86UA.js} +2 -2
  36. package/dist/app/server/assets/{zod-DSgpEGAE-DZ7M_Q33.js.map → zod-DSgpEGAE-BZMP86UA.js.map} +1 -1
  37. package/dist/app/server/index.js +35 -35
  38. package/dist/app/server/index.js.map +1 -1
  39. package/dist/client/Auth.d.ts +1 -1
  40. package/dist/client/Auth.d.ts.map +1 -1
  41. package/dist/client/Auth.js.map +1 -1
  42. package/dist/client/Decorator.d.ts +3 -1
  43. package/dist/client/Decorator.d.ts.map +1 -1
  44. package/dist/client/Decorator.js +1 -0
  45. package/dist/client/Decorator.js.map +1 -1
  46. package/dist/client/actions/passkey.d.ts +63 -2
  47. package/dist/client/actions/passkey.d.ts.map +1 -1
  48. package/dist/client/actions/passkey.js +121 -3
  49. package/dist/client/actions/passkey.js.map +1 -1
  50. package/dist/internal/Apps.d.ts +14 -0
  51. package/dist/internal/Apps.d.ts.map +1 -1
  52. package/dist/internal/Apps.js +14 -2
  53. package/dist/internal/Apps.js.map +1 -1
  54. package/dist/internal/Auth.d.ts +7 -0
  55. package/dist/internal/Auth.d.ts.map +1 -1
  56. package/dist/internal/Auth.js +2 -1
  57. package/dist/internal/Auth.js.map +1 -1
  58. package/dist/internal/Authorize.d.ts.map +1 -1
  59. package/dist/internal/Authorize.js +13 -13
  60. package/dist/internal/Authorize.js.map +1 -1
  61. package/dist/internal/ErrorResponse.d.ts +5 -0
  62. package/dist/internal/ErrorResponse.d.ts.map +1 -1
  63. package/dist/internal/ErrorResponse.js +8 -0
  64. package/dist/internal/ErrorResponse.js.map +1 -1
  65. package/dist/internal/KeyAuthorization.d.ts.map +1 -1
  66. package/dist/internal/KeyAuthorization.js +28 -28
  67. package/dist/internal/KeyAuthorization.js.map +1 -1
  68. package/dist/internal/Owner.d.ts +16 -0
  69. package/dist/internal/Owner.d.ts.map +1 -1
  70. package/dist/internal/Owner.js.map +1 -1
  71. package/dist/internal/Passkey.d.ts +66 -4
  72. package/dist/internal/Passkey.d.ts.map +1 -1
  73. package/dist/internal/Passkey.js +66 -30
  74. package/dist/internal/Passkey.js.map +1 -1
  75. package/dist/internal/Privy.d.ts +27 -0
  76. package/dist/internal/Privy.d.ts.map +1 -1
  77. package/dist/internal/Privy.js +82 -0
  78. package/dist/internal/Privy.js.map +1 -1
  79. package/dist/internal/TempoAccount.d.ts +57 -0
  80. package/dist/internal/TempoAccount.d.ts.map +1 -1
  81. package/dist/internal/TempoAccount.js +118 -5
  82. package/dist/internal/TempoAccount.js.map +1 -1
  83. package/dist/internal/owners/Privy.d.ts.map +1 -1
  84. package/dist/internal/owners/Privy.js +11 -2
  85. package/dist/internal/owners/Privy.js.map +1 -1
  86. package/package.json +1 -1
  87. package/src/api/account.ts +140 -103
  88. package/src/api/authenticate.ts +48 -51
  89. package/src/api/authorize.ts +35 -36
  90. package/src/api/device.ts +20 -23
  91. package/src/api/health.ts +1 -2
  92. package/src/api/lib/AccountStep.ts +75 -0
  93. package/src/api/lib/Auth.ts +6 -0
  94. package/src/api/lib/Cors.ts +3 -0
  95. package/src/api/lib/KeySigner.ts +1 -1
  96. package/src/api/oauth.ts +23 -22
  97. package/src/client/Auth.ts +1 -0
  98. package/src/client/Decorator.ts +6 -1
  99. package/src/client/actions/passkey.ts +197 -3
  100. package/src/internal/Apps.ts +26 -2
  101. package/src/internal/Auth.ts +4 -0
  102. package/src/internal/Authorize.ts +13 -15
  103. package/src/internal/ErrorResponse.ts +10 -0
  104. package/src/internal/KeyAuthorization.ts +28 -31
  105. package/src/internal/OpenApi.ts +35 -0
  106. package/src/internal/Owner.ts +16 -0
  107. package/src/internal/Passkey.ts +99 -34
  108. package/src/internal/Privy.ts +128 -0
  109. package/src/internal/TempoAccount.ts +221 -7
  110. package/src/internal/owners/Privy.ts +19 -6
  111. package/dist/app/server/assets/authorize-DXYo-K2n-rmQQ42x1.js +0 -56
  112. package/dist/app/server/assets/authorize-DXYo-K2n-rmQQ42x1.js.map +0 -1
  113. package/dist/app/server/assets/core-BBrZXfrB.js +0 -56
  114. package/dist/app/server/assets/core-BBrZXfrB.js.map +0 -1
  115. package/dist/app/server/assets/default-u_dwuiYb-DOrMMcg9.js +0 -2
  116. package/dist/app/server/assets/dist-CR6FW-yS.js +0 -1
  117. package/dist/app/server/assets/factory-dvoOlKer.js +0 -5
  118. package/dist/app/server/assets/get-id-field-OwLpfjj2.js +0 -6
  119. package/dist/app/server/assets/get-id-field-OwLpfjj2.js.map +0 -1
  120. package/dist/app/server/assets/kysely-adapter-B8tQwTcu.js +0 -1
@@ -71,8 +71,7 @@ namespace schema {
71
71
 
72
72
  export const response = z.object({
73
73
  sent: z.literal(true).meta({
74
- description:
75
- 'The request is accepted. The value is the same for every address.',
74
+ description: 'Always `true`, so the response reveals no account.',
76
75
  }),
77
76
  })
78
77
  }
@@ -82,11 +81,11 @@ namespace schema {
82
81
  .object({
83
82
  assertion: Passkey.schema.assertion.optional().meta({
84
83
  description:
85
- "The assertion of the email step's passkey, over a challenge from `POST /v1/auth/passkey/options` with `link`. Required with `link`, since only the person who holds the passkey can link it.",
84
+ "The passkey's assertion over options requested with the same `link`. Required with `link`, so only the passkey's holder can link it.",
86
85
  }),
87
86
  authorize: Authorize.schema.request.optional().meta({
88
87
  description:
89
- "The app's headless authorization request, as `POST /v1/authorize` takes it, from a first-party app's page. The sign-in then authorizes the app in the same request, creates a first Tempo Account for a user who holds none, and returns the authorization. A refusal that depends only on the app and the request, such as a key over the headless ceiling, comes before the sign-in and leaves the code unspent. A refusal of the authorization server after the sign-in, such as for a scope that the app's registration lacks, spends the code. Not with `link` or `oauth_query`.",
88
+ "A headless authorization request, as `POST /v1/authorize` takes it, to authorize the app in the same request. Only from a first-party app's page, and not with `link` or `oauth_query`.",
90
89
  }),
91
90
  code: z
92
91
  .string()
@@ -103,12 +102,12 @@ namespace schema {
103
102
  .optional()
104
103
  .meta({
105
104
  description:
106
- "The email step's `link`, which links the wallet.tempo passkey that asked for it to this user, with that passkey's `assertion`. An expired link refuses the sign-in with `passkey_link_expired`, and the code stays valid.",
105
+ "The `link` of the email step, which links its wallet.tempo passkey to this user. Send it with the passkey's `assertion`.",
107
106
  examples: ['dGhlIG5vbmNlIHRoYXQgdGhlIHN0ZXAgY2Fycmllcw'],
108
107
  }),
109
108
  passkey: z.literal(true).optional().meta({
110
109
  description:
111
- "With `authorize`, requests the passkey step for an account that a passkey owns, in place of `webauthn_required`. The response's `authorization` is then the step, which the page signs, and `POST /v1/authorize` with `passkey: { assertion }` signs the key.",
110
+ 'With `authorize`, returns a passkey step for a passkey-owned account, in place of `webauthn_required`. Send its assertion to `POST /v1/authorize` to sign the key.',
112
111
  }),
113
112
  // The bound covers an authorization request's query, and limits what an unsigned query can
114
113
  // write, since the passkey challenge stores its client ID before the signature is checked.
@@ -118,7 +117,7 @@ namespace schema {
118
117
  .optional()
119
118
  .meta({
120
119
  description:
121
- "The sign-in page's query string, which Better Auth signs when an app's authorization request sends the browser there. At most 8,192 characters.",
120
+ "The signed query string of the sign-in page, which names the app's pending authorization request.",
122
121
  examples: [
123
122
  'client_id=client_01JZ8Q6W3N1R5B4V7C2X9K0M3T&response_type=code&exp=1760000000&sig=Gx3kB0',
124
123
  ],
@@ -145,7 +144,7 @@ namespace schema {
145
144
  }),
146
145
  id: z.string().meta({
147
146
  description:
148
- "The user's ID, which is the `sub` of every token Tempo ID issues for the user.",
147
+ "The user's ID, which is the `sub` claim of the user's tokens.",
149
148
  examples: ['user_01JZ8Q6W3N1R5B4V7C2X9K0M3T'],
150
149
  }),
151
150
  })
@@ -157,14 +156,14 @@ namespace schema {
157
156
  .optional()
158
157
  .meta({
159
158
  description:
160
- "The app's headless authorization, for a sign-in that carried `authorize`, or a sign-in with key signature on the app's page whose options carried it. With `passkey`, the passkey step for a passkey-owned account. Absent for any other sign-in.",
159
+ "The app's authorization, for a sign-in with `authorize`, or a passkey step with `passkey`. Absent for any other sign-in.",
161
160
  }),
162
161
  redirect: z
163
162
  .url()
164
163
  .nullable()
165
164
  .meta({
166
165
  description:
167
- "Where the browser continues: the app's `redirect_uri` with an authorization code, or `null` for a sign-in that no app waits on.",
166
+ "The URL to send the browser to next, such as the app's `redirect_uri` with a code. `null` if no app waits on the sign-in.",
168
167
  examples: [
169
168
  'https://app.example.com/callback?code=SplxlOBeZQQYbYS6WxSbIA',
170
169
  ],
@@ -184,7 +183,7 @@ namespace schema {
184
183
  .object({
185
184
  authorize: Authorize.schema.request.optional().meta({
186
185
  description:
187
- "The app's headless authorization request, as `POST /v1/authorize` takes it, from a first-party app's page. The challenge is then the digest of its key, so the passkey's one assertion signs the user in and signs the key, and `POST /v1/auth/passkey/verify` returns the authorization. Requires `client_id`, the same as its own.",
186
+ "A headless authorization request, as `POST /v1/authorize` takes it. The passkey's one assertion then signs the user in and signs the key, and requires the same `client_id`.",
188
187
  }),
189
188
  client_id: z
190
189
  .string()
@@ -193,7 +192,7 @@ namespace schema {
193
192
  .optional()
194
193
  .meta({
195
194
  description:
196
- "The client ID of the first-party app whose page runs the ceremony, which selects the app's realms. Required from an app's page, whose `Origin` must be one of the app's redirect URI origins.",
195
+ "The first-party app whose page runs the sign-in. Required from an app's page, which must be on a redirect URI origin of the app.",
197
196
  examples: ['client_01JZ8Q6W3N1R5B4V7C2X9K0M3T'],
198
197
  }),
199
198
  credentialId: z
@@ -204,12 +203,12 @@ namespace schema {
204
203
  .optional()
205
204
  .meta({
206
205
  description:
207
- 'The credential ID, or up to 16 IDs, that the browser offers as `allowCredentials`, base64url. Defaults to every discoverable passkey of the relying party, as an empty list does.',
206
+ 'Up to 16 credential IDs, base64url, that the browser offers. Defaults to every passkey of the relying party.',
208
207
  examples: ['KEbWNCc7NgaYnUyrNeFGX9_3Y-8'],
209
208
  }),
210
209
  link: verify.json.shape.link.meta({
211
210
  description:
212
- "The email step's `link`, which limits the options to that step's passkey, in place of `credentialId`. The emailed-code sign-in then sends the passkey's assertion with the `link`.",
211
+ 'The `link` of the email step, which limits the options to its passkey. Send the assertion with `POST /v1/auth/code/verify`.',
213
212
  examples: ['dGhlIG5vbmNlIHRoYXQgdGhlIHN0ZXAgY2Fycmllcw'],
214
213
  }),
215
214
  mediation: z
@@ -217,7 +216,7 @@ namespace schema {
217
216
  .optional()
218
217
  .meta({
219
218
  description:
220
- 'Returned in the options for `navigator.credentials.get()`, such as `conditional` for passkey autofill.',
219
+ 'The `mediation` of the options, such as `conditional` for passkey autofill.',
221
220
  examples: ['conditional'],
222
221
  }),
223
222
  oauth_query: verify.json.shape.oauth_query,
@@ -227,7 +226,7 @@ namespace schema {
227
226
  .optional()
228
227
  .meta({
229
228
  description:
230
- "The user code of the device grant that the sign-in returns to, ignored with `oauth_query` or `client_id`. A pending, unbound code selects its app's realms, and any other code selects the `default` realm.",
229
+ 'The user code of the device grant that the sign-in continues, whose app selects the realm. Ignored with `oauth_query` or `client_id`.',
231
230
  examples: ['WDJB-MJHT'],
232
231
  }),
233
232
  })
@@ -262,16 +261,18 @@ namespace schema {
262
261
  description: 'The credential type.',
263
262
  }),
264
263
  })
265
- .meta({ description: 'A passkey the browser offers.' }),
264
+ .meta({
265
+ description: 'A passkey that the browser offers.',
266
+ }),
266
267
  )
267
268
  .optional()
268
269
  .meta({
269
270
  description:
270
- 'The passkeys the browser offers, from `credentialId`. Absent, it offers every discoverable passkey of the relying party.',
271
+ 'The passkeys that the browser offers. Absent to offer every passkey of the relying party.',
271
272
  }),
272
273
  challenge: z.templateLiteral(['0x', z.string()]).meta({
273
274
  description:
274
- 'The single-use challenge, as hex. It expires after 5 minutes.',
275
+ 'The single-use challenge, as hex, which expires after 5 minutes.',
275
276
  examples: [
276
277
  '0xf6310589abb21116acc6e123967ed0a125b5041c43f8e157237093e07eaa354c',
277
278
  ],
@@ -282,16 +283,16 @@ namespace schema {
282
283
  }),
283
284
  userVerification: z.literal('required').meta({
284
285
  description:
285
- 'Every passkey sign-in requires user verification.',
286
+ 'Requires user verification, such as a biometric or PIN.',
286
287
  }),
287
288
  })
288
289
  .meta({
289
290
  description:
290
- 'The `PublicKeyCredentialRequestOptions`, serialized with the challenge as hex.',
291
+ 'The `PublicKeyCredentialRequestOptions`, with the challenge as hex.',
291
292
  }),
292
293
  })
293
294
  .meta({
294
- description: 'The options for `navigator.credentials.get()`.',
295
+ description: 'The argument for `navigator.credentials.get()`.',
295
296
  }),
296
297
  })
297
298
  }
@@ -310,26 +311,25 @@ namespace schema {
310
311
  .object({
311
312
  link: z.string().meta({
312
313
  description:
313
- 'Send as `link` with the emailed-code sign-in, which links the passkey to that user.',
314
+ 'The value to send as `link` with the email sign-in, which links the passkey.',
314
315
  examples: ['dGhlIG5vbmNlIHRoYXQgdGhlIHN0ZXAgY2Fycmllcw'],
315
316
  }),
316
317
  signed: z.literal(false).meta({
317
- description:
318
- 'Whether the assertion already signed a key authorization. This route signs none.',
318
+ description: 'Always `false`, since this step signs no key.',
319
319
  }),
320
320
  type: z.literal('email').meta({
321
321
  description:
322
- 'Sign in with an emailed code, which links the passkey to that user.',
322
+ 'Sign in with an emailed code to link the passkey.',
323
323
  }),
324
324
  })
325
325
  .meta({
326
326
  description:
327
- 'The email step, for a wallet.tempo passkey whose account has no email.',
327
+ 'The email step, for a wallet.tempo passkey without an email.',
328
328
  }),
329
329
  })
330
330
  .meta({
331
331
  description:
332
- 'A passkey sign-in that continues when the user verifies an email address.',
332
+ 'A passkey sign-in that needs an email sign-in to finish.',
333
333
  }),
334
334
  ])
335
335
  }
@@ -350,8 +350,7 @@ namespace schema {
350
350
  .string()
351
351
  .nullable()
352
352
  .meta({
353
- description:
354
- "The user's name, or `null` for a user who signed up without one.",
353
+ description: "The user's name, or `null` if the user has none.",
355
354
  examples: ['Ada Lovelace'],
356
355
  }),
357
356
  })
@@ -392,15 +391,14 @@ namespace schema {
392
391
  .optional()
393
392
  .meta({
394
393
  description:
395
- "The page that sign-in returns to, from the sign-in page's query. Only a path on the device page passes, and any other value reads as absent.",
394
+ 'The page to return to after sign-in. Only a path on the device page is accepted.',
396
395
  examples: ['/device?code=WDJB-MJHT'],
397
396
  }),
398
397
  })
399
398
 
400
399
  export const response = z.object({
401
400
  passkeys: z.boolean().meta({
402
- description:
403
- "Whether one of the sign-in's realms holds passkeys that sign in at Tempo ID's origin, so the page offers passkey sign-in.",
401
+ description: 'Whether the page offers passkey sign-in.',
404
402
  examples: [true],
405
403
  }),
406
404
  app: z
@@ -408,7 +406,7 @@ namespace schema {
408
406
  .nullable()
409
407
  .meta({
410
408
  description:
411
- 'The display name of the app of the request in `oauth_query`, or its client ID without a name. `null` for a forged or expired query, or an unknown app.',
409
+ 'The display name of the app in `oauth_query`, or its client ID if it has none. `null` for an invalid query or an unknown app.',
412
410
  examples: ['Tempo Cash'],
413
411
  }),
414
412
  host: z
@@ -416,14 +414,14 @@ namespace schema {
416
414
  .nullable()
417
415
  .meta({
418
416
  description:
419
- "The host of a third-party app's client ID, which the page shows beside its name, or `null` for a registered app or without an app.",
417
+ "The host of a third-party app's client ID, which the page shows beside its name. `null` for a registered app.",
420
418
  examples: ['app.example'],
421
419
  }),
422
420
  request: z
423
421
  .object({
424
422
  app: z.string().meta({
425
423
  description:
426
- "The app's display name, or its client ID without one.",
424
+ "The app's display name, or its client ID if it has none.",
427
425
  examples: ['Tempo Cash'],
428
426
  }),
429
427
  key: KeyAuthorization.schema.description,
@@ -431,14 +429,14 @@ namespace schema {
431
429
  .nullable()
432
430
  .meta({
433
431
  description:
434
- 'The app and the key of the signed authorization request in `oauth_query`, which the sign-in grants. `null` when the sign-in grants no key, such as for an invalid query or a third-party app.',
432
+ 'The app and the key that the request in `oauth_query` grants on sign-in. `null` if the sign-in grants no key.',
435
433
  }),
436
434
  return_to: z
437
435
  .string()
438
436
  .nullable()
439
437
  .meta({
440
438
  description:
441
- 'The page that sign-in returns to, a path on the device page, or `null` for the account.',
439
+ 'The page to return to after sign-in, or `null` for the account page.',
442
440
  examples: ['/device?code=WDJB-MJHT'],
443
441
  }),
444
442
  user_code: z
@@ -446,12 +444,12 @@ namespace schema {
446
444
  .nullable()
447
445
  .meta({
448
446
  description:
449
- 'The user code of the device page that sign-in returns to, or `null` without one.',
447
+ 'The user code of the device page to return to, or `null`.',
450
448
  examples: ['WDJBMJHT'],
451
449
  }),
452
450
  verified: z.boolean().meta({
453
451
  description:
454
- 'Whether `app` is a registered app, whose name the page marks as verified. `false` for a third-party app, which names itself in its metadata document, and without an app.',
452
+ 'Whether `app` is a registered app, which the page marks as verified. `false` for a third-party app.',
455
453
  examples: [true],
456
454
  }),
457
455
  })
@@ -520,7 +518,7 @@ export const authenticate = new Hono<Env>()
520
518
  '/v1/auth/code',
521
519
  OpenApi.describeRoute({
522
520
  description:
523
- 'Emails a sign-in code. The response is the same for every address, so it reveals no account.',
521
+ 'Email sign-in, step 1 of 2: emails a sign-in code. The response is the same for every address, so it reveals no account.',
524
522
  responses: OpenApi.responses({
525
523
  errors: [
526
524
  ...BodyLimit.errors,
@@ -531,8 +529,7 @@ export const authenticate = new Hono<Env>()
531
529
  ErrorResponse.UpstreamUnavailableError,
532
530
  ],
533
531
  success: {
534
- description:
535
- 'The response for every address: the email service accepted the code, or does not deliver to the address.',
532
+ description: 'The same response for every address.',
536
533
  schema: schema.code.response,
537
534
  },
538
535
  }),
@@ -608,7 +605,7 @@ export const authenticate = new Hono<Env>()
608
605
  '/v1/auth/code/verify',
609
606
  OpenApi.describeRoute({
610
607
  description:
611
- 'Signs in with an emailed code, and sets the session cookie. For a user with no Tempo Account in the first realm of the app that `oauth_query` names, or in the `default` realm, it creates one when that realm creates accounts. A failed creation leaves the user signed in, and the next sign-in or `POST /v1/account` creates the account. With `authorize`, it also authorizes the app as `POST /v1/authorize` does, and a refusal after the sign-in carries `Tempo-Id-Signed-In: true`.',
608
+ 'Email sign-in, step 2 of 2: verifies the code, sets the session cookie, and creates a Tempo Account for a user who has none. With `authorize`, it also authorizes the app, as `POST /v1/authorize` does.',
612
609
  responses: OpenApi.responses({
613
610
  errors: [
614
611
  ...BodyLimit.errors,
@@ -881,7 +878,7 @@ export const authenticate = new Hono<Env>()
881
878
  '/v1/auth/passkey/options',
882
879
  OpenApi.describeRoute({
883
880
  description:
884
- "Issues a single-use challenge, and returns request options for the passkeys of the first realm whose relying party covers Tempo ID's origin, and also the page's origin from an app's page. The realms are those of the app that `oauth_query`, `client_id`, or `user_code` names, or the `default` realm. With `link`, that realm must be the `default` realm at the link's relying party.",
881
+ 'Passkey sign-in, step 1 of 2: returns the options for `navigator.credentials.get()`. The app that `oauth_query`, `client_id`, or `user_code` names selects the relying party.',
885
882
  responses: OpenApi.responses({
886
883
  errors: [
887
884
  ...BodyLimit.errors,
@@ -1117,7 +1114,7 @@ export const authenticate = new Hono<Env>()
1117
1114
  '/v1/auth/passkey/verify',
1118
1115
  OpenApi.describeRoute({
1119
1116
  description:
1120
- 'Signs in with a passkey assertion over a challenge from `POST /v1/auth/passkey/options`, and sets the session cookie. For a user with no Tempo Account in the first realm of the app that `oauth_query` names, or in the `default` realm, it creates one when that realm creates accounts. A failed creation leaves the user signed in, and the next sign-in or `POST /v1/account` creates the account.',
1117
+ "Passkey sign-in, step 2 of 2: verifies the passkey's assertion, sets the session cookie, and creates a Tempo Account for a user who has none.",
1121
1118
  responses: OpenApi.responses({
1122
1119
  errors: [
1123
1120
  ...BodyLimit.errors,
@@ -1132,7 +1129,7 @@ export const authenticate = new Hono<Env>()
1132
1129
  ],
1133
1130
  success: {
1134
1131
  description:
1135
- 'The signed-in user, with the authorization of a sign-in with key signature, or the email step for a wallet.tempo passkey without an email.',
1132
+ 'The signed-in user and any authorization, or the email step for a wallet.tempo passkey without an email.',
1136
1133
  schema: schema.passkeyVerify.response,
1137
1134
  },
1138
1135
  }),
@@ -1405,7 +1402,7 @@ export const authenticate = new Hono<Env>()
1405
1402
  '/v1/auth/logout',
1406
1403
  OpenApi.describeRoute({
1407
1404
  description:
1408
- 'Signs out: ends the session, revokes the access and refresh tokens that apps received through it, and clears its cookie.',
1405
+ 'Signs out: ends the session, revokes the tokens that apps received through it, and clears the cookie.',
1409
1406
  responses: OpenApi.responses({
1410
1407
  errors: [...BodyLimit.errors, ErrorResponse.CrossSiteRequestError],
1411
1408
  success: {
@@ -1431,7 +1428,7 @@ export const authenticate = new Hono<Env>()
1431
1428
  .get(
1432
1429
  '/v1/auth/session',
1433
1430
  OpenApi.describeRoute({
1434
- description: 'Reads the signed-in user, or `null` without a session.',
1431
+ description: 'Returns the signed-in user, or `null` without a session.',
1435
1432
  responses: OpenApi.responses({
1436
1433
  success: {
1437
1434
  description: 'The session.',
@@ -1461,7 +1458,7 @@ export const authenticate = new Hono<Env>()
1461
1458
  '/v1/auth/assets',
1462
1459
  OpenApi.describeRoute({
1463
1460
  description:
1464
- "Lists the sign-in page's scripts and style sheets, which a page on Tempo ID's site prefetches before it redirects. Browsers partition their caches by site, so a page on another site gains nothing.",
1461
+ "Lists the sign-in page's scripts and style sheets, which a page on Tempo ID's site can prefetch before it redirects to sign-in.",
1465
1462
  responses: OpenApi.responses({
1466
1463
  success: {
1467
1464
  description: 'The assets.',
@@ -1485,7 +1482,7 @@ export const authenticate = new Hono<Env>()
1485
1482
  '/v1/auth/methods',
1486
1483
  OpenApi.describeRoute({
1487
1484
  description:
1488
- 'Reads the sign-in methods that the sign-in page offers, the key that `oauth_query` grants, and the page that sign-in returns to. The app of `oauth_query`, or of a pending, unbound device code in `return_to`, selects the realms. The read binds nothing, and counts against the sign-in limit of the IP address.',
1485
+ 'Returns what the sign-in page shows: the sign-in methods, any key that `oauth_query` requests, and the page that sign-in returns to.',
1489
1486
  responses: OpenApi.responses({
1490
1487
  errors: [...OpenApi.validate.errors],
1491
1488
  success: {