@uniformdev/next-app-router 20.72.3-alpha.14 → 20.72.3-alpha.23
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/dist/cache.js +24 -49
- package/dist/cache.mjs +24 -49
- package/dist/component.js +24 -49
- package/dist/component.mjs +24 -49
- package/dist/handler.js +27 -50
- package/dist/handler.mjs +27 -50
- package/dist/index.esm.js +24 -49
- package/dist/index.js +24 -49
- package/dist/index.mjs +24 -49
- package/dist/middleware.js +24 -49
- package/dist/middleware.mjs +24 -49
- package/package.json +8 -8
package/dist/index.mjs
CHANGED
|
@@ -408,6 +408,7 @@ var __accessCheck2 = (obj, member, msg) => member.has(obj) || __typeError2("Cann
|
|
|
408
408
|
var __privateGet2 = (obj, member, getter) => (__accessCheck2(obj, member, "read from private field"), getter ? getter.call(obj) : member.get(obj));
|
|
409
409
|
var __privateAdd2 = (obj, member, value) => member.has(obj) ? __typeError2("Cannot add the same private member more than once") : member instanceof WeakSet ? member.add(obj) : member.set(obj, value);
|
|
410
410
|
var defaultLimitPolicy = (0, import_p_limit.default)(6);
|
|
411
|
+
var UNIFORM_BEARER_TOKEN_NOT_VALID_OR_EXPIRED_MESSAGE = "Bearer token not valid or expired";
|
|
411
412
|
var ApiClientError = class _ApiClientError extends Error {
|
|
412
413
|
constructor(errorMessage, fetchMethod, fetchUri, statusCode, statusText, requestId) {
|
|
413
414
|
super(
|
|
@@ -423,6 +424,12 @@ var ApiClientError = class _ApiClientError extends Error {
|
|
|
423
424
|
Object.setPrototypeOf(this, _ApiClientError.prototype);
|
|
424
425
|
}
|
|
425
426
|
};
|
|
427
|
+
var BearerTokenNotValidOrExpiredError = class _BearerTokenNotValidOrExpiredError extends ApiClientError {
|
|
428
|
+
constructor(errorMessage, fetchMethod, fetchUri, statusCode, statusText, requestId) {
|
|
429
|
+
super(errorMessage, fetchMethod, fetchUri, statusCode, statusText, requestId);
|
|
430
|
+
Object.setPrototypeOf(this, _BearerTokenNotValidOrExpiredError.prototype);
|
|
431
|
+
}
|
|
432
|
+
};
|
|
426
433
|
var ApiClient = class _ApiClient {
|
|
427
434
|
constructor(options) {
|
|
428
435
|
__publicField2(this, "options");
|
|
@@ -456,7 +463,7 @@ var ApiClient = class _ApiClient {
|
|
|
456
463
|
}
|
|
457
464
|
async apiClientWithResponse(fetchUri, options) {
|
|
458
465
|
return this.options.limitPolicy(async () => {
|
|
459
|
-
var _a;
|
|
466
|
+
var _a, _b;
|
|
460
467
|
const coreHeaders = this.options.apiKey ? {
|
|
461
468
|
"x-api-key": this.options.apiKey
|
|
462
469
|
} : {
|
|
@@ -492,9 +499,19 @@ var ApiClient = class _ApiClient {
|
|
|
492
499
|
} catch (e) {
|
|
493
500
|
message = `General error`;
|
|
494
501
|
}
|
|
502
|
+
if (apiResponse.status === 401 && message === UNIFORM_BEARER_TOKEN_NOT_VALID_OR_EXPIRED_MESSAGE) {
|
|
503
|
+
throw new BearerTokenNotValidOrExpiredError(
|
|
504
|
+
message,
|
|
505
|
+
(_a = options == null ? void 0 : options.method) != null ? _a : "GET",
|
|
506
|
+
fetchUri.toString(),
|
|
507
|
+
apiResponse.status,
|
|
508
|
+
apiResponse.statusText,
|
|
509
|
+
_ApiClient.getRequestId(apiResponse)
|
|
510
|
+
);
|
|
511
|
+
}
|
|
495
512
|
throw new ApiClientError(
|
|
496
513
|
message,
|
|
497
|
-
(
|
|
514
|
+
(_b = options == null ? void 0 : options.method) != null ? _b : "GET",
|
|
498
515
|
fetchUri.toString(),
|
|
499
516
|
apiResponse.status,
|
|
500
517
|
apiResponse.statusText,
|
|
@@ -2083,48 +2100,6 @@ var _IntegrationPropertyEditorsClient = class _IntegrationPropertyEditorsClient2
|
|
|
2083
2100
|
_baseUrl = /* @__PURE__ */ new WeakMap();
|
|
2084
2101
|
__privateAdd3(_IntegrationPropertyEditorsClient, _baseUrl, "/api/v1/integration-property-editors");
|
|
2085
2102
|
var _url22;
|
|
2086
|
-
var _NotificationsClient = class _NotificationsClient2 extends ApiClient {
|
|
2087
|
-
constructor(options) {
|
|
2088
|
-
super(options);
|
|
2089
|
-
}
|
|
2090
|
-
/**
|
|
2091
|
-
* Lists notifications for the current user.
|
|
2092
|
-
*
|
|
2093
|
-
* @deprecated This API is experimental and may change without notice.
|
|
2094
|
-
*/
|
|
2095
|
-
async list(options) {
|
|
2096
|
-
const fetchUri = this.createUrl(__privateGet3(_NotificationsClient2, _url22), options);
|
|
2097
|
-
return await this.apiClient(fetchUri);
|
|
2098
|
-
}
|
|
2099
|
-
/**
|
|
2100
|
-
* Creates a notification for one or more recipients.
|
|
2101
|
-
*
|
|
2102
|
-
* @deprecated This API is experimental and may change without notice.
|
|
2103
|
-
*/
|
|
2104
|
-
async create(body) {
|
|
2105
|
-
const fetchUri = this.createUrl(__privateGet3(_NotificationsClient2, _url22));
|
|
2106
|
-
return await this.apiClient(fetchUri, {
|
|
2107
|
-
method: "POST",
|
|
2108
|
-
body: JSON.stringify(body)
|
|
2109
|
-
});
|
|
2110
|
-
}
|
|
2111
|
-
/**
|
|
2112
|
-
* Updates the read state of the current user's notifications.
|
|
2113
|
-
*
|
|
2114
|
-
* @deprecated This API is experimental and may change without notice.
|
|
2115
|
-
*/
|
|
2116
|
-
async setReadState(body) {
|
|
2117
|
-
const fetchUri = this.createUrl(__privateGet3(_NotificationsClient2, _url22));
|
|
2118
|
-
await this.apiClient(fetchUri, {
|
|
2119
|
-
method: "PATCH",
|
|
2120
|
-
body: JSON.stringify(body),
|
|
2121
|
-
expectNoContent: true
|
|
2122
|
-
});
|
|
2123
|
-
}
|
|
2124
|
-
};
|
|
2125
|
-
_url22 = /* @__PURE__ */ new WeakMap();
|
|
2126
|
-
__privateAdd3(_NotificationsClient, _url22, "/api/v1/notifications");
|
|
2127
|
-
var _url32;
|
|
2128
2103
|
var _projectsUrl;
|
|
2129
2104
|
var _ProjectClient = class _ProjectClient2 extends ApiClient {
|
|
2130
2105
|
constructor(options) {
|
|
@@ -2132,7 +2107,7 @@ var _ProjectClient = class _ProjectClient2 extends ApiClient {
|
|
|
2132
2107
|
}
|
|
2133
2108
|
/** Fetches single Project */
|
|
2134
2109
|
async get(options) {
|
|
2135
|
-
const fetchUri = this.createUrl(__privateGet3(_ProjectClient2,
|
|
2110
|
+
const fetchUri = this.createUrl(__privateGet3(_ProjectClient2, _url22), { ...options });
|
|
2136
2111
|
return await this.apiClient(fetchUri);
|
|
2137
2112
|
}
|
|
2138
2113
|
/**
|
|
@@ -2150,7 +2125,7 @@ var _ProjectClient = class _ProjectClient2 extends ApiClient {
|
|
|
2150
2125
|
}
|
|
2151
2126
|
/** Updates or creates (based on id) a Project */
|
|
2152
2127
|
async save(body) {
|
|
2153
|
-
const fetchUri = this.createUrl(__privateGet3(_ProjectClient2,
|
|
2128
|
+
const fetchUri = this.createUrl(__privateGet3(_ProjectClient2, _url22));
|
|
2154
2129
|
return await this.apiClient(fetchUri, {
|
|
2155
2130
|
method: "PUT",
|
|
2156
2131
|
body: JSON.stringify({ ...body })
|
|
@@ -2162,7 +2137,7 @@ var _ProjectClient = class _ProjectClient2 extends ApiClient {
|
|
|
2162
2137
|
}
|
|
2163
2138
|
/** Deletes a Project */
|
|
2164
2139
|
async remove(body) {
|
|
2165
|
-
const fetchUri = this.createUrl(__privateGet3(_ProjectClient2,
|
|
2140
|
+
const fetchUri = this.createUrl(__privateGet3(_ProjectClient2, _url22));
|
|
2166
2141
|
await this.apiClient(fetchUri, {
|
|
2167
2142
|
method: "DELETE",
|
|
2168
2143
|
body: JSON.stringify({ ...body }),
|
|
@@ -2174,9 +2149,9 @@ var _ProjectClient = class _ProjectClient2 extends ApiClient {
|
|
|
2174
2149
|
return this.remove(body);
|
|
2175
2150
|
}
|
|
2176
2151
|
};
|
|
2177
|
-
|
|
2152
|
+
_url22 = /* @__PURE__ */ new WeakMap();
|
|
2178
2153
|
_projectsUrl = /* @__PURE__ */ new WeakMap();
|
|
2179
|
-
__privateAdd3(_ProjectClient,
|
|
2154
|
+
__privateAdd3(_ProjectClient, _url22, "/api/v1/project");
|
|
2180
2155
|
__privateAdd3(_ProjectClient, _projectsUrl, "/api/v1/projects");
|
|
2181
2156
|
var ROUTE_URL = "/api/v1/route";
|
|
2182
2157
|
var RouteClient = class extends ApiClient {
|
package/dist/middleware.js
CHANGED
|
@@ -606,6 +606,7 @@ var __accessCheck2 = (obj, member, msg) => member.has(obj) || __typeError2("Cann
|
|
|
606
606
|
var __privateGet2 = (obj, member, getter) => (__accessCheck2(obj, member, "read from private field"), getter ? getter.call(obj) : member.get(obj));
|
|
607
607
|
var __privateAdd2 = (obj, member, value) => member.has(obj) ? __typeError2("Cannot add the same private member more than once") : member instanceof WeakSet ? member.add(obj) : member.set(obj, value);
|
|
608
608
|
var defaultLimitPolicy = (0, import_p_limit.default)(6);
|
|
609
|
+
var UNIFORM_BEARER_TOKEN_NOT_VALID_OR_EXPIRED_MESSAGE = "Bearer token not valid or expired";
|
|
609
610
|
var ApiClientError = class _ApiClientError extends Error {
|
|
610
611
|
constructor(errorMessage, fetchMethod, fetchUri, statusCode, statusText, requestId) {
|
|
611
612
|
super(
|
|
@@ -621,6 +622,12 @@ var ApiClientError = class _ApiClientError extends Error {
|
|
|
621
622
|
Object.setPrototypeOf(this, _ApiClientError.prototype);
|
|
622
623
|
}
|
|
623
624
|
};
|
|
625
|
+
var BearerTokenNotValidOrExpiredError = class _BearerTokenNotValidOrExpiredError extends ApiClientError {
|
|
626
|
+
constructor(errorMessage, fetchMethod, fetchUri, statusCode, statusText, requestId) {
|
|
627
|
+
super(errorMessage, fetchMethod, fetchUri, statusCode, statusText, requestId);
|
|
628
|
+
Object.setPrototypeOf(this, _BearerTokenNotValidOrExpiredError.prototype);
|
|
629
|
+
}
|
|
630
|
+
};
|
|
624
631
|
var ApiClient = class _ApiClient {
|
|
625
632
|
constructor(options) {
|
|
626
633
|
__publicField2(this, "options");
|
|
@@ -654,7 +661,7 @@ var ApiClient = class _ApiClient {
|
|
|
654
661
|
}
|
|
655
662
|
async apiClientWithResponse(fetchUri, options) {
|
|
656
663
|
return this.options.limitPolicy(async () => {
|
|
657
|
-
var _a;
|
|
664
|
+
var _a, _b;
|
|
658
665
|
const coreHeaders = this.options.apiKey ? {
|
|
659
666
|
"x-api-key": this.options.apiKey
|
|
660
667
|
} : {
|
|
@@ -690,9 +697,19 @@ var ApiClient = class _ApiClient {
|
|
|
690
697
|
} catch (e) {
|
|
691
698
|
message = `General error`;
|
|
692
699
|
}
|
|
700
|
+
if (apiResponse.status === 401 && message === UNIFORM_BEARER_TOKEN_NOT_VALID_OR_EXPIRED_MESSAGE) {
|
|
701
|
+
throw new BearerTokenNotValidOrExpiredError(
|
|
702
|
+
message,
|
|
703
|
+
(_a = options == null ? void 0 : options.method) != null ? _a : "GET",
|
|
704
|
+
fetchUri.toString(),
|
|
705
|
+
apiResponse.status,
|
|
706
|
+
apiResponse.statusText,
|
|
707
|
+
_ApiClient.getRequestId(apiResponse)
|
|
708
|
+
);
|
|
709
|
+
}
|
|
693
710
|
throw new ApiClientError(
|
|
694
711
|
message,
|
|
695
|
-
(
|
|
712
|
+
(_b = options == null ? void 0 : options.method) != null ? _b : "GET",
|
|
696
713
|
fetchUri.toString(),
|
|
697
714
|
apiResponse.status,
|
|
698
715
|
apiResponse.statusText,
|
|
@@ -2298,48 +2315,6 @@ var _IntegrationPropertyEditorsClient = class _IntegrationPropertyEditorsClient2
|
|
|
2298
2315
|
_baseUrl = /* @__PURE__ */ new WeakMap();
|
|
2299
2316
|
__privateAdd3(_IntegrationPropertyEditorsClient, _baseUrl, "/api/v1/integration-property-editors");
|
|
2300
2317
|
var _url22;
|
|
2301
|
-
var _NotificationsClient = class _NotificationsClient2 extends ApiClient {
|
|
2302
|
-
constructor(options) {
|
|
2303
|
-
super(options);
|
|
2304
|
-
}
|
|
2305
|
-
/**
|
|
2306
|
-
* Lists notifications for the current user.
|
|
2307
|
-
*
|
|
2308
|
-
* @deprecated This API is experimental and may change without notice.
|
|
2309
|
-
*/
|
|
2310
|
-
async list(options) {
|
|
2311
|
-
const fetchUri = this.createUrl(__privateGet3(_NotificationsClient2, _url22), options);
|
|
2312
|
-
return await this.apiClient(fetchUri);
|
|
2313
|
-
}
|
|
2314
|
-
/**
|
|
2315
|
-
* Creates a notification for one or more recipients.
|
|
2316
|
-
*
|
|
2317
|
-
* @deprecated This API is experimental and may change without notice.
|
|
2318
|
-
*/
|
|
2319
|
-
async create(body) {
|
|
2320
|
-
const fetchUri = this.createUrl(__privateGet3(_NotificationsClient2, _url22));
|
|
2321
|
-
return await this.apiClient(fetchUri, {
|
|
2322
|
-
method: "POST",
|
|
2323
|
-
body: JSON.stringify(body)
|
|
2324
|
-
});
|
|
2325
|
-
}
|
|
2326
|
-
/**
|
|
2327
|
-
* Updates the read state of the current user's notifications.
|
|
2328
|
-
*
|
|
2329
|
-
* @deprecated This API is experimental and may change without notice.
|
|
2330
|
-
*/
|
|
2331
|
-
async setReadState(body) {
|
|
2332
|
-
const fetchUri = this.createUrl(__privateGet3(_NotificationsClient2, _url22));
|
|
2333
|
-
await this.apiClient(fetchUri, {
|
|
2334
|
-
method: "PATCH",
|
|
2335
|
-
body: JSON.stringify(body),
|
|
2336
|
-
expectNoContent: true
|
|
2337
|
-
});
|
|
2338
|
-
}
|
|
2339
|
-
};
|
|
2340
|
-
_url22 = /* @__PURE__ */ new WeakMap();
|
|
2341
|
-
__privateAdd3(_NotificationsClient, _url22, "/api/v1/notifications");
|
|
2342
|
-
var _url32;
|
|
2343
2318
|
var _projectsUrl;
|
|
2344
2319
|
var _ProjectClient = class _ProjectClient2 extends ApiClient {
|
|
2345
2320
|
constructor(options) {
|
|
@@ -2347,7 +2322,7 @@ var _ProjectClient = class _ProjectClient2 extends ApiClient {
|
|
|
2347
2322
|
}
|
|
2348
2323
|
/** Fetches single Project */
|
|
2349
2324
|
async get(options) {
|
|
2350
|
-
const fetchUri = this.createUrl(__privateGet3(_ProjectClient2,
|
|
2325
|
+
const fetchUri = this.createUrl(__privateGet3(_ProjectClient2, _url22), { ...options });
|
|
2351
2326
|
return await this.apiClient(fetchUri);
|
|
2352
2327
|
}
|
|
2353
2328
|
/**
|
|
@@ -2365,7 +2340,7 @@ var _ProjectClient = class _ProjectClient2 extends ApiClient {
|
|
|
2365
2340
|
}
|
|
2366
2341
|
/** Updates or creates (based on id) a Project */
|
|
2367
2342
|
async save(body) {
|
|
2368
|
-
const fetchUri = this.createUrl(__privateGet3(_ProjectClient2,
|
|
2343
|
+
const fetchUri = this.createUrl(__privateGet3(_ProjectClient2, _url22));
|
|
2369
2344
|
return await this.apiClient(fetchUri, {
|
|
2370
2345
|
method: "PUT",
|
|
2371
2346
|
body: JSON.stringify({ ...body })
|
|
@@ -2377,7 +2352,7 @@ var _ProjectClient = class _ProjectClient2 extends ApiClient {
|
|
|
2377
2352
|
}
|
|
2378
2353
|
/** Deletes a Project */
|
|
2379
2354
|
async remove(body) {
|
|
2380
|
-
const fetchUri = this.createUrl(__privateGet3(_ProjectClient2,
|
|
2355
|
+
const fetchUri = this.createUrl(__privateGet3(_ProjectClient2, _url22));
|
|
2381
2356
|
await this.apiClient(fetchUri, {
|
|
2382
2357
|
method: "DELETE",
|
|
2383
2358
|
body: JSON.stringify({ ...body }),
|
|
@@ -2389,9 +2364,9 @@ var _ProjectClient = class _ProjectClient2 extends ApiClient {
|
|
|
2389
2364
|
return this.remove(body);
|
|
2390
2365
|
}
|
|
2391
2366
|
};
|
|
2392
|
-
|
|
2367
|
+
_url22 = /* @__PURE__ */ new WeakMap();
|
|
2393
2368
|
_projectsUrl = /* @__PURE__ */ new WeakMap();
|
|
2394
|
-
__privateAdd3(_ProjectClient,
|
|
2369
|
+
__privateAdd3(_ProjectClient, _url22, "/api/v1/project");
|
|
2395
2370
|
__privateAdd3(_ProjectClient, _projectsUrl, "/api/v1/projects");
|
|
2396
2371
|
var ROUTE_URL = "/api/v1/route";
|
|
2397
2372
|
var RouteClient = class extends ApiClient {
|
package/dist/middleware.mjs
CHANGED
|
@@ -591,6 +591,7 @@ var __accessCheck2 = (obj, member, msg) => member.has(obj) || __typeError2("Cann
|
|
|
591
591
|
var __privateGet2 = (obj, member, getter) => (__accessCheck2(obj, member, "read from private field"), getter ? getter.call(obj) : member.get(obj));
|
|
592
592
|
var __privateAdd2 = (obj, member, value) => member.has(obj) ? __typeError2("Cannot add the same private member more than once") : member instanceof WeakSet ? member.add(obj) : member.set(obj, value);
|
|
593
593
|
var defaultLimitPolicy = (0, import_p_limit.default)(6);
|
|
594
|
+
var UNIFORM_BEARER_TOKEN_NOT_VALID_OR_EXPIRED_MESSAGE = "Bearer token not valid or expired";
|
|
594
595
|
var ApiClientError = class _ApiClientError extends Error {
|
|
595
596
|
constructor(errorMessage, fetchMethod, fetchUri, statusCode, statusText, requestId) {
|
|
596
597
|
super(
|
|
@@ -606,6 +607,12 @@ var ApiClientError = class _ApiClientError extends Error {
|
|
|
606
607
|
Object.setPrototypeOf(this, _ApiClientError.prototype);
|
|
607
608
|
}
|
|
608
609
|
};
|
|
610
|
+
var BearerTokenNotValidOrExpiredError = class _BearerTokenNotValidOrExpiredError extends ApiClientError {
|
|
611
|
+
constructor(errorMessage, fetchMethod, fetchUri, statusCode, statusText, requestId) {
|
|
612
|
+
super(errorMessage, fetchMethod, fetchUri, statusCode, statusText, requestId);
|
|
613
|
+
Object.setPrototypeOf(this, _BearerTokenNotValidOrExpiredError.prototype);
|
|
614
|
+
}
|
|
615
|
+
};
|
|
609
616
|
var ApiClient = class _ApiClient {
|
|
610
617
|
constructor(options) {
|
|
611
618
|
__publicField2(this, "options");
|
|
@@ -639,7 +646,7 @@ var ApiClient = class _ApiClient {
|
|
|
639
646
|
}
|
|
640
647
|
async apiClientWithResponse(fetchUri, options) {
|
|
641
648
|
return this.options.limitPolicy(async () => {
|
|
642
|
-
var _a;
|
|
649
|
+
var _a, _b;
|
|
643
650
|
const coreHeaders = this.options.apiKey ? {
|
|
644
651
|
"x-api-key": this.options.apiKey
|
|
645
652
|
} : {
|
|
@@ -675,9 +682,19 @@ var ApiClient = class _ApiClient {
|
|
|
675
682
|
} catch (e) {
|
|
676
683
|
message = `General error`;
|
|
677
684
|
}
|
|
685
|
+
if (apiResponse.status === 401 && message === UNIFORM_BEARER_TOKEN_NOT_VALID_OR_EXPIRED_MESSAGE) {
|
|
686
|
+
throw new BearerTokenNotValidOrExpiredError(
|
|
687
|
+
message,
|
|
688
|
+
(_a = options == null ? void 0 : options.method) != null ? _a : "GET",
|
|
689
|
+
fetchUri.toString(),
|
|
690
|
+
apiResponse.status,
|
|
691
|
+
apiResponse.statusText,
|
|
692
|
+
_ApiClient.getRequestId(apiResponse)
|
|
693
|
+
);
|
|
694
|
+
}
|
|
678
695
|
throw new ApiClientError(
|
|
679
696
|
message,
|
|
680
|
-
(
|
|
697
|
+
(_b = options == null ? void 0 : options.method) != null ? _b : "GET",
|
|
681
698
|
fetchUri.toString(),
|
|
682
699
|
apiResponse.status,
|
|
683
700
|
apiResponse.statusText,
|
|
@@ -2283,48 +2300,6 @@ var _IntegrationPropertyEditorsClient = class _IntegrationPropertyEditorsClient2
|
|
|
2283
2300
|
_baseUrl = /* @__PURE__ */ new WeakMap();
|
|
2284
2301
|
__privateAdd3(_IntegrationPropertyEditorsClient, _baseUrl, "/api/v1/integration-property-editors");
|
|
2285
2302
|
var _url22;
|
|
2286
|
-
var _NotificationsClient = class _NotificationsClient2 extends ApiClient {
|
|
2287
|
-
constructor(options) {
|
|
2288
|
-
super(options);
|
|
2289
|
-
}
|
|
2290
|
-
/**
|
|
2291
|
-
* Lists notifications for the current user.
|
|
2292
|
-
*
|
|
2293
|
-
* @deprecated This API is experimental and may change without notice.
|
|
2294
|
-
*/
|
|
2295
|
-
async list(options) {
|
|
2296
|
-
const fetchUri = this.createUrl(__privateGet3(_NotificationsClient2, _url22), options);
|
|
2297
|
-
return await this.apiClient(fetchUri);
|
|
2298
|
-
}
|
|
2299
|
-
/**
|
|
2300
|
-
* Creates a notification for one or more recipients.
|
|
2301
|
-
*
|
|
2302
|
-
* @deprecated This API is experimental and may change without notice.
|
|
2303
|
-
*/
|
|
2304
|
-
async create(body) {
|
|
2305
|
-
const fetchUri = this.createUrl(__privateGet3(_NotificationsClient2, _url22));
|
|
2306
|
-
return await this.apiClient(fetchUri, {
|
|
2307
|
-
method: "POST",
|
|
2308
|
-
body: JSON.stringify(body)
|
|
2309
|
-
});
|
|
2310
|
-
}
|
|
2311
|
-
/**
|
|
2312
|
-
* Updates the read state of the current user's notifications.
|
|
2313
|
-
*
|
|
2314
|
-
* @deprecated This API is experimental and may change without notice.
|
|
2315
|
-
*/
|
|
2316
|
-
async setReadState(body) {
|
|
2317
|
-
const fetchUri = this.createUrl(__privateGet3(_NotificationsClient2, _url22));
|
|
2318
|
-
await this.apiClient(fetchUri, {
|
|
2319
|
-
method: "PATCH",
|
|
2320
|
-
body: JSON.stringify(body),
|
|
2321
|
-
expectNoContent: true
|
|
2322
|
-
});
|
|
2323
|
-
}
|
|
2324
|
-
};
|
|
2325
|
-
_url22 = /* @__PURE__ */ new WeakMap();
|
|
2326
|
-
__privateAdd3(_NotificationsClient, _url22, "/api/v1/notifications");
|
|
2327
|
-
var _url32;
|
|
2328
2303
|
var _projectsUrl;
|
|
2329
2304
|
var _ProjectClient = class _ProjectClient2 extends ApiClient {
|
|
2330
2305
|
constructor(options) {
|
|
@@ -2332,7 +2307,7 @@ var _ProjectClient = class _ProjectClient2 extends ApiClient {
|
|
|
2332
2307
|
}
|
|
2333
2308
|
/** Fetches single Project */
|
|
2334
2309
|
async get(options) {
|
|
2335
|
-
const fetchUri = this.createUrl(__privateGet3(_ProjectClient2,
|
|
2310
|
+
const fetchUri = this.createUrl(__privateGet3(_ProjectClient2, _url22), { ...options });
|
|
2336
2311
|
return await this.apiClient(fetchUri);
|
|
2337
2312
|
}
|
|
2338
2313
|
/**
|
|
@@ -2350,7 +2325,7 @@ var _ProjectClient = class _ProjectClient2 extends ApiClient {
|
|
|
2350
2325
|
}
|
|
2351
2326
|
/** Updates or creates (based on id) a Project */
|
|
2352
2327
|
async save(body) {
|
|
2353
|
-
const fetchUri = this.createUrl(__privateGet3(_ProjectClient2,
|
|
2328
|
+
const fetchUri = this.createUrl(__privateGet3(_ProjectClient2, _url22));
|
|
2354
2329
|
return await this.apiClient(fetchUri, {
|
|
2355
2330
|
method: "PUT",
|
|
2356
2331
|
body: JSON.stringify({ ...body })
|
|
@@ -2362,7 +2337,7 @@ var _ProjectClient = class _ProjectClient2 extends ApiClient {
|
|
|
2362
2337
|
}
|
|
2363
2338
|
/** Deletes a Project */
|
|
2364
2339
|
async remove(body) {
|
|
2365
|
-
const fetchUri = this.createUrl(__privateGet3(_ProjectClient2,
|
|
2340
|
+
const fetchUri = this.createUrl(__privateGet3(_ProjectClient2, _url22));
|
|
2366
2341
|
await this.apiClient(fetchUri, {
|
|
2367
2342
|
method: "DELETE",
|
|
2368
2343
|
body: JSON.stringify({ ...body }),
|
|
@@ -2374,9 +2349,9 @@ var _ProjectClient = class _ProjectClient2 extends ApiClient {
|
|
|
2374
2349
|
return this.remove(body);
|
|
2375
2350
|
}
|
|
2376
2351
|
};
|
|
2377
|
-
|
|
2352
|
+
_url22 = /* @__PURE__ */ new WeakMap();
|
|
2378
2353
|
_projectsUrl = /* @__PURE__ */ new WeakMap();
|
|
2379
|
-
__privateAdd3(_ProjectClient,
|
|
2354
|
+
__privateAdd3(_ProjectClient, _url22, "/api/v1/project");
|
|
2380
2355
|
__privateAdd3(_ProjectClient, _projectsUrl, "/api/v1/projects");
|
|
2381
2356
|
var ROUTE_URL = "/api/v1/route";
|
|
2382
2357
|
var RouteClient = class extends ApiClient {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@uniformdev/next-app-router",
|
|
3
|
-
"version": "20.72.3-alpha.
|
|
3
|
+
"version": "20.72.3-alpha.23+cbe06f1e8a",
|
|
4
4
|
"license": "SEE LICENSE IN LICENSE.txt",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"build": "tsup",
|
|
@@ -98,12 +98,12 @@
|
|
|
98
98
|
"vitest": "4.1.9"
|
|
99
99
|
},
|
|
100
100
|
"dependencies": {
|
|
101
|
-
"@uniformdev/canvas-react": "20.72.3-alpha.
|
|
102
|
-
"@uniformdev/next-app-router-client": "20.72.3-alpha.
|
|
103
|
-
"@uniformdev/next-app-router-shared": "20.72.3-alpha.
|
|
104
|
-
"@uniformdev/redirect": "20.72.3-alpha.
|
|
105
|
-
"@uniformdev/richtext": "20.72.3-alpha.
|
|
106
|
-
"@uniformdev/webhooks": "20.72.3-alpha.
|
|
101
|
+
"@uniformdev/canvas-react": "20.72.3-alpha.23+cbe06f1e8a",
|
|
102
|
+
"@uniformdev/next-app-router-client": "20.72.3-alpha.23+cbe06f1e8a",
|
|
103
|
+
"@uniformdev/next-app-router-shared": "20.72.3-alpha.23+cbe06f1e8a",
|
|
104
|
+
"@uniformdev/redirect": "20.72.3-alpha.23+cbe06f1e8a",
|
|
105
|
+
"@uniformdev/richtext": "20.72.3-alpha.23+cbe06f1e8a",
|
|
106
|
+
"@uniformdev/webhooks": "20.72.3-alpha.23+cbe06f1e8a",
|
|
107
107
|
"@vercel/functions": "^3.7.2",
|
|
108
108
|
"encoding": "^0.1.13",
|
|
109
109
|
"server-only": "^0.0.1",
|
|
@@ -120,5 +120,5 @@
|
|
|
120
120
|
"publishConfig": {
|
|
121
121
|
"access": "public"
|
|
122
122
|
},
|
|
123
|
-
"gitHead": "
|
|
123
|
+
"gitHead": "cbe06f1e8a5bb93b0e3cae6b1c8774f21c10506e"
|
|
124
124
|
}
|