@bymax-one/nest-auth 1.5.2 → 1.5.4

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.
@@ -100,7 +100,12 @@ var AUTH_ERROR_CODES = {
100
100
  * An unexpected internal failure. Raised only by the server's optional `AuthExceptionFilter`,
101
101
  * which gives unhandled failures the same envelope everything else answers with.
102
102
  */
103
- INTERNAL: "auth.internal"
103
+ INTERNAL: "auth.internal",
104
+ /**
105
+ * A store the request depends on, Redis, did not answer in time or could not be reached, so
106
+ * the request was refused and nothing was admitted. A client may retry later.
107
+ */
108
+ SERVICE_UNAVAILABLE: "auth.service_unavailable"
104
109
  };
105
110
  var AUTH_ERROR_STATUS = {
106
111
  "auth.invalid_credentials": 401,
@@ -152,7 +157,8 @@ var AUTH_ERROR_STATUS = {
152
157
  "auth.registration_closed": 403,
153
158
  "auth.workspace_limit_reached": 403,
154
159
  "auth.workspace_pending_deletion": 409,
155
- "auth.internal": 500
160
+ "auth.internal": 500,
161
+ "auth.service_unavailable": 503
156
162
  };
157
163
 
158
164
  // src/shared/utils/fill-route.ts
@@ -150,6 +150,11 @@ declare const AUTH_ERROR_CODES: {
150
150
  * which gives unhandled failures the same envelope everything else answers with.
151
151
  */
152
152
  readonly INTERNAL: "auth.internal";
153
+ /**
154
+ * A store the request depends on, Redis, did not answer in time or could not be reached, so
155
+ * the request was refused and nothing was admitted. A client may retry later.
156
+ */
157
+ readonly SERVICE_UNAVAILABLE: "auth.service_unavailable";
153
158
  };
154
159
  /**
155
160
  * String literal union of every `AUTH_ERROR_CODES` value.
@@ -150,6 +150,11 @@ declare const AUTH_ERROR_CODES: {
150
150
  * which gives unhandled failures the same envelope everything else answers with.
151
151
  */
152
152
  readonly INTERNAL: "auth.internal";
153
+ /**
154
+ * A store the request depends on, Redis, did not answer in time or could not be reached, so
155
+ * the request was refused and nothing was admitted. A client may retry later.
156
+ */
157
+ readonly SERVICE_UNAVAILABLE: "auth.service_unavailable";
153
158
  };
154
159
  /**
155
160
  * String literal union of every `AUTH_ERROR_CODES` value.
@@ -98,7 +98,12 @@ var AUTH_ERROR_CODES = {
98
98
  * An unexpected internal failure. Raised only by the server's optional `AuthExceptionFilter`,
99
99
  * which gives unhandled failures the same envelope everything else answers with.
100
100
  */
101
- INTERNAL: "auth.internal"
101
+ INTERNAL: "auth.internal",
102
+ /**
103
+ * A store the request depends on, Redis, did not answer in time or could not be reached, so
104
+ * the request was refused and nothing was admitted. A client may retry later.
105
+ */
106
+ SERVICE_UNAVAILABLE: "auth.service_unavailable"
102
107
  };
103
108
  var AUTH_ERROR_STATUS = {
104
109
  "auth.invalid_credentials": 401,
@@ -150,7 +155,8 @@ var AUTH_ERROR_STATUS = {
150
155
  "auth.registration_closed": 403,
151
156
  "auth.workspace_limit_reached": 403,
152
157
  "auth.workspace_pending_deletion": 409,
153
- "auth.internal": 500
158
+ "auth.internal": 500,
159
+ "auth.service_unavailable": 503
154
160
  };
155
161
 
156
162
  // src/shared/utils/fill-route.ts
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bymax-one/nest-auth",
3
- "version": "1.5.2",
3
+ "version": "1.5.4",
4
4
  "description": "Full-stack authentication and authorization package for NestJS, React and Next.js — JWT, MFA, OAuth, sessions, multi-tenant SaaS ready",
5
5
  "author": "Bymax One <support@bymax.one>",
6
6
  "license": "MIT",
@@ -228,7 +228,7 @@
228
228
  "reflect-metadata": "^0.2.2",
229
229
  "socket.io": "^4.8.3",
230
230
  "socket.io-client": "^4.8.3",
231
- "supertest": "^7.2.2",
231
+ "supertest": "^7.3.1",
232
232
  "testcontainers": "^12.2.1",
233
233
  "ts-jest": "^29.4.9",
234
234
  "ts-node": "^10.9.2",