@tennantje/identity-types 1.0.1 → 1.0.5

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.
@@ -0,0 +1,14 @@
1
+ export type ActivateUserRequest = {
2
+ userId: string;
3
+ verificationCode: string;
4
+ };
5
+ export type VerifyEmailChangeRequest = {
6
+ userId: string;
7
+ verificationCode: string;
8
+ };
9
+ export type GetCurrentUserResponse = {
10
+ userId: string;
11
+ firstName: string;
12
+ lastName: string;
13
+ email: string;
14
+ };
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,42 @@
1
+ export type CreateOAuthClientRequest = {
2
+ clientName: string;
3
+ clientType: "CONFIDENTIAL_CLIENT" | "PUBLIC_CLIENT";
4
+ redirectUris: string[];
5
+ scopes: string[];
6
+ clientDescription: string;
7
+ clientWebsite: string;
8
+ clientLogoUri: string;
9
+ };
10
+ export interface OAuthClient {
11
+ clientId: string;
12
+ clientName: string;
13
+ clientType: "CONFIDENTIAL_CLIENT" | "PUBLIC_CLIENT";
14
+ scopes: string[];
15
+ redirectUris: string[];
16
+ createdAt: string;
17
+ createdBy: string;
18
+ modifiedAt: string;
19
+ modifiedBy: string;
20
+ clientDescription: string;
21
+ clientWebsite: string;
22
+ clientLogoUri: string;
23
+ }
24
+ export type CreateOAuthClientResponse = OAuthClient;
25
+ export type GetOAuthClientRequest = {
26
+ clientId: string;
27
+ };
28
+ export type GetOAuthClientResponse = OAuthClient;
29
+ export type GetOAuthClientsResponse = {
30
+ clients: OAuthClient[];
31
+ };
32
+ export type OAuthAuthorizeResponse = {
33
+ success: boolean;
34
+ redirect_uri: string;
35
+ };
36
+ export type OAuthTokenResponse = {
37
+ access_token?: string;
38
+ token_type?: string;
39
+ expires_in?: number;
40
+ refresh_token?: string;
41
+ scope?: string;
42
+ };
package/dist/OAuth.js ADDED
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,17 @@
1
+ export type RequestLoginCodeRequest = {
2
+ email: string;
3
+ };
4
+ export type RequestLoginCodeResponse = {
5
+ message: string;
6
+ email: string;
7
+ };
8
+ export type VerifyLoginCodeRequest = {
9
+ email: string;
10
+ loginCode: string;
11
+ };
12
+ export type RefreshResponse = {
13
+ message: string;
14
+ };
15
+ export type LogoutResponse = {
16
+ message: string;
17
+ };
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,38 @@
1
+ export type BeginWebAuthnRegistrationResponse = {
2
+ registrationOptions: any;
3
+ };
4
+ export type CompleteWebAuthnRegistrationRequest = {
5
+ registrationResponse: any;
6
+ };
7
+ export type CompleteWebAuthnRegistrationResponse = {
8
+ success: boolean;
9
+ };
10
+ export type BeginWebAuthnAuthenticationRequest = {
11
+ email: string;
12
+ };
13
+ export type BeginWebAuthnAuthenticationResponse = {
14
+ authenticationOptions: any;
15
+ };
16
+ export type CompleteWebAuthnAuthenticationRequest = {
17
+ email: string;
18
+ authenticationResponse: any;
19
+ };
20
+ export type CompleteWebAuthnAuthenticationResponse = {
21
+ success: boolean;
22
+ };
23
+ export interface PasskeySummary {
24
+ credentialId: string;
25
+ deviceType: string;
26
+ backedUp: boolean;
27
+ transports: string[];
28
+ createdAt: string;
29
+ }
30
+ export type ListPasskeysResponse = {
31
+ passkeys: PasskeySummary[];
32
+ };
33
+ export type DeletePasskeyRequest = {
34
+ credentialId: string;
35
+ };
36
+ export type DeletePasskeyResponse = {
37
+ success: boolean;
38
+ };
@@ -0,0 +1 @@
1
+ export {};
package/dist/index.d.ts CHANGED
@@ -1 +1,5 @@
1
1
  export * from './User';
2
+ export * from './Session';
3
+ export * from './WebAuthn';
4
+ export * from './OAuth';
5
+ export * from './Miscellaneous';
package/dist/index.js CHANGED
@@ -1 +1,5 @@
1
1
  export * from './User';
2
+ export * from './Session';
3
+ export * from './WebAuthn';
4
+ export * from './OAuth';
5
+ export * from './Miscellaneous';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tennantje/identity-types",
3
- "version": "1.0.1",
3
+ "version": "1.0.5",
4
4
  "description": "Shared TypeScript types for identity server project",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -20,6 +20,10 @@
20
20
  ],
21
21
  "author": "Jeremy Tennant",
22
22
  "license": "MIT",
23
+ "repository": {
24
+ "type": "git",
25
+ "url": "https://github.com/tennantje/identityTypes.git"
26
+ },
23
27
  "devDependencies": {
24
28
  "typescript": "^5.7.2"
25
29
  },