@unkey/api 2.0.4 → 2.0.6
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/README.md +4 -7
- package/RUNTIMES.md +6 -6
- package/bin/mcp-server.js +160 -68
- package/bin/mcp-server.js.map +53 -50
- package/dist/commonjs/funcs/apisCreateApi.js +1 -1
- package/dist/commonjs/funcs/apisCreateApi.js.map +1 -1
- package/dist/commonjs/funcs/apisDeleteApi.js +1 -1
- package/dist/commonjs/funcs/apisDeleteApi.js.map +1 -1
- package/dist/commonjs/funcs/apisGetApi.js +1 -1
- package/dist/commonjs/funcs/apisGetApi.js.map +1 -1
- package/dist/commonjs/funcs/apisListKeys.js +1 -1
- package/dist/commonjs/funcs/apisListKeys.js.map +1 -1
- package/dist/commonjs/funcs/identitiesCreateIdentity.js +1 -1
- package/dist/commonjs/funcs/identitiesCreateIdentity.js.map +1 -1
- package/dist/commonjs/funcs/identitiesDeleteIdentity.js +1 -1
- package/dist/commonjs/funcs/identitiesDeleteIdentity.js.map +1 -1
- package/dist/commonjs/funcs/identitiesGetIdentity.js +1 -1
- package/dist/commonjs/funcs/identitiesGetIdentity.js.map +1 -1
- package/dist/commonjs/funcs/identitiesListIdentities.js +4 -1
- package/dist/commonjs/funcs/identitiesListIdentities.js.map +1 -1
- package/dist/commonjs/funcs/identitiesUpdateIdentity.js +1 -1
- package/dist/commonjs/funcs/identitiesUpdateIdentity.js.map +1 -1
- package/dist/commonjs/funcs/keysAddPermissions.js +1 -1
- package/dist/commonjs/funcs/keysAddPermissions.js.map +1 -1
- package/dist/commonjs/funcs/keysAddRoles.js +1 -1
- package/dist/commonjs/funcs/keysAddRoles.js.map +1 -1
- package/dist/commonjs/funcs/keysCreateKey.js +1 -1
- package/dist/commonjs/funcs/keysCreateKey.js.map +1 -1
- package/dist/commonjs/funcs/keysDeleteKey.js +1 -1
- package/dist/commonjs/funcs/keysDeleteKey.js.map +1 -1
- package/dist/commonjs/funcs/keysGetKey.js +1 -1
- package/dist/commonjs/funcs/keysGetKey.js.map +1 -1
- package/dist/commonjs/funcs/keysRemovePermissions.js +1 -1
- package/dist/commonjs/funcs/keysRemovePermissions.js.map +1 -1
- package/dist/commonjs/funcs/keysRemoveRoles.js +1 -1
- package/dist/commonjs/funcs/keysRemoveRoles.js.map +1 -1
- package/dist/commonjs/funcs/keysRerollKey.js +1 -1
- package/dist/commonjs/funcs/keysRerollKey.js.map +1 -1
- package/dist/commonjs/funcs/keysSetPermissions.js +1 -1
- package/dist/commonjs/funcs/keysSetPermissions.js.map +1 -1
- package/dist/commonjs/funcs/keysSetRoles.js +1 -1
- package/dist/commonjs/funcs/keysSetRoles.js.map +1 -1
- package/dist/commonjs/funcs/keysUpdateCredits.js +1 -1
- package/dist/commonjs/funcs/keysUpdateCredits.js.map +1 -1
- package/dist/commonjs/funcs/keysUpdateKey.js +1 -1
- package/dist/commonjs/funcs/keysUpdateKey.js.map +1 -1
- package/dist/commonjs/funcs/keysVerifyKey.js +1 -1
- package/dist/commonjs/funcs/keysVerifyKey.js.map +1 -1
- package/dist/commonjs/funcs/keysWhoami.js +1 -1
- package/dist/commonjs/funcs/keysWhoami.js.map +1 -1
- package/dist/commonjs/funcs/permissionsCreatePermission.js +1 -1
- package/dist/commonjs/funcs/permissionsCreatePermission.js.map +1 -1
- package/dist/commonjs/funcs/permissionsCreateRole.js +1 -1
- package/dist/commonjs/funcs/permissionsCreateRole.js.map +1 -1
- package/dist/commonjs/funcs/permissionsDeletePermission.js +1 -1
- package/dist/commonjs/funcs/permissionsDeletePermission.js.map +1 -1
- package/dist/commonjs/funcs/permissionsDeleteRole.js +1 -1
- package/dist/commonjs/funcs/permissionsDeleteRole.js.map +1 -1
- package/dist/commonjs/funcs/permissionsGetPermission.js +1 -1
- package/dist/commonjs/funcs/permissionsGetPermission.js.map +1 -1
- package/dist/commonjs/funcs/permissionsGetRole.js +1 -1
- package/dist/commonjs/funcs/permissionsGetRole.js.map +1 -1
- package/dist/commonjs/funcs/permissionsListPermissions.js +1 -1
- package/dist/commonjs/funcs/permissionsListPermissions.js.map +1 -1
- package/dist/commonjs/funcs/permissionsListRoles.js +1 -1
- package/dist/commonjs/funcs/permissionsListRoles.js.map +1 -1
- package/dist/commonjs/funcs/ratelimitDeleteOverride.js +1 -1
- package/dist/commonjs/funcs/ratelimitDeleteOverride.js.map +1 -1
- package/dist/commonjs/funcs/ratelimitGetOverride.js +1 -1
- package/dist/commonjs/funcs/ratelimitGetOverride.js.map +1 -1
- package/dist/commonjs/funcs/ratelimitLimit.d.ts +2 -2
- package/dist/commonjs/funcs/ratelimitLimit.d.ts.map +1 -1
- package/dist/commonjs/funcs/ratelimitLimit.js +4 -4
- package/dist/commonjs/funcs/ratelimitLimit.js.map +1 -1
- package/dist/commonjs/funcs/ratelimitListOverrides.js +1 -1
- package/dist/commonjs/funcs/ratelimitListOverrides.js.map +1 -1
- package/dist/commonjs/funcs/ratelimitSetOverride.js +1 -1
- package/dist/commonjs/funcs/ratelimitSetOverride.js.map +1 -1
- package/dist/commonjs/lib/config.d.ts +3 -3
- package/dist/commonjs/lib/config.js +3 -3
- package/dist/commonjs/lib/config.js.map +1 -1
- package/dist/commonjs/lib/security.d.ts.map +1 -1
- package/dist/commonjs/lib/security.js.map +1 -1
- package/dist/commonjs/lib/url.js +1 -1
- package/dist/commonjs/lib/url.js.map +1 -1
- package/dist/commonjs/mcp-server/mcp-server.js +1 -1
- package/dist/commonjs/mcp-server/server.js +1 -1
- package/dist/commonjs/mcp-server/tools/ratelimitLimit.js +1 -1
- package/dist/commonjs/models/components/identity.d.ts +6 -26
- package/dist/commonjs/models/components/identity.d.ts.map +1 -1
- package/dist/commonjs/models/components/identity.js +3 -26
- package/dist/commonjs/models/components/identity.js.map +1 -1
- package/dist/commonjs/models/components/index.d.ts +2 -0
- package/dist/commonjs/models/components/index.d.ts.map +1 -1
- package/dist/commonjs/models/components/index.js +2 -0
- package/dist/commonjs/models/components/index.js.map +1 -1
- package/dist/commonjs/models/components/keycreditsrefill.d.ts +8 -8
- package/dist/commonjs/models/components/keycreditsrefill.d.ts.map +1 -1
- package/dist/commonjs/models/components/keycreditsrefill.js +13 -14
- package/dist/commonjs/models/components/keycreditsrefill.js.map +1 -1
- package/dist/commonjs/models/components/updatekeycreditsdata.d.ts +41 -0
- package/dist/commonjs/models/components/updatekeycreditsdata.d.ts.map +1 -0
- package/dist/commonjs/models/components/updatekeycreditsdata.js +72 -0
- package/dist/commonjs/models/components/updatekeycreditsdata.js.map +1 -0
- package/dist/commonjs/models/components/updatekeycreditsrefill.d.ts +81 -0
- package/dist/commonjs/models/components/updatekeycreditsrefill.d.ts.map +1 -0
- package/dist/commonjs/models/components/updatekeycreditsrefill.js +95 -0
- package/dist/commonjs/models/components/updatekeycreditsrefill.js.map +1 -0
- package/dist/commonjs/models/components/v2keysupdatekeyrequestbody.d.ts +3 -3
- package/dist/commonjs/models/components/v2keysupdatekeyrequestbody.d.ts.map +1 -1
- package/dist/commonjs/models/components/v2keysupdatekeyrequestbody.js +3 -3
- package/dist/commonjs/models/components/v2keysupdatekeyrequestbody.js.map +1 -1
- package/dist/commonjs/models/errors/goneerrorresponse.d.ts +72 -0
- package/dist/commonjs/models/errors/goneerrorresponse.d.ts.map +1 -0
- package/dist/commonjs/models/errors/goneerrorresponse.js +99 -0
- package/dist/commonjs/models/errors/goneerrorresponse.js.map +1 -0
- package/dist/commonjs/models/errors/index.d.ts +2 -0
- package/dist/commonjs/models/errors/index.d.ts.map +1 -1
- package/dist/commonjs/models/errors/index.js +2 -0
- package/dist/commonjs/models/errors/index.js.map +1 -1
- package/dist/commonjs/sdk/ratelimit.d.ts +1 -1
- package/dist/commonjs/sdk/ratelimit.js +1 -1
- package/dist/esm/funcs/apisCreateApi.js +1 -1
- package/dist/esm/funcs/apisCreateApi.js.map +1 -1
- package/dist/esm/funcs/apisDeleteApi.js +1 -1
- package/dist/esm/funcs/apisDeleteApi.js.map +1 -1
- package/dist/esm/funcs/apisGetApi.js +1 -1
- package/dist/esm/funcs/apisGetApi.js.map +1 -1
- package/dist/esm/funcs/apisListKeys.js +1 -1
- package/dist/esm/funcs/apisListKeys.js.map +1 -1
- package/dist/esm/funcs/identitiesCreateIdentity.js +1 -1
- package/dist/esm/funcs/identitiesCreateIdentity.js.map +1 -1
- package/dist/esm/funcs/identitiesDeleteIdentity.js +1 -1
- package/dist/esm/funcs/identitiesDeleteIdentity.js.map +1 -1
- package/dist/esm/funcs/identitiesGetIdentity.js +1 -1
- package/dist/esm/funcs/identitiesGetIdentity.js.map +1 -1
- package/dist/esm/funcs/identitiesListIdentities.js +4 -1
- package/dist/esm/funcs/identitiesListIdentities.js.map +1 -1
- package/dist/esm/funcs/identitiesUpdateIdentity.js +1 -1
- package/dist/esm/funcs/identitiesUpdateIdentity.js.map +1 -1
- package/dist/esm/funcs/keysAddPermissions.js +1 -1
- package/dist/esm/funcs/keysAddPermissions.js.map +1 -1
- package/dist/esm/funcs/keysAddRoles.js +1 -1
- package/dist/esm/funcs/keysAddRoles.js.map +1 -1
- package/dist/esm/funcs/keysCreateKey.js +1 -1
- package/dist/esm/funcs/keysCreateKey.js.map +1 -1
- package/dist/esm/funcs/keysDeleteKey.js +1 -1
- package/dist/esm/funcs/keysDeleteKey.js.map +1 -1
- package/dist/esm/funcs/keysGetKey.js +1 -1
- package/dist/esm/funcs/keysGetKey.js.map +1 -1
- package/dist/esm/funcs/keysRemovePermissions.js +1 -1
- package/dist/esm/funcs/keysRemovePermissions.js.map +1 -1
- package/dist/esm/funcs/keysRemoveRoles.js +1 -1
- package/dist/esm/funcs/keysRemoveRoles.js.map +1 -1
- package/dist/esm/funcs/keysRerollKey.js +1 -1
- package/dist/esm/funcs/keysRerollKey.js.map +1 -1
- package/dist/esm/funcs/keysSetPermissions.js +1 -1
- package/dist/esm/funcs/keysSetPermissions.js.map +1 -1
- package/dist/esm/funcs/keysSetRoles.js +1 -1
- package/dist/esm/funcs/keysSetRoles.js.map +1 -1
- package/dist/esm/funcs/keysUpdateCredits.js +1 -1
- package/dist/esm/funcs/keysUpdateCredits.js.map +1 -1
- package/dist/esm/funcs/keysUpdateKey.js +1 -1
- package/dist/esm/funcs/keysUpdateKey.js.map +1 -1
- package/dist/esm/funcs/keysVerifyKey.js +1 -1
- package/dist/esm/funcs/keysVerifyKey.js.map +1 -1
- package/dist/esm/funcs/keysWhoami.js +1 -1
- package/dist/esm/funcs/keysWhoami.js.map +1 -1
- package/dist/esm/funcs/permissionsCreatePermission.js +1 -1
- package/dist/esm/funcs/permissionsCreatePermission.js.map +1 -1
- package/dist/esm/funcs/permissionsCreateRole.js +1 -1
- package/dist/esm/funcs/permissionsCreateRole.js.map +1 -1
- package/dist/esm/funcs/permissionsDeletePermission.js +1 -1
- package/dist/esm/funcs/permissionsDeletePermission.js.map +1 -1
- package/dist/esm/funcs/permissionsDeleteRole.js +1 -1
- package/dist/esm/funcs/permissionsDeleteRole.js.map +1 -1
- package/dist/esm/funcs/permissionsGetPermission.js +1 -1
- package/dist/esm/funcs/permissionsGetPermission.js.map +1 -1
- package/dist/esm/funcs/permissionsGetRole.js +1 -1
- package/dist/esm/funcs/permissionsGetRole.js.map +1 -1
- package/dist/esm/funcs/permissionsListPermissions.js +1 -1
- package/dist/esm/funcs/permissionsListPermissions.js.map +1 -1
- package/dist/esm/funcs/permissionsListRoles.js +1 -1
- package/dist/esm/funcs/permissionsListRoles.js.map +1 -1
- package/dist/esm/funcs/ratelimitDeleteOverride.js +1 -1
- package/dist/esm/funcs/ratelimitDeleteOverride.js.map +1 -1
- package/dist/esm/funcs/ratelimitGetOverride.js +1 -1
- package/dist/esm/funcs/ratelimitGetOverride.js.map +1 -1
- package/dist/esm/funcs/ratelimitLimit.d.ts +2 -2
- package/dist/esm/funcs/ratelimitLimit.d.ts.map +1 -1
- package/dist/esm/funcs/ratelimitLimit.js +4 -4
- package/dist/esm/funcs/ratelimitLimit.js.map +1 -1
- package/dist/esm/funcs/ratelimitListOverrides.js +1 -1
- package/dist/esm/funcs/ratelimitListOverrides.js.map +1 -1
- package/dist/esm/funcs/ratelimitSetOverride.js +1 -1
- package/dist/esm/funcs/ratelimitSetOverride.js.map +1 -1
- package/dist/esm/lib/config.d.ts +3 -3
- package/dist/esm/lib/config.js +3 -3
- package/dist/esm/lib/config.js.map +1 -1
- package/dist/esm/lib/security.d.ts.map +1 -1
- package/dist/esm/lib/security.js.map +1 -1
- package/dist/esm/lib/url.js +1 -1
- package/dist/esm/lib/url.js.map +1 -1
- package/dist/esm/mcp-server/mcp-server.js +1 -1
- package/dist/esm/mcp-server/server.js +1 -1
- package/dist/esm/mcp-server/tools/ratelimitLimit.js +1 -1
- package/dist/esm/models/components/identity.d.ts +6 -26
- package/dist/esm/models/components/identity.d.ts.map +1 -1
- package/dist/esm/models/components/identity.js +2 -23
- package/dist/esm/models/components/identity.js.map +1 -1
- package/dist/esm/models/components/index.d.ts +2 -0
- package/dist/esm/models/components/index.d.ts.map +1 -1
- package/dist/esm/models/components/index.js +2 -0
- package/dist/esm/models/components/index.js.map +1 -1
- package/dist/esm/models/components/keycreditsrefill.d.ts +8 -8
- package/dist/esm/models/components/keycreditsrefill.d.ts.map +1 -1
- package/dist/esm/models/components/keycreditsrefill.js +12 -13
- package/dist/esm/models/components/keycreditsrefill.js.map +1 -1
- package/dist/esm/models/components/updatekeycreditsdata.d.ts +41 -0
- package/dist/esm/models/components/updatekeycreditsdata.d.ts.map +1 -0
- package/dist/esm/models/components/updatekeycreditsdata.js +34 -0
- package/dist/esm/models/components/updatekeycreditsdata.js.map +1 -0
- package/dist/esm/models/components/updatekeycreditsrefill.d.ts +81 -0
- package/dist/esm/models/components/updatekeycreditsrefill.d.ts.map +1 -0
- package/dist/esm/models/components/updatekeycreditsrefill.js +57 -0
- package/dist/esm/models/components/updatekeycreditsrefill.js.map +1 -0
- package/dist/esm/models/components/v2keysupdatekeyrequestbody.d.ts +3 -3
- package/dist/esm/models/components/v2keysupdatekeyrequestbody.d.ts.map +1 -1
- package/dist/esm/models/components/v2keysupdatekeyrequestbody.js +3 -3
- package/dist/esm/models/components/v2keysupdatekeyrequestbody.js.map +1 -1
- package/dist/esm/models/errors/goneerrorresponse.d.ts +72 -0
- package/dist/esm/models/errors/goneerrorresponse.d.ts.map +1 -0
- package/dist/esm/models/errors/goneerrorresponse.js +62 -0
- package/dist/esm/models/errors/goneerrorresponse.js.map +1 -0
- package/dist/esm/models/errors/index.d.ts +2 -0
- package/dist/esm/models/errors/index.d.ts.map +1 -1
- package/dist/esm/models/errors/index.js +2 -0
- package/dist/esm/models/errors/index.js.map +1 -1
- package/dist/esm/sdk/ratelimit.d.ts +1 -1
- package/dist/esm/sdk/ratelimit.js +1 -1
- package/docs/sdks/ratelimit/README.md +2 -1
- package/examples/apisCreateApi.example.ts +1 -1
- package/examples/package-lock.json +1 -1
- package/jsr.json +1 -1
- package/package.json +1 -1
- package/src/funcs/apisCreateApi.ts +1 -1
- package/src/funcs/apisDeleteApi.ts +1 -1
- package/src/funcs/apisGetApi.ts +1 -1
- package/src/funcs/apisListKeys.ts +1 -1
- package/src/funcs/identitiesCreateIdentity.ts +1 -1
- package/src/funcs/identitiesDeleteIdentity.ts +1 -1
- package/src/funcs/identitiesGetIdentity.ts +1 -1
- package/src/funcs/identitiesListIdentities.ts +4 -1
- package/src/funcs/identitiesUpdateIdentity.ts +1 -1
- package/src/funcs/keysAddPermissions.ts +1 -1
- package/src/funcs/keysAddRoles.ts +1 -1
- package/src/funcs/keysCreateKey.ts +1 -1
- package/src/funcs/keysDeleteKey.ts +1 -1
- package/src/funcs/keysGetKey.ts +1 -1
- package/src/funcs/keysRemovePermissions.ts +1 -1
- package/src/funcs/keysRemoveRoles.ts +1 -1
- package/src/funcs/keysRerollKey.ts +1 -1
- package/src/funcs/keysSetPermissions.ts +1 -1
- package/src/funcs/keysSetRoles.ts +1 -1
- package/src/funcs/keysUpdateCredits.ts +1 -1
- package/src/funcs/keysUpdateKey.ts +1 -1
- package/src/funcs/keysVerifyKey.ts +1 -1
- package/src/funcs/keysWhoami.ts +1 -1
- package/src/funcs/permissionsCreatePermission.ts +1 -1
- package/src/funcs/permissionsCreateRole.ts +1 -1
- package/src/funcs/permissionsDeletePermission.ts +1 -1
- package/src/funcs/permissionsDeleteRole.ts +1 -1
- package/src/funcs/permissionsGetPermission.ts +1 -1
- package/src/funcs/permissionsGetRole.ts +1 -1
- package/src/funcs/permissionsListPermissions.ts +1 -1
- package/src/funcs/permissionsListRoles.ts +1 -1
- package/src/funcs/ratelimitDeleteOverride.ts +1 -1
- package/src/funcs/ratelimitGetOverride.ts +1 -1
- package/src/funcs/ratelimitLimit.ts +7 -3
- package/src/funcs/ratelimitListOverrides.ts +1 -1
- package/src/funcs/ratelimitSetOverride.ts +1 -1
- package/src/lib/config.ts +3 -3
- package/src/lib/security.ts +4 -1
- package/src/lib/url.ts +1 -1
- package/src/mcp-server/mcp-server.ts +1 -1
- package/src/mcp-server/server.ts +1 -1
- package/src/mcp-server/tools/ratelimitLimit.ts +1 -1
- package/src/models/components/identity.ts +4 -53
- package/src/models/components/index.ts +2 -0
- package/src/models/components/keycreditsrefill.ts +18 -14
- package/src/models/components/updatekeycreditsdata.ts +85 -0
- package/src/models/components/updatekeycreditsrefill.ts +126 -0
- package/src/models/components/v2keysupdatekeyrequestbody.ts +10 -10
- package/src/models/errors/goneerrorresponse.ts +118 -0
- package/src/models/errors/index.ts +2 -0
- package/src/sdk/ratelimit.ts +1 -1
- package/docs/sdks/unkey/README.md +0 -82
package/bin/mcp-server.js
CHANGED
|
@@ -34227,7 +34227,7 @@ var init_base64 = __esm(() => {
|
|
|
34227
34227
|
|
|
34228
34228
|
// src/lib/url.ts
|
|
34229
34229
|
function pathToFunc(pathPattern, options) {
|
|
34230
|
-
const paramRE = /\{([a-zA-Z0-9_]
|
|
34230
|
+
const paramRE = /\{([a-zA-Z0-9_][a-zA-Z0-9_-]*?)\}/g;
|
|
34231
34231
|
return function buildURLPath(params = {}) {
|
|
34232
34232
|
return pathPattern.replace(paramRE, function(_2, placeholder) {
|
|
34233
34233
|
if (!hasOwn.call(params, placeholder)) {
|
|
@@ -34269,9 +34269,9 @@ var init_config = __esm(() => {
|
|
|
34269
34269
|
SDK_METADATA = {
|
|
34270
34270
|
language: "typescript",
|
|
34271
34271
|
openapiDocVersion: "2.0.0",
|
|
34272
|
-
sdkVersion: "2.0.
|
|
34273
|
-
genVersion: "2.
|
|
34274
|
-
userAgent: "speakeasy-sdk/typescript 2.0.
|
|
34272
|
+
sdkVersion: "2.0.6",
|
|
34273
|
+
genVersion: "2.723.11",
|
|
34274
|
+
userAgent: "speakeasy-sdk/typescript 2.0.6 2.723.11 2.0.0 @unkey/api"
|
|
34275
34275
|
};
|
|
34276
34276
|
});
|
|
34277
34277
|
|
|
@@ -35808,26 +35808,20 @@ var init_ratelimitresponse = __esm(() => {
|
|
|
35808
35808
|
});
|
|
35809
35809
|
|
|
35810
35810
|
// src/models/components/identity.ts
|
|
35811
|
-
var
|
|
35811
|
+
var Identity$inboundSchema, Identity$outboundSchema, Identity$;
|
|
35812
35812
|
var init_identity = __esm(() => {
|
|
35813
35813
|
init_zod();
|
|
35814
35814
|
init_ratelimitresponse();
|
|
35815
|
-
IdentityMeta$inboundSchema = objectType({});
|
|
35816
|
-
IdentityMeta$outboundSchema = objectType({});
|
|
35817
|
-
((IdentityMeta$) => {
|
|
35818
|
-
IdentityMeta$.inboundSchema = IdentityMeta$inboundSchema;
|
|
35819
|
-
IdentityMeta$.outboundSchema = IdentityMeta$outboundSchema;
|
|
35820
|
-
})(IdentityMeta$ ||= {});
|
|
35821
35815
|
Identity$inboundSchema = objectType({
|
|
35822
35816
|
id: stringType(),
|
|
35823
35817
|
externalId: stringType(),
|
|
35824
|
-
meta:
|
|
35818
|
+
meta: recordType(anyType()).optional(),
|
|
35825
35819
|
ratelimits: arrayType(RatelimitResponse$inboundSchema).optional()
|
|
35826
35820
|
});
|
|
35827
35821
|
Identity$outboundSchema = objectType({
|
|
35828
35822
|
id: stringType(),
|
|
35829
35823
|
externalId: stringType(),
|
|
35830
|
-
meta:
|
|
35824
|
+
meta: recordType(anyType()).optional(),
|
|
35831
35825
|
ratelimits: arrayType(RatelimitResponse$outboundSchema).optional()
|
|
35832
35826
|
});
|
|
35833
35827
|
((Identity$) => {
|
|
@@ -35837,26 +35831,26 @@ var init_identity = __esm(() => {
|
|
|
35837
35831
|
});
|
|
35838
35832
|
|
|
35839
35833
|
// src/models/components/keycreditsrefill.ts
|
|
35840
|
-
var
|
|
35834
|
+
var KeyCreditsRefillInterval, KeyCreditsRefillInterval$inboundSchema, KeyCreditsRefillInterval$outboundSchema, KeyCreditsRefillInterval$, KeyCreditsRefill$inboundSchema, KeyCreditsRefill$outboundSchema, KeyCreditsRefill$;
|
|
35841
35835
|
var init_keycreditsrefill = __esm(() => {
|
|
35842
35836
|
init_zod();
|
|
35843
|
-
|
|
35837
|
+
KeyCreditsRefillInterval = {
|
|
35844
35838
|
Daily: "daily",
|
|
35845
35839
|
Monthly: "monthly"
|
|
35846
35840
|
};
|
|
35847
|
-
|
|
35848
|
-
|
|
35849
|
-
((
|
|
35850
|
-
|
|
35851
|
-
|
|
35852
|
-
})(
|
|
35841
|
+
KeyCreditsRefillInterval$inboundSchema = nativeEnumType(KeyCreditsRefillInterval);
|
|
35842
|
+
KeyCreditsRefillInterval$outboundSchema = KeyCreditsRefillInterval$inboundSchema;
|
|
35843
|
+
((KeyCreditsRefillInterval$) => {
|
|
35844
|
+
KeyCreditsRefillInterval$.inboundSchema = KeyCreditsRefillInterval$inboundSchema;
|
|
35845
|
+
KeyCreditsRefillInterval$.outboundSchema = KeyCreditsRefillInterval$outboundSchema;
|
|
35846
|
+
})(KeyCreditsRefillInterval$ ||= {});
|
|
35853
35847
|
KeyCreditsRefill$inboundSchema = objectType({
|
|
35854
|
-
interval:
|
|
35848
|
+
interval: KeyCreditsRefillInterval$inboundSchema,
|
|
35855
35849
|
amount: numberType().int(),
|
|
35856
35850
|
refillDay: numberType().int().optional()
|
|
35857
35851
|
});
|
|
35858
35852
|
KeyCreditsRefill$outboundSchema = objectType({
|
|
35859
|
-
interval:
|
|
35853
|
+
interval: KeyCreditsRefillInterval$outboundSchema,
|
|
35860
35854
|
amount: numberType().int(),
|
|
35861
35855
|
refillDay: numberType().int().optional()
|
|
35862
35856
|
});
|
|
@@ -36107,6 +36101,55 @@ var init_security2 = __esm(() => {
|
|
|
36107
36101
|
})(Security$ ||= {});
|
|
36108
36102
|
});
|
|
36109
36103
|
|
|
36104
|
+
// src/models/components/updatekeycreditsrefill.ts
|
|
36105
|
+
var UpdateKeyCreditsRefillInterval, UpdateKeyCreditsRefillInterval$inboundSchema, UpdateKeyCreditsRefillInterval$outboundSchema, UpdateKeyCreditsRefillInterval$, UpdateKeyCreditsRefill$inboundSchema, UpdateKeyCreditsRefill$outboundSchema, UpdateKeyCreditsRefill$;
|
|
36106
|
+
var init_updatekeycreditsrefill = __esm(() => {
|
|
36107
|
+
init_zod();
|
|
36108
|
+
UpdateKeyCreditsRefillInterval = {
|
|
36109
|
+
Daily: "daily",
|
|
36110
|
+
Monthly: "monthly"
|
|
36111
|
+
};
|
|
36112
|
+
UpdateKeyCreditsRefillInterval$inboundSchema = nativeEnumType(UpdateKeyCreditsRefillInterval);
|
|
36113
|
+
UpdateKeyCreditsRefillInterval$outboundSchema = UpdateKeyCreditsRefillInterval$inboundSchema;
|
|
36114
|
+
((UpdateKeyCreditsRefillInterval$) => {
|
|
36115
|
+
UpdateKeyCreditsRefillInterval$.inboundSchema = UpdateKeyCreditsRefillInterval$inboundSchema;
|
|
36116
|
+
UpdateKeyCreditsRefillInterval$.outboundSchema = UpdateKeyCreditsRefillInterval$outboundSchema;
|
|
36117
|
+
})(UpdateKeyCreditsRefillInterval$ ||= {});
|
|
36118
|
+
UpdateKeyCreditsRefill$inboundSchema = objectType({
|
|
36119
|
+
interval: UpdateKeyCreditsRefillInterval$inboundSchema,
|
|
36120
|
+
amount: numberType().int(),
|
|
36121
|
+
refillDay: numberType().int().optional()
|
|
36122
|
+
});
|
|
36123
|
+
UpdateKeyCreditsRefill$outboundSchema = objectType({
|
|
36124
|
+
interval: UpdateKeyCreditsRefillInterval$outboundSchema,
|
|
36125
|
+
amount: numberType().int(),
|
|
36126
|
+
refillDay: numberType().int().optional()
|
|
36127
|
+
});
|
|
36128
|
+
((UpdateKeyCreditsRefill$) => {
|
|
36129
|
+
UpdateKeyCreditsRefill$.inboundSchema = UpdateKeyCreditsRefill$inboundSchema;
|
|
36130
|
+
UpdateKeyCreditsRefill$.outboundSchema = UpdateKeyCreditsRefill$outboundSchema;
|
|
36131
|
+
})(UpdateKeyCreditsRefill$ ||= {});
|
|
36132
|
+
});
|
|
36133
|
+
|
|
36134
|
+
// src/models/components/updatekeycreditsdata.ts
|
|
36135
|
+
var UpdateKeyCreditsData$inboundSchema, UpdateKeyCreditsData$outboundSchema, UpdateKeyCreditsData$;
|
|
36136
|
+
var init_updatekeycreditsdata = __esm(() => {
|
|
36137
|
+
init_zod();
|
|
36138
|
+
init_updatekeycreditsrefill();
|
|
36139
|
+
UpdateKeyCreditsData$inboundSchema = objectType({
|
|
36140
|
+
remaining: nullableType(numberType().int()).optional(),
|
|
36141
|
+
refill: nullableType(UpdateKeyCreditsRefill$inboundSchema).optional()
|
|
36142
|
+
});
|
|
36143
|
+
UpdateKeyCreditsData$outboundSchema = objectType({
|
|
36144
|
+
remaining: nullableType(numberType().int()).optional(),
|
|
36145
|
+
refill: nullableType(UpdateKeyCreditsRefill$outboundSchema).optional()
|
|
36146
|
+
});
|
|
36147
|
+
((UpdateKeyCreditsData$) => {
|
|
36148
|
+
UpdateKeyCreditsData$.inboundSchema = UpdateKeyCreditsData$inboundSchema;
|
|
36149
|
+
UpdateKeyCreditsData$.outboundSchema = UpdateKeyCreditsData$outboundSchema;
|
|
36150
|
+
})(UpdateKeyCreditsData$ ||= {});
|
|
36151
|
+
});
|
|
36152
|
+
|
|
36110
36153
|
// src/models/components/v2apiscreateapirequestbody.ts
|
|
36111
36154
|
var V2ApisCreateApiRequestBody$inboundSchema, V2ApisCreateApiRequestBody$outboundSchema, V2ApisCreateApiRequestBody$;
|
|
36112
36155
|
var init_v2apiscreateapirequestbody = __esm(() => {
|
|
@@ -37001,15 +37044,15 @@ var init_v2keysupdatecreditsresponsebody = __esm(() => {
|
|
|
37001
37044
|
var V2KeysUpdateKeyRequestBody$inboundSchema, V2KeysUpdateKeyRequestBody$outboundSchema, V2KeysUpdateKeyRequestBody$;
|
|
37002
37045
|
var init_v2keysupdatekeyrequestbody = __esm(() => {
|
|
37003
37046
|
init_zod();
|
|
37004
|
-
init_keycreditsdata();
|
|
37005
37047
|
init_ratelimitrequest();
|
|
37048
|
+
init_updatekeycreditsdata();
|
|
37006
37049
|
V2KeysUpdateKeyRequestBody$inboundSchema = objectType({
|
|
37007
37050
|
keyId: stringType(),
|
|
37008
37051
|
name: nullableType(stringType()).optional(),
|
|
37009
37052
|
externalId: nullableType(stringType()).optional(),
|
|
37010
37053
|
meta: nullableType(recordType(anyType())).optional(),
|
|
37011
37054
|
expires: nullableType(numberType().int()).optional(),
|
|
37012
|
-
credits:
|
|
37055
|
+
credits: nullableType(UpdateKeyCreditsData$inboundSchema).optional(),
|
|
37013
37056
|
ratelimits: arrayType(RatelimitRequest$inboundSchema).optional(),
|
|
37014
37057
|
enabled: booleanType().optional(),
|
|
37015
37058
|
roles: arrayType(stringType()).optional(),
|
|
@@ -37021,7 +37064,7 @@ var init_v2keysupdatekeyrequestbody = __esm(() => {
|
|
|
37021
37064
|
externalId: nullableType(stringType()).optional(),
|
|
37022
37065
|
meta: nullableType(recordType(anyType())).optional(),
|
|
37023
37066
|
expires: nullableType(numberType().int()).optional(),
|
|
37024
|
-
credits:
|
|
37067
|
+
credits: nullableType(UpdateKeyCreditsData$outboundSchema).optional(),
|
|
37025
37068
|
ratelimits: arrayType(RatelimitRequest$outboundSchema).optional(),
|
|
37026
37069
|
enabled: booleanType().optional(),
|
|
37027
37070
|
roles: arrayType(stringType()).optional(),
|
|
@@ -37834,6 +37877,8 @@ var init_components = __esm(() => {
|
|
|
37834
37877
|
init_ratelimitresponse();
|
|
37835
37878
|
init_role();
|
|
37836
37879
|
init_security2();
|
|
37880
|
+
init_updatekeycreditsdata();
|
|
37881
|
+
init_updatekeycreditsrefill();
|
|
37837
37882
|
init_v2apiscreateapirequestbody();
|
|
37838
37883
|
init_v2apiscreateapiresponsebody();
|
|
37839
37884
|
init_v2apiscreateapiresponsedata();
|
|
@@ -38047,6 +38092,48 @@ var init_forbiddenerrorresponse = __esm(() => {
|
|
|
38047
38092
|
})(ForbiddenErrorResponse$ ||= {});
|
|
38048
38093
|
});
|
|
38049
38094
|
|
|
38095
|
+
// src/models/errors/goneerrorresponse.ts
|
|
38096
|
+
var GoneErrorResponse, GoneErrorResponse$inboundSchema, GoneErrorResponse$outboundSchema, GoneErrorResponse$;
|
|
38097
|
+
var init_goneerrorresponse = __esm(() => {
|
|
38098
|
+
init_zod();
|
|
38099
|
+
init_components();
|
|
38100
|
+
init_unkeyerror();
|
|
38101
|
+
GoneErrorResponse = class GoneErrorResponse extends UnkeyError {
|
|
38102
|
+
meta;
|
|
38103
|
+
error;
|
|
38104
|
+
data$;
|
|
38105
|
+
constructor(err, httpMeta) {
|
|
38106
|
+
const message = "message" in err && typeof err.message === "string" ? err.message : `API error occurred: ${JSON.stringify(err)}`;
|
|
38107
|
+
super(message, httpMeta);
|
|
38108
|
+
this.data$ = err;
|
|
38109
|
+
this.meta = err.meta;
|
|
38110
|
+
this.error = err.error;
|
|
38111
|
+
this.name = "GoneErrorResponse";
|
|
38112
|
+
}
|
|
38113
|
+
};
|
|
38114
|
+
GoneErrorResponse$inboundSchema = objectType({
|
|
38115
|
+
meta: Meta$inboundSchema,
|
|
38116
|
+
error: BaseError$inboundSchema,
|
|
38117
|
+
request$: instanceOfType(Request),
|
|
38118
|
+
response$: instanceOfType(Response),
|
|
38119
|
+
body$: stringType()
|
|
38120
|
+
}).transform((v2) => {
|
|
38121
|
+
return new GoneErrorResponse(v2, {
|
|
38122
|
+
request: v2.request$,
|
|
38123
|
+
response: v2.response$,
|
|
38124
|
+
body: v2.body$
|
|
38125
|
+
});
|
|
38126
|
+
});
|
|
38127
|
+
GoneErrorResponse$outboundSchema = instanceOfType(GoneErrorResponse).transform((v2) => v2.data$).pipe(objectType({
|
|
38128
|
+
meta: Meta$outboundSchema,
|
|
38129
|
+
error: BaseError$outboundSchema
|
|
38130
|
+
}));
|
|
38131
|
+
((GoneErrorResponse$) => {
|
|
38132
|
+
GoneErrorResponse$.inboundSchema = GoneErrorResponse$inboundSchema;
|
|
38133
|
+
GoneErrorResponse$.outboundSchema = GoneErrorResponse$outboundSchema;
|
|
38134
|
+
})(GoneErrorResponse$ ||= {});
|
|
38135
|
+
});
|
|
38136
|
+
|
|
38050
38137
|
// src/models/errors/internalservererrorresponse.ts
|
|
38051
38138
|
var InternalServerErrorResponse, InternalServerErrorResponse$inboundSchema, InternalServerErrorResponse$outboundSchema, InternalServerErrorResponse$;
|
|
38052
38139
|
var init_internalservererrorresponse = __esm(() => {
|
|
@@ -38221,6 +38308,7 @@ var init_errors2 = __esm(() => {
|
|
|
38221
38308
|
init_badrequesterrorresponse();
|
|
38222
38309
|
init_conflicterrorresponse();
|
|
38223
38310
|
init_forbiddenerrorresponse();
|
|
38311
|
+
init_goneerrorresponse();
|
|
38224
38312
|
init_httpclienterrors();
|
|
38225
38313
|
init_internalservererrorresponse();
|
|
38226
38314
|
init_notfounderrorresponse();
|
|
@@ -38228,6 +38316,7 @@ var init_errors2 = __esm(() => {
|
|
|
38228
38316
|
init_responsevalidationerror();
|
|
38229
38317
|
init_sdkvalidationerror();
|
|
38230
38318
|
init_unauthorizederrorresponse();
|
|
38319
|
+
init_unkeyerror();
|
|
38231
38320
|
});
|
|
38232
38321
|
|
|
38233
38322
|
// src/types/async.ts
|
|
@@ -38279,7 +38368,7 @@ async function $do(client, request, options) {
|
|
|
38279
38368
|
options: client._options,
|
|
38280
38369
|
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
38281
38370
|
operationID: "createApi",
|
|
38282
|
-
oAuth2Scopes:
|
|
38371
|
+
oAuth2Scopes: null,
|
|
38283
38372
|
resolvedSecurity: requestSecurity,
|
|
38284
38373
|
securitySource: client._options.rootKey,
|
|
38285
38374
|
retryConfig: options?.retries || client._options.retryConfig || {
|
|
@@ -38401,7 +38490,7 @@ async function $do2(client, request, options) {
|
|
|
38401
38490
|
options: client._options,
|
|
38402
38491
|
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
38403
38492
|
operationID: "deleteApi",
|
|
38404
|
-
oAuth2Scopes:
|
|
38493
|
+
oAuth2Scopes: null,
|
|
38405
38494
|
resolvedSecurity: requestSecurity,
|
|
38406
38495
|
securitySource: client._options.rootKey,
|
|
38407
38496
|
retryConfig: options?.retries || client._options.retryConfig || {
|
|
@@ -38526,7 +38615,7 @@ async function $do3(client, request, options) {
|
|
|
38526
38615
|
options: client._options,
|
|
38527
38616
|
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
38528
38617
|
operationID: "getApi",
|
|
38529
|
-
oAuth2Scopes:
|
|
38618
|
+
oAuth2Scopes: null,
|
|
38530
38619
|
resolvedSecurity: requestSecurity,
|
|
38531
38620
|
securitySource: client._options.rootKey,
|
|
38532
38621
|
retryConfig: options?.retries || client._options.retryConfig || {
|
|
@@ -38647,7 +38736,7 @@ async function $do4(client, request, options) {
|
|
|
38647
38736
|
options: client._options,
|
|
38648
38737
|
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
38649
38738
|
operationID: "listKeys",
|
|
38650
|
-
oAuth2Scopes:
|
|
38739
|
+
oAuth2Scopes: null,
|
|
38651
38740
|
resolvedSecurity: requestSecurity,
|
|
38652
38741
|
securitySource: client._options.rootKey,
|
|
38653
38742
|
retryConfig: options?.retries || client._options.retryConfig || {
|
|
@@ -38776,7 +38865,7 @@ async function $do5(client, request, options) {
|
|
|
38776
38865
|
options: client._options,
|
|
38777
38866
|
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
38778
38867
|
operationID: "identities.createIdentity",
|
|
38779
|
-
oAuth2Scopes:
|
|
38868
|
+
oAuth2Scopes: null,
|
|
38780
38869
|
resolvedSecurity: requestSecurity,
|
|
38781
38870
|
securitySource: client._options.rootKey,
|
|
38782
38871
|
retryConfig: options?.retries || client._options.retryConfig || {
|
|
@@ -38894,7 +38983,7 @@ async function $do6(client, request, options) {
|
|
|
38894
38983
|
options: client._options,
|
|
38895
38984
|
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
38896
38985
|
operationID: "v2.identities.deleteIdentity",
|
|
38897
|
-
oAuth2Scopes:
|
|
38986
|
+
oAuth2Scopes: null,
|
|
38898
38987
|
resolvedSecurity: requestSecurity,
|
|
38899
38988
|
securitySource: client._options.rootKey,
|
|
38900
38989
|
retryConfig: options?.retries || client._options.retryConfig || {
|
|
@@ -39024,7 +39113,7 @@ async function $do7(client, request, options) {
|
|
|
39024
39113
|
options: client._options,
|
|
39025
39114
|
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
39026
39115
|
operationID: "identities.getIdentity",
|
|
39027
|
-
oAuth2Scopes:
|
|
39116
|
+
oAuth2Scopes: null,
|
|
39028
39117
|
resolvedSecurity: requestSecurity,
|
|
39029
39118
|
securitySource: client._options.rootKey,
|
|
39030
39119
|
retryConfig: options?.retries || client._options.retryConfig || {
|
|
@@ -39205,7 +39294,7 @@ async function $do8(client, request, options) {
|
|
|
39205
39294
|
options: client._options,
|
|
39206
39295
|
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
39207
39296
|
operationID: "identities.listIdentities",
|
|
39208
|
-
oAuth2Scopes:
|
|
39297
|
+
oAuth2Scopes: null,
|
|
39209
39298
|
resolvedSecurity: requestSecurity,
|
|
39210
39299
|
securitySource: client._options.rootKey,
|
|
39211
39300
|
retryConfig: options?.retries || client._options.retryConfig || {
|
|
@@ -39262,6 +39351,9 @@ async function $do8(client, request, options) {
|
|
|
39262
39351
|
if (typeof nextCursor !== "string") {
|
|
39263
39352
|
return { next: () => null };
|
|
39264
39353
|
}
|
|
39354
|
+
if (nextCursor.trim() === "") {
|
|
39355
|
+
return { next: () => null };
|
|
39356
|
+
}
|
|
39265
39357
|
const nextVal = () => identitiesListIdentities(client, {
|
|
39266
39358
|
...request,
|
|
39267
39359
|
cursor: nextCursor
|
|
@@ -39347,7 +39439,7 @@ async function $do9(client, request, options) {
|
|
|
39347
39439
|
options: client._options,
|
|
39348
39440
|
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
39349
39441
|
operationID: "v2.identities.updateIdentity",
|
|
39350
|
-
oAuth2Scopes:
|
|
39442
|
+
oAuth2Scopes: null,
|
|
39351
39443
|
resolvedSecurity: requestSecurity,
|
|
39352
39444
|
securitySource: client._options.rootKey,
|
|
39353
39445
|
retryConfig: options?.retries || client._options.retryConfig || {
|
|
@@ -39466,7 +39558,7 @@ async function $do10(client, request, options) {
|
|
|
39466
39558
|
options: client._options,
|
|
39467
39559
|
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
39468
39560
|
operationID: "addPermissions",
|
|
39469
|
-
oAuth2Scopes:
|
|
39561
|
+
oAuth2Scopes: null,
|
|
39470
39562
|
resolvedSecurity: requestSecurity,
|
|
39471
39563
|
securitySource: client._options.rootKey,
|
|
39472
39564
|
retryConfig: options?.retries || client._options.retryConfig || {
|
|
@@ -39593,7 +39685,7 @@ async function $do11(client, request, options) {
|
|
|
39593
39685
|
options: client._options,
|
|
39594
39686
|
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
39595
39687
|
operationID: "addRoles",
|
|
39596
|
-
oAuth2Scopes:
|
|
39688
|
+
oAuth2Scopes: null,
|
|
39597
39689
|
resolvedSecurity: requestSecurity,
|
|
39598
39690
|
securitySource: client._options.rootKey,
|
|
39599
39691
|
retryConfig: options?.retries || client._options.retryConfig || {
|
|
@@ -39720,7 +39812,7 @@ async function $do12(client, request, options) {
|
|
|
39720
39812
|
options: client._options,
|
|
39721
39813
|
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
39722
39814
|
operationID: "createKey",
|
|
39723
|
-
oAuth2Scopes:
|
|
39815
|
+
oAuth2Scopes: null,
|
|
39724
39816
|
resolvedSecurity: requestSecurity,
|
|
39725
39817
|
securitySource: client._options.rootKey,
|
|
39726
39818
|
retryConfig: options?.retries || client._options.retryConfig || {
|
|
@@ -39848,7 +39940,7 @@ async function $do13(client, request, options) {
|
|
|
39848
39940
|
options: client._options,
|
|
39849
39941
|
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
39850
39942
|
operationID: "deleteKey",
|
|
39851
|
-
oAuth2Scopes:
|
|
39943
|
+
oAuth2Scopes: null,
|
|
39852
39944
|
resolvedSecurity: requestSecurity,
|
|
39853
39945
|
securitySource: client._options.rootKey,
|
|
39854
39946
|
retryConfig: options?.retries || client._options.retryConfig || {
|
|
@@ -39971,7 +40063,7 @@ async function $do14(client, request, options) {
|
|
|
39971
40063
|
options: client._options,
|
|
39972
40064
|
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
39973
40065
|
operationID: "getKey",
|
|
39974
|
-
oAuth2Scopes:
|
|
40066
|
+
oAuth2Scopes: null,
|
|
39975
40067
|
resolvedSecurity: requestSecurity,
|
|
39976
40068
|
securitySource: client._options.rootKey,
|
|
39977
40069
|
retryConfig: options?.retries || client._options.retryConfig || {
|
|
@@ -40097,7 +40189,7 @@ async function $do15(client, request, options) {
|
|
|
40097
40189
|
options: client._options,
|
|
40098
40190
|
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
40099
40191
|
operationID: "removePermissions",
|
|
40100
|
-
oAuth2Scopes:
|
|
40192
|
+
oAuth2Scopes: null,
|
|
40101
40193
|
resolvedSecurity: requestSecurity,
|
|
40102
40194
|
securitySource: client._options.rootKey,
|
|
40103
40195
|
retryConfig: options?.retries || client._options.retryConfig || {
|
|
@@ -40224,7 +40316,7 @@ async function $do16(client, request, options) {
|
|
|
40224
40316
|
options: client._options,
|
|
40225
40317
|
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
40226
40318
|
operationID: "removeRoles",
|
|
40227
|
-
oAuth2Scopes:
|
|
40319
|
+
oAuth2Scopes: null,
|
|
40228
40320
|
resolvedSecurity: requestSecurity,
|
|
40229
40321
|
securitySource: client._options.rootKey,
|
|
40230
40322
|
retryConfig: options?.retries || client._options.retryConfig || {
|
|
@@ -40351,7 +40443,7 @@ async function $do17(client, request, options) {
|
|
|
40351
40443
|
options: client._options,
|
|
40352
40444
|
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
40353
40445
|
operationID: "rerollKey",
|
|
40354
|
-
oAuth2Scopes:
|
|
40446
|
+
oAuth2Scopes: null,
|
|
40355
40447
|
resolvedSecurity: requestSecurity,
|
|
40356
40448
|
securitySource: client._options.rootKey,
|
|
40357
40449
|
retryConfig: options?.retries || client._options.retryConfig || {
|
|
@@ -40495,7 +40587,7 @@ async function $do18(client, request, options) {
|
|
|
40495
40587
|
options: client._options,
|
|
40496
40588
|
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
40497
40589
|
operationID: "setPermissions",
|
|
40498
|
-
oAuth2Scopes:
|
|
40590
|
+
oAuth2Scopes: null,
|
|
40499
40591
|
resolvedSecurity: requestSecurity,
|
|
40500
40592
|
securitySource: client._options.rootKey,
|
|
40501
40593
|
retryConfig: options?.retries || client._options.retryConfig || {
|
|
@@ -40622,7 +40714,7 @@ async function $do19(client, request, options) {
|
|
|
40622
40714
|
options: client._options,
|
|
40623
40715
|
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
40624
40716
|
operationID: "setRoles",
|
|
40625
|
-
oAuth2Scopes:
|
|
40717
|
+
oAuth2Scopes: null,
|
|
40626
40718
|
resolvedSecurity: requestSecurity,
|
|
40627
40719
|
securitySource: client._options.rootKey,
|
|
40628
40720
|
retryConfig: options?.retries || client._options.retryConfig || {
|
|
@@ -40749,7 +40841,7 @@ async function $do20(client, request, options) {
|
|
|
40749
40841
|
options: client._options,
|
|
40750
40842
|
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
40751
40843
|
operationID: "updateCredits",
|
|
40752
|
-
oAuth2Scopes:
|
|
40844
|
+
oAuth2Scopes: null,
|
|
40753
40845
|
resolvedSecurity: requestSecurity,
|
|
40754
40846
|
securitySource: client._options.rootKey,
|
|
40755
40847
|
retryConfig: options?.retries || client._options.retryConfig || {
|
|
@@ -40876,7 +40968,7 @@ async function $do21(client, request, options) {
|
|
|
40876
40968
|
options: client._options,
|
|
40877
40969
|
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
40878
40970
|
operationID: "updateKey",
|
|
40879
|
-
oAuth2Scopes:
|
|
40971
|
+
oAuth2Scopes: null,
|
|
40880
40972
|
resolvedSecurity: requestSecurity,
|
|
40881
40973
|
securitySource: client._options.rootKey,
|
|
40882
40974
|
retryConfig: options?.retries || client._options.retryConfig || {
|
|
@@ -41003,7 +41095,7 @@ async function $do22(client, request, options) {
|
|
|
41003
41095
|
options: client._options,
|
|
41004
41096
|
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
41005
41097
|
operationID: "verifyKey",
|
|
41006
|
-
oAuth2Scopes:
|
|
41098
|
+
oAuth2Scopes: null,
|
|
41007
41099
|
resolvedSecurity: requestSecurity,
|
|
41008
41100
|
securitySource: client._options.rootKey,
|
|
41009
41101
|
retryConfig: options?.retries || client._options.retryConfig || {
|
|
@@ -41133,7 +41225,7 @@ async function $do23(client, request, options) {
|
|
|
41133
41225
|
options: client._options,
|
|
41134
41226
|
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
41135
41227
|
operationID: "whoami",
|
|
41136
|
-
oAuth2Scopes:
|
|
41228
|
+
oAuth2Scopes: null,
|
|
41137
41229
|
resolvedSecurity: requestSecurity,
|
|
41138
41230
|
securitySource: client._options.rootKey,
|
|
41139
41231
|
retryConfig: options?.retries || client._options.retryConfig || {
|
|
@@ -41254,7 +41346,7 @@ async function $do24(client, request, options) {
|
|
|
41254
41346
|
options: client._options,
|
|
41255
41347
|
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
41256
41348
|
operationID: "createPermission",
|
|
41257
|
-
oAuth2Scopes:
|
|
41349
|
+
oAuth2Scopes: null,
|
|
41258
41350
|
resolvedSecurity: requestSecurity,
|
|
41259
41351
|
securitySource: client._options.rootKey,
|
|
41260
41352
|
retryConfig: options?.retries || client._options.retryConfig || {
|
|
@@ -41376,7 +41468,7 @@ async function $do25(client, request, options) {
|
|
|
41376
41468
|
options: client._options,
|
|
41377
41469
|
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
41378
41470
|
operationID: "createRole",
|
|
41379
|
-
oAuth2Scopes:
|
|
41471
|
+
oAuth2Scopes: null,
|
|
41380
41472
|
resolvedSecurity: requestSecurity,
|
|
41381
41473
|
securitySource: client._options.rootKey,
|
|
41382
41474
|
retryConfig: options?.retries || client._options.retryConfig || {
|
|
@@ -41496,7 +41588,7 @@ async function $do26(client, request, options) {
|
|
|
41496
41588
|
options: client._options,
|
|
41497
41589
|
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
41498
41590
|
operationID: "deletePermission",
|
|
41499
|
-
oAuth2Scopes:
|
|
41591
|
+
oAuth2Scopes: null,
|
|
41500
41592
|
resolvedSecurity: requestSecurity,
|
|
41501
41593
|
securitySource: client._options.rootKey,
|
|
41502
41594
|
retryConfig: options?.retries || client._options.retryConfig || {
|
|
@@ -41616,7 +41708,7 @@ async function $do27(client, request, options) {
|
|
|
41616
41708
|
options: client._options,
|
|
41617
41709
|
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
41618
41710
|
operationID: "deleteRole",
|
|
41619
|
-
oAuth2Scopes:
|
|
41711
|
+
oAuth2Scopes: null,
|
|
41620
41712
|
resolvedSecurity: requestSecurity,
|
|
41621
41713
|
securitySource: client._options.rootKey,
|
|
41622
41714
|
retryConfig: options?.retries || client._options.retryConfig || {
|
|
@@ -41736,7 +41828,7 @@ async function $do28(client, request, options) {
|
|
|
41736
41828
|
options: client._options,
|
|
41737
41829
|
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
41738
41830
|
operationID: "getPermission",
|
|
41739
|
-
oAuth2Scopes:
|
|
41831
|
+
oAuth2Scopes: null,
|
|
41740
41832
|
resolvedSecurity: requestSecurity,
|
|
41741
41833
|
securitySource: client._options.rootKey,
|
|
41742
41834
|
retryConfig: options?.retries || client._options.retryConfig || {
|
|
@@ -41854,7 +41946,7 @@ async function $do29(client, request, options) {
|
|
|
41854
41946
|
options: client._options,
|
|
41855
41947
|
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
41856
41948
|
operationID: "getRole",
|
|
41857
|
-
oAuth2Scopes:
|
|
41949
|
+
oAuth2Scopes: null,
|
|
41858
41950
|
resolvedSecurity: requestSecurity,
|
|
41859
41951
|
securitySource: client._options.rootKey,
|
|
41860
41952
|
retryConfig: options?.retries || client._options.retryConfig || {
|
|
@@ -41972,7 +42064,7 @@ async function $do30(client, request, options) {
|
|
|
41972
42064
|
options: client._options,
|
|
41973
42065
|
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
41974
42066
|
operationID: "listPermissions",
|
|
41975
|
-
oAuth2Scopes:
|
|
42067
|
+
oAuth2Scopes: null,
|
|
41976
42068
|
resolvedSecurity: requestSecurity,
|
|
41977
42069
|
securitySource: client._options.rootKey,
|
|
41978
42070
|
retryConfig: options?.retries || client._options.retryConfig || {
|
|
@@ -42091,7 +42183,7 @@ async function $do31(client, request, options) {
|
|
|
42091
42183
|
options: client._options,
|
|
42092
42184
|
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
42093
42185
|
operationID: "listRoles",
|
|
42094
|
-
oAuth2Scopes:
|
|
42186
|
+
oAuth2Scopes: null,
|
|
42095
42187
|
resolvedSecurity: requestSecurity,
|
|
42096
42188
|
securitySource: client._options.rootKey,
|
|
42097
42189
|
retryConfig: options?.retries || client._options.retryConfig || {
|
|
@@ -42210,7 +42302,7 @@ async function $do32(client, request, options) {
|
|
|
42210
42302
|
options: client._options,
|
|
42211
42303
|
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
42212
42304
|
operationID: "ratelimit.deleteOverride",
|
|
42213
|
-
oAuth2Scopes:
|
|
42305
|
+
oAuth2Scopes: null,
|
|
42214
42306
|
resolvedSecurity: requestSecurity,
|
|
42215
42307
|
securitySource: client._options.rootKey,
|
|
42216
42308
|
retryConfig: options?.retries || client._options.retryConfig || {
|
|
@@ -42329,7 +42421,7 @@ async function $do33(client, request, options) {
|
|
|
42329
42421
|
options: client._options,
|
|
42330
42422
|
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
42331
42423
|
operationID: "ratelimit.getOverride",
|
|
42332
|
-
oAuth2Scopes:
|
|
42424
|
+
oAuth2Scopes: null,
|
|
42333
42425
|
resolvedSecurity: requestSecurity,
|
|
42334
42426
|
securitySource: client._options.rootKey,
|
|
42335
42427
|
retryConfig: options?.retries || client._options.retryConfig || {
|
|
@@ -42448,7 +42540,7 @@ async function $do34(client, request, options) {
|
|
|
42448
42540
|
options: client._options,
|
|
42449
42541
|
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
42450
42542
|
operationID: "ratelimit.limit",
|
|
42451
|
-
oAuth2Scopes:
|
|
42543
|
+
oAuth2Scopes: null,
|
|
42452
42544
|
resolvedSecurity: requestSecurity,
|
|
42453
42545
|
securitySource: client._options.rootKey,
|
|
42454
42546
|
retryConfig: options?.retries || client._options.retryConfig || {
|
|
@@ -42479,7 +42571,7 @@ async function $do34(client, request, options) {
|
|
|
42479
42571
|
const req = requestRes.value;
|
|
42480
42572
|
const doResult = await client._do(req, {
|
|
42481
42573
|
context,
|
|
42482
|
-
errorCodes: ["400", "401", "403", "404", "4XX", "500", "5XX"],
|
|
42574
|
+
errorCodes: ["400", "401", "403", "404", "410", "4XX", "500", "5XX"],
|
|
42483
42575
|
retryConfig: context.retryConfig,
|
|
42484
42576
|
retryCodes: context.retryCodes
|
|
42485
42577
|
});
|
|
@@ -42490,7 +42582,7 @@ async function $do34(client, request, options) {
|
|
|
42490
42582
|
const responseFields = {
|
|
42491
42583
|
HttpMeta: { Response: response, Request: req }
|
|
42492
42584
|
};
|
|
42493
|
-
const [result] = await match(json(200, V2RatelimitLimitResponseBody$inboundSchema), jsonErr(400, BadRequestErrorResponse$inboundSchema), jsonErr(401, UnauthorizedErrorResponse$inboundSchema), jsonErr(403, ForbiddenErrorResponse$inboundSchema), jsonErr(404, NotFoundErrorResponse$inboundSchema), jsonErr(500, InternalServerErrorResponse$inboundSchema), fail("4XX"), fail("5XX"))(response, req, { extraFields: responseFields });
|
|
42585
|
+
const [result] = await match(json(200, V2RatelimitLimitResponseBody$inboundSchema), jsonErr(400, BadRequestErrorResponse$inboundSchema), jsonErr(401, UnauthorizedErrorResponse$inboundSchema), jsonErr(403, ForbiddenErrorResponse$inboundSchema), jsonErr(404, NotFoundErrorResponse$inboundSchema), jsonErr(410, GoneErrorResponse$inboundSchema), jsonErr(500, InternalServerErrorResponse$inboundSchema), fail("4XX"), fail("5XX"))(response, req, { extraFields: responseFields });
|
|
42494
42586
|
if (!result.ok) {
|
|
42495
42587
|
return [result, { status: "complete", request: req, response }];
|
|
42496
42588
|
}
|
|
@@ -42525,7 +42617,7 @@ Check and enforce rate limits for any identifier (user ID, IP address, API clien
|
|
|
42525
42617
|
|
|
42526
42618
|
Use this for rate limiting beyond API keys - limit users by ID, IPs by address, or any custom identifier. Supports namespace organization, variable costs, and custom overrides.
|
|
42527
42619
|
|
|
42528
|
-
**
|
|
42620
|
+
**Response Codes**: Rate limit checks return HTTP 200 regardless of whether the limit is exceeded - check the \`success\` field in the response to determine if the request should be allowed. 4xx responses indicate auth, namespace existence/deletion, or validation errors (e.g., 410 Gone for deleted namespaces). 5xx responses indicate server errors.
|
|
42529
42621
|
|
|
42530
42622
|
**Required Permissions**
|
|
42531
42623
|
|
|
@@ -42575,7 +42667,7 @@ async function $do35(client, request, options) {
|
|
|
42575
42667
|
options: client._options,
|
|
42576
42668
|
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
42577
42669
|
operationID: "ratelimit.listOverrides",
|
|
42578
|
-
oAuth2Scopes:
|
|
42670
|
+
oAuth2Scopes: null,
|
|
42579
42671
|
resolvedSecurity: requestSecurity,
|
|
42580
42672
|
securitySource: client._options.rootKey,
|
|
42581
42673
|
retryConfig: options?.retries || client._options.retryConfig || {
|
|
@@ -42694,7 +42786,7 @@ async function $do36(client, request, options) {
|
|
|
42694
42786
|
options: client._options,
|
|
42695
42787
|
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
42696
42788
|
operationID: "ratelimit.setOverride",
|
|
42697
|
-
oAuth2Scopes:
|
|
42789
|
+
oAuth2Scopes: null,
|
|
42698
42790
|
resolvedSecurity: requestSecurity,
|
|
42699
42791
|
securitySource: client._options.rootKey,
|
|
42700
42792
|
retryConfig: options?.retries || client._options.retryConfig || {
|
|
@@ -42794,7 +42886,7 @@ Use this to create premium tiers with higher limits, apply stricter limits to sp
|
|
|
42794
42886
|
function createMCPServer(deps) {
|
|
42795
42887
|
const server = new McpServer({
|
|
42796
42888
|
name: "Unkey",
|
|
42797
|
-
version: "2.0.
|
|
42889
|
+
version: "2.0.6"
|
|
42798
42890
|
});
|
|
42799
42891
|
const client = new UnkeyCore({
|
|
42800
42892
|
rootKey: deps.rootKey,
|
|
@@ -44082,7 +44174,7 @@ var routes = ln({
|
|
|
44082
44174
|
var app = _e(routes, {
|
|
44083
44175
|
name: "mcp",
|
|
44084
44176
|
versionInfo: {
|
|
44085
|
-
currentVersion: "2.0.
|
|
44177
|
+
currentVersion: "2.0.6"
|
|
44086
44178
|
}
|
|
44087
44179
|
});
|
|
44088
44180
|
Yt(app, process3.argv.slice(2), buildContext(process3));
|
|
@@ -44090,5 +44182,5 @@ export {
|
|
|
44090
44182
|
app
|
|
44091
44183
|
};
|
|
44092
44184
|
|
|
44093
|
-
//# debugId=
|
|
44185
|
+
//# debugId=6D3A173DB9C7F03F64756E2164756E21
|
|
44094
44186
|
//# sourceMappingURL=mcp-server.js.map
|