@featureflip/mcp 0.3.0 → 0.4.0
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 +6 -3
- package/dist/cli.mjs +4 -7
- package/dist/generated/api-types.d.ts +483 -143
- package/dist/generated/api-types.d.ts.map +1 -1
- package/dist/generated/output-schemas.json.d.ts +337 -1
- package/dist/index.mjs +1 -1
- package/dist/{org-DFNWkYpr.js → org-C6HAk06Q.js} +45 -50
- package/dist/tools/flag-environments.d.ts.map +1 -1
- package/package.json +7 -7
|
@@ -8,6 +8,7 @@ declare const _default: {
|
|
|
8
8
|
"GET /api/v1/orgs/{org}/projects/{project}/flags/removal-candidates": "PublicFlagRemovalCandidatePagedResult",
|
|
9
9
|
"GET /api/v1/orgs/{org}/projects/{project}/flags/{flag}": "PublicFlagResponse",
|
|
10
10
|
"GET /api/v1/orgs/{org}/projects/{project}/flags/{flag}/environments/{env}": "PublicFlagEnvConfigResponse",
|
|
11
|
+
"GET /api/v1/orgs/{org}/projects/{project}/flags/{flag}/environments/{env}/evaluations": "PublicFlagEvaluationsResponse",
|
|
11
12
|
"GET /api/v1/orgs/{org}/projects/{project}/flags/{flag}/environments/{env}/targeting": "PublicTargetingConfigResponse",
|
|
12
13
|
"POST /api/v1/orgs/{org}/projects/{project}/flags/{flag}/environments/{env}/rules": "PublicTargetingRuleResponse",
|
|
13
14
|
"GET /api/v1/orgs/{org}/projects/{project}/flags/{flag}/environments/{env}/rules/{ruleId}": "PublicTargetingRuleResponse",
|
|
@@ -461,9 +462,19 @@ declare const _default: {
|
|
|
461
462
|
"string",
|
|
462
463
|
"null"
|
|
463
464
|
]
|
|
465
|
+
},
|
|
466
|
+
"plan_limit": {
|
|
467
|
+
"anyOf": [
|
|
468
|
+
{
|
|
469
|
+
"$ref": "#/$defs/PublicPlanLimit"
|
|
470
|
+
},
|
|
471
|
+
{
|
|
472
|
+
"type": "null"
|
|
473
|
+
}
|
|
474
|
+
]
|
|
464
475
|
}
|
|
465
476
|
},
|
|
466
|
-
"description": "The frozen public-API error contract. `error` codes are stable snake_case strings. Wire keys\nare frozen snake_case too (`error`, `message`, `docs_url`, `fields`,\n`retry_after`) — the global camelCase naming policy would otherwise emit\n`docsUrl`/`retryAfter`, breaking the published spec. !:JsonPropertyName\nalways wins over the policy, so these are pinned explicitly rather than relying on the\nproperty names already being lowercase for the single-word ones.\n`did_you_mean`, `next_actions` and `connection_id` are ADDITIVE optional keys\n(null → omitted via the global `DefaultIgnoreCondition = WhenWritingNull`), so\npre-existing error bodies are byte-for-byte unchanged when they're absent.\n\n`connection_id` is present only on the `sso_required` error: the organization\nrequires single sign-on, and this credential didn't come through its identity provider.\n`connection_id` identifies which SSO connection to sign in with
|
|
477
|
+
"description": "The frozen public-API error contract. `error` codes are stable snake_case strings. Wire keys\nare frozen snake_case too (`error`, `message`, `docs_url`, `fields`,\n`retry_after`) — the global camelCase naming policy would otherwise emit\n`docsUrl`/`retryAfter`, breaking the published spec. !:JsonPropertyName\nalways wins over the policy, so these are pinned explicitly rather than relying on the\nproperty names already being lowercase for the single-word ones.\n`did_you_mean`, `next_actions` and `connection_id` are ADDITIVE optional keys\n(null → omitted via the global `DefaultIgnoreCondition = WhenWritingNull`), so\npre-existing error bodies are byte-for-byte unchanged when they're absent.\n\n`connection_id` is present only on the `sso_required` error: the organization\nrequires single sign-on, and this credential didn't come through its identity provider.\n`connection_id` identifies which SSO connection to sign in with.\n`plan_limit` is present only on the `plan_limit_reached` error: which plan cap the\nrequest would have exceeded, so a client can branch on it without parsing `message`."
|
|
467
478
|
},
|
|
468
479
|
"PublicConditionGroupRequest": {
|
|
469
480
|
"type": [
|
|
@@ -609,6 +620,36 @@ declare const _default: {
|
|
|
609
620
|
},
|
|
610
621
|
"description": "A single condition within a PublicConditionGroupResponse. Maps 1:1 onto\nConditionDto. Operator is a bare wire string naming one of the\n`OperatorType` members (e.g. `\"Equals\"`, `\"In\"`)."
|
|
611
622
|
},
|
|
623
|
+
"PublicConfiguredWeight": {
|
|
624
|
+
"type": [
|
|
625
|
+
"object",
|
|
626
|
+
"null"
|
|
627
|
+
],
|
|
628
|
+
"properties": {
|
|
629
|
+
"variationKey": {
|
|
630
|
+
"type": [
|
|
631
|
+
"string",
|
|
632
|
+
"null"
|
|
633
|
+
],
|
|
634
|
+
"description": "The variation's key."
|
|
635
|
+
},
|
|
636
|
+
"name": {
|
|
637
|
+
"type": [
|
|
638
|
+
"string",
|
|
639
|
+
"null"
|
|
640
|
+
],
|
|
641
|
+
"description": "The variation's name, or null when the key no longer matches one of the flag's variations."
|
|
642
|
+
},
|
|
643
|
+
"weight": {
|
|
644
|
+
"type": [
|
|
645
|
+
"integer",
|
|
646
|
+
"null"
|
|
647
|
+
],
|
|
648
|
+
"description": "Percent of the rule's traffic."
|
|
649
|
+
}
|
|
650
|
+
},
|
|
651
|
+
"description": "A variation's configured share of a rollout rule."
|
|
652
|
+
},
|
|
612
653
|
"PublicCreateEnvironmentRequest": {
|
|
613
654
|
"type": [
|
|
614
655
|
"object",
|
|
@@ -1176,6 +1217,128 @@ declare const _default: {
|
|
|
1176
1217
|
},
|
|
1177
1218
|
"description": "A page of results plus an opaque cursor for the next page, or null when this is the last\npage. Wire keys are frozen: `items` (already lowercase under the camelCase policy) and\n`next_cursor` (pinned explicitly — the policy alone would emit `nextCursor`)."
|
|
1178
1219
|
},
|
|
1220
|
+
"PublicEvaluationSource": {
|
|
1221
|
+
"type": [
|
|
1222
|
+
"object",
|
|
1223
|
+
"null"
|
|
1224
|
+
],
|
|
1225
|
+
"properties": {
|
|
1226
|
+
"source": {
|
|
1227
|
+
"type": [
|
|
1228
|
+
"string",
|
|
1229
|
+
"null"
|
|
1230
|
+
],
|
|
1231
|
+
"description": "One of rule, fallthrough, off, prerequisite, error, notFound or unknown (an SDK that reports no reason, or evaluations recorded before sources were). Allowed values: rule, fallthrough, off, prerequisite, error, notFound, unknown."
|
|
1232
|
+
},
|
|
1233
|
+
"ruleId": {
|
|
1234
|
+
"type": [
|
|
1235
|
+
"string",
|
|
1236
|
+
"null"
|
|
1237
|
+
],
|
|
1238
|
+
"description": "For a rule, its id (rules have no key). Null otherwise, or when the SDK didn't say which rule."
|
|
1239
|
+
},
|
|
1240
|
+
"ruleLabel": {
|
|
1241
|
+
"type": [
|
|
1242
|
+
"string",
|
|
1243
|
+
"null"
|
|
1244
|
+
],
|
|
1245
|
+
"description": "For a live rule, its description or a generated label. Null otherwise."
|
|
1246
|
+
},
|
|
1247
|
+
"ruleExists": {
|
|
1248
|
+
"type": [
|
|
1249
|
+
"boolean",
|
|
1250
|
+
"null"
|
|
1251
|
+
],
|
|
1252
|
+
"description": "False when the rule is no longer in the environment's targeting."
|
|
1253
|
+
},
|
|
1254
|
+
"count": {
|
|
1255
|
+
"type": [
|
|
1256
|
+
"integer",
|
|
1257
|
+
"null"
|
|
1258
|
+
],
|
|
1259
|
+
"description": "Evaluations this source served."
|
|
1260
|
+
},
|
|
1261
|
+
"share": {
|
|
1262
|
+
"type": [
|
|
1263
|
+
"number",
|
|
1264
|
+
"null"
|
|
1265
|
+
],
|
|
1266
|
+
"description": "Count as a fraction (0 to 1) of all sources' counts combined."
|
|
1267
|
+
},
|
|
1268
|
+
"variations": {
|
|
1269
|
+
"type": [
|
|
1270
|
+
"array",
|
|
1271
|
+
"null"
|
|
1272
|
+
],
|
|
1273
|
+
"items": {
|
|
1274
|
+
"anyOf": [
|
|
1275
|
+
{
|
|
1276
|
+
"$ref": "#/$defs/PublicEvaluationVariation"
|
|
1277
|
+
},
|
|
1278
|
+
{
|
|
1279
|
+
"type": "null"
|
|
1280
|
+
}
|
|
1281
|
+
]
|
|
1282
|
+
},
|
|
1283
|
+
"description": "What this source served, with shares of this source's count."
|
|
1284
|
+
},
|
|
1285
|
+
"rollout": {
|
|
1286
|
+
"anyOf": [
|
|
1287
|
+
{
|
|
1288
|
+
"$ref": "#/$defs/PublicRolloutCheck"
|
|
1289
|
+
},
|
|
1290
|
+
{
|
|
1291
|
+
"type": "null"
|
|
1292
|
+
}
|
|
1293
|
+
]
|
|
1294
|
+
}
|
|
1295
|
+
},
|
|
1296
|
+
"description": "The evaluations one part of the targeting served."
|
|
1297
|
+
},
|
|
1298
|
+
"PublicEvaluationVariation": {
|
|
1299
|
+
"type": [
|
|
1300
|
+
"object",
|
|
1301
|
+
"null"
|
|
1302
|
+
],
|
|
1303
|
+
"properties": {
|
|
1304
|
+
"variationKey": {
|
|
1305
|
+
"type": [
|
|
1306
|
+
"string",
|
|
1307
|
+
"null"
|
|
1308
|
+
],
|
|
1309
|
+
"description": "The variation served, or null for evaluations recorded without one."
|
|
1310
|
+
},
|
|
1311
|
+
"name": {
|
|
1312
|
+
"type": [
|
|
1313
|
+
"string",
|
|
1314
|
+
"null"
|
|
1315
|
+
],
|
|
1316
|
+
"description": "The variation's name, or null when the key no longer matches one of the flag's variations."
|
|
1317
|
+
},
|
|
1318
|
+
"exists": {
|
|
1319
|
+
"type": [
|
|
1320
|
+
"boolean",
|
|
1321
|
+
"null"
|
|
1322
|
+
],
|
|
1323
|
+
"description": "False when the key no longer matches one of the flag's variations."
|
|
1324
|
+
},
|
|
1325
|
+
"count": {
|
|
1326
|
+
"type": [
|
|
1327
|
+
"integer",
|
|
1328
|
+
"null"
|
|
1329
|
+
],
|
|
1330
|
+
"description": "Evaluations that served this variation."
|
|
1331
|
+
},
|
|
1332
|
+
"share": {
|
|
1333
|
+
"type": [
|
|
1334
|
+
"number",
|
|
1335
|
+
"null"
|
|
1336
|
+
],
|
|
1337
|
+
"description": "Count as a fraction (0 to 1) of the parent total: the window's total, or for a source's variations that source's count. 0 when the parent total is 0."
|
|
1338
|
+
}
|
|
1339
|
+
},
|
|
1340
|
+
"description": "One variation's evaluations."
|
|
1341
|
+
},
|
|
1179
1342
|
"PublicFlagEnvConfigResponse": {
|
|
1180
1343
|
"type": [
|
|
1181
1344
|
"object",
|
|
@@ -1249,6 +1412,91 @@ declare const _default: {
|
|
|
1249
1412
|
},
|
|
1250
1413
|
"description": "Public representation of a flag's config within a single environment, returned by\n`GET .../flags/{flag}/environments` and `GET .../flags/{flag}/environments/{env}`.\nDrops internal/dashboard-only fields present on FlagEnvironmentConfigurationDto\n— Id (an internal row id, not part of the public\ncontract; EnvironmentId is the addressable key), `FeatureFlagId` (implicit\nin the route), the environment's name/color/sort-order (dashboard display fields — the public\ncontract only needs the addressable EnvironmentKey), and `Staleness` (an\ninternal analytics signal)."
|
|
1251
1414
|
},
|
|
1415
|
+
"PublicFlagEvaluationsResponse": {
|
|
1416
|
+
"type": [
|
|
1417
|
+
"object",
|
|
1418
|
+
"null"
|
|
1419
|
+
],
|
|
1420
|
+
"properties": {
|
|
1421
|
+
"environmentKey": {
|
|
1422
|
+
"type": [
|
|
1423
|
+
"string",
|
|
1424
|
+
"null"
|
|
1425
|
+
],
|
|
1426
|
+
"description": "The environment's key."
|
|
1427
|
+
},
|
|
1428
|
+
"days": {
|
|
1429
|
+
"type": [
|
|
1430
|
+
"integer",
|
|
1431
|
+
"null"
|
|
1432
|
+
],
|
|
1433
|
+
"description": "The window requested: 7, 30 or 90."
|
|
1434
|
+
},
|
|
1435
|
+
"fromUtc": {
|
|
1436
|
+
"type": [
|
|
1437
|
+
"string",
|
|
1438
|
+
"null"
|
|
1439
|
+
],
|
|
1440
|
+
"description": "Start of the window: UTC midnight `days - 1` days ago, or the flag's creation day if later."
|
|
1441
|
+
},
|
|
1442
|
+
"toUtc": {
|
|
1443
|
+
"type": [
|
|
1444
|
+
"string",
|
|
1445
|
+
"null"
|
|
1446
|
+
],
|
|
1447
|
+
"description": "When the counts were read."
|
|
1448
|
+
},
|
|
1449
|
+
"totalCount": {
|
|
1450
|
+
"type": [
|
|
1451
|
+
"integer",
|
|
1452
|
+
"null"
|
|
1453
|
+
],
|
|
1454
|
+
"description": "Evaluations in the window. Evaluation counts, not unique users."
|
|
1455
|
+
},
|
|
1456
|
+
"lastEvaluatedAtUtc": {
|
|
1457
|
+
"type": [
|
|
1458
|
+
"string",
|
|
1459
|
+
"null"
|
|
1460
|
+
],
|
|
1461
|
+
"description": "The last reported evaluation, or null if none was reported."
|
|
1462
|
+
},
|
|
1463
|
+
"variations": {
|
|
1464
|
+
"type": [
|
|
1465
|
+
"array",
|
|
1466
|
+
"null"
|
|
1467
|
+
],
|
|
1468
|
+
"items": {
|
|
1469
|
+
"anyOf": [
|
|
1470
|
+
{
|
|
1471
|
+
"$ref": "#/$defs/PublicEvaluationVariation"
|
|
1472
|
+
},
|
|
1473
|
+
{
|
|
1474
|
+
"type": "null"
|
|
1475
|
+
}
|
|
1476
|
+
]
|
|
1477
|
+
},
|
|
1478
|
+
"description": "Evaluations per variation over the window."
|
|
1479
|
+
},
|
|
1480
|
+
"sources": {
|
|
1481
|
+
"type": [
|
|
1482
|
+
"array",
|
|
1483
|
+
"null"
|
|
1484
|
+
],
|
|
1485
|
+
"items": {
|
|
1486
|
+
"anyOf": [
|
|
1487
|
+
{
|
|
1488
|
+
"$ref": "#/$defs/PublicEvaluationSource"
|
|
1489
|
+
},
|
|
1490
|
+
{
|
|
1491
|
+
"type": "null"
|
|
1492
|
+
}
|
|
1493
|
+
]
|
|
1494
|
+
},
|
|
1495
|
+
"description": "Evaluations per part of the targeting that served them: live rules in evaluation order, then deleted rules, then fallthrough, off, prerequisite, error, notFound and unknown."
|
|
1496
|
+
}
|
|
1497
|
+
},
|
|
1498
|
+
"description": "What a flag served in one environment over the window, returned by\n`GET .../flags/{flag}/environments/{env}/evaluations` (#4225). These are evaluation\ncounts, not unique users. They come from SDK-reported events, so an environment whose SDKs\nreport none reads zero: no evaluations reported, not necessarily no traffic. The public\ncounterpart of FlagEvaluationAnalyticsDto, keyed by environment key instead of\nid and without the dashboard's daily series."
|
|
1499
|
+
},
|
|
1252
1500
|
"PublicFlagListItem": {
|
|
1253
1501
|
"type": [
|
|
1254
1502
|
"object",
|
|
@@ -1659,6 +1907,33 @@ declare const _default: {
|
|
|
1659
1907
|
},
|
|
1660
1908
|
"description": "Public detail representation of a feature flag, returned by\n`GET .../flags/{flag}` and the body of a successful create. Drops internal/dashboard-only\nfields present on FeatureFlagDto — notably `ProjectId` (implicit in the\nroute) and `Staleness` (an internal analytics signal, not part of the public contract).\nEffectiveExpiresAtUtc is when the flag counts as past expiry, from its own ExpiresAtUtc\nor its project's default lifetime; ExpirySource says which (`explicit` / `project-default`),\nboth null when neither applies."
|
|
1661
1909
|
},
|
|
1910
|
+
"PublicPlanLimit": {
|
|
1911
|
+
"type": [
|
|
1912
|
+
"object",
|
|
1913
|
+
"null"
|
|
1914
|
+
],
|
|
1915
|
+
"properties": {
|
|
1916
|
+
"resource": {
|
|
1917
|
+
"type": [
|
|
1918
|
+
"string",
|
|
1919
|
+
"null"
|
|
1920
|
+
]
|
|
1921
|
+
},
|
|
1922
|
+
"plan": {
|
|
1923
|
+
"type": [
|
|
1924
|
+
"string",
|
|
1925
|
+
"null"
|
|
1926
|
+
]
|
|
1927
|
+
},
|
|
1928
|
+
"max": {
|
|
1929
|
+
"type": [
|
|
1930
|
+
"integer",
|
|
1931
|
+
"null"
|
|
1932
|
+
]
|
|
1933
|
+
}
|
|
1934
|
+
},
|
|
1935
|
+
"description": "The cap behind a `plan_limit_reached` error. `resource` is the capped collection\n(`projects`, `environments`, `flags`, `webhooks`, `members`);\n`plan` is the plan's wire name, as `GET /api/v1/orgs/{org}` returns it; `max` is\nthe cap. The environment and flag caps are per project."
|
|
1936
|
+
},
|
|
1662
1937
|
"PublicPrerequisiteDto": {
|
|
1663
1938
|
"type": [
|
|
1664
1939
|
"object",
|
|
@@ -1726,6 +2001,67 @@ declare const _default: {
|
|
|
1726
2001
|
},
|
|
1727
2002
|
"description": "Request body for `PUT .../rules/reorder`. Must include every existing rule id exactly\nonce — `ReorderTargetingRulesCommandHandler` rejects duplicate, omitted, or unknown rule\nids with `BadRequestException`, surfaced as an HTTP 400 `bad_request` envelope\ncarrying the handler's message."
|
|
1728
2003
|
},
|
|
2004
|
+
"PublicRolloutCheck": {
|
|
2005
|
+
"type": [
|
|
2006
|
+
"object",
|
|
2007
|
+
"null"
|
|
2008
|
+
],
|
|
2009
|
+
"properties": {
|
|
2010
|
+
"configured": {
|
|
2011
|
+
"type": [
|
|
2012
|
+
"array",
|
|
2013
|
+
"null"
|
|
2014
|
+
],
|
|
2015
|
+
"items": {
|
|
2016
|
+
"anyOf": [
|
|
2017
|
+
{
|
|
2018
|
+
"$ref": "#/$defs/PublicConfiguredWeight"
|
|
2019
|
+
},
|
|
2020
|
+
{
|
|
2021
|
+
"type": "null"
|
|
2022
|
+
}
|
|
2023
|
+
]
|
|
2024
|
+
},
|
|
2025
|
+
"description": "The configured weights, in percent; they sum to 100."
|
|
2026
|
+
},
|
|
2027
|
+
"splitChangedAtUtc": {
|
|
2028
|
+
"type": [
|
|
2029
|
+
"string",
|
|
2030
|
+
"null"
|
|
2031
|
+
],
|
|
2032
|
+
"description": "The last time the split may have changed (the rule was edited, or a variation was added), or null if it hasn't since the rule was created. A change inside the window mixes two splits."
|
|
2033
|
+
},
|
|
2034
|
+
"evaluable": {
|
|
2035
|
+
"type": [
|
|
2036
|
+
"boolean",
|
|
2037
|
+
"null"
|
|
2038
|
+
],
|
|
2039
|
+
"description": "Whether the check could run. See NotEvaluableReason when false."
|
|
2040
|
+
},
|
|
2041
|
+
"pValue": {
|
|
2042
|
+
"type": [
|
|
2043
|
+
"number",
|
|
2044
|
+
"null"
|
|
2045
|
+
],
|
|
2046
|
+
"description": "The sample-ratio test's p-value, or null when not evaluable."
|
|
2047
|
+
},
|
|
2048
|
+
"flagged": {
|
|
2049
|
+
"type": [
|
|
2050
|
+
"boolean",
|
|
2051
|
+
"null"
|
|
2052
|
+
],
|
|
2053
|
+
"description": "True only when the served split is both unlikely under the configured weights (p < 0.001) and at least 2 percentage points off for some variation."
|
|
2054
|
+
},
|
|
2055
|
+
"notEvaluableReason": {
|
|
2056
|
+
"type": [
|
|
2057
|
+
"string",
|
|
2058
|
+
"null"
|
|
2059
|
+
],
|
|
2060
|
+
"description": "too-little-traffic or unexpected-variation when the check couldn't run; null otherwise. Allowed values: too-little-traffic, unexpected-variation."
|
|
2061
|
+
}
|
|
2062
|
+
},
|
|
2063
|
+
"description": "A percentage-rollout rule's configured split beside a sample-ratio check of what it served."
|
|
2064
|
+
},
|
|
1729
2065
|
"PublicRotateWebhookSecretResponse": {
|
|
1730
2066
|
"type": [
|
|
1731
2067
|
"object",
|
package/dist/index.mjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export { o as ApiError, s as FeatureflipApi, c as PKG_VERSION, a as createServer, r as loadConfig, t as resolveOrg } from "./org-
|
|
1
|
+
export { o as ApiError, s as FeatureflipApi, c as PKG_VERSION, a as createServer, r as loadConfig, t as resolveOrg } from "./org-C6HAk06Q.js";
|