@atproto/oauth-provider-api 0.7.9 → 0.8.1

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.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,21 @@
1
1
  # @atproto/oauth-provider-api
2
2
 
3
+ ## 0.8.1
4
+
5
+ ### Patch Changes
6
+
7
+ - Updated dependencies [[`6af9f14`](https://github.com/bluesky-social/atproto/commit/6af9f141d18c1f41a04828af8256567d5f17a35e)]:
8
+ - @atproto/syntax@0.7.5
9
+
10
+ ## 0.8.0
11
+
12
+ ### Minor Changes
13
+
14
+ - [#5387](https://github.com/bluesky-social/atproto/pull/5387) [`4e18a00`](https://github.com/bluesky-social/atproto/commit/4e18a00b2de97e36b9b00a7fcb8713efd87964d1) Thanks [@bigmoves](https://github.com/bigmoves)! - Remove the `ISODateString` and `ActiveDeviceSession` types, which duplicated
15
+ `ISODatetimeString` from `@atproto/syntax` and `Session` respectively. Remove
16
+ the `deleteAfter` property from `DeactivateAccountInput`, which the
17
+ `/deactivate-account` endpoint never accepted.
18
+
3
19
  ## 0.7.9
4
20
 
5
21
  ### Patch Changes
@@ -1,7 +1,7 @@
1
1
  import type { SignedJwt } from '@atproto/jwk';
2
2
  import type { OAuthClientMetadata } from '@atproto/oauth-types';
3
- import type { DatetimeString, DidString, HandleString } from '@atproto/syntax';
4
- import type { Account, DeviceMetadata, ISODateString, Session } from './types.js';
3
+ import type { DidString, HandleString, ISODatetimeString } from '@atproto/syntax';
4
+ import type { Account, DeviceMetadata, Session } from './types.js';
5
5
  export type { DidString };
6
6
  export type ApiEndpoints = {
7
7
  '/verify-handle-availability': {
@@ -261,7 +261,6 @@ export type UpdateHandleOutput = {
261
261
  };
262
262
  export type DeactivateAccountInput = {
263
263
  did: DidString;
264
- deleteAfter?: DatetimeString;
265
264
  };
266
265
  export type DeactivateAccountOutput = {
267
266
  account: Account;
@@ -302,18 +301,6 @@ export type ConsentInput = {
302
301
  scope?: string;
303
302
  };
304
303
  export type RejectInput = Record<string, never>;
305
- /**
306
- * Represents an account that is currently signed-in to the Authorization
307
- * Server. If the session was created too long ago, the user may be required to
308
- * re-authenticate ({@link ActiveDeviceSession.loginRequired}).
309
- */
310
- export type ActiveDeviceSession = {
311
- account: Account;
312
- /**
313
- * The session is too old and the user must re-authenticate.
314
- */
315
- loginRequired: boolean;
316
- };
317
304
  /**
318
305
  * Represents another device on which an account is currently signed-in.
319
306
  */
@@ -327,8 +314,8 @@ export type ActiveAccountSession = {
327
314
  */
328
315
  export type ActiveOAuthSession = {
329
316
  tokenId: string;
330
- createdAt: ISODateString;
331
- updatedAt: ISODateString;
317
+ createdAt: ISODatetimeString;
318
+ updatedAt: ISODatetimeString;
332
319
  active: boolean;
333
320
  clientId: string;
334
321
  /** An "undefined" value means that the client metadata could not be fetched */
@@ -1 +1 @@
1
- {"version":3,"file":"api-endpoints.d.ts","sourceRoot":"","sources":["../src/api-endpoints.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,cAAc,CAAA;AAC7C,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,sBAAsB,CAAA;AAC/D,OAAO,KAAK,EAAE,cAAc,EAAE,SAAS,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAA;AAC9E,OAAO,KAAK,EACV,OAAO,EACP,cAAc,EACd,aAAa,EACb,OAAO,EACR,MAAM,YAAY,CAAA;AAEnB,YAAY,EAAE,SAAS,EAAE,CAAA;AAKzB,MAAM,MAAM,YAAY,GAAG;IACzB,6BAA6B,EAAE;QAC7B,MAAM,EAAE,MAAM,CAAA;QACd,KAAK,EAAE,6BAA6B,CAAA;QACpC,MAAM,EAAE;YAAE,SAAS,EAAE,IAAI,CAAA;SAAE,CAAA;KAC5B,CAAA;IACD,UAAU,EAAE;QACV,MAAM,EAAE,MAAM,CAAA;QACd,KAAK,EAAE,WAAW,CAAA;QAClB,MAAM,EAAE,YAAY,CAAA;KACrB,CAAA;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AAM,MAAM,kBAAkB,GAAG;IAC/B,OAAO,EAAE,MAAM,CAAA;IAEf,SAAS,EAAE,iBAAiB,CAAA;IAC5B,SAAS,EAAE,iBAAiB,CAAA;IAE5B,MAAM,EAAE,OAAO,CAAA;IAEf,QAAQ,EAAE,MAAM,CAAA;IAChB,+EAA+E;IAC/E,cAAc,CAAC,EAAE,mBAAmB,CAAA;IAEpC,KAAK,CAAC,EAAE,MAAM,CAAA;CACf,CAAA"}
@@ -1 +1 @@
1
- {"version":3,"file":"api-endpoints.js","sourceRoot":"","sources":["../src/api-endpoints.ts"],"names":[],"mappings":"","sourcesContent":["import type { SignedJwt } from '@atproto/jwk'\nimport type { OAuthClientMetadata } from '@atproto/oauth-types'\nimport type { DatetimeString, DidString, HandleString } from '@atproto/syntax'\nimport type {\n Account,\n DeviceMetadata,\n ISODateString,\n Session,\n} from './types.js'\n\nexport type { DidString }\n\n// These are the endpoints implemented by the OAuth provider, for its UI to\n// call.\n\nexport type ApiEndpoints = {\n '/verify-handle-availability': {\n method: 'POST'\n input: VerifyHandleAvailabilityInput\n output: { available: true }\n }\n '/sign-up': {\n method: 'POST'\n input: SignUpInput\n output: SignUpOutput\n }\n '/sign-in': {\n method: 'POST'\n input: SignInInput\n output: SignInOutput\n }\n '/reset-password-request': {\n method: 'POST'\n input: InitiatePasswordResetInput\n output: { success: true }\n }\n '/reset-password-confirm': {\n method: 'POST'\n input: ConfirmResetPasswordInput\n output: { success: true }\n }\n '/sign-out': {\n method: 'POST'\n input: SignOutInput\n output: { success: true }\n }\n /**\n * Lists all the accounts that are currently active, on the current device.\n */\n '/device-sessions': {\n method: 'GET'\n output: Session[]\n }\n /**\n * Lists all the active OAuth sessions (access/refresh tokens) that where\n * issued to OAuth clients (apps).\n *\n * @NOTE can be revoked using the oauth revocation endpoint (json or form\n * encoded)\n *\n * ```http\n * POST /oauth/revoke\n * Content-Type: application/x-www-form-urlencoded\n *\n * token=<tokenId>\n * ```\n */\n '/oauth-sessions': {\n method: 'GET'\n params: OAuthSessionsInput\n output: OAuthSessionsOutput\n }\n '/revoke-oauth-session': {\n method: 'POST'\n input: RevokeOAuthSessionInput\n output: { success: true }\n }\n /**\n * Lists all the sessions that are currently active for a particular user, on\n * other devices.\n */\n '/account-sessions': {\n method: 'GET'\n params: AccountSessionsInput\n output: AccountSessionsOutput\n }\n '/revoke-account-session': {\n method: 'POST'\n input: RevokeAccountSessionInput\n output: { success: true }\n }\n '/update-email-request': {\n method: 'POST'\n input: InitiateEmailUpdateInput\n output: InitiateEmailUpdateOutput\n }\n '/update-email-confirm': {\n method: 'POST'\n input: ConfirmEmailUpdateInput\n output: ConfirmEmailUpdateOutput\n }\n '/verify-email-request': {\n method: 'POST'\n input: InitiateEmailVerificationInput\n output: { success: true }\n }\n '/verify-email-confirm': {\n method: 'POST'\n input: ConfirmEmailVerificationInput\n output: ConfirmEmailVerificationOutput\n }\n '/update-handle': {\n method: 'POST'\n input: UpdateHandleInput\n output: UpdateHandleOutput\n }\n /**\n * Marks the account as deactivated. The account remains recoverable — the\n * user can sign back in to reactivate via {@link ApiEndpoints['/reactivate-account']}.\n * Profile, posts, feeds and lists are hidden across the network until then.\n */\n '/deactivate-account': {\n method: 'POST'\n input: DeactivateAccountInput\n output: DeactivateAccountOutput\n }\n /**\n * Reactivates a previously-deactivated account. No-op when the account is\n * already active.\n */\n '/reactivate-account': {\n method: 'POST'\n input: ReactivateAccountInput\n output: ReactivateAccountOutput\n }\n /**\n * Initiates account deletion by sending a confirmation code to the account's\n * email address. The account is NOT deleted until\n * {@link ApiEndpoints['/delete-account-confirm']} is called with the matching\n * token and the user's current password.\n */\n '/delete-account-request': {\n method: 'POST'\n input: InitiateAccountDeletionInput\n output: { success: true }\n }\n /**\n * Confirms and finalizes account deletion. Requires both the email\n * confirmation token issued by {@link ApiEndpoints['/delete-account-request']}\n * and the user's current password. Deletion is irreversible.\n */\n '/delete-account-confirm': {\n method: 'POST'\n input: ConfirmAccountDeletionInput\n output: { success: true }\n }\n '/consent': {\n method: 'POST'\n input: ConsentInput\n output: { url: string }\n }\n '/reject': {\n method: 'POST'\n input: RejectInput\n output: { url: string }\n }\n}\n\n/**\n * When a user signs in without the \"remember me\" option, the server returns an\n * ephemeral token. When used as `Bearer` authorization header, the token will\n * be used in order to authenticate the users in place of using the user's\n * cookie based session (which are only created when \"remember me\" is checked).\n *\n * Only include this token in the `Authorization` header when making requests to\n * the OAuth provider API, **FOR THE ACCOUNT IT WAS GENERATED FOR**.\n */\nexport type EphemeralToken = SignedJwt\n\nexport type SignInInput = {\n locale: string\n username: string\n password: string\n emailOtp?: string\n remember?: boolean\n}\n\nexport type SignInOutput = {\n account: Account\n ephemeralToken?: EphemeralToken\n}\n\nexport type SignUpInput = {\n locale: string\n handle: string\n email: string\n password: string\n inviteCode?: string\n hcaptchaToken?: string\n}\n\nexport type SignUpOutput = {\n account: Account\n ephemeralToken?: EphemeralToken\n}\n\nexport type SignOutInput = {\n did: DidString | DidString[]\n}\n\nexport type InitiatePasswordResetInput = {\n locale: string\n email: string\n}\n\nexport type ConfirmResetPasswordInput = {\n token: string\n password: string\n}\n\nexport type InitiateEmailUpdateInput = {\n did: DidString\n locale?: string\n}\n\nexport type InitiateEmailUpdateOutput = {\n tokenRequired: boolean\n}\n\nexport type ConfirmEmailUpdateInput = {\n did: DidString\n token?: string\n email: string\n locale?: string\n}\n\nexport type ConfirmEmailUpdateOutput = {\n account: Account\n}\n\nexport type InitiateEmailVerificationInput = {\n did: DidString\n locale?: string\n}\n\nexport type ConfirmEmailVerificationInput = {\n did: DidString\n token: string\n email: string\n}\n\nexport type ConfirmEmailVerificationOutput = {\n account: Account\n}\n\nexport type VerifyHandleAvailabilityInput = {\n handle: HandleString\n}\n\nexport type UpdateHandleInput = {\n did: DidString\n handle: HandleString\n}\n\nexport type UpdateHandleOutput = {\n account: Account\n}\n\nexport type DeactivateAccountInput = {\n did: DidString\n deleteAfter?: DatetimeString\n}\n\nexport type DeactivateAccountOutput = {\n account: Account\n}\n\nexport type ReactivateAccountInput = {\n did: DidString\n}\n\nexport type ReactivateAccountOutput = {\n account: Account\n}\n\nexport type InitiateAccountDeletionInput = {\n did: DidString\n locale?: string\n}\n\nexport type ConfirmAccountDeletionInput = {\n did: DidString\n token: string\n password: string\n}\n\nexport type RevokeAccountSessionInput = {\n did: DidString\n deviceId: string\n}\n\nexport type OAuthSessionsInput = {\n did: DidString\n}\n\nexport type OAuthSessionsOutput = ActiveOAuthSession[]\n\nexport type AccountSessionsInput = {\n did: DidString\n}\n\nexport type AccountSessionsOutput = ActiveAccountSession[]\n\nexport type RevokeOAuthSessionInput = {\n did: DidString\n tokenId: string\n}\n\nexport type ConsentInput = {\n did: DidString\n scope?: string\n}\n\nexport type RejectInput = Record<string, never>\n\n/**\n * Represents an account that is currently signed-in to the Authorization\n * Server. If the session was created too long ago, the user may be required to\n * re-authenticate ({@link ActiveDeviceSession.loginRequired}).\n */\nexport type ActiveDeviceSession = {\n account: Account\n\n /**\n * The session is too old and the user must re-authenticate.\n */\n loginRequired: boolean\n}\n\n/**\n * Represents another device on which an account is currently signed-in.\n */\nexport type ActiveAccountSession = {\n deviceId: string\n deviceMetadata: DeviceMetadata\n\n isCurrentDevice: boolean\n}\n\n/**\n * Represents an active OAuth session (access token).\n */\nexport type ActiveOAuthSession = {\n tokenId: string\n\n createdAt: ISODateString\n updatedAt: ISODateString\n\n active: boolean\n\n clientId: string\n /** An \"undefined\" value means that the client metadata could not be fetched */\n clientMetadata?: OAuthClientMetadata\n\n scope?: string\n}\n"]}
1
+ {"version":3,"file":"api-endpoints.js","sourceRoot":"","sources":["../src/api-endpoints.ts"],"names":[],"mappings":"","sourcesContent":["import type { SignedJwt } from '@atproto/jwk'\nimport type { OAuthClientMetadata } from '@atproto/oauth-types'\nimport type {\n DidString,\n HandleString,\n ISODatetimeString,\n} from '@atproto/syntax'\nimport type { Account, DeviceMetadata, Session } from './types.js'\n\nexport type { DidString }\n\n// These are the endpoints implemented by the OAuth provider, for its UI to\n// call.\n\nexport type ApiEndpoints = {\n '/verify-handle-availability': {\n method: 'POST'\n input: VerifyHandleAvailabilityInput\n output: { available: true }\n }\n '/sign-up': {\n method: 'POST'\n input: SignUpInput\n output: SignUpOutput\n }\n '/sign-in': {\n method: 'POST'\n input: SignInInput\n output: SignInOutput\n }\n '/reset-password-request': {\n method: 'POST'\n input: InitiatePasswordResetInput\n output: { success: true }\n }\n '/reset-password-confirm': {\n method: 'POST'\n input: ConfirmResetPasswordInput\n output: { success: true }\n }\n '/sign-out': {\n method: 'POST'\n input: SignOutInput\n output: { success: true }\n }\n /**\n * Lists all the accounts that are currently active, on the current device.\n */\n '/device-sessions': {\n method: 'GET'\n output: Session[]\n }\n /**\n * Lists all the active OAuth sessions (access/refresh tokens) that where\n * issued to OAuth clients (apps).\n *\n * @NOTE can be revoked using the oauth revocation endpoint (json or form\n * encoded)\n *\n * ```http\n * POST /oauth/revoke\n * Content-Type: application/x-www-form-urlencoded\n *\n * token=<tokenId>\n * ```\n */\n '/oauth-sessions': {\n method: 'GET'\n params: OAuthSessionsInput\n output: OAuthSessionsOutput\n }\n '/revoke-oauth-session': {\n method: 'POST'\n input: RevokeOAuthSessionInput\n output: { success: true }\n }\n /**\n * Lists all the sessions that are currently active for a particular user, on\n * other devices.\n */\n '/account-sessions': {\n method: 'GET'\n params: AccountSessionsInput\n output: AccountSessionsOutput\n }\n '/revoke-account-session': {\n method: 'POST'\n input: RevokeAccountSessionInput\n output: { success: true }\n }\n '/update-email-request': {\n method: 'POST'\n input: InitiateEmailUpdateInput\n output: InitiateEmailUpdateOutput\n }\n '/update-email-confirm': {\n method: 'POST'\n input: ConfirmEmailUpdateInput\n output: ConfirmEmailUpdateOutput\n }\n '/verify-email-request': {\n method: 'POST'\n input: InitiateEmailVerificationInput\n output: { success: true }\n }\n '/verify-email-confirm': {\n method: 'POST'\n input: ConfirmEmailVerificationInput\n output: ConfirmEmailVerificationOutput\n }\n '/update-handle': {\n method: 'POST'\n input: UpdateHandleInput\n output: UpdateHandleOutput\n }\n /**\n * Marks the account as deactivated. The account remains recoverable — the\n * user can sign back in to reactivate via {@link ApiEndpoints['/reactivate-account']}.\n * Profile, posts, feeds and lists are hidden across the network until then.\n */\n '/deactivate-account': {\n method: 'POST'\n input: DeactivateAccountInput\n output: DeactivateAccountOutput\n }\n /**\n * Reactivates a previously-deactivated account. No-op when the account is\n * already active.\n */\n '/reactivate-account': {\n method: 'POST'\n input: ReactivateAccountInput\n output: ReactivateAccountOutput\n }\n /**\n * Initiates account deletion by sending a confirmation code to the account's\n * email address. The account is NOT deleted until\n * {@link ApiEndpoints['/delete-account-confirm']} is called with the matching\n * token and the user's current password.\n */\n '/delete-account-request': {\n method: 'POST'\n input: InitiateAccountDeletionInput\n output: { success: true }\n }\n /**\n * Confirms and finalizes account deletion. Requires both the email\n * confirmation token issued by {@link ApiEndpoints['/delete-account-request']}\n * and the user's current password. Deletion is irreversible.\n */\n '/delete-account-confirm': {\n method: 'POST'\n input: ConfirmAccountDeletionInput\n output: { success: true }\n }\n '/consent': {\n method: 'POST'\n input: ConsentInput\n output: { url: string }\n }\n '/reject': {\n method: 'POST'\n input: RejectInput\n output: { url: string }\n }\n}\n\n/**\n * When a user signs in without the \"remember me\" option, the server returns an\n * ephemeral token. When used as `Bearer` authorization header, the token will\n * be used in order to authenticate the users in place of using the user's\n * cookie based session (which are only created when \"remember me\" is checked).\n *\n * Only include this token in the `Authorization` header when making requests to\n * the OAuth provider API, **FOR THE ACCOUNT IT WAS GENERATED FOR**.\n */\nexport type EphemeralToken = SignedJwt\n\nexport type SignInInput = {\n locale: string\n username: string\n password: string\n emailOtp?: string\n remember?: boolean\n}\n\nexport type SignInOutput = {\n account: Account\n ephemeralToken?: EphemeralToken\n}\n\nexport type SignUpInput = {\n locale: string\n handle: string\n email: string\n password: string\n inviteCode?: string\n hcaptchaToken?: string\n}\n\nexport type SignUpOutput = {\n account: Account\n ephemeralToken?: EphemeralToken\n}\n\nexport type SignOutInput = {\n did: DidString | DidString[]\n}\n\nexport type InitiatePasswordResetInput = {\n locale: string\n email: string\n}\n\nexport type ConfirmResetPasswordInput = {\n token: string\n password: string\n}\n\nexport type InitiateEmailUpdateInput = {\n did: DidString\n locale?: string\n}\n\nexport type InitiateEmailUpdateOutput = {\n tokenRequired: boolean\n}\n\nexport type ConfirmEmailUpdateInput = {\n did: DidString\n token?: string\n email: string\n locale?: string\n}\n\nexport type ConfirmEmailUpdateOutput = {\n account: Account\n}\n\nexport type InitiateEmailVerificationInput = {\n did: DidString\n locale?: string\n}\n\nexport type ConfirmEmailVerificationInput = {\n did: DidString\n token: string\n email: string\n}\n\nexport type ConfirmEmailVerificationOutput = {\n account: Account\n}\n\nexport type VerifyHandleAvailabilityInput = {\n handle: HandleString\n}\n\nexport type UpdateHandleInput = {\n did: DidString\n handle: HandleString\n}\n\nexport type UpdateHandleOutput = {\n account: Account\n}\n\nexport type DeactivateAccountInput = {\n did: DidString\n}\n\nexport type DeactivateAccountOutput = {\n account: Account\n}\n\nexport type ReactivateAccountInput = {\n did: DidString\n}\n\nexport type ReactivateAccountOutput = {\n account: Account\n}\n\nexport type InitiateAccountDeletionInput = {\n did: DidString\n locale?: string\n}\n\nexport type ConfirmAccountDeletionInput = {\n did: DidString\n token: string\n password: string\n}\n\nexport type RevokeAccountSessionInput = {\n did: DidString\n deviceId: string\n}\n\nexport type OAuthSessionsInput = {\n did: DidString\n}\n\nexport type OAuthSessionsOutput = ActiveOAuthSession[]\n\nexport type AccountSessionsInput = {\n did: DidString\n}\n\nexport type AccountSessionsOutput = ActiveAccountSession[]\n\nexport type RevokeOAuthSessionInput = {\n did: DidString\n tokenId: string\n}\n\nexport type ConsentInput = {\n did: DidString\n scope?: string\n}\n\nexport type RejectInput = Record<string, never>\n\n/**\n * Represents another device on which an account is currently signed-in.\n */\nexport type ActiveAccountSession = {\n deviceId: string\n deviceMetadata: DeviceMetadata\n\n isCurrentDevice: boolean\n}\n\n/**\n * Represents an active OAuth session (access token).\n */\nexport type ActiveOAuthSession = {\n tokenId: string\n\n createdAt: ISODatetimeString\n updatedAt: ISODatetimeString\n\n active: boolean\n\n clientId: string\n /** An \"undefined\" value means that the client metadata could not be fetched */\n clientMetadata?: OAuthClientMetadata\n\n scope?: string\n}\n"]}
@@ -1,4 +1,4 @@
1
1
  export declare const CSRF_COOKIE_NAME = "csrf-token";
2
2
  export declare const CSRF_HEADER_NAME = "x-csrf-token";
3
3
  export declare const API_ENDPOINT_PREFIX = "/@atproto/oauth-provider/~api";
4
- //# sourceMappingURL=contants.d.ts.map
4
+ //# sourceMappingURL=constants.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../src/constants.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,gBAAgB,eAAe,CAAA;AAC5C,eAAO,MAAM,gBAAgB,iBAAiB,CAAA;AAE9C,eAAO,MAAM,mBAAmB,kCAAkC,CAAA"}
@@ -1,4 +1,4 @@
1
1
  export const CSRF_COOKIE_NAME = 'csrf-token';
2
2
  export const CSRF_HEADER_NAME = 'x-csrf-token';
3
3
  export const API_ENDPOINT_PREFIX = '/@atproto/oauth-provider/~api';
4
- //# sourceMappingURL=contants.js.map
4
+ //# sourceMappingURL=constants.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"constants.js","sourceRoot":"","sources":["../src/constants.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,MAAM,gBAAgB,GAAG,YAAY,CAAA;AAC5C,MAAM,CAAC,MAAM,gBAAgB,GAAG,cAAc,CAAA;AAE9C,MAAM,CAAC,MAAM,mBAAmB,GAAG,+BAA+B,CAAA","sourcesContent":["export const CSRF_COOKIE_NAME = 'csrf-token'\nexport const CSRF_HEADER_NAME = 'x-csrf-token'\n\nexport const API_ENDPOINT_PREFIX = '/@atproto/oauth-provider/~api'\n"]}
package/dist/index.d.ts CHANGED
@@ -1,6 +1,6 @@
1
1
  export type * from './api-endpoints.js';
2
2
  export type * from './customization-data.js';
3
3
  export type * from './types.js';
4
- export * from './contants.js';
4
+ export * from './constants.js';
5
5
  export * from './errors.js';
6
6
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,mBAAmB,oBAAoB,CAAA;AACvC,mBAAmB,yBAAyB,CAAA;AAC5C,mBAAmB,YAAY,CAAA;AAE/B,cAAc,eAAe,CAAA;AAC7B,cAAc,aAAa,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,mBAAmB,oBAAoB,CAAA;AACvC,mBAAmB,yBAAyB,CAAA;AAC5C,mBAAmB,YAAY,CAAA;AAE/B,cAAc,gBAAgB,CAAA;AAC9B,cAAc,aAAa,CAAA"}
package/dist/index.js CHANGED
@@ -1,3 +1,3 @@
1
- export * from './contants.js';
1
+ export * from './constants.js';
2
2
  export * from './errors.js';
3
3
  //# sourceMappingURL=index.js.map
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAIA,cAAc,eAAe,CAAA;AAC7B,cAAc,aAAa,CAAA","sourcesContent":["export type * from './api-endpoints.js'\nexport type * from './customization-data.js'\nexport type * from './types.js'\n\nexport * from './contants.js'\nexport * from './errors.js'\n"]}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAIA,cAAc,gBAAgB,CAAA;AAC9B,cAAc,aAAa,CAAA","sourcesContent":["export type * from './api-endpoints.js'\nexport type * from './customization-data.js'\nexport type * from './types.js'\n\nexport * from './constants.js'\nexport * from './errors.js'\n"]}
package/dist/types.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import type { DidString, HandleString } from '@atproto/syntax';
1
+ import type { DidString, HandleString, ISODatetimeString } from '@atproto/syntax';
2
2
  export type { DidString };
3
3
  export type Account = {
4
4
  did: DidString;
@@ -30,7 +30,6 @@ export type LinkDefinition = {
30
30
  export type DeviceMetadata = {
31
31
  userAgent: string | null;
32
32
  ipAddress: string;
33
- lastSeenAt: ISODateString;
33
+ lastSeenAt: ISODatetimeString;
34
34
  };
35
- export type ISODateString = `${string}T${string}Z`;
36
35
  //# sourceMappingURL=types.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAA;AAE9D,YAAY,EAAE,SAAS,EAAE,CAAA;AAEzB,MAAM,MAAM,OAAO,GAAG;IACpB,GAAG,EAAE,SAAS,CAAA;IACd,GAAG,EAAE,SAAS,CAAA;IACd,WAAW,EAAE,OAAO,CAAA;IACpB,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,aAAa,CAAC,EAAE,OAAO,CAAA;IACvB,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,MAAM,CAAC,EAAE,YAAY,CAAA;IACrB,OAAO,CAAC,EAAE,MAAM,CAAA;CACjB,CAAA;AAED;;;;GAIG;AACH,MAAM,MAAM,OAAO,GAAG;IACpB,OAAO,EAAE,OAAO,CAAA;IAChB,IAAI,CAAC,EAAE,KAAK,CAAA;IAEZ,aAAa,EAAE,OAAO,CAAA;CACvB,CAAA;AAED,MAAM,MAAM,eAAe,GAAG,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,CAAC,CAAA;AAEhE,MAAM,MAAM,cAAc,GAAG;IAC3B,KAAK,EAAE,MAAM,GAAG,eAAe,CAAA;IAC/B,IAAI,EAAE,MAAM,CAAA;IACZ,GAAG,CAAC,EAAE,MAAM,CAAA;CACb,CAAA;AAED,MAAM,MAAM,cAAc,GAAG;IAC3B,SAAS,EAAE,MAAM,GAAG,IAAI,CAAA;IACxB,SAAS,EAAE,MAAM,CAAA;IACjB,UAAU,EAAE,aAAa,CAAA;CAC1B,CAAA;AAED,MAAM,MAAM,aAAa,GAAG,GAAG,MAAM,IAAI,MAAM,GAAG,CAAA"}
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,SAAS,EACT,YAAY,EACZ,iBAAiB,EAClB,MAAM,iBAAiB,CAAA;AAExB,YAAY,EAAE,SAAS,EAAE,CAAA;AAEzB,MAAM,MAAM,OAAO,GAAG;IACpB,GAAG,EAAE,SAAS,CAAA;IACd,GAAG,EAAE,SAAS,CAAA;IACd,WAAW,EAAE,OAAO,CAAA;IACpB,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,aAAa,CAAC,EAAE,OAAO,CAAA;IACvB,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,MAAM,CAAC,EAAE,YAAY,CAAA;IACrB,OAAO,CAAC,EAAE,MAAM,CAAA;CACjB,CAAA;AAED;;;;GAIG;AACH,MAAM,MAAM,OAAO,GAAG;IACpB,OAAO,EAAE,OAAO,CAAA;IAChB,IAAI,CAAC,EAAE,KAAK,CAAA;IAEZ,aAAa,EAAE,OAAO,CAAA;CACvB,CAAA;AAED,MAAM,MAAM,eAAe,GAAG,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,CAAC,CAAA;AAEhE,MAAM,MAAM,cAAc,GAAG;IAC3B,KAAK,EAAE,MAAM,GAAG,eAAe,CAAA;IAC/B,IAAI,EAAE,MAAM,CAAA;IACZ,GAAG,CAAC,EAAE,MAAM,CAAA;CACb,CAAA;AAED,MAAM,MAAM,cAAc,GAAG;IAC3B,SAAS,EAAE,MAAM,GAAG,IAAI,CAAA;IACxB,SAAS,EAAE,MAAM,CAAA;IACjB,UAAU,EAAE,iBAAiB,CAAA;CAC9B,CAAA"}
package/dist/types.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"types.js","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"","sourcesContent":["import type { DidString, HandleString } from '@atproto/syntax'\n\nexport type { DidString }\n\nexport type Account = {\n did: DidString\n pds: DidString\n deactivated: boolean\n locale?: string\n email?: string\n emailVerified?: boolean\n name?: string\n handle?: HandleString\n picture?: string\n}\n\n/**\n * Represents an account that is currently signed-in to the Authorization\n * Server. If the session was created too long ago, the user may be required to\n * re-authenticate ({@link Session.loginRequired}).\n */\nexport type Session = {\n account: Account\n info?: never // Prevent relying on this in the frontend\n\n loginRequired: boolean\n}\n\nexport type MultiLangString = Record<string, string | undefined>\n\nexport type LinkDefinition = {\n title: string | MultiLangString\n href: string\n rel?: string\n}\n\nexport type DeviceMetadata = {\n userAgent: string | null\n ipAddress: string\n lastSeenAt: ISODateString\n}\n\nexport type ISODateString = `${string}T${string}Z`\n"]}
1
+ {"version":3,"file":"types.js","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"","sourcesContent":["import type {\n DidString,\n HandleString,\n ISODatetimeString,\n} from '@atproto/syntax'\n\nexport type { DidString }\n\nexport type Account = {\n did: DidString\n pds: DidString\n deactivated: boolean\n locale?: string\n email?: string\n emailVerified?: boolean\n name?: string\n handle?: HandleString\n picture?: string\n}\n\n/**\n * Represents an account that is currently signed-in to the Authorization\n * Server. If the session was created too long ago, the user may be required to\n * re-authenticate ({@link Session.loginRequired}).\n */\nexport type Session = {\n account: Account\n info?: never // Prevent relying on this in the frontend\n\n loginRequired: boolean\n}\n\nexport type MultiLangString = Record<string, string | undefined>\n\nexport type LinkDefinition = {\n title: string | MultiLangString\n href: string\n rel?: string\n}\n\nexport type DeviceMetadata = {\n userAgent: string | null\n ipAddress: string\n lastSeenAt: ISODatetimeString\n}\n"]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atproto/oauth-provider-api",
3
- "version": "0.7.9",
3
+ "version": "0.8.1",
4
4
  "license": "MIT",
5
5
  "description": "Shared data types for the @atproto/oauth-provider and @atproto/oauth-provider-ui packages",
6
6
  "keywords": [
@@ -32,7 +32,7 @@
32
32
  "dependencies": {
33
33
  "@atproto/jwk": "^0.7.4",
34
34
  "@atproto/oauth-types": "^0.7.5",
35
- "@atproto/syntax": "^0.7.4"
35
+ "@atproto/syntax": "^0.7.5"
36
36
  },
37
37
  "scripts": {
38
38
  "build": "tsc --build tsconfig.build.json"
@@ -1 +0,0 @@
1
- {"version":3,"file":"contants.d.ts","sourceRoot":"","sources":["../src/contants.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,gBAAgB,eAAe,CAAA;AAC5C,eAAO,MAAM,gBAAgB,iBAAiB,CAAA;AAE9C,eAAO,MAAM,mBAAmB,kCAAkC,CAAA"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"contants.js","sourceRoot":"","sources":["../src/contants.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,MAAM,gBAAgB,GAAG,YAAY,CAAA;AAC5C,MAAM,CAAC,MAAM,gBAAgB,GAAG,cAAc,CAAA;AAE9C,MAAM,CAAC,MAAM,mBAAmB,GAAG,+BAA+B,CAAA","sourcesContent":["export const CSRF_COOKIE_NAME = 'csrf-token'\nexport const CSRF_HEADER_NAME = 'x-csrf-token'\n\nexport const API_ENDPOINT_PREFIX = '/@atproto/oauth-provider/~api'\n"]}