@boboddy/sdk 0.4.3 → 0.5.1
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/boboddy-config-parser.js +2 -2
- package/dist/client.js +20 -43
- package/dist/contracts/artifacts.js +948 -948
- package/dist/defaults/index.js +11 -11
- package/dist/definitions/advancement-policies/define-advancement-policy.d.ts +30 -5
- package/dist/definitions/advancement-policies/index.js +21 -11
- package/dist/definitions/pipelines/bindings.d.ts +62 -0
- package/dist/definitions/pipelines/builder-helpers.d.ts +19 -106
- package/dist/definitions/pipelines/chain-graph.d.ts +15 -14
- package/dist/definitions/pipelines/compile-node-definitions.d.ts +27 -0
- package/dist/definitions/pipelines/define-pipeline.d.ts +101 -154
- package/dist/definitions/pipelines/index.d.ts +0 -2
- package/dist/definitions/pipelines/index.js +1457 -1602
- package/dist/definitions/pipelines/node-input-ctx.d.ts +31 -0
- package/dist/definitions/pipelines/pipeline-definitions-client.d.ts +18 -4
- package/dist/definitions/pipelines/pipeline-states.d.ts +104 -0
- package/dist/definitions/steps/define-code-step.d.ts +50 -0
- package/dist/definitions/steps/define-step.d.ts +22 -1
- package/dist/definitions/steps/index.d.ts +1 -0
- package/dist/definitions/steps/index.js +13782 -13765
- package/dist/definitions/steps/step-definitions-client.d.ts +29 -5
- package/dist/definitions/validation/index.js +15152 -98
- package/dist/definitions/validation/validate-definition-specs.d.ts +19 -1
- package/dist/generated/index.d.ts +1 -1
- package/dist/generated/sdk.gen.d.ts +1 -4
- package/dist/generated/types.gen.d.ts +296 -878
- package/dist/health-checks.js +950 -950
- package/dist/index.js +1624 -1729
- package/dist/jsonc.js +2 -2
- package/dist/opencode-mcp.js +946 -946
- package/dist/opencode-plugin.js +950 -950
- package/dist/push/collect-definitions.d.ts +40 -1
- package/dist/push/index.d.ts +2 -2
- package/dist/push/index.js +14595 -14545
- package/dist/step-execution-plane-client.d.ts +9 -4
- package/package.json +2 -2
- package/dist/definitions/pipelines/builder.d.ts +0 -80
- package/dist/definitions/pipelines/fan-out-builder.d.ts +0 -66
- package/dist/definitions/pipelines/input-accessor.d.ts +0 -25
package/dist/index.js
CHANGED
|
@@ -1093,29 +1093,6 @@ class PipelineDefinitions extends HeyApiClient {
|
|
|
1093
1093
|
unarchivePipelineDefinition(options) {
|
|
1094
1094
|
return (options.client ?? this.client).put({ url: "/api/pipeline-definitions/{pipelineDefinitionId}/unarchive", ...options });
|
|
1095
1095
|
}
|
|
1096
|
-
addPipelineStep(options) {
|
|
1097
|
-
return (options.client ?? this.client).post({
|
|
1098
|
-
url: "/api/pipeline-definitions/{pipelineDefinitionId}/steps",
|
|
1099
|
-
...options,
|
|
1100
|
-
headers: {
|
|
1101
|
-
"Content-Type": "application/json",
|
|
1102
|
-
...options.headers
|
|
1103
|
-
}
|
|
1104
|
-
});
|
|
1105
|
-
}
|
|
1106
|
-
removePipelineStep(options) {
|
|
1107
|
-
return (options.client ?? this.client).delete({ url: "/api/pipeline-definitions/{pipelineDefinitionId}/steps/{pipelineStepDefinitionId}", ...options });
|
|
1108
|
-
}
|
|
1109
|
-
updatePipelineStep(options) {
|
|
1110
|
-
return (options.client ?? this.client).put({
|
|
1111
|
-
url: "/api/pipeline-definitions/{pipelineDefinitionId}/steps/{pipelineStepDefinitionId}",
|
|
1112
|
-
...options,
|
|
1113
|
-
headers: {
|
|
1114
|
-
"Content-Type": "application/json",
|
|
1115
|
-
...options.headers
|
|
1116
|
-
}
|
|
1117
|
-
});
|
|
1118
|
-
}
|
|
1119
1096
|
setPipelineStepAdvancementPolicy(options) {
|
|
1120
1097
|
return (options.client ?? this.client).put({
|
|
1121
1098
|
url: "/api/pipeline-definitions/{pipelineDefinitionId}/steps/{pipelineStepDefinitionId}/advancement-policy",
|
|
@@ -1738,523 +1715,523 @@ function createBoboddyClient(baseUrl) {
|
|
|
1738
1715
|
// ../../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/classic/external.js
|
|
1739
1716
|
var exports_external = {};
|
|
1740
1717
|
__export(exports_external, {
|
|
1741
|
-
|
|
1742
|
-
xid: () => xid2,
|
|
1743
|
-
void: () => _void2,
|
|
1744
|
-
uuidv7: () => uuidv7,
|
|
1745
|
-
uuidv6: () => uuidv6,
|
|
1746
|
-
uuidv4: () => uuidv4,
|
|
1747
|
-
uuid: () => uuid2,
|
|
1748
|
-
util: () => exports_util,
|
|
1749
|
-
url: () => url,
|
|
1750
|
-
uppercase: () => _uppercase,
|
|
1751
|
-
unknown: () => unknown,
|
|
1752
|
-
union: () => union,
|
|
1753
|
-
undefined: () => _undefined3,
|
|
1754
|
-
ulid: () => ulid2,
|
|
1755
|
-
uint64: () => uint64,
|
|
1756
|
-
uint32: () => uint32,
|
|
1757
|
-
tuple: () => tuple,
|
|
1758
|
-
trim: () => _trim,
|
|
1759
|
-
treeifyError: () => treeifyError,
|
|
1760
|
-
transform: () => transform,
|
|
1761
|
-
toUpperCase: () => _toUpperCase,
|
|
1762
|
-
toLowerCase: () => _toLowerCase,
|
|
1763
|
-
toJSONSchema: () => toJSONSchema,
|
|
1764
|
-
templateLiteral: () => templateLiteral,
|
|
1765
|
-
symbol: () => symbol,
|
|
1766
|
-
superRefine: () => superRefine,
|
|
1767
|
-
success: () => success,
|
|
1768
|
-
stringbool: () => stringbool,
|
|
1769
|
-
stringFormat: () => stringFormat,
|
|
1770
|
-
string: () => string2,
|
|
1771
|
-
strictObject: () => strictObject,
|
|
1772
|
-
startsWith: () => _startsWith,
|
|
1773
|
-
slugify: () => _slugify,
|
|
1774
|
-
size: () => _size,
|
|
1775
|
-
setErrorMap: () => setErrorMap,
|
|
1776
|
-
set: () => set,
|
|
1777
|
-
safeParseAsync: () => safeParseAsync2,
|
|
1778
|
-
safeParse: () => safeParse2,
|
|
1779
|
-
safeEncodeAsync: () => safeEncodeAsync2,
|
|
1780
|
-
safeEncode: () => safeEncode2,
|
|
1781
|
-
safeDecodeAsync: () => safeDecodeAsync2,
|
|
1782
|
-
safeDecode: () => safeDecode2,
|
|
1783
|
-
registry: () => registry,
|
|
1784
|
-
regexes: () => exports_regexes,
|
|
1785
|
-
regex: () => _regex,
|
|
1786
|
-
refine: () => refine,
|
|
1787
|
-
record: () => record,
|
|
1788
|
-
readonly: () => readonly,
|
|
1789
|
-
property: () => _property,
|
|
1790
|
-
promise: () => promise,
|
|
1791
|
-
prettifyError: () => prettifyError,
|
|
1792
|
-
preprocess: () => preprocess,
|
|
1793
|
-
prefault: () => prefault,
|
|
1794
|
-
positive: () => _positive,
|
|
1795
|
-
pipe: () => pipe,
|
|
1796
|
-
partialRecord: () => partialRecord,
|
|
1797
|
-
parseAsync: () => parseAsync2,
|
|
1798
|
-
parse: () => parse3,
|
|
1799
|
-
overwrite: () => _overwrite,
|
|
1800
|
-
optional: () => optional,
|
|
1801
|
-
object: () => object,
|
|
1802
|
-
number: () => number2,
|
|
1803
|
-
nullish: () => nullish2,
|
|
1804
|
-
nullable: () => nullable,
|
|
1805
|
-
null: () => _null3,
|
|
1806
|
-
normalize: () => _normalize,
|
|
1807
|
-
nonpositive: () => _nonpositive,
|
|
1808
|
-
nonoptional: () => nonoptional,
|
|
1809
|
-
nonnegative: () => _nonnegative,
|
|
1810
|
-
never: () => never,
|
|
1811
|
-
negative: () => _negative,
|
|
1812
|
-
nativeEnum: () => nativeEnum,
|
|
1813
|
-
nanoid: () => nanoid2,
|
|
1814
|
-
nan: () => nan,
|
|
1815
|
-
multipleOf: () => _multipleOf,
|
|
1816
|
-
minSize: () => _minSize,
|
|
1817
|
-
minLength: () => _minLength,
|
|
1818
|
-
mime: () => _mime,
|
|
1819
|
-
meta: () => meta2,
|
|
1820
|
-
maxSize: () => _maxSize,
|
|
1821
|
-
maxLength: () => _maxLength,
|
|
1822
|
-
map: () => map,
|
|
1823
|
-
mac: () => mac2,
|
|
1824
|
-
lte: () => _lte,
|
|
1825
|
-
lt: () => _lt,
|
|
1826
|
-
lowercase: () => _lowercase,
|
|
1827
|
-
looseRecord: () => looseRecord,
|
|
1828
|
-
looseObject: () => looseObject,
|
|
1829
|
-
locales: () => exports_locales,
|
|
1830
|
-
literal: () => literal,
|
|
1831
|
-
length: () => _length,
|
|
1832
|
-
lazy: () => lazy,
|
|
1833
|
-
ksuid: () => ksuid2,
|
|
1834
|
-
keyof: () => keyof,
|
|
1835
|
-
jwt: () => jwt,
|
|
1836
|
-
json: () => json,
|
|
1837
|
-
iso: () => exports_iso,
|
|
1838
|
-
ipv6: () => ipv62,
|
|
1839
|
-
ipv4: () => ipv42,
|
|
1840
|
-
invertCodec: () => invertCodec,
|
|
1841
|
-
intersection: () => intersection,
|
|
1842
|
-
int64: () => int64,
|
|
1843
|
-
int32: () => int32,
|
|
1844
|
-
int: () => int,
|
|
1845
|
-
instanceof: () => _instanceof,
|
|
1846
|
-
includes: () => _includes,
|
|
1847
|
-
httpUrl: () => httpUrl,
|
|
1848
|
-
hostname: () => hostname2,
|
|
1849
|
-
hex: () => hex2,
|
|
1850
|
-
hash: () => hash,
|
|
1851
|
-
guid: () => guid2,
|
|
1852
|
-
gte: () => _gte,
|
|
1853
|
-
gt: () => _gt,
|
|
1854
|
-
globalRegistry: () => globalRegistry,
|
|
1855
|
-
getErrorMap: () => getErrorMap,
|
|
1856
|
-
function: () => _function,
|
|
1857
|
-
fromJSONSchema: () => fromJSONSchema,
|
|
1858
|
-
formatError: () => formatError,
|
|
1859
|
-
float64: () => float64,
|
|
1860
|
-
float32: () => float32,
|
|
1861
|
-
flattenError: () => flattenError,
|
|
1862
|
-
file: () => file,
|
|
1863
|
-
exactOptional: () => exactOptional,
|
|
1864
|
-
enum: () => _enum2,
|
|
1865
|
-
endsWith: () => _endsWith,
|
|
1866
|
-
encodeAsync: () => encodeAsync2,
|
|
1867
|
-
encode: () => encode2,
|
|
1868
|
-
emoji: () => emoji2,
|
|
1869
|
-
email: () => email2,
|
|
1870
|
-
e164: () => e1642,
|
|
1871
|
-
discriminatedUnion: () => discriminatedUnion,
|
|
1872
|
-
describe: () => describe2,
|
|
1873
|
-
decodeAsync: () => decodeAsync2,
|
|
1874
|
-
decode: () => decode2,
|
|
1875
|
-
date: () => date3,
|
|
1876
|
-
custom: () => custom,
|
|
1877
|
-
cuid2: () => cuid22,
|
|
1878
|
-
cuid: () => cuid3,
|
|
1879
|
-
core: () => exports_core2,
|
|
1880
|
-
config: () => config,
|
|
1881
|
-
coerce: () => exports_coerce,
|
|
1882
|
-
codec: () => codec,
|
|
1883
|
-
clone: () => clone,
|
|
1884
|
-
cidrv6: () => cidrv62,
|
|
1885
|
-
cidrv4: () => cidrv42,
|
|
1886
|
-
check: () => check,
|
|
1887
|
-
catch: () => _catch2,
|
|
1888
|
-
boolean: () => boolean2,
|
|
1889
|
-
bigint: () => bigint2,
|
|
1890
|
-
base64url: () => base64url2,
|
|
1891
|
-
base64: () => base642,
|
|
1892
|
-
array: () => array,
|
|
1893
|
-
any: () => any,
|
|
1894
|
-
_function: () => _function,
|
|
1895
|
-
_default: () => _default2,
|
|
1896
|
-
_ZodString: () => _ZodString,
|
|
1897
|
-
ZodXor: () => ZodXor,
|
|
1898
|
-
ZodXID: () => ZodXID,
|
|
1899
|
-
ZodVoid: () => ZodVoid,
|
|
1900
|
-
ZodUnknown: () => ZodUnknown,
|
|
1901
|
-
ZodUnion: () => ZodUnion,
|
|
1902
|
-
ZodUndefined: () => ZodUndefined,
|
|
1903
|
-
ZodUUID: () => ZodUUID,
|
|
1904
|
-
ZodURL: () => ZodURL,
|
|
1905
|
-
ZodULID: () => ZodULID,
|
|
1906
|
-
ZodType: () => ZodType,
|
|
1907
|
-
ZodTuple: () => ZodTuple,
|
|
1908
|
-
ZodTransform: () => ZodTransform,
|
|
1909
|
-
ZodTemplateLiteral: () => ZodTemplateLiteral,
|
|
1910
|
-
ZodSymbol: () => ZodSymbol,
|
|
1911
|
-
ZodSuccess: () => ZodSuccess,
|
|
1912
|
-
ZodStringFormat: () => ZodStringFormat,
|
|
1913
|
-
ZodString: () => ZodString,
|
|
1914
|
-
ZodSet: () => ZodSet,
|
|
1915
|
-
ZodRecord: () => ZodRecord,
|
|
1916
|
-
ZodRealError: () => ZodRealError,
|
|
1917
|
-
ZodReadonly: () => ZodReadonly,
|
|
1918
|
-
ZodPromise: () => ZodPromise,
|
|
1919
|
-
ZodPreprocess: () => ZodPreprocess,
|
|
1920
|
-
ZodPrefault: () => ZodPrefault,
|
|
1921
|
-
ZodPipe: () => ZodPipe,
|
|
1922
|
-
ZodOptional: () => ZodOptional,
|
|
1923
|
-
ZodObject: () => ZodObject,
|
|
1924
|
-
ZodNumberFormat: () => ZodNumberFormat,
|
|
1925
|
-
ZodNumber: () => ZodNumber,
|
|
1926
|
-
ZodNullable: () => ZodNullable,
|
|
1927
|
-
ZodNull: () => ZodNull,
|
|
1928
|
-
ZodNonOptional: () => ZodNonOptional,
|
|
1929
|
-
ZodNever: () => ZodNever,
|
|
1930
|
-
ZodNanoID: () => ZodNanoID,
|
|
1931
|
-
ZodNaN: () => ZodNaN,
|
|
1932
|
-
ZodMap: () => ZodMap,
|
|
1933
|
-
ZodMAC: () => ZodMAC,
|
|
1934
|
-
ZodLiteral: () => ZodLiteral,
|
|
1935
|
-
ZodLazy: () => ZodLazy,
|
|
1936
|
-
ZodKSUID: () => ZodKSUID,
|
|
1937
|
-
ZodJWT: () => ZodJWT,
|
|
1938
|
-
ZodIssueCode: () => ZodIssueCode,
|
|
1939
|
-
ZodIntersection: () => ZodIntersection,
|
|
1940
|
-
ZodISOTime: () => ZodISOTime,
|
|
1941
|
-
ZodISODuration: () => ZodISODuration,
|
|
1942
|
-
ZodISODateTime: () => ZodISODateTime,
|
|
1943
|
-
ZodISODate: () => ZodISODate,
|
|
1944
|
-
ZodIPv6: () => ZodIPv6,
|
|
1945
|
-
ZodIPv4: () => ZodIPv4,
|
|
1946
|
-
ZodGUID: () => ZodGUID,
|
|
1947
|
-
ZodFunction: () => ZodFunction,
|
|
1948
|
-
ZodFirstPartyTypeKind: () => ZodFirstPartyTypeKind,
|
|
1949
|
-
ZodFile: () => ZodFile,
|
|
1950
|
-
ZodExactOptional: () => ZodExactOptional,
|
|
1951
|
-
ZodError: () => ZodError,
|
|
1952
|
-
ZodEnum: () => ZodEnum,
|
|
1953
|
-
ZodEmoji: () => ZodEmoji,
|
|
1954
|
-
ZodEmail: () => ZodEmail,
|
|
1955
|
-
ZodE164: () => ZodE164,
|
|
1956
|
-
ZodDiscriminatedUnion: () => ZodDiscriminatedUnion,
|
|
1957
|
-
ZodDefault: () => ZodDefault,
|
|
1958
|
-
ZodDate: () => ZodDate,
|
|
1959
|
-
ZodCustomStringFormat: () => ZodCustomStringFormat,
|
|
1960
|
-
ZodCustom: () => ZodCustom,
|
|
1961
|
-
ZodCodec: () => ZodCodec,
|
|
1962
|
-
ZodCatch: () => ZodCatch,
|
|
1963
|
-
ZodCUID2: () => ZodCUID2,
|
|
1964
|
-
ZodCUID: () => ZodCUID,
|
|
1965
|
-
ZodCIDRv6: () => ZodCIDRv6,
|
|
1966
|
-
ZodCIDRv4: () => ZodCIDRv4,
|
|
1967
|
-
ZodBoolean: () => ZodBoolean,
|
|
1968
|
-
ZodBigIntFormat: () => ZodBigIntFormat,
|
|
1969
|
-
ZodBigInt: () => ZodBigInt,
|
|
1970
|
-
ZodBase64URL: () => ZodBase64URL,
|
|
1971
|
-
ZodBase64: () => ZodBase64,
|
|
1972
|
-
ZodArray: () => ZodArray,
|
|
1973
|
-
ZodAny: () => ZodAny,
|
|
1974
|
-
TimePrecision: () => TimePrecision,
|
|
1975
|
-
NEVER: () => NEVER,
|
|
1976
|
-
$output: () => $output,
|
|
1718
|
+
$brand: () => $brand,
|
|
1977
1719
|
$input: () => $input,
|
|
1978
|
-
$
|
|
1979
|
-
|
|
1980
|
-
|
|
1981
|
-
|
|
1720
|
+
$output: () => $output,
|
|
1721
|
+
NEVER: () => NEVER,
|
|
1722
|
+
TimePrecision: () => TimePrecision,
|
|
1723
|
+
ZodAny: () => ZodAny,
|
|
1724
|
+
ZodArray: () => ZodArray,
|
|
1725
|
+
ZodBase64: () => ZodBase64,
|
|
1726
|
+
ZodBase64URL: () => ZodBase64URL,
|
|
1727
|
+
ZodBigInt: () => ZodBigInt,
|
|
1728
|
+
ZodBigIntFormat: () => ZodBigIntFormat,
|
|
1729
|
+
ZodBoolean: () => ZodBoolean,
|
|
1730
|
+
ZodCIDRv4: () => ZodCIDRv4,
|
|
1731
|
+
ZodCIDRv6: () => ZodCIDRv6,
|
|
1732
|
+
ZodCUID: () => ZodCUID,
|
|
1733
|
+
ZodCUID2: () => ZodCUID2,
|
|
1734
|
+
ZodCatch: () => ZodCatch,
|
|
1735
|
+
ZodCodec: () => ZodCodec,
|
|
1736
|
+
ZodCustom: () => ZodCustom,
|
|
1737
|
+
ZodCustomStringFormat: () => ZodCustomStringFormat,
|
|
1738
|
+
ZodDate: () => ZodDate,
|
|
1739
|
+
ZodDefault: () => ZodDefault,
|
|
1740
|
+
ZodDiscriminatedUnion: () => ZodDiscriminatedUnion,
|
|
1741
|
+
ZodE164: () => ZodE164,
|
|
1742
|
+
ZodEmail: () => ZodEmail,
|
|
1743
|
+
ZodEmoji: () => ZodEmoji,
|
|
1744
|
+
ZodEnum: () => ZodEnum,
|
|
1745
|
+
ZodError: () => ZodError,
|
|
1746
|
+
ZodExactOptional: () => ZodExactOptional,
|
|
1747
|
+
ZodFile: () => ZodFile,
|
|
1748
|
+
ZodFirstPartyTypeKind: () => ZodFirstPartyTypeKind,
|
|
1749
|
+
ZodFunction: () => ZodFunction,
|
|
1750
|
+
ZodGUID: () => ZodGUID,
|
|
1751
|
+
ZodIPv4: () => ZodIPv4,
|
|
1752
|
+
ZodIPv6: () => ZodIPv6,
|
|
1753
|
+
ZodISODate: () => ZodISODate,
|
|
1754
|
+
ZodISODateTime: () => ZodISODateTime,
|
|
1755
|
+
ZodISODuration: () => ZodISODuration,
|
|
1756
|
+
ZodISOTime: () => ZodISOTime,
|
|
1757
|
+
ZodIntersection: () => ZodIntersection,
|
|
1758
|
+
ZodIssueCode: () => ZodIssueCode,
|
|
1759
|
+
ZodJWT: () => ZodJWT,
|
|
1760
|
+
ZodKSUID: () => ZodKSUID,
|
|
1761
|
+
ZodLazy: () => ZodLazy,
|
|
1762
|
+
ZodLiteral: () => ZodLiteral,
|
|
1763
|
+
ZodMAC: () => ZodMAC,
|
|
1764
|
+
ZodMap: () => ZodMap,
|
|
1765
|
+
ZodNaN: () => ZodNaN,
|
|
1766
|
+
ZodNanoID: () => ZodNanoID,
|
|
1767
|
+
ZodNever: () => ZodNever,
|
|
1768
|
+
ZodNonOptional: () => ZodNonOptional,
|
|
1769
|
+
ZodNull: () => ZodNull,
|
|
1770
|
+
ZodNullable: () => ZodNullable,
|
|
1771
|
+
ZodNumber: () => ZodNumber,
|
|
1772
|
+
ZodNumberFormat: () => ZodNumberFormat,
|
|
1773
|
+
ZodObject: () => ZodObject,
|
|
1774
|
+
ZodOptional: () => ZodOptional,
|
|
1775
|
+
ZodPipe: () => ZodPipe,
|
|
1776
|
+
ZodPrefault: () => ZodPrefault,
|
|
1777
|
+
ZodPreprocess: () => ZodPreprocess,
|
|
1778
|
+
ZodPromise: () => ZodPromise,
|
|
1779
|
+
ZodReadonly: () => ZodReadonly,
|
|
1780
|
+
ZodRealError: () => ZodRealError,
|
|
1781
|
+
ZodRecord: () => ZodRecord,
|
|
1782
|
+
ZodSet: () => ZodSet,
|
|
1783
|
+
ZodString: () => ZodString,
|
|
1784
|
+
ZodStringFormat: () => ZodStringFormat,
|
|
1785
|
+
ZodSuccess: () => ZodSuccess,
|
|
1786
|
+
ZodSymbol: () => ZodSymbol,
|
|
1787
|
+
ZodTemplateLiteral: () => ZodTemplateLiteral,
|
|
1788
|
+
ZodTransform: () => ZodTransform,
|
|
1789
|
+
ZodTuple: () => ZodTuple,
|
|
1790
|
+
ZodType: () => ZodType,
|
|
1791
|
+
ZodULID: () => ZodULID,
|
|
1792
|
+
ZodURL: () => ZodURL,
|
|
1793
|
+
ZodUUID: () => ZodUUID,
|
|
1794
|
+
ZodUndefined: () => ZodUndefined,
|
|
1795
|
+
ZodUnion: () => ZodUnion,
|
|
1796
|
+
ZodUnknown: () => ZodUnknown,
|
|
1797
|
+
ZodVoid: () => ZodVoid,
|
|
1798
|
+
ZodXID: () => ZodXID,
|
|
1799
|
+
ZodXor: () => ZodXor,
|
|
1800
|
+
_ZodString: () => _ZodString,
|
|
1801
|
+
_default: () => _default2,
|
|
1802
|
+
_function: () => _function,
|
|
1803
|
+
any: () => any,
|
|
1804
|
+
array: () => array,
|
|
1805
|
+
base64: () => base642,
|
|
1806
|
+
base64url: () => base64url2,
|
|
1807
|
+
bigint: () => bigint2,
|
|
1808
|
+
boolean: () => boolean2,
|
|
1809
|
+
catch: () => _catch2,
|
|
1810
|
+
check: () => check,
|
|
1811
|
+
cidrv4: () => cidrv42,
|
|
1812
|
+
cidrv6: () => cidrv62,
|
|
1813
|
+
clone: () => clone,
|
|
1814
|
+
codec: () => codec,
|
|
1815
|
+
coerce: () => exports_coerce,
|
|
1816
|
+
config: () => config,
|
|
1817
|
+
core: () => exports_core2,
|
|
1818
|
+
cuid: () => cuid3,
|
|
1819
|
+
cuid2: () => cuid22,
|
|
1820
|
+
custom: () => custom,
|
|
1821
|
+
date: () => date3,
|
|
1822
|
+
decode: () => decode2,
|
|
1823
|
+
decodeAsync: () => decodeAsync2,
|
|
1824
|
+
describe: () => describe2,
|
|
1825
|
+
discriminatedUnion: () => discriminatedUnion,
|
|
1826
|
+
e164: () => e1642,
|
|
1827
|
+
email: () => email2,
|
|
1828
|
+
emoji: () => emoji2,
|
|
1829
|
+
encode: () => encode2,
|
|
1830
|
+
encodeAsync: () => encodeAsync2,
|
|
1831
|
+
endsWith: () => _endsWith,
|
|
1832
|
+
enum: () => _enum2,
|
|
1833
|
+
exactOptional: () => exactOptional,
|
|
1834
|
+
file: () => file,
|
|
1835
|
+
flattenError: () => flattenError,
|
|
1836
|
+
float32: () => float32,
|
|
1837
|
+
float64: () => float64,
|
|
1838
|
+
formatError: () => formatError,
|
|
1839
|
+
fromJSONSchema: () => fromJSONSchema,
|
|
1840
|
+
function: () => _function,
|
|
1841
|
+
getErrorMap: () => getErrorMap,
|
|
1842
|
+
globalRegistry: () => globalRegistry,
|
|
1843
|
+
gt: () => _gt,
|
|
1844
|
+
gte: () => _gte,
|
|
1845
|
+
guid: () => guid2,
|
|
1846
|
+
hash: () => hash,
|
|
1847
|
+
hex: () => hex2,
|
|
1848
|
+
hostname: () => hostname2,
|
|
1849
|
+
httpUrl: () => httpUrl,
|
|
1850
|
+
includes: () => _includes,
|
|
1851
|
+
instanceof: () => _instanceof,
|
|
1852
|
+
int: () => int,
|
|
1853
|
+
int32: () => int32,
|
|
1854
|
+
int64: () => int64,
|
|
1855
|
+
intersection: () => intersection,
|
|
1856
|
+
invertCodec: () => invertCodec,
|
|
1857
|
+
ipv4: () => ipv42,
|
|
1858
|
+
ipv6: () => ipv62,
|
|
1859
|
+
iso: () => exports_iso,
|
|
1860
|
+
json: () => json,
|
|
1861
|
+
jwt: () => jwt,
|
|
1862
|
+
keyof: () => keyof,
|
|
1863
|
+
ksuid: () => ksuid2,
|
|
1864
|
+
lazy: () => lazy,
|
|
1865
|
+
length: () => _length,
|
|
1866
|
+
literal: () => literal,
|
|
1867
|
+
locales: () => exports_locales,
|
|
1868
|
+
looseObject: () => looseObject,
|
|
1869
|
+
looseRecord: () => looseRecord,
|
|
1870
|
+
lowercase: () => _lowercase,
|
|
1871
|
+
lt: () => _lt,
|
|
1872
|
+
lte: () => _lte,
|
|
1873
|
+
mac: () => mac2,
|
|
1874
|
+
map: () => map,
|
|
1875
|
+
maxLength: () => _maxLength,
|
|
1876
|
+
maxSize: () => _maxSize,
|
|
1877
|
+
meta: () => meta2,
|
|
1878
|
+
mime: () => _mime,
|
|
1879
|
+
minLength: () => _minLength,
|
|
1880
|
+
minSize: () => _minSize,
|
|
1881
|
+
multipleOf: () => _multipleOf,
|
|
1882
|
+
nan: () => nan,
|
|
1883
|
+
nanoid: () => nanoid2,
|
|
1884
|
+
nativeEnum: () => nativeEnum,
|
|
1885
|
+
negative: () => _negative,
|
|
1886
|
+
never: () => never,
|
|
1887
|
+
nonnegative: () => _nonnegative,
|
|
1888
|
+
nonoptional: () => nonoptional,
|
|
1889
|
+
nonpositive: () => _nonpositive,
|
|
1890
|
+
normalize: () => _normalize,
|
|
1891
|
+
null: () => _null3,
|
|
1892
|
+
nullable: () => nullable,
|
|
1893
|
+
nullish: () => nullish2,
|
|
1894
|
+
number: () => number2,
|
|
1895
|
+
object: () => object,
|
|
1896
|
+
optional: () => optional,
|
|
1897
|
+
overwrite: () => _overwrite,
|
|
1898
|
+
parse: () => parse3,
|
|
1899
|
+
parseAsync: () => parseAsync2,
|
|
1900
|
+
partialRecord: () => partialRecord,
|
|
1901
|
+
pipe: () => pipe,
|
|
1902
|
+
positive: () => _positive,
|
|
1903
|
+
prefault: () => prefault,
|
|
1904
|
+
preprocess: () => preprocess,
|
|
1905
|
+
prettifyError: () => prettifyError,
|
|
1906
|
+
promise: () => promise,
|
|
1907
|
+
property: () => _property,
|
|
1908
|
+
readonly: () => readonly,
|
|
1909
|
+
record: () => record,
|
|
1910
|
+
refine: () => refine,
|
|
1911
|
+
regex: () => _regex,
|
|
1912
|
+
regexes: () => exports_regexes,
|
|
1913
|
+
registry: () => registry,
|
|
1914
|
+
safeDecode: () => safeDecode2,
|
|
1915
|
+
safeDecodeAsync: () => safeDecodeAsync2,
|
|
1916
|
+
safeEncode: () => safeEncode2,
|
|
1917
|
+
safeEncodeAsync: () => safeEncodeAsync2,
|
|
1918
|
+
safeParse: () => safeParse2,
|
|
1919
|
+
safeParseAsync: () => safeParseAsync2,
|
|
1920
|
+
set: () => set,
|
|
1921
|
+
setErrorMap: () => setErrorMap,
|
|
1922
|
+
size: () => _size,
|
|
1923
|
+
slugify: () => _slugify,
|
|
1924
|
+
startsWith: () => _startsWith,
|
|
1925
|
+
strictObject: () => strictObject,
|
|
1926
|
+
string: () => string2,
|
|
1927
|
+
stringFormat: () => stringFormat,
|
|
1928
|
+
stringbool: () => stringbool,
|
|
1929
|
+
success: () => success,
|
|
1930
|
+
superRefine: () => superRefine,
|
|
1931
|
+
symbol: () => symbol,
|
|
1932
|
+
templateLiteral: () => templateLiteral,
|
|
1933
|
+
toJSONSchema: () => toJSONSchema,
|
|
1934
|
+
toLowerCase: () => _toLowerCase,
|
|
1935
|
+
toUpperCase: () => _toUpperCase,
|
|
1936
|
+
transform: () => transform,
|
|
1937
|
+
treeifyError: () => treeifyError,
|
|
1938
|
+
trim: () => _trim,
|
|
1939
|
+
tuple: () => tuple,
|
|
1940
|
+
uint32: () => uint32,
|
|
1941
|
+
uint64: () => uint64,
|
|
1942
|
+
ulid: () => ulid2,
|
|
1943
|
+
undefined: () => _undefined3,
|
|
1944
|
+
union: () => union,
|
|
1945
|
+
unknown: () => unknown,
|
|
1946
|
+
uppercase: () => _uppercase,
|
|
1947
|
+
url: () => url,
|
|
1948
|
+
util: () => exports_util,
|
|
1949
|
+
uuid: () => uuid2,
|
|
1950
|
+
uuidv4: () => uuidv4,
|
|
1951
|
+
uuidv6: () => uuidv6,
|
|
1952
|
+
uuidv7: () => uuidv7,
|
|
1953
|
+
void: () => _void2,
|
|
1954
|
+
xid: () => xid2,
|
|
1955
|
+
xor: () => xor
|
|
1956
|
+
});
|
|
1957
|
+
|
|
1958
|
+
// ../../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/core/index.js
|
|
1982
1959
|
var exports_core2 = {};
|
|
1983
1960
|
__export(exports_core2, {
|
|
1984
|
-
|
|
1985
|
-
util: () => exports_util,
|
|
1986
|
-
treeifyError: () => treeifyError,
|
|
1987
|
-
toJSONSchema: () => toJSONSchema,
|
|
1988
|
-
toDotPath: () => toDotPath,
|
|
1989
|
-
safeParseAsync: () => safeParseAsync,
|
|
1990
|
-
safeParse: () => safeParse,
|
|
1991
|
-
safeEncodeAsync: () => safeEncodeAsync,
|
|
1992
|
-
safeEncode: () => safeEncode,
|
|
1993
|
-
safeDecodeAsync: () => safeDecodeAsync,
|
|
1994
|
-
safeDecode: () => safeDecode,
|
|
1995
|
-
registry: () => registry,
|
|
1996
|
-
regexes: () => exports_regexes,
|
|
1997
|
-
process: () => process,
|
|
1998
|
-
prettifyError: () => prettifyError,
|
|
1999
|
-
parseAsync: () => parseAsync,
|
|
2000
|
-
parse: () => parse,
|
|
2001
|
-
meta: () => meta,
|
|
2002
|
-
locales: () => exports_locales,
|
|
2003
|
-
isValidJWT: () => isValidJWT,
|
|
2004
|
-
isValidBase64URL: () => isValidBase64URL,
|
|
2005
|
-
isValidBase64: () => isValidBase64,
|
|
2006
|
-
initializeContext: () => initializeContext,
|
|
2007
|
-
globalRegistry: () => globalRegistry,
|
|
2008
|
-
globalConfig: () => globalConfig,
|
|
2009
|
-
formatError: () => formatError,
|
|
2010
|
-
flattenError: () => flattenError,
|
|
2011
|
-
finalize: () => finalize,
|
|
2012
|
-
extractDefs: () => extractDefs,
|
|
2013
|
-
encodeAsync: () => encodeAsync,
|
|
2014
|
-
encode: () => encode,
|
|
2015
|
-
describe: () => describe,
|
|
2016
|
-
decodeAsync: () => decodeAsync,
|
|
2017
|
-
decode: () => decode,
|
|
2018
|
-
createToJSONSchemaMethod: () => createToJSONSchemaMethod,
|
|
2019
|
-
createStandardJSONSchemaMethod: () => createStandardJSONSchemaMethod,
|
|
2020
|
-
config: () => config,
|
|
2021
|
-
clone: () => clone,
|
|
2022
|
-
_xor: () => _xor,
|
|
2023
|
-
_xid: () => _xid,
|
|
2024
|
-
_void: () => _void,
|
|
2025
|
-
_uuidv7: () => _uuidv7,
|
|
2026
|
-
_uuidv6: () => _uuidv6,
|
|
2027
|
-
_uuidv4: () => _uuidv4,
|
|
2028
|
-
_uuid: () => _uuid,
|
|
2029
|
-
_url: () => _url,
|
|
2030
|
-
_uppercase: () => _uppercase,
|
|
2031
|
-
_unknown: () => _unknown,
|
|
2032
|
-
_union: () => _union,
|
|
2033
|
-
_undefined: () => _undefined2,
|
|
2034
|
-
_ulid: () => _ulid,
|
|
2035
|
-
_uint64: () => _uint64,
|
|
2036
|
-
_uint32: () => _uint32,
|
|
2037
|
-
_tuple: () => _tuple,
|
|
2038
|
-
_trim: () => _trim,
|
|
2039
|
-
_transform: () => _transform,
|
|
2040
|
-
_toUpperCase: () => _toUpperCase,
|
|
2041
|
-
_toLowerCase: () => _toLowerCase,
|
|
2042
|
-
_templateLiteral: () => _templateLiteral,
|
|
2043
|
-
_symbol: () => _symbol,
|
|
2044
|
-
_superRefine: () => _superRefine,
|
|
2045
|
-
_success: () => _success,
|
|
2046
|
-
_stringbool: () => _stringbool,
|
|
2047
|
-
_stringFormat: () => _stringFormat,
|
|
2048
|
-
_string: () => _string,
|
|
2049
|
-
_startsWith: () => _startsWith,
|
|
2050
|
-
_slugify: () => _slugify,
|
|
2051
|
-
_size: () => _size,
|
|
2052
|
-
_set: () => _set,
|
|
2053
|
-
_safeParseAsync: () => _safeParseAsync,
|
|
2054
|
-
_safeParse: () => _safeParse,
|
|
2055
|
-
_safeEncodeAsync: () => _safeEncodeAsync,
|
|
2056
|
-
_safeEncode: () => _safeEncode,
|
|
2057
|
-
_safeDecodeAsync: () => _safeDecodeAsync,
|
|
2058
|
-
_safeDecode: () => _safeDecode,
|
|
2059
|
-
_regex: () => _regex,
|
|
2060
|
-
_refine: () => _refine,
|
|
2061
|
-
_record: () => _record,
|
|
2062
|
-
_readonly: () => _readonly,
|
|
2063
|
-
_property: () => _property,
|
|
2064
|
-
_promise: () => _promise,
|
|
2065
|
-
_positive: () => _positive,
|
|
2066
|
-
_pipe: () => _pipe,
|
|
2067
|
-
_parseAsync: () => _parseAsync,
|
|
2068
|
-
_parse: () => _parse,
|
|
2069
|
-
_overwrite: () => _overwrite,
|
|
2070
|
-
_optional: () => _optional,
|
|
2071
|
-
_number: () => _number,
|
|
2072
|
-
_nullable: () => _nullable,
|
|
2073
|
-
_null: () => _null2,
|
|
2074
|
-
_normalize: () => _normalize,
|
|
2075
|
-
_nonpositive: () => _nonpositive,
|
|
2076
|
-
_nonoptional: () => _nonoptional,
|
|
2077
|
-
_nonnegative: () => _nonnegative,
|
|
2078
|
-
_never: () => _never,
|
|
2079
|
-
_negative: () => _negative,
|
|
2080
|
-
_nativeEnum: () => _nativeEnum,
|
|
2081
|
-
_nanoid: () => _nanoid,
|
|
2082
|
-
_nan: () => _nan,
|
|
2083
|
-
_multipleOf: () => _multipleOf,
|
|
2084
|
-
_minSize: () => _minSize,
|
|
2085
|
-
_minLength: () => _minLength,
|
|
2086
|
-
_min: () => _gte,
|
|
2087
|
-
_mime: () => _mime,
|
|
2088
|
-
_maxSize: () => _maxSize,
|
|
2089
|
-
_maxLength: () => _maxLength,
|
|
2090
|
-
_max: () => _lte,
|
|
2091
|
-
_map: () => _map,
|
|
2092
|
-
_mac: () => _mac,
|
|
2093
|
-
_lte: () => _lte,
|
|
2094
|
-
_lt: () => _lt,
|
|
2095
|
-
_lowercase: () => _lowercase,
|
|
2096
|
-
_literal: () => _literal,
|
|
2097
|
-
_length: () => _length,
|
|
2098
|
-
_lazy: () => _lazy,
|
|
2099
|
-
_ksuid: () => _ksuid,
|
|
2100
|
-
_jwt: () => _jwt,
|
|
2101
|
-
_isoTime: () => _isoTime,
|
|
2102
|
-
_isoDuration: () => _isoDuration,
|
|
2103
|
-
_isoDateTime: () => _isoDateTime,
|
|
2104
|
-
_isoDate: () => _isoDate,
|
|
2105
|
-
_ipv6: () => _ipv6,
|
|
2106
|
-
_ipv4: () => _ipv4,
|
|
2107
|
-
_intersection: () => _intersection,
|
|
2108
|
-
_int64: () => _int64,
|
|
2109
|
-
_int32: () => _int32,
|
|
2110
|
-
_int: () => _int,
|
|
2111
|
-
_includes: () => _includes,
|
|
2112
|
-
_guid: () => _guid,
|
|
2113
|
-
_gte: () => _gte,
|
|
2114
|
-
_gt: () => _gt,
|
|
2115
|
-
_float64: () => _float64,
|
|
2116
|
-
_float32: () => _float32,
|
|
2117
|
-
_file: () => _file,
|
|
2118
|
-
_enum: () => _enum,
|
|
2119
|
-
_endsWith: () => _endsWith,
|
|
2120
|
-
_encodeAsync: () => _encodeAsync,
|
|
2121
|
-
_encode: () => _encode,
|
|
2122
|
-
_emoji: () => _emoji2,
|
|
2123
|
-
_email: () => _email,
|
|
2124
|
-
_e164: () => _e164,
|
|
2125
|
-
_discriminatedUnion: () => _discriminatedUnion,
|
|
2126
|
-
_default: () => _default,
|
|
2127
|
-
_decodeAsync: () => _decodeAsync,
|
|
2128
|
-
_decode: () => _decode,
|
|
2129
|
-
_date: () => _date,
|
|
2130
|
-
_custom: () => _custom,
|
|
2131
|
-
_cuid2: () => _cuid2,
|
|
2132
|
-
_cuid: () => _cuid,
|
|
2133
|
-
_coercedString: () => _coercedString,
|
|
2134
|
-
_coercedNumber: () => _coercedNumber,
|
|
2135
|
-
_coercedDate: () => _coercedDate,
|
|
2136
|
-
_coercedBoolean: () => _coercedBoolean,
|
|
2137
|
-
_coercedBigint: () => _coercedBigint,
|
|
2138
|
-
_cidrv6: () => _cidrv6,
|
|
2139
|
-
_cidrv4: () => _cidrv4,
|
|
2140
|
-
_check: () => _check,
|
|
2141
|
-
_catch: () => _catch,
|
|
2142
|
-
_boolean: () => _boolean,
|
|
2143
|
-
_bigint: () => _bigint,
|
|
2144
|
-
_base64url: () => _base64url,
|
|
2145
|
-
_base64: () => _base64,
|
|
2146
|
-
_array: () => _array,
|
|
2147
|
-
_any: () => _any,
|
|
2148
|
-
TimePrecision: () => TimePrecision,
|
|
2149
|
-
NEVER: () => NEVER,
|
|
2150
|
-
JSONSchemaGenerator: () => JSONSchemaGenerator,
|
|
2151
|
-
JSONSchema: () => exports_json_schema,
|
|
2152
|
-
Doc: () => Doc,
|
|
2153
|
-
$output: () => $output,
|
|
2154
|
-
$input: () => $input,
|
|
2155
|
-
$constructor: () => $constructor,
|
|
2156
|
-
$brand: () => $brand,
|
|
2157
|
-
$ZodXor: () => $ZodXor,
|
|
2158
|
-
$ZodXID: () => $ZodXID,
|
|
2159
|
-
$ZodVoid: () => $ZodVoid,
|
|
2160
|
-
$ZodUnknown: () => $ZodUnknown,
|
|
2161
|
-
$ZodUnion: () => $ZodUnion,
|
|
2162
|
-
$ZodUndefined: () => $ZodUndefined,
|
|
2163
|
-
$ZodUUID: () => $ZodUUID,
|
|
2164
|
-
$ZodURL: () => $ZodURL,
|
|
2165
|
-
$ZodULID: () => $ZodULID,
|
|
2166
|
-
$ZodType: () => $ZodType,
|
|
2167
|
-
$ZodTuple: () => $ZodTuple,
|
|
2168
|
-
$ZodTransform: () => $ZodTransform,
|
|
2169
|
-
$ZodTemplateLiteral: () => $ZodTemplateLiteral,
|
|
2170
|
-
$ZodSymbol: () => $ZodSymbol,
|
|
2171
|
-
$ZodSuccess: () => $ZodSuccess,
|
|
2172
|
-
$ZodStringFormat: () => $ZodStringFormat,
|
|
2173
|
-
$ZodString: () => $ZodString,
|
|
2174
|
-
$ZodSet: () => $ZodSet,
|
|
2175
|
-
$ZodRegistry: () => $ZodRegistry,
|
|
2176
|
-
$ZodRecord: () => $ZodRecord,
|
|
2177
|
-
$ZodRealError: () => $ZodRealError,
|
|
2178
|
-
$ZodReadonly: () => $ZodReadonly,
|
|
2179
|
-
$ZodPromise: () => $ZodPromise,
|
|
2180
|
-
$ZodPreprocess: () => $ZodPreprocess,
|
|
2181
|
-
$ZodPrefault: () => $ZodPrefault,
|
|
2182
|
-
$ZodPipe: () => $ZodPipe,
|
|
2183
|
-
$ZodOptional: () => $ZodOptional,
|
|
2184
|
-
$ZodObjectJIT: () => $ZodObjectJIT,
|
|
2185
|
-
$ZodObject: () => $ZodObject,
|
|
2186
|
-
$ZodNumberFormat: () => $ZodNumberFormat,
|
|
2187
|
-
$ZodNumber: () => $ZodNumber,
|
|
2188
|
-
$ZodNullable: () => $ZodNullable,
|
|
2189
|
-
$ZodNull: () => $ZodNull,
|
|
2190
|
-
$ZodNonOptional: () => $ZodNonOptional,
|
|
2191
|
-
$ZodNever: () => $ZodNever,
|
|
2192
|
-
$ZodNanoID: () => $ZodNanoID,
|
|
2193
|
-
$ZodNaN: () => $ZodNaN,
|
|
2194
|
-
$ZodMap: () => $ZodMap,
|
|
2195
|
-
$ZodMAC: () => $ZodMAC,
|
|
2196
|
-
$ZodLiteral: () => $ZodLiteral,
|
|
2197
|
-
$ZodLazy: () => $ZodLazy,
|
|
2198
|
-
$ZodKSUID: () => $ZodKSUID,
|
|
2199
|
-
$ZodJWT: () => $ZodJWT,
|
|
2200
|
-
$ZodIntersection: () => $ZodIntersection,
|
|
2201
|
-
$ZodISOTime: () => $ZodISOTime,
|
|
2202
|
-
$ZodISODuration: () => $ZodISODuration,
|
|
2203
|
-
$ZodISODateTime: () => $ZodISODateTime,
|
|
2204
|
-
$ZodISODate: () => $ZodISODate,
|
|
2205
|
-
$ZodIPv6: () => $ZodIPv6,
|
|
2206
|
-
$ZodIPv4: () => $ZodIPv4,
|
|
2207
|
-
$ZodGUID: () => $ZodGUID,
|
|
2208
|
-
$ZodFunction: () => $ZodFunction,
|
|
2209
|
-
$ZodFile: () => $ZodFile,
|
|
2210
|
-
$ZodExactOptional: () => $ZodExactOptional,
|
|
2211
|
-
$ZodError: () => $ZodError,
|
|
2212
|
-
$ZodEnum: () => $ZodEnum,
|
|
2213
|
-
$ZodEncodeError: () => $ZodEncodeError,
|
|
2214
|
-
$ZodEmoji: () => $ZodEmoji,
|
|
2215
|
-
$ZodEmail: () => $ZodEmail,
|
|
2216
|
-
$ZodE164: () => $ZodE164,
|
|
2217
|
-
$ZodDiscriminatedUnion: () => $ZodDiscriminatedUnion,
|
|
2218
|
-
$ZodDefault: () => $ZodDefault,
|
|
2219
|
-
$ZodDate: () => $ZodDate,
|
|
2220
|
-
$ZodCustomStringFormat: () => $ZodCustomStringFormat,
|
|
2221
|
-
$ZodCustom: () => $ZodCustom,
|
|
2222
|
-
$ZodCodec: () => $ZodCodec,
|
|
2223
|
-
$ZodCheckUpperCase: () => $ZodCheckUpperCase,
|
|
2224
|
-
$ZodCheckStringFormat: () => $ZodCheckStringFormat,
|
|
2225
|
-
$ZodCheckStartsWith: () => $ZodCheckStartsWith,
|
|
2226
|
-
$ZodCheckSizeEquals: () => $ZodCheckSizeEquals,
|
|
2227
|
-
$ZodCheckRegex: () => $ZodCheckRegex,
|
|
2228
|
-
$ZodCheckProperty: () => $ZodCheckProperty,
|
|
2229
|
-
$ZodCheckOverwrite: () => $ZodCheckOverwrite,
|
|
2230
|
-
$ZodCheckNumberFormat: () => $ZodCheckNumberFormat,
|
|
2231
|
-
$ZodCheckMultipleOf: () => $ZodCheckMultipleOf,
|
|
2232
|
-
$ZodCheckMinSize: () => $ZodCheckMinSize,
|
|
2233
|
-
$ZodCheckMinLength: () => $ZodCheckMinLength,
|
|
2234
|
-
$ZodCheckMimeType: () => $ZodCheckMimeType,
|
|
2235
|
-
$ZodCheckMaxSize: () => $ZodCheckMaxSize,
|
|
2236
|
-
$ZodCheckMaxLength: () => $ZodCheckMaxLength,
|
|
2237
|
-
$ZodCheckLowerCase: () => $ZodCheckLowerCase,
|
|
2238
|
-
$ZodCheckLessThan: () => $ZodCheckLessThan,
|
|
2239
|
-
$ZodCheckLengthEquals: () => $ZodCheckLengthEquals,
|
|
2240
|
-
$ZodCheckIncludes: () => $ZodCheckIncludes,
|
|
2241
|
-
$ZodCheckGreaterThan: () => $ZodCheckGreaterThan,
|
|
2242
|
-
$ZodCheckEndsWith: () => $ZodCheckEndsWith,
|
|
2243
|
-
$ZodCheckBigIntFormat: () => $ZodCheckBigIntFormat,
|
|
2244
|
-
$ZodCheck: () => $ZodCheck,
|
|
2245
|
-
$ZodCatch: () => $ZodCatch,
|
|
2246
|
-
$ZodCUID2: () => $ZodCUID2,
|
|
2247
|
-
$ZodCUID: () => $ZodCUID,
|
|
2248
|
-
$ZodCIDRv6: () => $ZodCIDRv6,
|
|
2249
|
-
$ZodCIDRv4: () => $ZodCIDRv4,
|
|
2250
|
-
$ZodBoolean: () => $ZodBoolean,
|
|
2251
|
-
$ZodBigIntFormat: () => $ZodBigIntFormat,
|
|
2252
|
-
$ZodBigInt: () => $ZodBigInt,
|
|
2253
|
-
$ZodBase64URL: () => $ZodBase64URL,
|
|
2254
|
-
$ZodBase64: () => $ZodBase64,
|
|
2255
|
-
$ZodAsyncError: () => $ZodAsyncError,
|
|
1961
|
+
$ZodAny: () => $ZodAny,
|
|
2256
1962
|
$ZodArray: () => $ZodArray,
|
|
2257
|
-
$
|
|
1963
|
+
$ZodAsyncError: () => $ZodAsyncError,
|
|
1964
|
+
$ZodBase64: () => $ZodBase64,
|
|
1965
|
+
$ZodBase64URL: () => $ZodBase64URL,
|
|
1966
|
+
$ZodBigInt: () => $ZodBigInt,
|
|
1967
|
+
$ZodBigIntFormat: () => $ZodBigIntFormat,
|
|
1968
|
+
$ZodBoolean: () => $ZodBoolean,
|
|
1969
|
+
$ZodCIDRv4: () => $ZodCIDRv4,
|
|
1970
|
+
$ZodCIDRv6: () => $ZodCIDRv6,
|
|
1971
|
+
$ZodCUID: () => $ZodCUID,
|
|
1972
|
+
$ZodCUID2: () => $ZodCUID2,
|
|
1973
|
+
$ZodCatch: () => $ZodCatch,
|
|
1974
|
+
$ZodCheck: () => $ZodCheck,
|
|
1975
|
+
$ZodCheckBigIntFormat: () => $ZodCheckBigIntFormat,
|
|
1976
|
+
$ZodCheckEndsWith: () => $ZodCheckEndsWith,
|
|
1977
|
+
$ZodCheckGreaterThan: () => $ZodCheckGreaterThan,
|
|
1978
|
+
$ZodCheckIncludes: () => $ZodCheckIncludes,
|
|
1979
|
+
$ZodCheckLengthEquals: () => $ZodCheckLengthEquals,
|
|
1980
|
+
$ZodCheckLessThan: () => $ZodCheckLessThan,
|
|
1981
|
+
$ZodCheckLowerCase: () => $ZodCheckLowerCase,
|
|
1982
|
+
$ZodCheckMaxLength: () => $ZodCheckMaxLength,
|
|
1983
|
+
$ZodCheckMaxSize: () => $ZodCheckMaxSize,
|
|
1984
|
+
$ZodCheckMimeType: () => $ZodCheckMimeType,
|
|
1985
|
+
$ZodCheckMinLength: () => $ZodCheckMinLength,
|
|
1986
|
+
$ZodCheckMinSize: () => $ZodCheckMinSize,
|
|
1987
|
+
$ZodCheckMultipleOf: () => $ZodCheckMultipleOf,
|
|
1988
|
+
$ZodCheckNumberFormat: () => $ZodCheckNumberFormat,
|
|
1989
|
+
$ZodCheckOverwrite: () => $ZodCheckOverwrite,
|
|
1990
|
+
$ZodCheckProperty: () => $ZodCheckProperty,
|
|
1991
|
+
$ZodCheckRegex: () => $ZodCheckRegex,
|
|
1992
|
+
$ZodCheckSizeEquals: () => $ZodCheckSizeEquals,
|
|
1993
|
+
$ZodCheckStartsWith: () => $ZodCheckStartsWith,
|
|
1994
|
+
$ZodCheckStringFormat: () => $ZodCheckStringFormat,
|
|
1995
|
+
$ZodCheckUpperCase: () => $ZodCheckUpperCase,
|
|
1996
|
+
$ZodCodec: () => $ZodCodec,
|
|
1997
|
+
$ZodCustom: () => $ZodCustom,
|
|
1998
|
+
$ZodCustomStringFormat: () => $ZodCustomStringFormat,
|
|
1999
|
+
$ZodDate: () => $ZodDate,
|
|
2000
|
+
$ZodDefault: () => $ZodDefault,
|
|
2001
|
+
$ZodDiscriminatedUnion: () => $ZodDiscriminatedUnion,
|
|
2002
|
+
$ZodE164: () => $ZodE164,
|
|
2003
|
+
$ZodEmail: () => $ZodEmail,
|
|
2004
|
+
$ZodEmoji: () => $ZodEmoji,
|
|
2005
|
+
$ZodEncodeError: () => $ZodEncodeError,
|
|
2006
|
+
$ZodEnum: () => $ZodEnum,
|
|
2007
|
+
$ZodError: () => $ZodError,
|
|
2008
|
+
$ZodExactOptional: () => $ZodExactOptional,
|
|
2009
|
+
$ZodFile: () => $ZodFile,
|
|
2010
|
+
$ZodFunction: () => $ZodFunction,
|
|
2011
|
+
$ZodGUID: () => $ZodGUID,
|
|
2012
|
+
$ZodIPv4: () => $ZodIPv4,
|
|
2013
|
+
$ZodIPv6: () => $ZodIPv6,
|
|
2014
|
+
$ZodISODate: () => $ZodISODate,
|
|
2015
|
+
$ZodISODateTime: () => $ZodISODateTime,
|
|
2016
|
+
$ZodISODuration: () => $ZodISODuration,
|
|
2017
|
+
$ZodISOTime: () => $ZodISOTime,
|
|
2018
|
+
$ZodIntersection: () => $ZodIntersection,
|
|
2019
|
+
$ZodJWT: () => $ZodJWT,
|
|
2020
|
+
$ZodKSUID: () => $ZodKSUID,
|
|
2021
|
+
$ZodLazy: () => $ZodLazy,
|
|
2022
|
+
$ZodLiteral: () => $ZodLiteral,
|
|
2023
|
+
$ZodMAC: () => $ZodMAC,
|
|
2024
|
+
$ZodMap: () => $ZodMap,
|
|
2025
|
+
$ZodNaN: () => $ZodNaN,
|
|
2026
|
+
$ZodNanoID: () => $ZodNanoID,
|
|
2027
|
+
$ZodNever: () => $ZodNever,
|
|
2028
|
+
$ZodNonOptional: () => $ZodNonOptional,
|
|
2029
|
+
$ZodNull: () => $ZodNull,
|
|
2030
|
+
$ZodNullable: () => $ZodNullable,
|
|
2031
|
+
$ZodNumber: () => $ZodNumber,
|
|
2032
|
+
$ZodNumberFormat: () => $ZodNumberFormat,
|
|
2033
|
+
$ZodObject: () => $ZodObject,
|
|
2034
|
+
$ZodObjectJIT: () => $ZodObjectJIT,
|
|
2035
|
+
$ZodOptional: () => $ZodOptional,
|
|
2036
|
+
$ZodPipe: () => $ZodPipe,
|
|
2037
|
+
$ZodPrefault: () => $ZodPrefault,
|
|
2038
|
+
$ZodPreprocess: () => $ZodPreprocess,
|
|
2039
|
+
$ZodPromise: () => $ZodPromise,
|
|
2040
|
+
$ZodReadonly: () => $ZodReadonly,
|
|
2041
|
+
$ZodRealError: () => $ZodRealError,
|
|
2042
|
+
$ZodRecord: () => $ZodRecord,
|
|
2043
|
+
$ZodRegistry: () => $ZodRegistry,
|
|
2044
|
+
$ZodSet: () => $ZodSet,
|
|
2045
|
+
$ZodString: () => $ZodString,
|
|
2046
|
+
$ZodStringFormat: () => $ZodStringFormat,
|
|
2047
|
+
$ZodSuccess: () => $ZodSuccess,
|
|
2048
|
+
$ZodSymbol: () => $ZodSymbol,
|
|
2049
|
+
$ZodTemplateLiteral: () => $ZodTemplateLiteral,
|
|
2050
|
+
$ZodTransform: () => $ZodTransform,
|
|
2051
|
+
$ZodTuple: () => $ZodTuple,
|
|
2052
|
+
$ZodType: () => $ZodType,
|
|
2053
|
+
$ZodULID: () => $ZodULID,
|
|
2054
|
+
$ZodURL: () => $ZodURL,
|
|
2055
|
+
$ZodUUID: () => $ZodUUID,
|
|
2056
|
+
$ZodUndefined: () => $ZodUndefined,
|
|
2057
|
+
$ZodUnion: () => $ZodUnion,
|
|
2058
|
+
$ZodUnknown: () => $ZodUnknown,
|
|
2059
|
+
$ZodVoid: () => $ZodVoid,
|
|
2060
|
+
$ZodXID: () => $ZodXID,
|
|
2061
|
+
$ZodXor: () => $ZodXor,
|
|
2062
|
+
$brand: () => $brand,
|
|
2063
|
+
$constructor: () => $constructor,
|
|
2064
|
+
$input: () => $input,
|
|
2065
|
+
$output: () => $output,
|
|
2066
|
+
Doc: () => Doc,
|
|
2067
|
+
JSONSchema: () => exports_json_schema,
|
|
2068
|
+
JSONSchemaGenerator: () => JSONSchemaGenerator,
|
|
2069
|
+
NEVER: () => NEVER,
|
|
2070
|
+
TimePrecision: () => TimePrecision,
|
|
2071
|
+
_any: () => _any,
|
|
2072
|
+
_array: () => _array,
|
|
2073
|
+
_base64: () => _base64,
|
|
2074
|
+
_base64url: () => _base64url,
|
|
2075
|
+
_bigint: () => _bigint,
|
|
2076
|
+
_boolean: () => _boolean,
|
|
2077
|
+
_catch: () => _catch,
|
|
2078
|
+
_check: () => _check,
|
|
2079
|
+
_cidrv4: () => _cidrv4,
|
|
2080
|
+
_cidrv6: () => _cidrv6,
|
|
2081
|
+
_coercedBigint: () => _coercedBigint,
|
|
2082
|
+
_coercedBoolean: () => _coercedBoolean,
|
|
2083
|
+
_coercedDate: () => _coercedDate,
|
|
2084
|
+
_coercedNumber: () => _coercedNumber,
|
|
2085
|
+
_coercedString: () => _coercedString,
|
|
2086
|
+
_cuid: () => _cuid,
|
|
2087
|
+
_cuid2: () => _cuid2,
|
|
2088
|
+
_custom: () => _custom,
|
|
2089
|
+
_date: () => _date,
|
|
2090
|
+
_decode: () => _decode,
|
|
2091
|
+
_decodeAsync: () => _decodeAsync,
|
|
2092
|
+
_default: () => _default,
|
|
2093
|
+
_discriminatedUnion: () => _discriminatedUnion,
|
|
2094
|
+
_e164: () => _e164,
|
|
2095
|
+
_email: () => _email,
|
|
2096
|
+
_emoji: () => _emoji2,
|
|
2097
|
+
_encode: () => _encode,
|
|
2098
|
+
_encodeAsync: () => _encodeAsync,
|
|
2099
|
+
_endsWith: () => _endsWith,
|
|
2100
|
+
_enum: () => _enum,
|
|
2101
|
+
_file: () => _file,
|
|
2102
|
+
_float32: () => _float32,
|
|
2103
|
+
_float64: () => _float64,
|
|
2104
|
+
_gt: () => _gt,
|
|
2105
|
+
_gte: () => _gte,
|
|
2106
|
+
_guid: () => _guid,
|
|
2107
|
+
_includes: () => _includes,
|
|
2108
|
+
_int: () => _int,
|
|
2109
|
+
_int32: () => _int32,
|
|
2110
|
+
_int64: () => _int64,
|
|
2111
|
+
_intersection: () => _intersection,
|
|
2112
|
+
_ipv4: () => _ipv4,
|
|
2113
|
+
_ipv6: () => _ipv6,
|
|
2114
|
+
_isoDate: () => _isoDate,
|
|
2115
|
+
_isoDateTime: () => _isoDateTime,
|
|
2116
|
+
_isoDuration: () => _isoDuration,
|
|
2117
|
+
_isoTime: () => _isoTime,
|
|
2118
|
+
_jwt: () => _jwt,
|
|
2119
|
+
_ksuid: () => _ksuid,
|
|
2120
|
+
_lazy: () => _lazy,
|
|
2121
|
+
_length: () => _length,
|
|
2122
|
+
_literal: () => _literal,
|
|
2123
|
+
_lowercase: () => _lowercase,
|
|
2124
|
+
_lt: () => _lt,
|
|
2125
|
+
_lte: () => _lte,
|
|
2126
|
+
_mac: () => _mac,
|
|
2127
|
+
_map: () => _map,
|
|
2128
|
+
_max: () => _lte,
|
|
2129
|
+
_maxLength: () => _maxLength,
|
|
2130
|
+
_maxSize: () => _maxSize,
|
|
2131
|
+
_mime: () => _mime,
|
|
2132
|
+
_min: () => _gte,
|
|
2133
|
+
_minLength: () => _minLength,
|
|
2134
|
+
_minSize: () => _minSize,
|
|
2135
|
+
_multipleOf: () => _multipleOf,
|
|
2136
|
+
_nan: () => _nan,
|
|
2137
|
+
_nanoid: () => _nanoid,
|
|
2138
|
+
_nativeEnum: () => _nativeEnum,
|
|
2139
|
+
_negative: () => _negative,
|
|
2140
|
+
_never: () => _never,
|
|
2141
|
+
_nonnegative: () => _nonnegative,
|
|
2142
|
+
_nonoptional: () => _nonoptional,
|
|
2143
|
+
_nonpositive: () => _nonpositive,
|
|
2144
|
+
_normalize: () => _normalize,
|
|
2145
|
+
_null: () => _null2,
|
|
2146
|
+
_nullable: () => _nullable,
|
|
2147
|
+
_number: () => _number,
|
|
2148
|
+
_optional: () => _optional,
|
|
2149
|
+
_overwrite: () => _overwrite,
|
|
2150
|
+
_parse: () => _parse,
|
|
2151
|
+
_parseAsync: () => _parseAsync,
|
|
2152
|
+
_pipe: () => _pipe,
|
|
2153
|
+
_positive: () => _positive,
|
|
2154
|
+
_promise: () => _promise,
|
|
2155
|
+
_property: () => _property,
|
|
2156
|
+
_readonly: () => _readonly,
|
|
2157
|
+
_record: () => _record,
|
|
2158
|
+
_refine: () => _refine,
|
|
2159
|
+
_regex: () => _regex,
|
|
2160
|
+
_safeDecode: () => _safeDecode,
|
|
2161
|
+
_safeDecodeAsync: () => _safeDecodeAsync,
|
|
2162
|
+
_safeEncode: () => _safeEncode,
|
|
2163
|
+
_safeEncodeAsync: () => _safeEncodeAsync,
|
|
2164
|
+
_safeParse: () => _safeParse,
|
|
2165
|
+
_safeParseAsync: () => _safeParseAsync,
|
|
2166
|
+
_set: () => _set,
|
|
2167
|
+
_size: () => _size,
|
|
2168
|
+
_slugify: () => _slugify,
|
|
2169
|
+
_startsWith: () => _startsWith,
|
|
2170
|
+
_string: () => _string,
|
|
2171
|
+
_stringFormat: () => _stringFormat,
|
|
2172
|
+
_stringbool: () => _stringbool,
|
|
2173
|
+
_success: () => _success,
|
|
2174
|
+
_superRefine: () => _superRefine,
|
|
2175
|
+
_symbol: () => _symbol,
|
|
2176
|
+
_templateLiteral: () => _templateLiteral,
|
|
2177
|
+
_toLowerCase: () => _toLowerCase,
|
|
2178
|
+
_toUpperCase: () => _toUpperCase,
|
|
2179
|
+
_transform: () => _transform,
|
|
2180
|
+
_trim: () => _trim,
|
|
2181
|
+
_tuple: () => _tuple,
|
|
2182
|
+
_uint32: () => _uint32,
|
|
2183
|
+
_uint64: () => _uint64,
|
|
2184
|
+
_ulid: () => _ulid,
|
|
2185
|
+
_undefined: () => _undefined2,
|
|
2186
|
+
_union: () => _union,
|
|
2187
|
+
_unknown: () => _unknown,
|
|
2188
|
+
_uppercase: () => _uppercase,
|
|
2189
|
+
_url: () => _url,
|
|
2190
|
+
_uuid: () => _uuid,
|
|
2191
|
+
_uuidv4: () => _uuidv4,
|
|
2192
|
+
_uuidv6: () => _uuidv6,
|
|
2193
|
+
_uuidv7: () => _uuidv7,
|
|
2194
|
+
_void: () => _void,
|
|
2195
|
+
_xid: () => _xid,
|
|
2196
|
+
_xor: () => _xor,
|
|
2197
|
+
clone: () => clone,
|
|
2198
|
+
config: () => config,
|
|
2199
|
+
createStandardJSONSchemaMethod: () => createStandardJSONSchemaMethod,
|
|
2200
|
+
createToJSONSchemaMethod: () => createToJSONSchemaMethod,
|
|
2201
|
+
decode: () => decode,
|
|
2202
|
+
decodeAsync: () => decodeAsync,
|
|
2203
|
+
describe: () => describe,
|
|
2204
|
+
encode: () => encode,
|
|
2205
|
+
encodeAsync: () => encodeAsync,
|
|
2206
|
+
extractDefs: () => extractDefs,
|
|
2207
|
+
finalize: () => finalize,
|
|
2208
|
+
flattenError: () => flattenError,
|
|
2209
|
+
formatError: () => formatError,
|
|
2210
|
+
globalConfig: () => globalConfig,
|
|
2211
|
+
globalRegistry: () => globalRegistry,
|
|
2212
|
+
initializeContext: () => initializeContext,
|
|
2213
|
+
isValidBase64: () => isValidBase64,
|
|
2214
|
+
isValidBase64URL: () => isValidBase64URL,
|
|
2215
|
+
isValidJWT: () => isValidJWT,
|
|
2216
|
+
locales: () => exports_locales,
|
|
2217
|
+
meta: () => meta,
|
|
2218
|
+
parse: () => parse,
|
|
2219
|
+
parseAsync: () => parseAsync,
|
|
2220
|
+
prettifyError: () => prettifyError,
|
|
2221
|
+
process: () => process,
|
|
2222
|
+
regexes: () => exports_regexes,
|
|
2223
|
+
registry: () => registry,
|
|
2224
|
+
safeDecode: () => safeDecode,
|
|
2225
|
+
safeDecodeAsync: () => safeDecodeAsync,
|
|
2226
|
+
safeEncode: () => safeEncode,
|
|
2227
|
+
safeEncodeAsync: () => safeEncodeAsync,
|
|
2228
|
+
safeParse: () => safeParse,
|
|
2229
|
+
safeParseAsync: () => safeParseAsync,
|
|
2230
|
+
toDotPath: () => toDotPath,
|
|
2231
|
+
toJSONSchema: () => toJSONSchema,
|
|
2232
|
+
treeifyError: () => treeifyError,
|
|
2233
|
+
util: () => exports_util,
|
|
2234
|
+
version: () => version
|
|
2258
2235
|
});
|
|
2259
2236
|
|
|
2260
2237
|
// ../../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/core/core.js
|
|
@@ -2308,99 +2285,99 @@ function $constructor(name, initializer, params) {
|
|
|
2308
2285
|
value: (inst) => {
|
|
2309
2286
|
if (params?.Parent && inst instanceof params.Parent)
|
|
2310
2287
|
return true;
|
|
2311
|
-
return inst?._zod?.traits?.has(name);
|
|
2312
|
-
}
|
|
2313
|
-
});
|
|
2314
|
-
Object.defineProperty(_, "name", { value: name });
|
|
2315
|
-
return _;
|
|
2316
|
-
}
|
|
2317
|
-
var $brand = Symbol("zod_brand");
|
|
2318
|
-
|
|
2319
|
-
class $ZodAsyncError extends Error {
|
|
2320
|
-
constructor() {
|
|
2321
|
-
super(`Encountered Promise during synchronous parse. Use .parseAsync() instead.`);
|
|
2322
|
-
}
|
|
2323
|
-
}
|
|
2324
|
-
|
|
2325
|
-
class $ZodEncodeError extends Error {
|
|
2326
|
-
constructor(name) {
|
|
2327
|
-
super(`Encountered unidirectional transform during encode: ${name}`);
|
|
2328
|
-
this.name = "ZodEncodeError";
|
|
2329
|
-
}
|
|
2330
|
-
}
|
|
2331
|
-
(_a = globalThis).__zod_globalConfig ?? (_a.__zod_globalConfig = {});
|
|
2332
|
-
var globalConfig = globalThis.__zod_globalConfig;
|
|
2333
|
-
function config(newConfig) {
|
|
2334
|
-
if (newConfig)
|
|
2335
|
-
Object.assign(globalConfig, newConfig);
|
|
2336
|
-
return globalConfig;
|
|
2337
|
-
}
|
|
2338
|
-
// ../../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/core/util.js
|
|
2339
|
-
var exports_util = {};
|
|
2340
|
-
__export(exports_util, {
|
|
2341
|
-
|
|
2342
|
-
uint8ArrayToHex: () => uint8ArrayToHex,
|
|
2343
|
-
uint8ArrayToBase64url: () => uint8ArrayToBase64url,
|
|
2344
|
-
uint8ArrayToBase64: () => uint8ArrayToBase64,
|
|
2345
|
-
stringifyPrimitive: () => stringifyPrimitive,
|
|
2346
|
-
slugify: () => slugify,
|
|
2347
|
-
shallowClone: () => shallowClone,
|
|
2348
|
-
safeExtend: () => safeExtend,
|
|
2349
|
-
required: () => required,
|
|
2350
|
-
randomString: () => randomString,
|
|
2351
|
-
propertyKeyTypes: () => propertyKeyTypes,
|
|
2352
|
-
promiseAllObject: () => promiseAllObject,
|
|
2353
|
-
primitiveTypes: () => primitiveTypes,
|
|
2354
|
-
prefixIssues: () => prefixIssues,
|
|
2355
|
-
pick: () => pick,
|
|
2356
|
-
partial: () => partial,
|
|
2357
|
-
parsedType: () => parsedType,
|
|
2358
|
-
optionalKeys: () => optionalKeys,
|
|
2359
|
-
omit: () => omit,
|
|
2360
|
-
objectClone: () => objectClone,
|
|
2361
|
-
numKeys: () => numKeys,
|
|
2362
|
-
nullish: () => nullish,
|
|
2363
|
-
normalizeParams: () => normalizeParams,
|
|
2364
|
-
mergeDefs: () => mergeDefs,
|
|
2365
|
-
merge: () => merge,
|
|
2366
|
-
jsonStringifyReplacer: () => jsonStringifyReplacer,
|
|
2367
|
-
joinValues: () => joinValues,
|
|
2368
|
-
issue: () => issue,
|
|
2369
|
-
isPlainObject: () => isPlainObject,
|
|
2370
|
-
isObject: () => isObject,
|
|
2371
|
-
hexToUint8Array: () => hexToUint8Array,
|
|
2372
|
-
getSizableOrigin: () => getSizableOrigin,
|
|
2373
|
-
getParsedType: () => getParsedType,
|
|
2374
|
-
getLengthableOrigin: () => getLengthableOrigin,
|
|
2375
|
-
getEnumValues: () => getEnumValues,
|
|
2376
|
-
getElementAtPath: () => getElementAtPath,
|
|
2377
|
-
floatSafeRemainder: () => floatSafeRemainder,
|
|
2378
|
-
finalizeIssue: () => finalizeIssue,
|
|
2379
|
-
extend: () => extend,
|
|
2380
|
-
explicitlyAborted: () => explicitlyAborted,
|
|
2381
|
-
escapeRegex: () => escapeRegex,
|
|
2382
|
-
esc: () => esc,
|
|
2383
|
-
defineLazy: () => defineLazy,
|
|
2384
|
-
createTransparentProxy: () => createTransparentProxy,
|
|
2385
|
-
cloneDef: () => cloneDef,
|
|
2386
|
-
clone: () => clone,
|
|
2387
|
-
cleanRegex: () => cleanRegex,
|
|
2388
|
-
cleanEnum: () => cleanEnum,
|
|
2389
|
-
captureStackTrace: () => captureStackTrace,
|
|
2390
|
-
cached: () => cached,
|
|
2391
|
-
base64urlToUint8Array: () => base64urlToUint8Array,
|
|
2392
|
-
base64ToUint8Array: () => base64ToUint8Array,
|
|
2393
|
-
assignProp: () => assignProp,
|
|
2394
|
-
assertNotEqual: () => assertNotEqual,
|
|
2395
|
-
assertNever: () => assertNever,
|
|
2396
|
-
assertIs: () => assertIs,
|
|
2397
|
-
assertEqual: () => assertEqual,
|
|
2398
|
-
assert: () => assert,
|
|
2399
|
-
allowsEval: () => allowsEval,
|
|
2400
|
-
aborted: () => aborted,
|
|
2401
|
-
NUMBER_FORMAT_RANGES: () => NUMBER_FORMAT_RANGES,
|
|
2288
|
+
return inst?._zod?.traits?.has(name);
|
|
2289
|
+
}
|
|
2290
|
+
});
|
|
2291
|
+
Object.defineProperty(_, "name", { value: name });
|
|
2292
|
+
return _;
|
|
2293
|
+
}
|
|
2294
|
+
var $brand = Symbol("zod_brand");
|
|
2295
|
+
|
|
2296
|
+
class $ZodAsyncError extends Error {
|
|
2297
|
+
constructor() {
|
|
2298
|
+
super(`Encountered Promise during synchronous parse. Use .parseAsync() instead.`);
|
|
2299
|
+
}
|
|
2300
|
+
}
|
|
2301
|
+
|
|
2302
|
+
class $ZodEncodeError extends Error {
|
|
2303
|
+
constructor(name) {
|
|
2304
|
+
super(`Encountered unidirectional transform during encode: ${name}`);
|
|
2305
|
+
this.name = "ZodEncodeError";
|
|
2306
|
+
}
|
|
2307
|
+
}
|
|
2308
|
+
(_a = globalThis).__zod_globalConfig ?? (_a.__zod_globalConfig = {});
|
|
2309
|
+
var globalConfig = globalThis.__zod_globalConfig;
|
|
2310
|
+
function config(newConfig) {
|
|
2311
|
+
if (newConfig)
|
|
2312
|
+
Object.assign(globalConfig, newConfig);
|
|
2313
|
+
return globalConfig;
|
|
2314
|
+
}
|
|
2315
|
+
// ../../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/core/util.js
|
|
2316
|
+
var exports_util = {};
|
|
2317
|
+
__export(exports_util, {
|
|
2318
|
+
BIGINT_FORMAT_RANGES: () => BIGINT_FORMAT_RANGES,
|
|
2402
2319
|
Class: () => Class,
|
|
2403
|
-
|
|
2320
|
+
NUMBER_FORMAT_RANGES: () => NUMBER_FORMAT_RANGES,
|
|
2321
|
+
aborted: () => aborted,
|
|
2322
|
+
allowsEval: () => allowsEval,
|
|
2323
|
+
assert: () => assert,
|
|
2324
|
+
assertEqual: () => assertEqual,
|
|
2325
|
+
assertIs: () => assertIs,
|
|
2326
|
+
assertNever: () => assertNever,
|
|
2327
|
+
assertNotEqual: () => assertNotEqual,
|
|
2328
|
+
assignProp: () => assignProp,
|
|
2329
|
+
base64ToUint8Array: () => base64ToUint8Array,
|
|
2330
|
+
base64urlToUint8Array: () => base64urlToUint8Array,
|
|
2331
|
+
cached: () => cached,
|
|
2332
|
+
captureStackTrace: () => captureStackTrace,
|
|
2333
|
+
cleanEnum: () => cleanEnum,
|
|
2334
|
+
cleanRegex: () => cleanRegex,
|
|
2335
|
+
clone: () => clone,
|
|
2336
|
+
cloneDef: () => cloneDef,
|
|
2337
|
+
createTransparentProxy: () => createTransparentProxy,
|
|
2338
|
+
defineLazy: () => defineLazy,
|
|
2339
|
+
esc: () => esc,
|
|
2340
|
+
escapeRegex: () => escapeRegex,
|
|
2341
|
+
explicitlyAborted: () => explicitlyAborted,
|
|
2342
|
+
extend: () => extend,
|
|
2343
|
+
finalizeIssue: () => finalizeIssue,
|
|
2344
|
+
floatSafeRemainder: () => floatSafeRemainder,
|
|
2345
|
+
getElementAtPath: () => getElementAtPath,
|
|
2346
|
+
getEnumValues: () => getEnumValues,
|
|
2347
|
+
getLengthableOrigin: () => getLengthableOrigin,
|
|
2348
|
+
getParsedType: () => getParsedType,
|
|
2349
|
+
getSizableOrigin: () => getSizableOrigin,
|
|
2350
|
+
hexToUint8Array: () => hexToUint8Array,
|
|
2351
|
+
isObject: () => isObject,
|
|
2352
|
+
isPlainObject: () => isPlainObject,
|
|
2353
|
+
issue: () => issue,
|
|
2354
|
+
joinValues: () => joinValues,
|
|
2355
|
+
jsonStringifyReplacer: () => jsonStringifyReplacer,
|
|
2356
|
+
merge: () => merge,
|
|
2357
|
+
mergeDefs: () => mergeDefs,
|
|
2358
|
+
normalizeParams: () => normalizeParams,
|
|
2359
|
+
nullish: () => nullish,
|
|
2360
|
+
numKeys: () => numKeys,
|
|
2361
|
+
objectClone: () => objectClone,
|
|
2362
|
+
omit: () => omit,
|
|
2363
|
+
optionalKeys: () => optionalKeys,
|
|
2364
|
+
parsedType: () => parsedType,
|
|
2365
|
+
partial: () => partial,
|
|
2366
|
+
pick: () => pick,
|
|
2367
|
+
prefixIssues: () => prefixIssues,
|
|
2368
|
+
primitiveTypes: () => primitiveTypes,
|
|
2369
|
+
promiseAllObject: () => promiseAllObject,
|
|
2370
|
+
propertyKeyTypes: () => propertyKeyTypes,
|
|
2371
|
+
randomString: () => randomString,
|
|
2372
|
+
required: () => required,
|
|
2373
|
+
safeExtend: () => safeExtend,
|
|
2374
|
+
shallowClone: () => shallowClone,
|
|
2375
|
+
slugify: () => slugify,
|
|
2376
|
+
stringifyPrimitive: () => stringifyPrimitive,
|
|
2377
|
+
uint8ArrayToBase64: () => uint8ArrayToBase64,
|
|
2378
|
+
uint8ArrayToBase64url: () => uint8ArrayToBase64url,
|
|
2379
|
+
uint8ArrayToHex: () => uint8ArrayToHex,
|
|
2380
|
+
unwrapMessage: () => unwrapMessage
|
|
2404
2381
|
});
|
|
2405
2382
|
function assertEqual(val) {
|
|
2406
2383
|
return val;
|
|
@@ -3257,65 +3234,65 @@ var safeDecodeAsync = /* @__PURE__ */ _safeDecodeAsync($ZodRealError);
|
|
|
3257
3234
|
// ../../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/core/regexes.js
|
|
3258
3235
|
var exports_regexes = {};
|
|
3259
3236
|
__export(exports_regexes, {
|
|
3260
|
-
|
|
3261
|
-
uuid7: () => uuid7,
|
|
3262
|
-
uuid6: () => uuid6,
|
|
3263
|
-
uuid4: () => uuid4,
|
|
3264
|
-
uuid: () => uuid,
|
|
3265
|
-
uppercase: () => uppercase,
|
|
3266
|
-
unicodeEmail: () => unicodeEmail,
|
|
3267
|
-
undefined: () => _undefined,
|
|
3268
|
-
ulid: () => ulid,
|
|
3269
|
-
time: () => time,
|
|
3270
|
-
string: () => string,
|
|
3271
|
-
sha512_hex: () => sha512_hex,
|
|
3272
|
-
sha512_base64url: () => sha512_base64url,
|
|
3273
|
-
sha512_base64: () => sha512_base64,
|
|
3274
|
-
sha384_hex: () => sha384_hex,
|
|
3275
|
-
sha384_base64url: () => sha384_base64url,
|
|
3276
|
-
sha384_base64: () => sha384_base64,
|
|
3277
|
-
sha256_hex: () => sha256_hex,
|
|
3278
|
-
sha256_base64url: () => sha256_base64url,
|
|
3279
|
-
sha256_base64: () => sha256_base64,
|
|
3280
|
-
sha1_hex: () => sha1_hex,
|
|
3281
|
-
sha1_base64url: () => sha1_base64url,
|
|
3282
|
-
sha1_base64: () => sha1_base64,
|
|
3283
|
-
rfc5322Email: () => rfc5322Email,
|
|
3284
|
-
number: () => number,
|
|
3285
|
-
null: () => _null,
|
|
3286
|
-
nanoid: () => nanoid,
|
|
3287
|
-
md5_hex: () => md5_hex,
|
|
3288
|
-
md5_base64url: () => md5_base64url,
|
|
3289
|
-
md5_base64: () => md5_base64,
|
|
3290
|
-
mac: () => mac,
|
|
3291
|
-
lowercase: () => lowercase,
|
|
3292
|
-
ksuid: () => ksuid,
|
|
3293
|
-
ipv6: () => ipv6,
|
|
3294
|
-
ipv4: () => ipv4,
|
|
3295
|
-
integer: () => integer,
|
|
3296
|
-
idnEmail: () => idnEmail,
|
|
3297
|
-
httpProtocol: () => httpProtocol,
|
|
3298
|
-
html5Email: () => html5Email,
|
|
3299
|
-
hostname: () => hostname,
|
|
3300
|
-
hex: () => hex,
|
|
3301
|
-
guid: () => guid,
|
|
3302
|
-
extendedDuration: () => extendedDuration,
|
|
3303
|
-
emoji: () => emoji,
|
|
3304
|
-
email: () => email,
|
|
3305
|
-
e164: () => e164,
|
|
3306
|
-
duration: () => duration,
|
|
3307
|
-
domain: () => domain,
|
|
3308
|
-
datetime: () => datetime,
|
|
3309
|
-
date: () => date,
|
|
3310
|
-
cuid2: () => cuid2,
|
|
3311
|
-
cuid: () => cuid,
|
|
3312
|
-
cidrv6: () => cidrv6,
|
|
3313
|
-
cidrv4: () => cidrv4,
|
|
3314
|
-
browserEmail: () => browserEmail,
|
|
3315
|
-
boolean: () => boolean,
|
|
3316
|
-
bigint: () => bigint,
|
|
3237
|
+
base64: () => base64,
|
|
3317
3238
|
base64url: () => base64url,
|
|
3318
|
-
|
|
3239
|
+
bigint: () => bigint,
|
|
3240
|
+
boolean: () => boolean,
|
|
3241
|
+
browserEmail: () => browserEmail,
|
|
3242
|
+
cidrv4: () => cidrv4,
|
|
3243
|
+
cidrv6: () => cidrv6,
|
|
3244
|
+
cuid: () => cuid,
|
|
3245
|
+
cuid2: () => cuid2,
|
|
3246
|
+
date: () => date,
|
|
3247
|
+
datetime: () => datetime,
|
|
3248
|
+
domain: () => domain,
|
|
3249
|
+
duration: () => duration,
|
|
3250
|
+
e164: () => e164,
|
|
3251
|
+
email: () => email,
|
|
3252
|
+
emoji: () => emoji,
|
|
3253
|
+
extendedDuration: () => extendedDuration,
|
|
3254
|
+
guid: () => guid,
|
|
3255
|
+
hex: () => hex,
|
|
3256
|
+
hostname: () => hostname,
|
|
3257
|
+
html5Email: () => html5Email,
|
|
3258
|
+
httpProtocol: () => httpProtocol,
|
|
3259
|
+
idnEmail: () => idnEmail,
|
|
3260
|
+
integer: () => integer,
|
|
3261
|
+
ipv4: () => ipv4,
|
|
3262
|
+
ipv6: () => ipv6,
|
|
3263
|
+
ksuid: () => ksuid,
|
|
3264
|
+
lowercase: () => lowercase,
|
|
3265
|
+
mac: () => mac,
|
|
3266
|
+
md5_base64: () => md5_base64,
|
|
3267
|
+
md5_base64url: () => md5_base64url,
|
|
3268
|
+
md5_hex: () => md5_hex,
|
|
3269
|
+
nanoid: () => nanoid,
|
|
3270
|
+
null: () => _null,
|
|
3271
|
+
number: () => number,
|
|
3272
|
+
rfc5322Email: () => rfc5322Email,
|
|
3273
|
+
sha1_base64: () => sha1_base64,
|
|
3274
|
+
sha1_base64url: () => sha1_base64url,
|
|
3275
|
+
sha1_hex: () => sha1_hex,
|
|
3276
|
+
sha256_base64: () => sha256_base64,
|
|
3277
|
+
sha256_base64url: () => sha256_base64url,
|
|
3278
|
+
sha256_hex: () => sha256_hex,
|
|
3279
|
+
sha384_base64: () => sha384_base64,
|
|
3280
|
+
sha384_base64url: () => sha384_base64url,
|
|
3281
|
+
sha384_hex: () => sha384_hex,
|
|
3282
|
+
sha512_base64: () => sha512_base64,
|
|
3283
|
+
sha512_base64url: () => sha512_base64url,
|
|
3284
|
+
sha512_hex: () => sha512_hex,
|
|
3285
|
+
string: () => string,
|
|
3286
|
+
time: () => time,
|
|
3287
|
+
ulid: () => ulid,
|
|
3288
|
+
undefined: () => _undefined,
|
|
3289
|
+
unicodeEmail: () => unicodeEmail,
|
|
3290
|
+
uppercase: () => uppercase,
|
|
3291
|
+
uuid: () => uuid,
|
|
3292
|
+
uuid4: () => uuid4,
|
|
3293
|
+
uuid6: () => uuid6,
|
|
3294
|
+
uuid7: () => uuid7,
|
|
3295
|
+
xid: () => xid
|
|
3319
3296
|
});
|
|
3320
3297
|
var cuid = /^[cC][0-9a-z]{6,}$/;
|
|
3321
3298
|
var cuid2 = /^[0-9a-z]+$/;
|
|
@@ -6087,63 +6064,63 @@ function handleRefineResult(result, payload, input, inst) {
|
|
|
6087
6064
|
if (inst._zod.def.params)
|
|
6088
6065
|
_iss.params = inst._zod.def.params;
|
|
6089
6066
|
payload.issues.push(issue(_iss));
|
|
6090
|
-
}
|
|
6091
|
-
}
|
|
6092
|
-
// ../../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/index.js
|
|
6093
|
-
var exports_locales = {};
|
|
6094
|
-
__export(exports_locales, {
|
|
6095
|
-
|
|
6096
|
-
zhCN: () => zh_CN_default,
|
|
6097
|
-
yo: () => yo_default,
|
|
6098
|
-
vi: () => vi_default,
|
|
6099
|
-
uz: () => uz_default,
|
|
6100
|
-
ur: () => ur_default,
|
|
6101
|
-
uk: () => uk_default,
|
|
6102
|
-
ua: () => ua_default,
|
|
6103
|
-
tr: () => tr_default,
|
|
6104
|
-
th: () => th_default,
|
|
6105
|
-
ta: () => ta_default,
|
|
6106
|
-
sv: () => sv_default,
|
|
6107
|
-
sl: () => sl_default,
|
|
6108
|
-
ru: () => ru_default,
|
|
6109
|
-
ro: () => ro_default,
|
|
6110
|
-
pt: () => pt_default,
|
|
6111
|
-
ps: () => ps_default,
|
|
6112
|
-
pl: () => pl_default,
|
|
6113
|
-
ota: () => ota_default,
|
|
6114
|
-
no: () => no_default,
|
|
6115
|
-
nl: () => nl_default,
|
|
6116
|
-
ms: () => ms_default,
|
|
6117
|
-
mk: () => mk_default,
|
|
6118
|
-
lt: () => lt_default,
|
|
6119
|
-
ko: () => ko_default,
|
|
6120
|
-
km: () => km_default,
|
|
6121
|
-
kh: () => kh_default,
|
|
6122
|
-
ka: () => ka_default,
|
|
6123
|
-
ja: () => ja_default,
|
|
6124
|
-
it: () => it_default,
|
|
6125
|
-
is: () => is_default,
|
|
6126
|
-
id: () => id_default,
|
|
6127
|
-
hy: () => hy_default,
|
|
6128
|
-
hu: () => hu_default,
|
|
6129
|
-
hr: () => hr_default,
|
|
6130
|
-
he: () => he_default,
|
|
6131
|
-
frCA: () => fr_CA_default,
|
|
6132
|
-
fr: () => fr_default,
|
|
6133
|
-
fi: () => fi_default,
|
|
6134
|
-
fa: () => fa_default,
|
|
6135
|
-
es: () => es_default,
|
|
6136
|
-
eo: () => eo_default,
|
|
6137
|
-
en: () => en_default,
|
|
6138
|
-
el: () => el_default,
|
|
6139
|
-
de: () => de_default,
|
|
6140
|
-
da: () => da_default,
|
|
6141
|
-
cs: () => cs_default,
|
|
6142
|
-
ca: () => ca_default,
|
|
6143
|
-
bg: () => bg_default,
|
|
6144
|
-
be: () => be_default,
|
|
6067
|
+
}
|
|
6068
|
+
}
|
|
6069
|
+
// ../../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/index.js
|
|
6070
|
+
var exports_locales = {};
|
|
6071
|
+
__export(exports_locales, {
|
|
6072
|
+
ar: () => ar_default,
|
|
6145
6073
|
az: () => az_default,
|
|
6146
|
-
|
|
6074
|
+
be: () => be_default,
|
|
6075
|
+
bg: () => bg_default,
|
|
6076
|
+
ca: () => ca_default,
|
|
6077
|
+
cs: () => cs_default,
|
|
6078
|
+
da: () => da_default,
|
|
6079
|
+
de: () => de_default,
|
|
6080
|
+
el: () => el_default,
|
|
6081
|
+
en: () => en_default,
|
|
6082
|
+
eo: () => eo_default,
|
|
6083
|
+
es: () => es_default,
|
|
6084
|
+
fa: () => fa_default,
|
|
6085
|
+
fi: () => fi_default,
|
|
6086
|
+
fr: () => fr_default,
|
|
6087
|
+
frCA: () => fr_CA_default,
|
|
6088
|
+
he: () => he_default,
|
|
6089
|
+
hr: () => hr_default,
|
|
6090
|
+
hu: () => hu_default,
|
|
6091
|
+
hy: () => hy_default,
|
|
6092
|
+
id: () => id_default,
|
|
6093
|
+
is: () => is_default,
|
|
6094
|
+
it: () => it_default,
|
|
6095
|
+
ja: () => ja_default,
|
|
6096
|
+
ka: () => ka_default,
|
|
6097
|
+
kh: () => kh_default,
|
|
6098
|
+
km: () => km_default,
|
|
6099
|
+
ko: () => ko_default,
|
|
6100
|
+
lt: () => lt_default,
|
|
6101
|
+
mk: () => mk_default,
|
|
6102
|
+
ms: () => ms_default,
|
|
6103
|
+
nl: () => nl_default,
|
|
6104
|
+
no: () => no_default,
|
|
6105
|
+
ota: () => ota_default,
|
|
6106
|
+
pl: () => pl_default,
|
|
6107
|
+
ps: () => ps_default,
|
|
6108
|
+
pt: () => pt_default,
|
|
6109
|
+
ro: () => ro_default,
|
|
6110
|
+
ru: () => ru_default,
|
|
6111
|
+
sl: () => sl_default,
|
|
6112
|
+
sv: () => sv_default,
|
|
6113
|
+
ta: () => ta_default,
|
|
6114
|
+
th: () => th_default,
|
|
6115
|
+
tr: () => tr_default,
|
|
6116
|
+
ua: () => ua_default,
|
|
6117
|
+
uk: () => uk_default,
|
|
6118
|
+
ur: () => ur_default,
|
|
6119
|
+
uz: () => uz_default,
|
|
6120
|
+
vi: () => vi_default,
|
|
6121
|
+
yo: () => yo_default,
|
|
6122
|
+
zhCN: () => zh_CN_default,
|
|
6123
|
+
zhTW: () => zh_TW_default
|
|
6147
6124
|
});
|
|
6148
6125
|
|
|
6149
6126
|
// ../../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/ar.js
|
|
@@ -13875,258 +13852,258 @@ class JSONSchemaGenerator {
|
|
|
13875
13852
|
}
|
|
13876
13853
|
get seen() {
|
|
13877
13854
|
return this.ctx.seen;
|
|
13878
|
-
}
|
|
13879
|
-
constructor(params) {
|
|
13880
|
-
let normalizedTarget = params?.target ?? "draft-2020-12";
|
|
13881
|
-
if (normalizedTarget === "draft-4")
|
|
13882
|
-
normalizedTarget = "draft-04";
|
|
13883
|
-
if (normalizedTarget === "draft-7")
|
|
13884
|
-
normalizedTarget = "draft-07";
|
|
13885
|
-
this.ctx = initializeContext({
|
|
13886
|
-
processors: allProcessors,
|
|
13887
|
-
target: normalizedTarget,
|
|
13888
|
-
...params?.metadata && { metadata: params.metadata },
|
|
13889
|
-
...params?.unrepresentable && { unrepresentable: params.unrepresentable },
|
|
13890
|
-
...params?.override && { override: params.override },
|
|
13891
|
-
...params?.io && { io: params.io }
|
|
13892
|
-
});
|
|
13893
|
-
}
|
|
13894
|
-
process(schema, _params = { path: [], schemaPath: [] }) {
|
|
13895
|
-
return process(schema, this.ctx, _params);
|
|
13896
|
-
}
|
|
13897
|
-
emit(schema, _params) {
|
|
13898
|
-
if (_params) {
|
|
13899
|
-
if (_params.cycles)
|
|
13900
|
-
this.ctx.cycles = _params.cycles;
|
|
13901
|
-
if (_params.reused)
|
|
13902
|
-
this.ctx.reused = _params.reused;
|
|
13903
|
-
if (_params.external)
|
|
13904
|
-
this.ctx.external = _params.external;
|
|
13905
|
-
}
|
|
13906
|
-
extractDefs(this.ctx, schema);
|
|
13907
|
-
const result = finalize(this.ctx, schema);
|
|
13908
|
-
const { "~standard": _, ...plainResult } = result;
|
|
13909
|
-
return plainResult;
|
|
13910
|
-
}
|
|
13911
|
-
}
|
|
13912
|
-
// ../../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/core/json-schema.js
|
|
13913
|
-
var exports_json_schema = {};
|
|
13914
|
-
// ../../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/classic/schemas.js
|
|
13915
|
-
var exports_schemas2 = {};
|
|
13916
|
-
__export(exports_schemas2, {
|
|
13917
|
-
|
|
13918
|
-
xid: () => xid2,
|
|
13919
|
-
void: () => _void2,
|
|
13920
|
-
uuidv7: () => uuidv7,
|
|
13921
|
-
uuidv6: () => uuidv6,
|
|
13922
|
-
uuidv4: () => uuidv4,
|
|
13923
|
-
uuid: () => uuid2,
|
|
13924
|
-
url: () => url,
|
|
13925
|
-
unknown: () => unknown,
|
|
13926
|
-
union: () => union,
|
|
13927
|
-
undefined: () => _undefined3,
|
|
13928
|
-
ulid: () => ulid2,
|
|
13929
|
-
uint64: () => uint64,
|
|
13930
|
-
uint32: () => uint32,
|
|
13931
|
-
tuple: () => tuple,
|
|
13932
|
-
transform: () => transform,
|
|
13933
|
-
templateLiteral: () => templateLiteral,
|
|
13934
|
-
symbol: () => symbol,
|
|
13935
|
-
superRefine: () => superRefine,
|
|
13936
|
-
success: () => success,
|
|
13937
|
-
stringbool: () => stringbool,
|
|
13938
|
-
stringFormat: () => stringFormat,
|
|
13939
|
-
string: () => string2,
|
|
13940
|
-
strictObject: () => strictObject,
|
|
13941
|
-
set: () => set,
|
|
13942
|
-
refine: () => refine,
|
|
13943
|
-
record: () => record,
|
|
13944
|
-
readonly: () => readonly,
|
|
13945
|
-
promise: () => promise,
|
|
13946
|
-
preprocess: () => preprocess,
|
|
13947
|
-
prefault: () => prefault,
|
|
13948
|
-
pipe: () => pipe,
|
|
13949
|
-
partialRecord: () => partialRecord,
|
|
13950
|
-
optional: () => optional,
|
|
13951
|
-
object: () => object,
|
|
13952
|
-
number: () => number2,
|
|
13953
|
-
nullish: () => nullish2,
|
|
13954
|
-
nullable: () => nullable,
|
|
13955
|
-
null: () => _null3,
|
|
13956
|
-
nonoptional: () => nonoptional,
|
|
13957
|
-
never: () => never,
|
|
13958
|
-
nativeEnum: () => nativeEnum,
|
|
13959
|
-
nanoid: () => nanoid2,
|
|
13960
|
-
nan: () => nan,
|
|
13961
|
-
meta: () => meta2,
|
|
13962
|
-
map: () => map,
|
|
13963
|
-
mac: () => mac2,
|
|
13964
|
-
looseRecord: () => looseRecord,
|
|
13965
|
-
looseObject: () => looseObject,
|
|
13966
|
-
literal: () => literal,
|
|
13967
|
-
lazy: () => lazy,
|
|
13968
|
-
ksuid: () => ksuid2,
|
|
13969
|
-
keyof: () => keyof,
|
|
13970
|
-
jwt: () => jwt,
|
|
13971
|
-
json: () => json,
|
|
13972
|
-
ipv6: () => ipv62,
|
|
13973
|
-
ipv4: () => ipv42,
|
|
13974
|
-
invertCodec: () => invertCodec,
|
|
13975
|
-
intersection: () => intersection,
|
|
13976
|
-
int64: () => int64,
|
|
13977
|
-
int32: () => int32,
|
|
13978
|
-
int: () => int,
|
|
13979
|
-
instanceof: () => _instanceof,
|
|
13980
|
-
httpUrl: () => httpUrl,
|
|
13981
|
-
hostname: () => hostname2,
|
|
13982
|
-
hex: () => hex2,
|
|
13983
|
-
hash: () => hash,
|
|
13984
|
-
guid: () => guid2,
|
|
13985
|
-
function: () => _function,
|
|
13986
|
-
float64: () => float64,
|
|
13987
|
-
float32: () => float32,
|
|
13988
|
-
file: () => file,
|
|
13989
|
-
exactOptional: () => exactOptional,
|
|
13990
|
-
enum: () => _enum2,
|
|
13991
|
-
emoji: () => emoji2,
|
|
13992
|
-
email: () => email2,
|
|
13993
|
-
e164: () => e1642,
|
|
13994
|
-
discriminatedUnion: () => discriminatedUnion,
|
|
13995
|
-
describe: () => describe2,
|
|
13996
|
-
date: () => date3,
|
|
13997
|
-
custom: () => custom,
|
|
13998
|
-
cuid2: () => cuid22,
|
|
13999
|
-
cuid: () => cuid3,
|
|
14000
|
-
codec: () => codec,
|
|
14001
|
-
cidrv6: () => cidrv62,
|
|
14002
|
-
cidrv4: () => cidrv42,
|
|
14003
|
-
check: () => check,
|
|
14004
|
-
catch: () => _catch2,
|
|
14005
|
-
boolean: () => boolean2,
|
|
14006
|
-
bigint: () => bigint2,
|
|
14007
|
-
base64url: () => base64url2,
|
|
14008
|
-
base64: () => base642,
|
|
14009
|
-
array: () => array,
|
|
14010
|
-
any: () => any,
|
|
14011
|
-
_function: () => _function,
|
|
14012
|
-
_default: () => _default2,
|
|
14013
|
-
_ZodString: () => _ZodString,
|
|
14014
|
-
ZodXor: () => ZodXor,
|
|
14015
|
-
ZodXID: () => ZodXID,
|
|
14016
|
-
ZodVoid: () => ZodVoid,
|
|
14017
|
-
ZodUnknown: () => ZodUnknown,
|
|
14018
|
-
ZodUnion: () => ZodUnion,
|
|
14019
|
-
ZodUndefined: () => ZodUndefined,
|
|
14020
|
-
ZodUUID: () => ZodUUID,
|
|
14021
|
-
ZodURL: () => ZodURL,
|
|
14022
|
-
ZodULID: () => ZodULID,
|
|
14023
|
-
ZodType: () => ZodType,
|
|
14024
|
-
ZodTuple: () => ZodTuple,
|
|
14025
|
-
ZodTransform: () => ZodTransform,
|
|
14026
|
-
ZodTemplateLiteral: () => ZodTemplateLiteral,
|
|
14027
|
-
ZodSymbol: () => ZodSymbol,
|
|
14028
|
-
ZodSuccess: () => ZodSuccess,
|
|
14029
|
-
ZodStringFormat: () => ZodStringFormat,
|
|
14030
|
-
ZodString: () => ZodString,
|
|
14031
|
-
ZodSet: () => ZodSet,
|
|
14032
|
-
ZodRecord: () => ZodRecord,
|
|
14033
|
-
ZodReadonly: () => ZodReadonly,
|
|
14034
|
-
ZodPromise: () => ZodPromise,
|
|
14035
|
-
ZodPreprocess: () => ZodPreprocess,
|
|
14036
|
-
ZodPrefault: () => ZodPrefault,
|
|
14037
|
-
ZodPipe: () => ZodPipe,
|
|
14038
|
-
ZodOptional: () => ZodOptional,
|
|
14039
|
-
ZodObject: () => ZodObject,
|
|
14040
|
-
ZodNumberFormat: () => ZodNumberFormat,
|
|
14041
|
-
ZodNumber: () => ZodNumber,
|
|
14042
|
-
ZodNullable: () => ZodNullable,
|
|
14043
|
-
ZodNull: () => ZodNull,
|
|
14044
|
-
ZodNonOptional: () => ZodNonOptional,
|
|
14045
|
-
ZodNever: () => ZodNever,
|
|
14046
|
-
ZodNanoID: () => ZodNanoID,
|
|
14047
|
-
ZodNaN: () => ZodNaN,
|
|
14048
|
-
ZodMap: () => ZodMap,
|
|
14049
|
-
ZodMAC: () => ZodMAC,
|
|
14050
|
-
ZodLiteral: () => ZodLiteral,
|
|
14051
|
-
ZodLazy: () => ZodLazy,
|
|
14052
|
-
ZodKSUID: () => ZodKSUID,
|
|
14053
|
-
ZodJWT: () => ZodJWT,
|
|
14054
|
-
ZodIntersection: () => ZodIntersection,
|
|
14055
|
-
ZodIPv6: () => ZodIPv6,
|
|
14056
|
-
ZodIPv4: () => ZodIPv4,
|
|
14057
|
-
ZodGUID: () => ZodGUID,
|
|
14058
|
-
ZodFunction: () => ZodFunction,
|
|
14059
|
-
ZodFile: () => ZodFile,
|
|
14060
|
-
ZodExactOptional: () => ZodExactOptional,
|
|
14061
|
-
ZodEnum: () => ZodEnum,
|
|
14062
|
-
ZodEmoji: () => ZodEmoji,
|
|
14063
|
-
ZodEmail: () => ZodEmail,
|
|
14064
|
-
ZodE164: () => ZodE164,
|
|
14065
|
-
ZodDiscriminatedUnion: () => ZodDiscriminatedUnion,
|
|
14066
|
-
ZodDefault: () => ZodDefault,
|
|
14067
|
-
ZodDate: () => ZodDate,
|
|
14068
|
-
ZodCustomStringFormat: () => ZodCustomStringFormat,
|
|
14069
|
-
ZodCustom: () => ZodCustom,
|
|
14070
|
-
ZodCodec: () => ZodCodec,
|
|
14071
|
-
ZodCatch: () => ZodCatch,
|
|
14072
|
-
ZodCUID2: () => ZodCUID2,
|
|
14073
|
-
ZodCUID: () => ZodCUID,
|
|
14074
|
-
ZodCIDRv6: () => ZodCIDRv6,
|
|
14075
|
-
ZodCIDRv4: () => ZodCIDRv4,
|
|
14076
|
-
ZodBoolean: () => ZodBoolean,
|
|
14077
|
-
ZodBigIntFormat: () => ZodBigIntFormat,
|
|
14078
|
-
ZodBigInt: () => ZodBigInt,
|
|
14079
|
-
ZodBase64URL: () => ZodBase64URL,
|
|
14080
|
-
ZodBase64: () => ZodBase64,
|
|
13855
|
+
}
|
|
13856
|
+
constructor(params) {
|
|
13857
|
+
let normalizedTarget = params?.target ?? "draft-2020-12";
|
|
13858
|
+
if (normalizedTarget === "draft-4")
|
|
13859
|
+
normalizedTarget = "draft-04";
|
|
13860
|
+
if (normalizedTarget === "draft-7")
|
|
13861
|
+
normalizedTarget = "draft-07";
|
|
13862
|
+
this.ctx = initializeContext({
|
|
13863
|
+
processors: allProcessors,
|
|
13864
|
+
target: normalizedTarget,
|
|
13865
|
+
...params?.metadata && { metadata: params.metadata },
|
|
13866
|
+
...params?.unrepresentable && { unrepresentable: params.unrepresentable },
|
|
13867
|
+
...params?.override && { override: params.override },
|
|
13868
|
+
...params?.io && { io: params.io }
|
|
13869
|
+
});
|
|
13870
|
+
}
|
|
13871
|
+
process(schema, _params = { path: [], schemaPath: [] }) {
|
|
13872
|
+
return process(schema, this.ctx, _params);
|
|
13873
|
+
}
|
|
13874
|
+
emit(schema, _params) {
|
|
13875
|
+
if (_params) {
|
|
13876
|
+
if (_params.cycles)
|
|
13877
|
+
this.ctx.cycles = _params.cycles;
|
|
13878
|
+
if (_params.reused)
|
|
13879
|
+
this.ctx.reused = _params.reused;
|
|
13880
|
+
if (_params.external)
|
|
13881
|
+
this.ctx.external = _params.external;
|
|
13882
|
+
}
|
|
13883
|
+
extractDefs(this.ctx, schema);
|
|
13884
|
+
const result = finalize(this.ctx, schema);
|
|
13885
|
+
const { "~standard": _, ...plainResult } = result;
|
|
13886
|
+
return plainResult;
|
|
13887
|
+
}
|
|
13888
|
+
}
|
|
13889
|
+
// ../../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/core/json-schema.js
|
|
13890
|
+
var exports_json_schema = {};
|
|
13891
|
+
// ../../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/classic/schemas.js
|
|
13892
|
+
var exports_schemas2 = {};
|
|
13893
|
+
__export(exports_schemas2, {
|
|
13894
|
+
ZodAny: () => ZodAny,
|
|
14081
13895
|
ZodArray: () => ZodArray,
|
|
14082
|
-
|
|
13896
|
+
ZodBase64: () => ZodBase64,
|
|
13897
|
+
ZodBase64URL: () => ZodBase64URL,
|
|
13898
|
+
ZodBigInt: () => ZodBigInt,
|
|
13899
|
+
ZodBigIntFormat: () => ZodBigIntFormat,
|
|
13900
|
+
ZodBoolean: () => ZodBoolean,
|
|
13901
|
+
ZodCIDRv4: () => ZodCIDRv4,
|
|
13902
|
+
ZodCIDRv6: () => ZodCIDRv6,
|
|
13903
|
+
ZodCUID: () => ZodCUID,
|
|
13904
|
+
ZodCUID2: () => ZodCUID2,
|
|
13905
|
+
ZodCatch: () => ZodCatch,
|
|
13906
|
+
ZodCodec: () => ZodCodec,
|
|
13907
|
+
ZodCustom: () => ZodCustom,
|
|
13908
|
+
ZodCustomStringFormat: () => ZodCustomStringFormat,
|
|
13909
|
+
ZodDate: () => ZodDate,
|
|
13910
|
+
ZodDefault: () => ZodDefault,
|
|
13911
|
+
ZodDiscriminatedUnion: () => ZodDiscriminatedUnion,
|
|
13912
|
+
ZodE164: () => ZodE164,
|
|
13913
|
+
ZodEmail: () => ZodEmail,
|
|
13914
|
+
ZodEmoji: () => ZodEmoji,
|
|
13915
|
+
ZodEnum: () => ZodEnum,
|
|
13916
|
+
ZodExactOptional: () => ZodExactOptional,
|
|
13917
|
+
ZodFile: () => ZodFile,
|
|
13918
|
+
ZodFunction: () => ZodFunction,
|
|
13919
|
+
ZodGUID: () => ZodGUID,
|
|
13920
|
+
ZodIPv4: () => ZodIPv4,
|
|
13921
|
+
ZodIPv6: () => ZodIPv6,
|
|
13922
|
+
ZodIntersection: () => ZodIntersection,
|
|
13923
|
+
ZodJWT: () => ZodJWT,
|
|
13924
|
+
ZodKSUID: () => ZodKSUID,
|
|
13925
|
+
ZodLazy: () => ZodLazy,
|
|
13926
|
+
ZodLiteral: () => ZodLiteral,
|
|
13927
|
+
ZodMAC: () => ZodMAC,
|
|
13928
|
+
ZodMap: () => ZodMap,
|
|
13929
|
+
ZodNaN: () => ZodNaN,
|
|
13930
|
+
ZodNanoID: () => ZodNanoID,
|
|
13931
|
+
ZodNever: () => ZodNever,
|
|
13932
|
+
ZodNonOptional: () => ZodNonOptional,
|
|
13933
|
+
ZodNull: () => ZodNull,
|
|
13934
|
+
ZodNullable: () => ZodNullable,
|
|
13935
|
+
ZodNumber: () => ZodNumber,
|
|
13936
|
+
ZodNumberFormat: () => ZodNumberFormat,
|
|
13937
|
+
ZodObject: () => ZodObject,
|
|
13938
|
+
ZodOptional: () => ZodOptional,
|
|
13939
|
+
ZodPipe: () => ZodPipe,
|
|
13940
|
+
ZodPrefault: () => ZodPrefault,
|
|
13941
|
+
ZodPreprocess: () => ZodPreprocess,
|
|
13942
|
+
ZodPromise: () => ZodPromise,
|
|
13943
|
+
ZodReadonly: () => ZodReadonly,
|
|
13944
|
+
ZodRecord: () => ZodRecord,
|
|
13945
|
+
ZodSet: () => ZodSet,
|
|
13946
|
+
ZodString: () => ZodString,
|
|
13947
|
+
ZodStringFormat: () => ZodStringFormat,
|
|
13948
|
+
ZodSuccess: () => ZodSuccess,
|
|
13949
|
+
ZodSymbol: () => ZodSymbol,
|
|
13950
|
+
ZodTemplateLiteral: () => ZodTemplateLiteral,
|
|
13951
|
+
ZodTransform: () => ZodTransform,
|
|
13952
|
+
ZodTuple: () => ZodTuple,
|
|
13953
|
+
ZodType: () => ZodType,
|
|
13954
|
+
ZodULID: () => ZodULID,
|
|
13955
|
+
ZodURL: () => ZodURL,
|
|
13956
|
+
ZodUUID: () => ZodUUID,
|
|
13957
|
+
ZodUndefined: () => ZodUndefined,
|
|
13958
|
+
ZodUnion: () => ZodUnion,
|
|
13959
|
+
ZodUnknown: () => ZodUnknown,
|
|
13960
|
+
ZodVoid: () => ZodVoid,
|
|
13961
|
+
ZodXID: () => ZodXID,
|
|
13962
|
+
ZodXor: () => ZodXor,
|
|
13963
|
+
_ZodString: () => _ZodString,
|
|
13964
|
+
_default: () => _default2,
|
|
13965
|
+
_function: () => _function,
|
|
13966
|
+
any: () => any,
|
|
13967
|
+
array: () => array,
|
|
13968
|
+
base64: () => base642,
|
|
13969
|
+
base64url: () => base64url2,
|
|
13970
|
+
bigint: () => bigint2,
|
|
13971
|
+
boolean: () => boolean2,
|
|
13972
|
+
catch: () => _catch2,
|
|
13973
|
+
check: () => check,
|
|
13974
|
+
cidrv4: () => cidrv42,
|
|
13975
|
+
cidrv6: () => cidrv62,
|
|
13976
|
+
codec: () => codec,
|
|
13977
|
+
cuid: () => cuid3,
|
|
13978
|
+
cuid2: () => cuid22,
|
|
13979
|
+
custom: () => custom,
|
|
13980
|
+
date: () => date3,
|
|
13981
|
+
describe: () => describe2,
|
|
13982
|
+
discriminatedUnion: () => discriminatedUnion,
|
|
13983
|
+
e164: () => e1642,
|
|
13984
|
+
email: () => email2,
|
|
13985
|
+
emoji: () => emoji2,
|
|
13986
|
+
enum: () => _enum2,
|
|
13987
|
+
exactOptional: () => exactOptional,
|
|
13988
|
+
file: () => file,
|
|
13989
|
+
float32: () => float32,
|
|
13990
|
+
float64: () => float64,
|
|
13991
|
+
function: () => _function,
|
|
13992
|
+
guid: () => guid2,
|
|
13993
|
+
hash: () => hash,
|
|
13994
|
+
hex: () => hex2,
|
|
13995
|
+
hostname: () => hostname2,
|
|
13996
|
+
httpUrl: () => httpUrl,
|
|
13997
|
+
instanceof: () => _instanceof,
|
|
13998
|
+
int: () => int,
|
|
13999
|
+
int32: () => int32,
|
|
14000
|
+
int64: () => int64,
|
|
14001
|
+
intersection: () => intersection,
|
|
14002
|
+
invertCodec: () => invertCodec,
|
|
14003
|
+
ipv4: () => ipv42,
|
|
14004
|
+
ipv6: () => ipv62,
|
|
14005
|
+
json: () => json,
|
|
14006
|
+
jwt: () => jwt,
|
|
14007
|
+
keyof: () => keyof,
|
|
14008
|
+
ksuid: () => ksuid2,
|
|
14009
|
+
lazy: () => lazy,
|
|
14010
|
+
literal: () => literal,
|
|
14011
|
+
looseObject: () => looseObject,
|
|
14012
|
+
looseRecord: () => looseRecord,
|
|
14013
|
+
mac: () => mac2,
|
|
14014
|
+
map: () => map,
|
|
14015
|
+
meta: () => meta2,
|
|
14016
|
+
nan: () => nan,
|
|
14017
|
+
nanoid: () => nanoid2,
|
|
14018
|
+
nativeEnum: () => nativeEnum,
|
|
14019
|
+
never: () => never,
|
|
14020
|
+
nonoptional: () => nonoptional,
|
|
14021
|
+
null: () => _null3,
|
|
14022
|
+
nullable: () => nullable,
|
|
14023
|
+
nullish: () => nullish2,
|
|
14024
|
+
number: () => number2,
|
|
14025
|
+
object: () => object,
|
|
14026
|
+
optional: () => optional,
|
|
14027
|
+
partialRecord: () => partialRecord,
|
|
14028
|
+
pipe: () => pipe,
|
|
14029
|
+
prefault: () => prefault,
|
|
14030
|
+
preprocess: () => preprocess,
|
|
14031
|
+
promise: () => promise,
|
|
14032
|
+
readonly: () => readonly,
|
|
14033
|
+
record: () => record,
|
|
14034
|
+
refine: () => refine,
|
|
14035
|
+
set: () => set,
|
|
14036
|
+
strictObject: () => strictObject,
|
|
14037
|
+
string: () => string2,
|
|
14038
|
+
stringFormat: () => stringFormat,
|
|
14039
|
+
stringbool: () => stringbool,
|
|
14040
|
+
success: () => success,
|
|
14041
|
+
superRefine: () => superRefine,
|
|
14042
|
+
symbol: () => symbol,
|
|
14043
|
+
templateLiteral: () => templateLiteral,
|
|
14044
|
+
transform: () => transform,
|
|
14045
|
+
tuple: () => tuple,
|
|
14046
|
+
uint32: () => uint32,
|
|
14047
|
+
uint64: () => uint64,
|
|
14048
|
+
ulid: () => ulid2,
|
|
14049
|
+
undefined: () => _undefined3,
|
|
14050
|
+
union: () => union,
|
|
14051
|
+
unknown: () => unknown,
|
|
14052
|
+
url: () => url,
|
|
14053
|
+
uuid: () => uuid2,
|
|
14054
|
+
uuidv4: () => uuidv4,
|
|
14055
|
+
uuidv6: () => uuidv6,
|
|
14056
|
+
uuidv7: () => uuidv7,
|
|
14057
|
+
void: () => _void2,
|
|
14058
|
+
xid: () => xid2,
|
|
14059
|
+
xor: () => xor
|
|
14083
14060
|
});
|
|
14084
14061
|
|
|
14085
14062
|
// ../../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/classic/checks.js
|
|
14086
14063
|
var exports_checks2 = {};
|
|
14087
14064
|
__export(exports_checks2, {
|
|
14088
|
-
|
|
14089
|
-
trim: () => _trim,
|
|
14090
|
-
toUpperCase: () => _toUpperCase,
|
|
14091
|
-
toLowerCase: () => _toLowerCase,
|
|
14092
|
-
startsWith: () => _startsWith,
|
|
14093
|
-
slugify: () => _slugify,
|
|
14094
|
-
size: () => _size,
|
|
14095
|
-
regex: () => _regex,
|
|
14096
|
-
property: () => _property,
|
|
14097
|
-
positive: () => _positive,
|
|
14098
|
-
overwrite: () => _overwrite,
|
|
14099
|
-
normalize: () => _normalize,
|
|
14100
|
-
nonpositive: () => _nonpositive,
|
|
14101
|
-
nonnegative: () => _nonnegative,
|
|
14102
|
-
negative: () => _negative,
|
|
14103
|
-
multipleOf: () => _multipleOf,
|
|
14104
|
-
minSize: () => _minSize,
|
|
14105
|
-
minLength: () => _minLength,
|
|
14106
|
-
mime: () => _mime,
|
|
14107
|
-
maxSize: () => _maxSize,
|
|
14108
|
-
maxLength: () => _maxLength,
|
|
14109
|
-
lte: () => _lte,
|
|
14110
|
-
lt: () => _lt,
|
|
14111
|
-
lowercase: () => _lowercase,
|
|
14112
|
-
length: () => _length,
|
|
14113
|
-
includes: () => _includes,
|
|
14114
|
-
gte: () => _gte,
|
|
14065
|
+
endsWith: () => _endsWith,
|
|
14115
14066
|
gt: () => _gt,
|
|
14116
|
-
|
|
14067
|
+
gte: () => _gte,
|
|
14068
|
+
includes: () => _includes,
|
|
14069
|
+
length: () => _length,
|
|
14070
|
+
lowercase: () => _lowercase,
|
|
14071
|
+
lt: () => _lt,
|
|
14072
|
+
lte: () => _lte,
|
|
14073
|
+
maxLength: () => _maxLength,
|
|
14074
|
+
maxSize: () => _maxSize,
|
|
14075
|
+
mime: () => _mime,
|
|
14076
|
+
minLength: () => _minLength,
|
|
14077
|
+
minSize: () => _minSize,
|
|
14078
|
+
multipleOf: () => _multipleOf,
|
|
14079
|
+
negative: () => _negative,
|
|
14080
|
+
nonnegative: () => _nonnegative,
|
|
14081
|
+
nonpositive: () => _nonpositive,
|
|
14082
|
+
normalize: () => _normalize,
|
|
14083
|
+
overwrite: () => _overwrite,
|
|
14084
|
+
positive: () => _positive,
|
|
14085
|
+
property: () => _property,
|
|
14086
|
+
regex: () => _regex,
|
|
14087
|
+
size: () => _size,
|
|
14088
|
+
slugify: () => _slugify,
|
|
14089
|
+
startsWith: () => _startsWith,
|
|
14090
|
+
toLowerCase: () => _toLowerCase,
|
|
14091
|
+
toUpperCase: () => _toUpperCase,
|
|
14092
|
+
trim: () => _trim,
|
|
14093
|
+
uppercase: () => _uppercase
|
|
14117
14094
|
});
|
|
14118
14095
|
|
|
14119
14096
|
// ../../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/classic/iso.js
|
|
14120
14097
|
var exports_iso = {};
|
|
14121
14098
|
__export(exports_iso, {
|
|
14122
|
-
|
|
14123
|
-
duration: () => duration2,
|
|
14124
|
-
datetime: () => datetime2,
|
|
14125
|
-
date: () => date2,
|
|
14126
|
-
ZodISOTime: () => ZodISOTime,
|
|
14127
|
-
ZodISODuration: () => ZodISODuration,
|
|
14099
|
+
ZodISODate: () => ZodISODate,
|
|
14128
14100
|
ZodISODateTime: () => ZodISODateTime,
|
|
14129
|
-
|
|
14101
|
+
ZodISODuration: () => ZodISODuration,
|
|
14102
|
+
ZodISOTime: () => ZodISOTime,
|
|
14103
|
+
date: () => date2,
|
|
14104
|
+
datetime: () => datetime2,
|
|
14105
|
+
duration: () => duration2,
|
|
14106
|
+
time: () => time2
|
|
14130
14107
|
});
|
|
14131
14108
|
var ZodISODateTime = /* @__PURE__ */ $constructor("ZodISODateTime", (inst, def) => {
|
|
14132
14109
|
$ZodISODateTime.init(inst, def);
|
|
@@ -15987,11 +15964,11 @@ function fromJSONSchema(schema, params) {
|
|
|
15987
15964
|
// ../../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/classic/coerce.js
|
|
15988
15965
|
var exports_coerce = {};
|
|
15989
15966
|
__export(exports_coerce, {
|
|
15990
|
-
|
|
15991
|
-
number: () => number3,
|
|
15992
|
-
date: () => date4,
|
|
15967
|
+
bigint: () => bigint3,
|
|
15993
15968
|
boolean: () => boolean3,
|
|
15994
|
-
|
|
15969
|
+
date: () => date4,
|
|
15970
|
+
number: () => number3,
|
|
15971
|
+
string: () => string3
|
|
15995
15972
|
});
|
|
15996
15973
|
function string3(params) {
|
|
15997
15974
|
return _coercedString(ZodString, params);
|
|
@@ -16147,6 +16124,32 @@ ${feature._promptAddition}` : feature._promptAddition;
|
|
|
16147
16124
|
};
|
|
16148
16125
|
return spec;
|
|
16149
16126
|
}
|
|
16127
|
+
// src/definitions/steps/define-code-step.ts
|
|
16128
|
+
function codeStep(config2) {
|
|
16129
|
+
const spec = {
|
|
16130
|
+
key: config2.key,
|
|
16131
|
+
name: config2.name,
|
|
16132
|
+
description: config2.description ?? null,
|
|
16133
|
+
version: config2.version ?? 1,
|
|
16134
|
+
kind: "code",
|
|
16135
|
+
status: config2.status ?? "active",
|
|
16136
|
+
prompt: null,
|
|
16137
|
+
inputSchemaJson: config2.inputSchema ? toJSONSchema(config2.inputSchema) : null,
|
|
16138
|
+
resultSchemaJson: config2.resultSchema ? toJSONSchema(config2.resultSchema) : null,
|
|
16139
|
+
signalExtractorDefinitions: (config2.signals ?? []).map((signal) => ({
|
|
16140
|
+
key: signal.key ?? signal.sourcePath,
|
|
16141
|
+
sourcePath: signal.sourcePath,
|
|
16142
|
+
type: signal.type,
|
|
16143
|
+
required: signal.required ?? true,
|
|
16144
|
+
availableWhenResultStatusIn: signal.availableWhenResultStatusIn ?? null
|
|
16145
|
+
})),
|
|
16146
|
+
opencodeMcpJson: null,
|
|
16147
|
+
opencodePluginJson: null,
|
|
16148
|
+
healthChecksJson: null,
|
|
16149
|
+
entrypoint: { fn: config2.fn }
|
|
16150
|
+
};
|
|
16151
|
+
return spec;
|
|
16152
|
+
}
|
|
16150
16153
|
// src/definitions/steps/step-definitions-client.ts
|
|
16151
16154
|
function createStepDefinitionsClient(baseUrl) {
|
|
16152
16155
|
const client2 = createClient({ baseUrl });
|
|
@@ -16174,8 +16177,21 @@ var buildStepDefinitionsClient = (stepDefinitions) => {
|
|
|
16174
16177
|
},
|
|
16175
16178
|
upsertFromSpec: async (projectId, spec, options) => {
|
|
16176
16179
|
const body = {
|
|
16177
|
-
|
|
16180
|
+
key: spec.key,
|
|
16181
|
+
name: spec.name,
|
|
16182
|
+
description: spec.description,
|
|
16178
16183
|
prompt: spec.prompt ?? "",
|
|
16184
|
+
version: spec.version,
|
|
16185
|
+
kind: spec.kind,
|
|
16186
|
+
entrypointJson: spec.entrypointJson ?? null,
|
|
16187
|
+
executionMode: spec.executionMode,
|
|
16188
|
+
inputSchemaJson: spec.inputSchemaJson,
|
|
16189
|
+
resultSchemaJson: spec.resultSchemaJson,
|
|
16190
|
+
opencodeMcpJson: spec.opencodeMcpJson,
|
|
16191
|
+
opencodePluginJson: spec.opencodePluginJson,
|
|
16192
|
+
healthChecksJson: spec.healthChecksJson,
|
|
16193
|
+
status: spec.status,
|
|
16194
|
+
signalExtractorDefinitions: spec.signalExtractorDefinitions,
|
|
16179
16195
|
projectId
|
|
16180
16196
|
};
|
|
16181
16197
|
const result = await stepDefinitions.upsertStepDefinition({
|
|
@@ -16289,10 +16305,19 @@ function any2(conditions, outcome) {
|
|
|
16289
16305
|
return { _tag: "rule", mode: "any", conditions, outcome };
|
|
16290
16306
|
}
|
|
16291
16307
|
function when(signal2, operator, value, outcome) {
|
|
16308
|
+
const condition = {
|
|
16309
|
+
_tag: "signal",
|
|
16310
|
+
signal: signal2,
|
|
16311
|
+
operator,
|
|
16312
|
+
value
|
|
16313
|
+
};
|
|
16314
|
+
if (outcome === undefined) {
|
|
16315
|
+
return condition;
|
|
16316
|
+
}
|
|
16292
16317
|
return {
|
|
16293
16318
|
_tag: "rule",
|
|
16294
16319
|
mode: "all",
|
|
16295
|
-
conditions: [
|
|
16320
|
+
conditions: [condition],
|
|
16296
16321
|
outcome
|
|
16297
16322
|
};
|
|
16298
16323
|
}
|
|
@@ -16383,521 +16408,94 @@ function extractInlineComputedSignals(policy) {
|
|
|
16383
16408
|
availableWhenResultStatusIn: inline.availableWhenResultStatusIn ? [...inline.availableWhenResultStatusIn] : null
|
|
16384
16409
|
};
|
|
16385
16410
|
const existing = byKey.get(def.key);
|
|
16386
|
-
if (existing) {
|
|
16387
|
-
if (!isSameComputedDefinition(existing, def)) {
|
|
16388
|
-
throw new Error(`Conflicting inline computed signal definitions for key "${def.key}"`);
|
|
16389
|
-
}
|
|
16390
|
-
return;
|
|
16391
|
-
}
|
|
16392
|
-
byKey.set(def.key, def);
|
|
16393
|
-
});
|
|
16394
|
-
}
|
|
16395
|
-
return [...byKey.values()];
|
|
16396
|
-
}
|
|
16397
|
-
|
|
16398
|
-
// src/definitions/advancement-policies/cohort-advancement-policy.ts
|
|
16399
|
-
var cohortAdvancementEventTypeValues = ["continue", "block"];
|
|
16400
|
-
function serializeCohortCondition(condition) {
|
|
16401
|
-
if (condition._tag === "signal") {
|
|
16402
|
-
return {
|
|
16403
|
-
fact: typeof condition.signal === "string" ? condition.signal : condition.signal.key,
|
|
16404
|
-
operator: condition.operator,
|
|
16405
|
-
value: condition.value
|
|
16406
|
-
};
|
|
16407
|
-
}
|
|
16408
|
-
if (condition._tag === "all") {
|
|
16409
|
-
return { all: condition.conditions.map(serializeCohortCondition) };
|
|
16410
|
-
}
|
|
16411
|
-
return { any: condition.conditions.map(serializeCohortCondition) };
|
|
16412
|
-
}
|
|
16413
|
-
function serializeCohortRule(rule) {
|
|
16414
|
-
return {
|
|
16415
|
-
conditions: { [rule.mode]: rule.conditions.map(serializeCohortCondition) },
|
|
16416
|
-
event: {
|
|
16417
|
-
type: rule.outcome,
|
|
16418
|
-
...rule.outcomeJson ? { params: rule.outcomeJson } : {}
|
|
16419
|
-
}
|
|
16420
|
-
};
|
|
16421
|
-
}
|
|
16422
|
-
function serializeCohortAdvancementPolicy(policy) {
|
|
16423
|
-
if (!policy) {
|
|
16424
|
-
return { rules: [], defaultEventType: "continue", defaultEventParamsJson: null };
|
|
16425
|
-
}
|
|
16426
|
-
return {
|
|
16427
|
-
rules: (policy.rules ?? []).map(serializeCohortRule),
|
|
16428
|
-
defaultEventType: policy.default,
|
|
16429
|
-
defaultEventParamsJson: policy.defaultParamsJson ?? null
|
|
16430
|
-
};
|
|
16431
|
-
}
|
|
16432
|
-
function visitCohortSignalConditions(conditions, visit) {
|
|
16433
|
-
for (const c of conditions) {
|
|
16434
|
-
if (c._tag === "signal") {
|
|
16435
|
-
visit(c);
|
|
16436
|
-
} else {
|
|
16437
|
-
visitCohortSignalConditions(c.conditions, visit);
|
|
16438
|
-
}
|
|
16439
|
-
}
|
|
16440
|
-
}
|
|
16441
|
-
function isSameStepSignalsListDefinition(a, b) {
|
|
16442
|
-
return JSON.stringify(a.ops) === JSON.stringify(b.ops) && JSON.stringify(a.reducer) === JSON.stringify(b.reducer);
|
|
16443
|
-
}
|
|
16444
|
-
function extractInlineStepSignalsListDefinitions(policy) {
|
|
16445
|
-
if (!policy?.rules)
|
|
16446
|
-
return [];
|
|
16447
|
-
const byKey = new Map;
|
|
16448
|
-
for (const rule of policy.rules) {
|
|
16449
|
-
visitCohortSignalConditions(rule.conditions, (cond) => {
|
|
16450
|
-
if (typeof cond.signal === "string")
|
|
16451
|
-
return;
|
|
16452
|
-
const inline = cond.signal;
|
|
16453
|
-
const def = {
|
|
16454
|
-
key: inline.key,
|
|
16455
|
-
ops: inline.ops,
|
|
16456
|
-
reducer: inline.reducer
|
|
16457
|
-
};
|
|
16458
|
-
const existing = byKey.get(def.key);
|
|
16459
|
-
if (existing) {
|
|
16460
|
-
if (!isSameStepSignalsListDefinition(existing, def)) {
|
|
16461
|
-
throw new Error(`Conflicting inline stepSignalsList definitions for key "${def.key}"`);
|
|
16462
|
-
}
|
|
16463
|
-
return;
|
|
16464
|
-
}
|
|
16465
|
-
byKey.set(def.key, def);
|
|
16466
|
-
});
|
|
16467
|
-
}
|
|
16468
|
-
return [...byKey.values()];
|
|
16469
|
-
}
|
|
16470
|
-
|
|
16471
|
-
// src/definitions/pipelines/chain-graph.ts
|
|
16472
|
-
function tryOrderChainNodeDefinitions(nodeDefinitions, dependencyEdges) {
|
|
16473
|
-
const nodesByKey = new Map;
|
|
16474
|
-
for (const nodeDefinition of nodeDefinitions) {
|
|
16475
|
-
nodesByKey.set(nodeDefinition.nodeKey, nodeDefinition);
|
|
16476
|
-
}
|
|
16477
|
-
const outgoing = new Map;
|
|
16478
|
-
const incomingCount = new Map;
|
|
16479
|
-
for (const nodeDefinition of nodeDefinitions) {
|
|
16480
|
-
incomingCount.set(nodeDefinition.nodeKey, 0);
|
|
16481
|
-
}
|
|
16482
|
-
for (const edge of dependencyEdges) {
|
|
16483
|
-
if (!nodesByKey.has(edge.fromNodeKey) || !nodesByKey.has(edge.toNodeKey)) {
|
|
16484
|
-
return null;
|
|
16485
|
-
}
|
|
16486
|
-
if (outgoing.has(edge.fromNodeKey))
|
|
16487
|
-
return null;
|
|
16488
|
-
outgoing.set(edge.fromNodeKey, edge.toNodeKey);
|
|
16489
|
-
incomingCount.set(edge.toNodeKey, (incomingCount.get(edge.toNodeKey) ?? 0) + 1);
|
|
16490
|
-
}
|
|
16491
|
-
for (const count of incomingCount.values()) {
|
|
16492
|
-
if (count > 1)
|
|
16493
|
-
return null;
|
|
16494
|
-
}
|
|
16495
|
-
if (nodeDefinitions.length === 0)
|
|
16496
|
-
return [];
|
|
16497
|
-
const roots = nodeDefinitions.filter((nodeDefinition) => (incomingCount.get(nodeDefinition.nodeKey) ?? 0) === 0);
|
|
16498
|
-
if (roots.length !== 1)
|
|
16499
|
-
return null;
|
|
16500
|
-
const rootNode = roots[0];
|
|
16501
|
-
if (!rootNode)
|
|
16502
|
-
return null;
|
|
16503
|
-
const ordered = [];
|
|
16504
|
-
const visited = new Set;
|
|
16505
|
-
let currentKey = rootNode.nodeKey;
|
|
16506
|
-
while (currentKey !== undefined) {
|
|
16507
|
-
if (visited.has(currentKey))
|
|
16508
|
-
return null;
|
|
16509
|
-
visited.add(currentKey);
|
|
16510
|
-
const currentNode = nodesByKey.get(currentKey);
|
|
16511
|
-
if (!currentNode)
|
|
16512
|
-
return null;
|
|
16513
|
-
ordered.push(currentNode);
|
|
16514
|
-
currentKey = outgoing.get(currentKey);
|
|
16515
|
-
}
|
|
16516
|
-
if (ordered.length !== nodeDefinitions.length)
|
|
16517
|
-
return null;
|
|
16518
|
-
return ordered;
|
|
16519
|
-
}
|
|
16520
|
-
function buildChainDependencyEdges(orderedNodes) {
|
|
16521
|
-
const dependencyEdges = [];
|
|
16522
|
-
for (let index = 0;index < orderedNodes.length - 1; index += 1) {
|
|
16523
|
-
const from = orderedNodes[index];
|
|
16524
|
-
const to = orderedNodes[index + 1];
|
|
16525
|
-
if (!from || !to)
|
|
16526
|
-
continue;
|
|
16527
|
-
dependencyEdges.push({ fromNodeKey: from.nodeKey, toNodeKey: to.nodeKey });
|
|
16528
|
-
}
|
|
16529
|
-
return dependencyEdges;
|
|
16530
|
-
}
|
|
16531
|
-
|
|
16532
|
-
// src/definitions/pipelines/define-pipeline.ts
|
|
16533
|
-
function serializeBinding(binding) {
|
|
16534
|
-
if (binding.source === "pipeline_input") {
|
|
16535
|
-
return { source: "pipeline_input", path: binding.path };
|
|
16536
|
-
}
|
|
16537
|
-
if (binding.source === "work_item") {
|
|
16538
|
-
return { source: "work_item", field: binding.field };
|
|
16539
|
-
}
|
|
16540
|
-
if (binding.source === "step_signal") {
|
|
16541
|
-
return {
|
|
16542
|
-
source: "step_signal",
|
|
16543
|
-
stepKey: binding.step.key,
|
|
16544
|
-
signalKey: binding.signalKey
|
|
16545
|
-
};
|
|
16546
|
-
}
|
|
16547
|
-
if (binding.source === "literal") {
|
|
16548
|
-
return { source: "literal", value: binding.value };
|
|
16549
|
-
}
|
|
16550
|
-
if (binding.source === "signals_list") {
|
|
16551
|
-
return { source: "signals_list", stepKey: binding.fanOutStep.key };
|
|
16552
|
-
}
|
|
16553
|
-
if (binding.source === "fan_out_item") {
|
|
16554
|
-
return { source: "fan_out_item" };
|
|
16555
|
-
}
|
|
16556
|
-
return { source: "step_output", stepKey: binding.step.key };
|
|
16557
|
-
}
|
|
16558
|
-
var isFanOutConfig = (node) => ("nodeType" in node) && node.nodeType === "fanOut";
|
|
16559
|
-
var isCohortGateConfig = (node) => ("nodeType" in node) && node.nodeType === "cohortGate";
|
|
16560
|
-
function serializeInputBindings(input, pipelineInputBindings) {
|
|
16561
|
-
const autoBindings = {
|
|
16562
|
-
workItemTitle: { source: "work_item", field: "title" },
|
|
16563
|
-
workItemDescription: { source: "work_item", field: "description" }
|
|
16564
|
-
};
|
|
16565
|
-
const pipelineBindings = {};
|
|
16566
|
-
for (const [key, binding] of Object.entries(pipelineInputBindings ?? {})) {
|
|
16567
|
-
pipelineBindings[key] = serializeBinding(binding);
|
|
16568
|
-
}
|
|
16569
|
-
const explicitBindings = Object.fromEntries(Object.entries(input ?? {}).filter((entry) => entry[1] !== undefined).map(([key, binding]) => [key, serializeBinding(binding)]));
|
|
16570
|
-
return { ...autoBindings, ...pipelineBindings, ...explicitBindings };
|
|
16571
|
-
}
|
|
16572
|
-
function buildPipelineSpec(config2) {
|
|
16573
|
-
const nodes = config2.nodes;
|
|
16574
|
-
const stepDefMap = new Map;
|
|
16575
|
-
const registerStepDef = (step) => {
|
|
16576
|
-
const mapKey = `${step.key}@v${String(step.version)}`;
|
|
16577
|
-
if (!stepDefMap.has(mapKey)) {
|
|
16578
|
-
stepDefMap.set(mapKey, step);
|
|
16579
|
-
}
|
|
16580
|
-
};
|
|
16581
|
-
for (const node of nodes) {
|
|
16582
|
-
if (isFanOutConfig(node)) {
|
|
16583
|
-
registerStepDef(node.fanOutStep);
|
|
16584
|
-
} else if (!isCohortGateConfig(node)) {
|
|
16585
|
-
registerStepDef(node.step);
|
|
16586
|
-
}
|
|
16587
|
-
}
|
|
16588
|
-
let inputSchemaJson = null;
|
|
16589
|
-
if (config2.input) {
|
|
16590
|
-
try {
|
|
16591
|
-
inputSchemaJson = exports_external.toJSONSchema(config2.input);
|
|
16592
|
-
} catch {
|
|
16593
|
-
inputSchemaJson = null;
|
|
16594
|
-
}
|
|
16595
|
-
}
|
|
16596
|
-
const nodeDefinitions = nodes.map((node) => {
|
|
16597
|
-
if (isCohortGateConfig(node)) {
|
|
16598
|
-
const serializedPolicy = serializeCohortAdvancementPolicy(node.advanceAll);
|
|
16599
|
-
const inlineStepSignalsListDefinitions = extractInlineStepSignalsListDefinitions(node.advanceAll);
|
|
16600
|
-
return {
|
|
16601
|
-
nodeKey: node.nodeKey,
|
|
16602
|
-
kind: "cohortGate",
|
|
16603
|
-
advanceAllPolicyDefinition: serializedPolicy,
|
|
16604
|
-
stepSignalsListDefinitions: [
|
|
16605
|
-
...inlineStepSignalsListDefinitions,
|
|
16606
|
-
...node.stepSignalsListDefinitions ?? []
|
|
16607
|
-
]
|
|
16608
|
-
};
|
|
16609
|
-
}
|
|
16610
|
-
if (isFanOutConfig(node)) {
|
|
16611
|
-
return {
|
|
16612
|
-
nodeKey: node.fanOutStep.key,
|
|
16613
|
-
kind: "fanOut",
|
|
16614
|
-
stepKey: node.fanOutStep.key,
|
|
16615
|
-
stepName: node.fanOutStep.name,
|
|
16616
|
-
stepDescription: node.fanOutStep.description,
|
|
16617
|
-
inputBindingsJson: serializeInputBindings(node.input, config2.pipelineInputBindings),
|
|
16618
|
-
timeoutSeconds: node.timeout ?? null,
|
|
16619
|
-
overSignalKey: node.overSignalKey,
|
|
16620
|
-
advanceEachPolicyDefinition: serializeCohortAdvancementPolicy(node.advanceEach)
|
|
16621
|
-
};
|
|
16622
|
-
}
|
|
16623
|
-
return {
|
|
16624
|
-
nodeKey: node.step.key,
|
|
16625
|
-
kind: "step",
|
|
16626
|
-
stepKey: node.step.key,
|
|
16627
|
-
stepName: node.step.name,
|
|
16628
|
-
stepDescription: node.step.description,
|
|
16629
|
-
inputBindingsJson: serializeInputBindings(node.input, config2.pipelineInputBindings),
|
|
16630
|
-
timeoutSeconds: node.timeout ?? null,
|
|
16631
|
-
advancementPolicyDefinition: serializeAdvancementPolicy(node.advancement),
|
|
16632
|
-
computedSignalDefinitions: extractInlineComputedSignals(node.advancement)
|
|
16633
|
-
};
|
|
16634
|
-
});
|
|
16635
|
-
const dependencyEdges = buildChainDependencyEdges(nodeDefinitions);
|
|
16636
|
-
return {
|
|
16637
|
-
key: config2.key,
|
|
16638
|
-
name: config2.name,
|
|
16639
|
-
description: config2.description ?? null,
|
|
16640
|
-
version: config2.version ?? 1,
|
|
16641
|
-
status: config2.status ?? "active",
|
|
16642
|
-
inputSchemaJson,
|
|
16643
|
-
_stepDefinitions: [...stepDefMap.values()],
|
|
16644
|
-
nodeDefinitions,
|
|
16645
|
-
dependencyEdges
|
|
16646
|
-
};
|
|
16647
|
-
}
|
|
16648
|
-
// src/definitions/advancement-policies/fluent-rules.ts
|
|
16649
|
-
var LEAF_BRAND = Symbol.for("boboddy.fluentRule.leaf");
|
|
16650
|
-
var GROUP_BRAND = Symbol.for("boboddy.fluentRule.group");
|
|
16651
|
-
var SIGNAL_KEY = Symbol.for("boboddy.fluentRule.signalKey");
|
|
16652
|
-
function createSignalRef(signal2) {
|
|
16653
|
-
const leaf = (operator, value) => {
|
|
16654
|
-
const condition = {
|
|
16655
|
-
_tag: "signal",
|
|
16656
|
-
signal: signal2,
|
|
16657
|
-
operator,
|
|
16658
|
-
value
|
|
16659
|
-
};
|
|
16660
|
-
return {
|
|
16661
|
-
[LEAF_BRAND]: condition,
|
|
16662
|
-
then(outcome) {
|
|
16663
|
-
return {
|
|
16664
|
-
_tag: "rule",
|
|
16665
|
-
mode: "all",
|
|
16666
|
-
conditions: [condition],
|
|
16667
|
-
outcome
|
|
16668
|
-
};
|
|
16669
|
-
}
|
|
16670
|
-
};
|
|
16671
|
-
};
|
|
16672
|
-
return {
|
|
16673
|
-
eq: (v) => leaf("equal", v),
|
|
16674
|
-
ne: (v) => leaf("notEqual", v),
|
|
16675
|
-
gt: (v) => leaf("greaterThan", v),
|
|
16676
|
-
gte: (v) => leaf("greaterThanInclusive", v),
|
|
16677
|
-
lt: (v) => leaf("lessThan", v),
|
|
16678
|
-
lte: (v) => leaf("lessThanInclusive", v),
|
|
16679
|
-
in: (vs) => leaf("in", vs),
|
|
16680
|
-
notIn: (vs) => leaf("notIn", vs),
|
|
16681
|
-
contains: (v) => leaf("contains", v),
|
|
16682
|
-
doesNotContain: (v) => leaf("doesNotContain", v)
|
|
16683
|
-
};
|
|
16684
|
-
}
|
|
16685
|
-
function extractCondition(ref) {
|
|
16686
|
-
if (LEAF_BRAND in ref)
|
|
16687
|
-
return ref[LEAF_BRAND];
|
|
16688
|
-
const group = ref[GROUP_BRAND];
|
|
16689
|
-
return group.mode === "all" ? { _tag: "all", conditions: group.conditions } : { _tag: "any", conditions: group.conditions };
|
|
16690
|
-
}
|
|
16691
|
-
function createGroup(mode, refs) {
|
|
16692
|
-
const conditions = refs.map(extractCondition);
|
|
16693
|
-
return {
|
|
16694
|
-
[GROUP_BRAND]: { mode, conditions },
|
|
16695
|
-
then(outcome) {
|
|
16696
|
-
return { _tag: "rule", mode, conditions, outcome };
|
|
16697
|
-
}
|
|
16698
|
-
};
|
|
16699
|
-
}
|
|
16700
|
-
function resolveComputedArg(arg) {
|
|
16701
|
-
return arg[SIGNAL_KEY];
|
|
16702
|
-
}
|
|
16703
|
-
function makeKeyedSignalRef(key) {
|
|
16704
|
-
const ref = createSignalRef(key);
|
|
16705
|
-
return Object.assign(ref, {
|
|
16706
|
-
[SIGNAL_KEY]: key
|
|
16707
|
-
});
|
|
16708
|
-
}
|
|
16709
|
-
function makeAdvanceCtx() {
|
|
16710
|
-
const wrapComputed = (token) => createSignalRef(token);
|
|
16711
|
-
return {
|
|
16712
|
-
signal: (key) => makeKeyedSignalRef(key),
|
|
16713
|
-
stepSignals: new Proxy({}, {
|
|
16714
|
-
get(_, key) {
|
|
16715
|
-
if (typeof key === "string")
|
|
16716
|
-
return makeKeyedSignalRef(key);
|
|
16411
|
+
if (existing) {
|
|
16412
|
+
if (!isSameComputedDefinition(existing, def)) {
|
|
16413
|
+
throw new Error(`Conflicting inline computed signal definitions for key "${def.key}"`);
|
|
16414
|
+
}
|
|
16717
16415
|
return;
|
|
16718
16416
|
}
|
|
16719
|
-
|
|
16720
|
-
|
|
16721
|
-
|
|
16722
|
-
|
|
16723
|
-
min: (...args) => wrapComputed(Computed.min(args.map(resolveComputedArg))),
|
|
16724
|
-
max: (...args) => wrapComputed(Computed.max(args.map(resolveComputedArg))),
|
|
16725
|
-
count: (...args) => wrapComputed(Computed.count(args.map(resolveComputedArg))),
|
|
16726
|
-
booleanAny: (...args) => wrapComputed(Computed.booleanAny(args.map(resolveComputedArg))),
|
|
16727
|
-
booleanAll: (...args) => wrapComputed(Computed.booleanAll(args.map(resolveComputedArg))),
|
|
16728
|
-
all: (...refs) => createGroup("all", refs),
|
|
16729
|
-
any: (...refs) => createGroup("any", refs),
|
|
16730
|
-
route: (pipelineKey, inputJson) => inputJson !== undefined ? { outcome: "route", pipelineKey, inputJson } : { outcome: "route", pipelineKey }
|
|
16731
|
-
};
|
|
16732
|
-
}
|
|
16733
|
-
|
|
16734
|
-
// src/definitions/pipelines/input-accessor.ts
|
|
16735
|
-
var ACCESSOR_BRAND = Symbol.for("boboddy.inputAccessor.brand");
|
|
16736
|
-
var ACCESSOR_PATH = Symbol.for("boboddy.inputAccessor.path");
|
|
16737
|
-
function createInputAccessor(_schema) {
|
|
16738
|
-
return createProxy([]);
|
|
16739
|
-
}
|
|
16740
|
-
function createProxy(path) {
|
|
16741
|
-
const pathStr = path.join(".");
|
|
16742
|
-
const target = Object.freeze({});
|
|
16743
|
-
return new Proxy(target, {
|
|
16744
|
-
get(_t, prop) {
|
|
16745
|
-
if (prop === ACCESSOR_BRAND)
|
|
16746
|
-
return true;
|
|
16747
|
-
if (prop === ACCESSOR_PATH)
|
|
16748
|
-
return pathStr;
|
|
16749
|
-
if (prop === "toJSON") {
|
|
16750
|
-
return () => ({
|
|
16751
|
-
source: "pipeline_input",
|
|
16752
|
-
path: pathStr
|
|
16753
|
-
});
|
|
16754
|
-
}
|
|
16755
|
-
if (prop === Symbol.toPrimitive) {
|
|
16756
|
-
return () => {
|
|
16757
|
-
throw new Error(`Pipeline input accessor at path "${pathStr || "<root>"}" cannot be coerced to a primitive. ` + `Pass it to a step input field instead of using it in a string/number expression.`);
|
|
16758
|
-
};
|
|
16759
|
-
}
|
|
16760
|
-
if (typeof prop === "symbol")
|
|
16761
|
-
return;
|
|
16762
|
-
return createProxy([...path, prop]);
|
|
16763
|
-
},
|
|
16764
|
-
has(_t, prop) {
|
|
16765
|
-
return prop === ACCESSOR_BRAND || prop === ACCESSOR_PATH;
|
|
16766
|
-
},
|
|
16767
|
-
ownKeys() {
|
|
16768
|
-
throw new Error(`Pipeline input accessor at path "${pathStr || "<root>"}" cannot be enumerated. ` + `Drill into specific fields instead of spreading the input.`);
|
|
16769
|
-
},
|
|
16770
|
-
set() {
|
|
16771
|
-
throw new Error(`Pipeline input accessor at path "${pathStr || "<root>"}" is read-only.`);
|
|
16772
|
-
}
|
|
16773
|
-
});
|
|
16774
|
-
}
|
|
16775
|
-
function isInputAccessor(value) {
|
|
16776
|
-
return typeof value === "object" && value !== null && value[ACCESSOR_BRAND] === true;
|
|
16777
|
-
}
|
|
16778
|
-
function materializeAccessor(accessor) {
|
|
16779
|
-
return {
|
|
16780
|
-
source: "pipeline_input",
|
|
16781
|
-
path: accessor[ACCESSOR_PATH]
|
|
16782
|
-
};
|
|
16417
|
+
byKey.set(def.key, def);
|
|
16418
|
+
});
|
|
16419
|
+
}
|
|
16420
|
+
return [...byKey.values()];
|
|
16783
16421
|
}
|
|
16784
16422
|
|
|
16785
|
-
// src/definitions/
|
|
16786
|
-
var
|
|
16787
|
-
|
|
16788
|
-
"
|
|
16789
|
-
|
|
16790
|
-
|
|
16791
|
-
|
|
16792
|
-
|
|
16793
|
-
|
|
16794
|
-
"description",
|
|
16795
|
-
"sourceCreatedAt",
|
|
16796
|
-
"sourceUpdatedAt",
|
|
16797
|
-
"createdByUserId",
|
|
16798
|
-
"parentWorkItemId",
|
|
16799
|
-
"createdAt",
|
|
16800
|
-
"updatedAt"
|
|
16801
|
-
];
|
|
16802
|
-
var WORK_ITEM_FIELDS_PATH_PREFIX = "fields.";
|
|
16803
|
-
function resolveWorkItemFieldPath(record2, path) {
|
|
16804
|
-
if (typeof record2 !== "object" || record2 === null)
|
|
16805
|
-
return;
|
|
16806
|
-
const asRecord = record2;
|
|
16807
|
-
if (path.startsWith(WORK_ITEM_FIELDS_PATH_PREFIX)) {
|
|
16808
|
-
const fieldName = path.slice(WORK_ITEM_FIELDS_PATH_PREFIX.length);
|
|
16809
|
-
const fields = asRecord["fields"];
|
|
16810
|
-
if (typeof fields !== "object" || fields === null)
|
|
16811
|
-
return;
|
|
16812
|
-
return fields[fieldName];
|
|
16423
|
+
// src/definitions/advancement-policies/cohort-advancement-policy.ts
|
|
16424
|
+
var cohortAdvancementEventTypeValues = ["continue", "block"];
|
|
16425
|
+
function serializeCohortCondition(condition) {
|
|
16426
|
+
if (condition._tag === "signal") {
|
|
16427
|
+
return {
|
|
16428
|
+
fact: typeof condition.signal === "string" ? condition.signal : condition.signal.key,
|
|
16429
|
+
operator: condition.operator,
|
|
16430
|
+
value: condition.value
|
|
16431
|
+
};
|
|
16813
16432
|
}
|
|
16814
|
-
|
|
16433
|
+
if (condition._tag === "all") {
|
|
16434
|
+
return { all: condition.conditions.map(serializeCohortCondition) };
|
|
16435
|
+
}
|
|
16436
|
+
return { any: condition.conditions.map(serializeCohortCondition) };
|
|
16815
16437
|
}
|
|
16816
|
-
|
|
16817
|
-
// src/definitions/pipelines/builder-helpers.ts
|
|
16818
|
-
var WORK_ITEM_ACCESSOR = Object.freeze({
|
|
16819
|
-
...Object.fromEntries(WORK_ITEM_TOP_LEVEL_FIELDS.map((field) => [
|
|
16820
|
-
field,
|
|
16821
|
-
Object.freeze({ source: "work_item", field })
|
|
16822
|
-
])),
|
|
16823
|
-
field: (fieldName) => Object.freeze({
|
|
16824
|
-
source: "work_item",
|
|
16825
|
-
field: `${WORK_ITEM_FIELDS_PATH_PREFIX}${fieldName}`
|
|
16826
|
-
})
|
|
16827
|
-
});
|
|
16828
|
-
var WORK_ITEM_FIELD_BINDINGS = {
|
|
16829
|
-
workItemTitle: { source: "work_item", field: "title" },
|
|
16830
|
-
workItemDescription: { source: "work_item", field: "description" }
|
|
16831
|
-
};
|
|
16832
|
-
function makeStepInputCtx(inputSchema) {
|
|
16833
|
-
const baseAccessor = createInputAccessor(inputSchema);
|
|
16834
|
-
const input = new Proxy(baseAccessor, {
|
|
16835
|
-
get(target, prop) {
|
|
16836
|
-
if (typeof prop === "string" && prop in WORK_ITEM_FIELD_BINDINGS) {
|
|
16837
|
-
return WORK_ITEM_FIELD_BINDINGS[prop];
|
|
16838
|
-
}
|
|
16839
|
-
return target[prop];
|
|
16840
|
-
}
|
|
16841
|
-
});
|
|
16438
|
+
function serializeCohortRule(rule) {
|
|
16842
16439
|
return {
|
|
16843
|
-
|
|
16844
|
-
|
|
16845
|
-
|
|
16846
|
-
|
|
16847
|
-
output(step) {
|
|
16848
|
-
return { source: "step_output", step };
|
|
16849
|
-
},
|
|
16850
|
-
literal: literal2,
|
|
16851
|
-
signalsList(fanOutStep) {
|
|
16852
|
-
return { source: "signals_list", fanOutStep };
|
|
16440
|
+
conditions: { [rule.mode]: rule.conditions.map(serializeCohortCondition) },
|
|
16441
|
+
event: {
|
|
16442
|
+
type: rule.outcome,
|
|
16443
|
+
...rule.outcomeJson ? { params: rule.outcomeJson } : {}
|
|
16853
16444
|
}
|
|
16854
16445
|
};
|
|
16855
16446
|
}
|
|
16856
|
-
function
|
|
16857
|
-
|
|
16858
|
-
}
|
|
16859
|
-
function normalizeInputMapping(mapping) {
|
|
16860
|
-
if (!mapping)
|
|
16861
|
-
return;
|
|
16862
|
-
const out = {};
|
|
16863
|
-
for (const [key, value] of Object.entries(mapping)) {
|
|
16864
|
-
if (value === undefined)
|
|
16865
|
-
continue;
|
|
16866
|
-
out[key] = isInputAccessor(value) ? materializeAccessor(value) : value;
|
|
16447
|
+
function serializeCohortAdvancementPolicy(policy) {
|
|
16448
|
+
if (!policy) {
|
|
16449
|
+
return { rules: [], defaultEventType: "continue", defaultEventParamsJson: null };
|
|
16867
16450
|
}
|
|
16868
|
-
return
|
|
16451
|
+
return {
|
|
16452
|
+
rules: (policy.rules ?? []).map(serializeCohortRule),
|
|
16453
|
+
defaultEventType: policy.default,
|
|
16454
|
+
defaultEventParamsJson: policy.defaultParamsJson ?? null
|
|
16455
|
+
};
|
|
16869
16456
|
}
|
|
16870
|
-
function
|
|
16871
|
-
|
|
16872
|
-
|
|
16873
|
-
|
|
16874
|
-
|
|
16875
|
-
|
|
16876
|
-
source: "work_item",
|
|
16877
|
-
field: `${WORK_ITEM_FIELDS_PATH_PREFIX}${fieldName}`
|
|
16878
|
-
}),
|
|
16879
|
-
literal: literal2
|
|
16880
|
-
});
|
|
16881
|
-
if (definition.schema instanceof exports_external.ZodObject) {
|
|
16882
|
-
const validKeys = new Set(Object.keys(definition.schema.shape));
|
|
16883
|
-
const unknown2 = Object.keys(raw).filter((key) => !validKeys.has(key));
|
|
16884
|
-
if (unknown2.length > 0) {
|
|
16885
|
-
throw new Error(`${label}.bindings returned key${unknown2.length > 1 ? "s" : ""} not in schema: ${unknown2.map((key) => `"${key}"`).join(", ")}`);
|
|
16457
|
+
function visitCohortSignalConditions(conditions, visit) {
|
|
16458
|
+
for (const c of conditions) {
|
|
16459
|
+
if (c._tag === "signal") {
|
|
16460
|
+
visit(c);
|
|
16461
|
+
} else {
|
|
16462
|
+
visitCohortSignalConditions(c.conditions, visit);
|
|
16886
16463
|
}
|
|
16887
16464
|
}
|
|
16888
|
-
return normalizeInputMapping(raw) ?? {};
|
|
16889
16465
|
}
|
|
16890
|
-
function
|
|
16891
|
-
|
|
16892
|
-
|
|
16893
|
-
|
|
16894
|
-
|
|
16895
|
-
|
|
16466
|
+
function isSameStepSignalsListDefinition(a, b) {
|
|
16467
|
+
return JSON.stringify(a.ops) === JSON.stringify(b.ops) && JSON.stringify(a.reducer) === JSON.stringify(b.reducer);
|
|
16468
|
+
}
|
|
16469
|
+
function extractInlineStepSignalsListDefinitions(policy) {
|
|
16470
|
+
if (!policy?.rules)
|
|
16471
|
+
return [];
|
|
16472
|
+
const byKey = new Map;
|
|
16473
|
+
for (const rule of policy.rules) {
|
|
16474
|
+
visitCohortSignalConditions(rule.conditions, (cond) => {
|
|
16475
|
+
if (typeof cond.signal === "string")
|
|
16476
|
+
return;
|
|
16477
|
+
const inline = cond.signal;
|
|
16478
|
+
const def = {
|
|
16479
|
+
key: inline.key,
|
|
16480
|
+
ops: inline.ops,
|
|
16481
|
+
reducer: inline.reducer
|
|
16482
|
+
};
|
|
16483
|
+
const existing = byKey.get(def.key);
|
|
16484
|
+
if (existing) {
|
|
16485
|
+
if (!isSameStepSignalsListDefinition(existing, def)) {
|
|
16486
|
+
throw new Error(`Conflicting inline stepSignalsList definitions for key "${def.key}"`);
|
|
16487
|
+
}
|
|
16488
|
+
return;
|
|
16489
|
+
}
|
|
16490
|
+
byKey.set(def.key, def);
|
|
16491
|
+
});
|
|
16492
|
+
}
|
|
16493
|
+
return [...byKey.values()];
|
|
16896
16494
|
}
|
|
16897
16495
|
|
|
16898
16496
|
// src/definitions/advancement-policies/cohort-fluent-rules.ts
|
|
16899
|
-
var
|
|
16900
|
-
var
|
|
16497
|
+
var LEAF_BRAND = Symbol("boboddy.cohortRule.leaf");
|
|
16498
|
+
var GROUP_BRAND = Symbol("boboddy.cohortRule.group");
|
|
16901
16499
|
function createCohortSignalRef(signal2) {
|
|
16902
16500
|
const leaf = (operator, value) => {
|
|
16903
16501
|
const condition = {
|
|
@@ -16907,7 +16505,7 @@ function createCohortSignalRef(signal2) {
|
|
|
16907
16505
|
value
|
|
16908
16506
|
};
|
|
16909
16507
|
return {
|
|
16910
|
-
[
|
|
16508
|
+
[LEAF_BRAND]: condition,
|
|
16911
16509
|
then(outcome, paramsJson) {
|
|
16912
16510
|
return {
|
|
16913
16511
|
_tag: "rule",
|
|
@@ -16934,7 +16532,7 @@ function createCohortSignalRef(signal2) {
|
|
|
16934
16532
|
}
|
|
16935
16533
|
function createCohortLeafFromCondition(condition) {
|
|
16936
16534
|
return {
|
|
16937
|
-
[
|
|
16535
|
+
[LEAF_BRAND]: condition,
|
|
16938
16536
|
then(outcome, paramsJson) {
|
|
16939
16537
|
return {
|
|
16940
16538
|
_tag: "rule",
|
|
@@ -16947,15 +16545,15 @@ function createCohortLeafFromCondition(condition) {
|
|
|
16947
16545
|
};
|
|
16948
16546
|
}
|
|
16949
16547
|
function extractCohortCondition(ref) {
|
|
16950
|
-
if (
|
|
16951
|
-
return ref[
|
|
16952
|
-
const group = ref[
|
|
16548
|
+
if (LEAF_BRAND in ref)
|
|
16549
|
+
return ref[LEAF_BRAND];
|
|
16550
|
+
const group = ref[GROUP_BRAND];
|
|
16953
16551
|
return group.mode === "all" ? { _tag: "all", conditions: group.conditions } : { _tag: "any", conditions: group.conditions };
|
|
16954
16552
|
}
|
|
16955
16553
|
function createCohortGroup(mode, refs) {
|
|
16956
16554
|
const conditions = refs.map(extractCohortCondition);
|
|
16957
16555
|
return {
|
|
16958
|
-
[
|
|
16556
|
+
[GROUP_BRAND]: { mode, conditions },
|
|
16959
16557
|
then(outcome, paramsJson) {
|
|
16960
16558
|
return {
|
|
16961
16559
|
_tag: "rule",
|
|
@@ -17019,179 +16617,502 @@ function createStepSignalsListBuilder(ops) {
|
|
|
17019
16617
|
return createCohortSignalRef(token);
|
|
17020
16618
|
};
|
|
17021
16619
|
return {
|
|
17022
|
-
filter: (operator, value) => withOp({ op: "filter", operator, value }),
|
|
17023
|
-
sortBy: (direction = "asc") => withOp({ op: "sortBy", direction }),
|
|
17024
|
-
unique: () => withOp({ op: "unique" }),
|
|
17025
|
-
count: () => reduce({ op: "count" }),
|
|
17026
|
-
sum: () => reduce({ op: "sum" }),
|
|
17027
|
-
avg: () => reduce({ op: "avg" }),
|
|
17028
|
-
min: () => reduce({ op: "min" }),
|
|
17029
|
-
max: () => reduce({ op: "max" }),
|
|
17030
|
-
booleanAll: () => reduce({ op: "booleanAll" }),
|
|
17031
|
-
booleanAny: () => reduce({ op: "booleanAny" }),
|
|
17032
|
-
join: (separator = ",") => reduce({ op: "join", separator }),
|
|
17033
|
-
first: () => reduce({ op: "first" }),
|
|
17034
|
-
last: () => reduce({ op: "last" })
|
|
16620
|
+
filter: (operator, value) => withOp({ op: "filter", operator, value }),
|
|
16621
|
+
sortBy: (direction = "asc") => withOp({ op: "sortBy", direction }),
|
|
16622
|
+
unique: () => withOp({ op: "unique" }),
|
|
16623
|
+
count: () => reduce({ op: "count" }),
|
|
16624
|
+
sum: () => reduce({ op: "sum" }),
|
|
16625
|
+
avg: () => reduce({ op: "avg" }),
|
|
16626
|
+
min: () => reduce({ op: "min" }),
|
|
16627
|
+
max: () => reduce({ op: "max" }),
|
|
16628
|
+
booleanAll: () => reduce({ op: "booleanAll" }),
|
|
16629
|
+
booleanAny: () => reduce({ op: "booleanAny" }),
|
|
16630
|
+
join: (separator = ",") => reduce({ op: "join", separator }),
|
|
16631
|
+
first: () => reduce({ op: "first" }),
|
|
16632
|
+
last: () => reduce({ op: "last" })
|
|
16633
|
+
};
|
|
16634
|
+
}
|
|
16635
|
+
function makeAdvanceAllCtx() {
|
|
16636
|
+
return {
|
|
16637
|
+
branchOutcomes: {
|
|
16638
|
+
total: () => createCohortSignalRef("branchCount"),
|
|
16639
|
+
count: (outcome) => createCohortSignalRef(`${outcome}Count`),
|
|
16640
|
+
every: (outcome) => createCohortLeafFromCondition({
|
|
16641
|
+
_tag: "signal",
|
|
16642
|
+
signal: `${outcome}Count`,
|
|
16643
|
+
operator: "equal",
|
|
16644
|
+
value: { fact: "branchCount" }
|
|
16645
|
+
}),
|
|
16646
|
+
some: (outcome) => createCohortLeafFromCondition({
|
|
16647
|
+
_tag: "signal",
|
|
16648
|
+
signal: `${outcome}Count`,
|
|
16649
|
+
operator: "greaterThan",
|
|
16650
|
+
value: 0
|
|
16651
|
+
})
|
|
16652
|
+
},
|
|
16653
|
+
stepSignalsList: {
|
|
16654
|
+
pluck: (signalKey) => createStepSignalsListBuilder([{ op: "pluck", signalKey }])
|
|
16655
|
+
},
|
|
16656
|
+
all: (...refs) => createCohortGroup("all", refs),
|
|
16657
|
+
any: (...refs) => createCohortGroup("any", refs)
|
|
16658
|
+
};
|
|
16659
|
+
}
|
|
16660
|
+
|
|
16661
|
+
// src/definitions/pipelines/bindings.ts
|
|
16662
|
+
function serializeBinding(binding) {
|
|
16663
|
+
if (binding.source === "pipeline_input") {
|
|
16664
|
+
return { source: "pipeline_input", path: binding.path };
|
|
16665
|
+
}
|
|
16666
|
+
if (binding.source === "work_item") {
|
|
16667
|
+
return { source: "work_item", field: binding.field };
|
|
16668
|
+
}
|
|
16669
|
+
if (binding.source === "step_signal") {
|
|
16670
|
+
return {
|
|
16671
|
+
source: "step_signal",
|
|
16672
|
+
stepKey: binding.nodeKey,
|
|
16673
|
+
signalKey: binding.signalKey
|
|
16674
|
+
};
|
|
16675
|
+
}
|
|
16676
|
+
if (binding.source === "literal") {
|
|
16677
|
+
return { source: "literal", value: binding.value };
|
|
16678
|
+
}
|
|
16679
|
+
if (binding.source === "signals_list") {
|
|
16680
|
+
return { source: "signals_list", stepKey: binding.nodeKey };
|
|
16681
|
+
}
|
|
16682
|
+
if (binding.source === "fan_out_item") {
|
|
16683
|
+
return { source: "fan_out_item" };
|
|
16684
|
+
}
|
|
16685
|
+
return { source: "step_output", stepKey: binding.nodeKey };
|
|
16686
|
+
}
|
|
16687
|
+
function serializeInputBindings(input) {
|
|
16688
|
+
const autoBindings = {
|
|
16689
|
+
workItemTitle: { source: "work_item", field: "title" },
|
|
16690
|
+
workItemDescription: { source: "work_item", field: "description" }
|
|
16691
|
+
};
|
|
16692
|
+
const explicitBindings = Object.fromEntries(Object.entries(input).filter((entry) => entry[1] !== undefined).map(([key, binding]) => [key, serializeBinding(binding)]));
|
|
16693
|
+
return { ...autoBindings, ...explicitBindings };
|
|
16694
|
+
}
|
|
16695
|
+
|
|
16696
|
+
// src/definitions/pipelines/work-item-fields.ts
|
|
16697
|
+
var WORK_ITEM_TOP_LEVEL_FIELDS = [
|
|
16698
|
+
"id",
|
|
16699
|
+
"projectId",
|
|
16700
|
+
"platform",
|
|
16701
|
+
"platformId",
|
|
16702
|
+
"platformKey",
|
|
16703
|
+
"url",
|
|
16704
|
+
"title",
|
|
16705
|
+
"description",
|
|
16706
|
+
"sourceCreatedAt",
|
|
16707
|
+
"sourceUpdatedAt",
|
|
16708
|
+
"createdByUserId",
|
|
16709
|
+
"parentWorkItemId",
|
|
16710
|
+
"createdAt",
|
|
16711
|
+
"updatedAt"
|
|
16712
|
+
];
|
|
16713
|
+
var WORK_ITEM_FIELDS_PATH_PREFIX = "fields.";
|
|
16714
|
+
function resolveWorkItemFieldPath(record2, path) {
|
|
16715
|
+
if (typeof record2 !== "object" || record2 === null)
|
|
16716
|
+
return;
|
|
16717
|
+
const asRecord = record2;
|
|
16718
|
+
if (path.startsWith(WORK_ITEM_FIELDS_PATH_PREFIX)) {
|
|
16719
|
+
const fieldName = path.slice(WORK_ITEM_FIELDS_PATH_PREFIX.length);
|
|
16720
|
+
const fields = asRecord["fields"];
|
|
16721
|
+
if (typeof fields !== "object" || fields === null)
|
|
16722
|
+
return;
|
|
16723
|
+
return fields[fieldName];
|
|
16724
|
+
}
|
|
16725
|
+
return asRecord[path];
|
|
16726
|
+
}
|
|
16727
|
+
|
|
16728
|
+
// src/definitions/pipelines/builder-helpers.ts
|
|
16729
|
+
var WORK_ITEM_ACCESSOR = Object.freeze({
|
|
16730
|
+
...Object.fromEntries(WORK_ITEM_TOP_LEVEL_FIELDS.map((field) => [
|
|
16731
|
+
field,
|
|
16732
|
+
Object.freeze({ source: "work_item", field })
|
|
16733
|
+
])),
|
|
16734
|
+
field: (fieldName) => Object.freeze({
|
|
16735
|
+
source: "work_item",
|
|
16736
|
+
field: `${WORK_ITEM_FIELDS_PATH_PREFIX}${fieldName}`
|
|
16737
|
+
})
|
|
16738
|
+
});
|
|
16739
|
+
function literal2(value) {
|
|
16740
|
+
return { source: "literal", value };
|
|
16741
|
+
}
|
|
16742
|
+
|
|
16743
|
+
// src/definitions/pipelines/node-input-ctx.ts
|
|
16744
|
+
function makeBaseNodeInputCtx() {
|
|
16745
|
+
return {
|
|
16746
|
+
pipelineInput: (path) => ({ source: "pipeline_input", path }),
|
|
16747
|
+
workItem: WORK_ITEM_ACCESSOR,
|
|
16748
|
+
signal: (nodeKey, signalKey) => ({
|
|
16749
|
+
source: "step_signal",
|
|
16750
|
+
nodeKey,
|
|
16751
|
+
signalKey
|
|
16752
|
+
}),
|
|
16753
|
+
output: (nodeKey) => ({ source: "step_output", nodeKey }),
|
|
16754
|
+
signalsList: (nodeKey) => ({ source: "signals_list", nodeKey }),
|
|
16755
|
+
literal: literal2
|
|
17035
16756
|
};
|
|
17036
16757
|
}
|
|
17037
|
-
function
|
|
16758
|
+
function makeNodeInputCtx() {
|
|
16759
|
+
return makeBaseNodeInputCtx();
|
|
16760
|
+
}
|
|
16761
|
+
function makeFanOutNodeInputCtx() {
|
|
17038
16762
|
return {
|
|
17039
|
-
|
|
17040
|
-
|
|
17041
|
-
count: (outcome) => createCohortSignalRef(`${outcome}Count`),
|
|
17042
|
-
every: (outcome) => createCohortLeafFromCondition({
|
|
17043
|
-
_tag: "signal",
|
|
17044
|
-
signal: `${outcome}Count`,
|
|
17045
|
-
operator: "equal",
|
|
17046
|
-
value: { fact: "branchCount" }
|
|
17047
|
-
}),
|
|
17048
|
-
some: (outcome) => createCohortLeafFromCondition({
|
|
17049
|
-
_tag: "signal",
|
|
17050
|
-
signal: `${outcome}Count`,
|
|
17051
|
-
operator: "greaterThan",
|
|
17052
|
-
value: 0
|
|
17053
|
-
})
|
|
17054
|
-
},
|
|
17055
|
-
stepSignalsList: {
|
|
17056
|
-
pluck: (signalKey) => createStepSignalsListBuilder([{ op: "pluck", signalKey }])
|
|
17057
|
-
},
|
|
17058
|
-
all: (...refs) => createCohortGroup("all", refs),
|
|
17059
|
-
any: (...refs) => createCohortGroup("any", refs)
|
|
16763
|
+
...makeBaseNodeInputCtx(),
|
|
16764
|
+
item: { source: "fan_out_item" }
|
|
17060
16765
|
};
|
|
17061
16766
|
}
|
|
17062
16767
|
|
|
17063
|
-
// src/definitions/pipelines/
|
|
17064
|
-
function
|
|
17065
|
-
|
|
17066
|
-
|
|
17067
|
-
|
|
17068
|
-
|
|
16768
|
+
// src/definitions/pipelines/compile-node-definitions.ts
|
|
16769
|
+
function assertTargetExists(ctx, fromKey, toKey) {
|
|
16770
|
+
if (!ctx.stateKeys.has(toKey)) {
|
|
16771
|
+
throw new Error(`Pipeline "${ctx.pipelineKey}": state "${fromKey}" targets unknown state "${toKey}"`);
|
|
16772
|
+
}
|
|
16773
|
+
}
|
|
16774
|
+
function overSignalKeyOf(over) {
|
|
16775
|
+
const lastDot = over.lastIndexOf(".");
|
|
16776
|
+
return lastDot === -1 ? over : over.slice(lastDot + 1);
|
|
16777
|
+
}
|
|
16778
|
+
function compileStepState(stateKey, state, ctx) {
|
|
16779
|
+
ctx.registerStep(state.step);
|
|
16780
|
+
const inputCtx = makeNodeInputCtx();
|
|
16781
|
+
const rawInput = state.input ? state.input(inputCtx) : {};
|
|
16782
|
+
const inputBindingsJson = serializeInputBindings(rawInput);
|
|
16783
|
+
const routeTarget = typeof state.next === "object" ? state.next : null;
|
|
16784
|
+
const defaultOutcome = routeTarget ? {
|
|
16785
|
+
outcome: "route",
|
|
16786
|
+
pipelineKey: routeTarget.routeToPipeline,
|
|
16787
|
+
...routeTarget.input ? { inputJson: routeTarget.input } : {}
|
|
16788
|
+
} : "continue";
|
|
16789
|
+
const rules = state.blockWhen ? [{ _tag: "rule", mode: "all", conditions: [state.blockWhen], outcome: "block" }] : [];
|
|
16790
|
+
const policy = { defaultOutcome, rules };
|
|
16791
|
+
const nodeDefinitions = [
|
|
16792
|
+
{
|
|
16793
|
+
nodeKey: stateKey,
|
|
16794
|
+
kind: "step",
|
|
16795
|
+
stepKey: state.step.key,
|
|
16796
|
+
stepName: state.step.name,
|
|
16797
|
+
stepDescription: state.step.description,
|
|
16798
|
+
inputBindingsJson,
|
|
16799
|
+
timeoutSeconds: state.timeout ?? null,
|
|
16800
|
+
advancementPolicyDefinition: serializeAdvancementPolicy(policy),
|
|
16801
|
+
computedSignalDefinitions: extractInlineComputedSignals(policy)
|
|
16802
|
+
}
|
|
16803
|
+
];
|
|
16804
|
+
const edges = [];
|
|
16805
|
+
if (!routeTarget) {
|
|
16806
|
+
const nextKey = state.next;
|
|
16807
|
+
assertTargetExists(ctx, stateKey, nextKey);
|
|
16808
|
+
edges.push({ fromNodeKey: stateKey, toNodeKey: nextKey });
|
|
16809
|
+
}
|
|
16810
|
+
return { nodeDefinitions, edges };
|
|
16811
|
+
}
|
|
16812
|
+
function compileChoiceState(stateKey, state, ctx) {
|
|
16813
|
+
const stateChoices = state.choices ?? [];
|
|
16814
|
+
if (stateChoices.length === 0 && !state.default) {
|
|
16815
|
+
throw new Error(`Pipeline "${ctx.pipelineKey}": choice state "${stateKey}" requires at least one entry in choices or a default target`);
|
|
16816
|
+
}
|
|
16817
|
+
const choices = stateChoices.map((choiceCase) => {
|
|
16818
|
+
assertTargetExists(ctx, stateKey, choiceCase.next);
|
|
16819
|
+
return {
|
|
16820
|
+
conditionJson: serializeCondition(choiceCase.when),
|
|
16821
|
+
targetNodeKey: choiceCase.next
|
|
16822
|
+
};
|
|
16823
|
+
});
|
|
16824
|
+
if (state.default)
|
|
16825
|
+
assertTargetExists(ctx, stateKey, state.default);
|
|
16826
|
+
const edges = stateChoices.map((choiceCase) => ({
|
|
16827
|
+
fromNodeKey: stateKey,
|
|
16828
|
+
toNodeKey: choiceCase.next,
|
|
16829
|
+
discriminantJson: { conditionSummary: serializeCondition(choiceCase.when) }
|
|
16830
|
+
}));
|
|
16831
|
+
if (state.default) {
|
|
16832
|
+
edges.push({
|
|
16833
|
+
fromNodeKey: stateKey,
|
|
16834
|
+
toNodeKey: state.default,
|
|
16835
|
+
discriminantJson: { default: true }
|
|
16836
|
+
});
|
|
16837
|
+
}
|
|
16838
|
+
return {
|
|
16839
|
+
nodeDefinitions: [
|
|
16840
|
+
{ nodeKey: stateKey, kind: "choice", choices, default: state.default ?? null }
|
|
16841
|
+
],
|
|
16842
|
+
edges
|
|
17069
16843
|
};
|
|
17070
|
-
|
|
17071
|
-
|
|
17072
|
-
|
|
17073
|
-
|
|
17074
|
-
|
|
17075
|
-
|
|
17076
|
-
|
|
17077
|
-
...config2.timeout !== undefined ? { timeout: config2.timeout } : {}
|
|
17078
|
-
};
|
|
17079
|
-
const advanceEachCtx = makeAdvanceEachCtx();
|
|
17080
|
-
const advanceEachResult = config2.advance(advanceEachCtx);
|
|
16844
|
+
}
|
|
16845
|
+
function compileFanOutState(stateKey, state, ctx) {
|
|
16846
|
+
ctx.registerStep(state.step);
|
|
16847
|
+
const inputCtx = makeFanOutNodeInputCtx();
|
|
16848
|
+
const rawInput = state.input ? state.input(inputCtx) : {};
|
|
16849
|
+
const inputBindingsJson = serializeInputBindings(rawInput);
|
|
16850
|
+
const advanceEachResult = state.advanceEach(makeAdvanceEachCtx());
|
|
17081
16851
|
const advanceEachPolicy = {
|
|
17082
16852
|
default: advanceEachResult.default,
|
|
17083
16853
|
...advanceEachResult.rules !== undefined ? { rules: advanceEachResult.rules } : {}
|
|
17084
16854
|
};
|
|
17085
|
-
|
|
17086
|
-
const cohortGateNodeConfig = {
|
|
17087
|
-
nodeType: "cohortGate",
|
|
17088
|
-
nodeKey: `${step.key}__cohortGate`
|
|
17089
|
-
};
|
|
17090
|
-
const advanceAllCtx = makeAdvanceAllCtx();
|
|
17091
|
-
const advanceAllResult = config2.advanceAll(advanceAllCtx);
|
|
16855
|
+
const advanceAllResult = state.advanceAll(makeAdvanceAllCtx());
|
|
17092
16856
|
const advanceAllPolicy = {
|
|
17093
16857
|
default: advanceAllResult.default,
|
|
17094
16858
|
...advanceAllResult.rules !== undefined ? { rules: advanceAllResult.rules } : {}
|
|
17095
16859
|
};
|
|
17096
|
-
|
|
17097
|
-
|
|
17098
|
-
|
|
17099
|
-
}
|
|
17100
|
-
|
|
17101
|
-
|
|
17102
|
-
|
|
17103
|
-
|
|
17104
|
-
|
|
17105
|
-
|
|
17106
|
-
|
|
17107
|
-
|
|
17108
|
-
|
|
17109
|
-
|
|
17110
|
-
|
|
17111
|
-
|
|
17112
|
-
|
|
17113
|
-
|
|
17114
|
-
|
|
17115
|
-
|
|
17116
|
-
|
|
17117
|
-
|
|
17118
|
-
|
|
17119
|
-
|
|
17120
|
-
|
|
17121
|
-
|
|
17122
|
-
|
|
17123
|
-
|
|
17124
|
-
|
|
17125
|
-
|
|
17126
|
-
|
|
17127
|
-
|
|
17128
|
-
|
|
17129
|
-
|
|
17130
|
-
|
|
17131
|
-
|
|
17132
|
-
|
|
17133
|
-
}
|
|
17134
|
-
|
|
17135
|
-
|
|
17136
|
-
|
|
17137
|
-
|
|
17138
|
-
|
|
17139
|
-
|
|
17140
|
-
|
|
17141
|
-
|
|
17142
|
-
|
|
17143
|
-
|
|
17144
|
-
|
|
17145
|
-
|
|
17146
|
-
|
|
17147
|
-
|
|
17148
|
-
|
|
17149
|
-
|
|
16860
|
+
const gateKey = `${stateKey}__cohortGate`;
|
|
16861
|
+
if (ctx.stateKeys.has(gateKey)) {
|
|
16862
|
+
throw new Error(`Pipeline "${ctx.pipelineKey}": synthesized cohortGate key "${gateKey}" collides with an author-declared state \u2014 rename state "${stateKey}"`);
|
|
16863
|
+
}
|
|
16864
|
+
assertTargetExists(ctx, stateKey, state.next);
|
|
16865
|
+
return {
|
|
16866
|
+
nodeDefinitions: [
|
|
16867
|
+
{
|
|
16868
|
+
nodeKey: stateKey,
|
|
16869
|
+
kind: "fanOut",
|
|
16870
|
+
stepKey: state.step.key,
|
|
16871
|
+
stepName: state.step.name,
|
|
16872
|
+
stepDescription: state.step.description,
|
|
16873
|
+
inputBindingsJson,
|
|
16874
|
+
timeoutSeconds: state.timeout ?? null,
|
|
16875
|
+
overSignalKey: overSignalKeyOf(state.over),
|
|
16876
|
+
advanceEachPolicyDefinition: serializeCohortAdvancementPolicy(advanceEachPolicy),
|
|
16877
|
+
maxConcurrency: state.maxConcurrency ?? null
|
|
16878
|
+
},
|
|
16879
|
+
{
|
|
16880
|
+
nodeKey: gateKey,
|
|
16881
|
+
kind: "cohortGate",
|
|
16882
|
+
advanceAllPolicyDefinition: serializeCohortAdvancementPolicy(advanceAllPolicy),
|
|
16883
|
+
stepSignalsListDefinitions: extractInlineStepSignalsListDefinitions(advanceAllPolicy)
|
|
16884
|
+
}
|
|
16885
|
+
],
|
|
16886
|
+
edges: [
|
|
16887
|
+
{ fromNodeKey: stateKey, toNodeKey: gateKey },
|
|
16888
|
+
{ fromNodeKey: gateKey, toNodeKey: state.next }
|
|
16889
|
+
]
|
|
16890
|
+
};
|
|
16891
|
+
}
|
|
16892
|
+
function compileParallelState(stateKey, state, ctx) {
|
|
16893
|
+
const branchEntries = Object.entries(state.branches);
|
|
16894
|
+
if (branchEntries.length === 0) {
|
|
16895
|
+
throw new Error(`Pipeline "${ctx.pipelineKey}": parallel state "${stateKey}" requires at least one branch`);
|
|
16896
|
+
}
|
|
16897
|
+
const branches = {};
|
|
16898
|
+
for (const [branchKey, branchConfig] of branchEntries) {
|
|
16899
|
+
ctx.registerStep(branchConfig.step);
|
|
16900
|
+
const inputCtx = makeNodeInputCtx();
|
|
16901
|
+
const rawInput = branchConfig.input ? branchConfig.input(inputCtx) : {};
|
|
16902
|
+
branches[branchKey] = {
|
|
16903
|
+
stepKey: branchConfig.step.key,
|
|
16904
|
+
stepName: branchConfig.step.name,
|
|
16905
|
+
stepDescription: branchConfig.step.description,
|
|
16906
|
+
inputBindingsJson: serializeInputBindings(rawInput)
|
|
16907
|
+
};
|
|
16908
|
+
}
|
|
16909
|
+
let advanceAllPolicyDefinition;
|
|
16910
|
+
if (state.advanceAll) {
|
|
16911
|
+
const advanceAllResult = state.advanceAll(makeAdvanceAllCtx());
|
|
16912
|
+
const advanceAllPolicy = {
|
|
16913
|
+
default: advanceAllResult.default,
|
|
16914
|
+
...advanceAllResult.rules !== undefined ? { rules: advanceAllResult.rules } : {}
|
|
17150
16915
|
};
|
|
17151
|
-
|
|
16916
|
+
advanceAllPolicyDefinition = serializeCohortAdvancementPolicy(advanceAllPolicy);
|
|
17152
16917
|
}
|
|
16918
|
+
assertTargetExists(ctx, stateKey, state.next);
|
|
16919
|
+
return {
|
|
16920
|
+
nodeDefinitions: [
|
|
16921
|
+
{
|
|
16922
|
+
nodeKey: stateKey,
|
|
16923
|
+
kind: "parallel",
|
|
16924
|
+
branches,
|
|
16925
|
+
...advanceAllPolicyDefinition ? { advanceAllPolicyDefinition } : {}
|
|
16926
|
+
}
|
|
16927
|
+
],
|
|
16928
|
+
edges: [{ fromNodeKey: stateKey, toNodeKey: state.next }]
|
|
16929
|
+
};
|
|
17153
16930
|
}
|
|
17154
|
-
|
|
17155
|
-
|
|
17156
|
-
|
|
17157
|
-
|
|
17158
|
-
|
|
17159
|
-
|
|
17160
|
-
|
|
17161
|
-
|
|
17162
|
-
|
|
17163
|
-
|
|
17164
|
-
|
|
17165
|
-
|
|
17166
|
-
|
|
17167
|
-
|
|
17168
|
-
|
|
17169
|
-
|
|
17170
|
-
|
|
17171
|
-
|
|
17172
|
-
const unknown2 = Object.keys(raw).filter((k) => !validKeys.has(k));
|
|
17173
|
-
if (unknown2.length > 0) {
|
|
17174
|
-
throw new Error(`additionalPipelineInput.bindings returned key${unknown2.length > 1 ? "s" : ""} not in schema: ${unknown2.map((k) => `"${k}"`).join(", ")}`);
|
|
17175
|
-
}
|
|
16931
|
+
function compileLoopState(stateKey, state, ctx) {
|
|
16932
|
+
ctx.registerStep(state.step);
|
|
16933
|
+
const inputCtx = makeNodeInputCtx();
|
|
16934
|
+
const rawInput = state.input ? state.input(inputCtx) : {};
|
|
16935
|
+
assertTargetExists(ctx, stateKey, state.next);
|
|
16936
|
+
assertTargetExists(ctx, stateKey, state.onExhausted);
|
|
16937
|
+
return {
|
|
16938
|
+
nodeDefinitions: [
|
|
16939
|
+
{
|
|
16940
|
+
nodeKey: stateKey,
|
|
16941
|
+
kind: "loop",
|
|
16942
|
+
stepKey: state.step.key,
|
|
16943
|
+
stepName: state.step.name,
|
|
16944
|
+
stepDescription: state.step.description,
|
|
16945
|
+
inputBindingsJson: serializeInputBindings(rawInput),
|
|
16946
|
+
timeoutSeconds: state.timeout ?? null,
|
|
16947
|
+
maxIterations: state.maxIterations,
|
|
16948
|
+
untilConditionJson: serializeCondition(state.until)
|
|
17176
16949
|
}
|
|
17177
|
-
|
|
17178
|
-
|
|
17179
|
-
|
|
17180
|
-
|
|
17181
|
-
|
|
16950
|
+
],
|
|
16951
|
+
edges: [
|
|
16952
|
+
{ fromNodeKey: stateKey, toNodeKey: state.next, discriminantJson: { loopExit: "next" } },
|
|
16953
|
+
{
|
|
16954
|
+
fromNodeKey: stateKey,
|
|
16955
|
+
toNodeKey: state.onExhausted,
|
|
16956
|
+
discriminantJson: { loopExit: "onExhausted" }
|
|
16957
|
+
}
|
|
16958
|
+
]
|
|
16959
|
+
};
|
|
16960
|
+
}
|
|
16961
|
+
function compileTerminalState(stateKey, kind) {
|
|
16962
|
+
return { nodeDefinitions: [{ nodeKey: stateKey, kind }], edges: [] };
|
|
16963
|
+
}
|
|
16964
|
+
function assertNoIllegalConvergentEdges(pipelineKey, nodeKindByKey, edges) {
|
|
16965
|
+
const incoming = new Map;
|
|
16966
|
+
for (const edge of edges) {
|
|
16967
|
+
const list = incoming.get(edge.toNodeKey) ?? [];
|
|
16968
|
+
list.push(edge);
|
|
16969
|
+
incoming.set(edge.toNodeKey, list);
|
|
17182
16970
|
}
|
|
17183
|
-
|
|
17184
|
-
|
|
16971
|
+
for (const [targetKey, incomingEdges] of incoming) {
|
|
16972
|
+
if (incomingEdges.length <= 1)
|
|
16973
|
+
continue;
|
|
16974
|
+
const hasInvalidSource = incomingEdges.some((edge) => {
|
|
16975
|
+
const kind = nodeKindByKey.get(edge.fromNodeKey);
|
|
16976
|
+
return kind !== "choice" && kind !== "loop";
|
|
16977
|
+
});
|
|
16978
|
+
if (hasInvalidSource) {
|
|
16979
|
+
throw new Error(`Pipeline "${pipelineKey}": state "${targetKey}" has more than one incoming edge, but not every source is a 'choice'/'loop' state (unconditional convergent edges are not allowed \u2014 see docs/research/flat-pipeline-sdk-and-visual-designer.md \xA76).`);
|
|
16980
|
+
}
|
|
17185
16981
|
}
|
|
17186
16982
|
}
|
|
17187
|
-
|
|
17188
|
-
|
|
16983
|
+
|
|
16984
|
+
// src/definitions/pipelines/define-pipeline.ts
|
|
16985
|
+
function isWorkingNodeDefinition(node) {
|
|
16986
|
+
return node.kind === "step" || node.kind === "fanOut" || node.kind === "loop";
|
|
16987
|
+
}
|
|
16988
|
+
function definePipeline(config2) {
|
|
16989
|
+
const stateEntries = Object.entries(config2.states);
|
|
16990
|
+
if (stateEntries.length === 0) {
|
|
16991
|
+
throw new Error(`Pipeline "${config2.key}" must declare at least one state`);
|
|
16992
|
+
}
|
|
16993
|
+
const startState = config2.states[config2.startAt];
|
|
16994
|
+
if (!startState) {
|
|
16995
|
+
throw new Error(`Pipeline "${config2.key}"'s startAt "${config2.startAt}" does not name a declared state`);
|
|
16996
|
+
}
|
|
16997
|
+
if (startState.kind === "choice" || startState.kind === "succeed" || startState.kind === "fail") {
|
|
16998
|
+
throw new Error(`Pipeline "${config2.key}"'s startAt "${config2.startAt}" names a '${startState.kind}' state, which cannot be an entry point`);
|
|
16999
|
+
}
|
|
17000
|
+
const stateKeys = new Set(Object.keys(config2.states));
|
|
17001
|
+
const stepDefMap = new Map;
|
|
17002
|
+
const registerStep = (step) => {
|
|
17003
|
+
const mapKey = `${step.key}@v${String(step.version)}`;
|
|
17004
|
+
if (!stepDefMap.has(mapKey))
|
|
17005
|
+
stepDefMap.set(mapKey, step);
|
|
17006
|
+
};
|
|
17007
|
+
const compileContext = {
|
|
17008
|
+
pipelineKey: config2.key,
|
|
17009
|
+
stateKeys,
|
|
17010
|
+
registerStep
|
|
17011
|
+
};
|
|
17012
|
+
const nodeDefinitions = [];
|
|
17013
|
+
const dependencyEdges = [];
|
|
17014
|
+
for (const [stateKey, state] of stateEntries) {
|
|
17015
|
+
const compiled = state.kind === "step" ? compileStepState(stateKey, state, compileContext) : state.kind === "choice" ? compileChoiceState(stateKey, state, compileContext) : state.kind === "fanOut" ? compileFanOutState(stateKey, state, compileContext) : state.kind === "parallel" ? compileParallelState(stateKey, state, compileContext) : state.kind === "loop" ? compileLoopState(stateKey, state, compileContext) : compileTerminalState(stateKey, state.kind);
|
|
17016
|
+
nodeDefinitions.push(...compiled.nodeDefinitions);
|
|
17017
|
+
dependencyEdges.push(...compiled.edges);
|
|
17018
|
+
}
|
|
17019
|
+
const nodeKindByKey = new Map(nodeDefinitions.map((node) => [node.nodeKey, node.kind]));
|
|
17020
|
+
assertNoIllegalConvergentEdges(config2.key, nodeKindByKey, dependencyEdges);
|
|
17021
|
+
let inputSchemaJson = null;
|
|
17022
|
+
if (config2.input) {
|
|
17023
|
+
try {
|
|
17024
|
+
inputSchemaJson = exports_external.toJSONSchema(config2.input);
|
|
17025
|
+
} catch {
|
|
17026
|
+
inputSchemaJson = null;
|
|
17027
|
+
}
|
|
17028
|
+
}
|
|
17029
|
+
return {
|
|
17030
|
+
key: config2.key,
|
|
17031
|
+
name: config2.name ?? config2.key,
|
|
17032
|
+
description: config2.description ?? null,
|
|
17033
|
+
version: config2.version ?? 1,
|
|
17034
|
+
status: config2.status ?? "active",
|
|
17035
|
+
inputSchemaJson,
|
|
17036
|
+
_stepDefinitions: [...stepDefMap.values()],
|
|
17037
|
+
nodeDefinitions,
|
|
17038
|
+
dependencyEdges
|
|
17039
|
+
};
|
|
17189
17040
|
}
|
|
17190
17041
|
// src/definitions/pipelines/pipeline-definitions-client.ts
|
|
17191
17042
|
function createPipelineDefinitionsClient(baseUrl) {
|
|
17192
17043
|
const client2 = createClient({ baseUrl });
|
|
17193
17044
|
return buildPipelineDefinitionsClient(new PipelineDefinitions({ client: client2 }));
|
|
17194
17045
|
}
|
|
17046
|
+
function resolveStepRef(pipelineKey, nodeKey, stepKey, stepDefMap) {
|
|
17047
|
+
const stepDef = stepDefMap.get(stepKey);
|
|
17048
|
+
if (!stepDef) {
|
|
17049
|
+
throw new Error(`Step "${stepKey}" referenced by node "${nodeKey}" in pipeline "${pipelineKey}" was not found on ` + `the server. Run \`boboddy steps push\` first to push your step definitions.`);
|
|
17050
|
+
}
|
|
17051
|
+
return {
|
|
17052
|
+
stepDefinitionId: stepDef.id,
|
|
17053
|
+
stepDefinitionVersion: stepDef.version
|
|
17054
|
+
};
|
|
17055
|
+
}
|
|
17056
|
+
function buildConfigJson(pipelineKey, node, stepDefMap) {
|
|
17057
|
+
if (node.kind === "choice") {
|
|
17058
|
+
return { choices: node.choices, default: node.default };
|
|
17059
|
+
}
|
|
17060
|
+
if (node.kind === "loop") {
|
|
17061
|
+
return {
|
|
17062
|
+
maxIterations: node.maxIterations,
|
|
17063
|
+
untilConditionJson: node.untilConditionJson
|
|
17064
|
+
};
|
|
17065
|
+
}
|
|
17066
|
+
if (node.kind === "parallel") {
|
|
17067
|
+
const branches = {};
|
|
17068
|
+
for (const [branchKey, branch] of Object.entries(node.branches)) {
|
|
17069
|
+
branches[branchKey] = {
|
|
17070
|
+
...resolveStepRef(pipelineKey, node.nodeKey, branch.stepKey, stepDefMap),
|
|
17071
|
+
inputBindingsJson: branch.inputBindingsJson
|
|
17072
|
+
};
|
|
17073
|
+
}
|
|
17074
|
+
return {
|
|
17075
|
+
branches,
|
|
17076
|
+
...node.advanceAllPolicyDefinition ? { advanceAllPolicyDefinition: node.advanceAllPolicyDefinition } : {}
|
|
17077
|
+
};
|
|
17078
|
+
}
|
|
17079
|
+
if (node.kind === "fanOut") {
|
|
17080
|
+
return {
|
|
17081
|
+
overSignalKey: node.overSignalKey,
|
|
17082
|
+
advanceEachPolicyDefinition: node.advanceEachPolicyDefinition,
|
|
17083
|
+
maxConcurrency: node.maxConcurrency
|
|
17084
|
+
};
|
|
17085
|
+
}
|
|
17086
|
+
if (node.kind === "cohortGate") {
|
|
17087
|
+
return {
|
|
17088
|
+
advanceAllPolicyDefinition: node.advanceAllPolicyDefinition,
|
|
17089
|
+
stepSignalsListDefinitions: node.stepSignalsListDefinitions
|
|
17090
|
+
};
|
|
17091
|
+
}
|
|
17092
|
+
return null;
|
|
17093
|
+
}
|
|
17094
|
+
function buildGraphNodeInput(pipelineKey, node, stepDefMap) {
|
|
17095
|
+
const working = isWorkingNodeDefinition(node) ? node : null;
|
|
17096
|
+
const stepRef = working ? resolveStepRef(pipelineKey, node.nodeKey, working.stepKey, stepDefMap) : null;
|
|
17097
|
+
const policy = node.kind === "step" ? node.advancementPolicyDefinition : undefined;
|
|
17098
|
+
return {
|
|
17099
|
+
key: node.nodeKey,
|
|
17100
|
+
kind: node.kind,
|
|
17101
|
+
name: working?.stepName ?? node.nodeKey,
|
|
17102
|
+
...stepRef ?? {},
|
|
17103
|
+
description: working?.stepDescription ?? null,
|
|
17104
|
+
inputBindingsJson: working ? working.inputBindingsJson : null,
|
|
17105
|
+
timeoutSeconds: working?.timeoutSeconds ?? null,
|
|
17106
|
+
...policy ? {
|
|
17107
|
+
advancementPolicyRulesJson: policy.rulesJson,
|
|
17108
|
+
advancementPolicyDefaultEventType: policy.defaultEventType,
|
|
17109
|
+
advancementPolicyDefaultEventParamsJson: policy.defaultEventParamsJson,
|
|
17110
|
+
advancementPolicyAllowedEventTypes: policy.allowedEventTypes
|
|
17111
|
+
} : {},
|
|
17112
|
+
configJson: buildConfigJson(pipelineKey, node, stepDefMap),
|
|
17113
|
+
computedSignalDefinitions: node.kind === "step" ? node.computedSignalDefinitions : []
|
|
17114
|
+
};
|
|
17115
|
+
}
|
|
17195
17116
|
var buildPipelineDefinitionsClient = (pipelineDefinitions) => {
|
|
17196
17117
|
return {
|
|
17197
17118
|
listByProjectId: async (projectId, options) => {
|
|
@@ -17211,37 +17132,12 @@ var buildPipelineDefinitionsClient = (pipelineDefinitions) => {
|
|
|
17211
17132
|
stepDefMap.set(s.key, s);
|
|
17212
17133
|
}
|
|
17213
17134
|
}
|
|
17214
|
-
const
|
|
17215
|
-
|
|
17216
|
-
|
|
17217
|
-
|
|
17218
|
-
|
|
17219
|
-
|
|
17220
|
-
throw new Error(`Pipeline "${spec.key}" has a malformed step graph: its node and ` + `dependency-edge definitions do not form a single connected, ` + `acyclic chain. This should not happen from the \`pipeline()\` ` + `builder \u2014 check for hand-edited or generated pipeline specs.`);
|
|
17221
|
-
}
|
|
17222
|
-
const stepDefinitions = ordered.map((node, index) => {
|
|
17223
|
-
const stepKey = node.stepKey;
|
|
17224
|
-
if (!stepKey) {
|
|
17225
|
-
throw new Error(`Node "${node.nodeKey}" in pipeline "${spec.key}" has no stepKey.`);
|
|
17226
|
-
}
|
|
17227
|
-
const stepDef = stepDefMap.get(stepKey);
|
|
17228
|
-
if (!stepDef) {
|
|
17229
|
-
throw new Error(`Step "${stepKey}" referenced in pipeline "${spec.key}" was not found on the server. ` + `Run \`boboddy steps push\` first to push your step definitions.`);
|
|
17230
|
-
}
|
|
17231
|
-
return {
|
|
17232
|
-
stepDefinitionId: stepDef.id,
|
|
17233
|
-
stepDefinitionVersion: stepDef.version,
|
|
17234
|
-
key: node.nodeKey,
|
|
17235
|
-
name: node.stepName ?? "",
|
|
17236
|
-
description: node.stepDescription ?? null,
|
|
17237
|
-
position: index + 1,
|
|
17238
|
-
inputBindingsJson: node.inputBindingsJson ?? {},
|
|
17239
|
-
timeoutSeconds: node.timeoutSeconds ?? null,
|
|
17240
|
-
retryPolicyJson: null,
|
|
17241
|
-
advancementPolicyDefinition: node.advancementPolicyDefinition,
|
|
17242
|
-
computedSignalDefinitions: node.computedSignalDefinitions ?? []
|
|
17243
|
-
};
|
|
17244
|
-
});
|
|
17135
|
+
const nodeDefinitions = spec.nodeDefinitions.map((node) => buildGraphNodeInput(spec.key, node, stepDefMap));
|
|
17136
|
+
const dependencyEdges = spec.dependencyEdges.map((edge) => ({
|
|
17137
|
+
fromNodeKey: edge.fromNodeKey,
|
|
17138
|
+
toNodeKey: edge.toNodeKey,
|
|
17139
|
+
discriminantJson: edge.discriminantJson ?? null
|
|
17140
|
+
}));
|
|
17245
17141
|
const body = {
|
|
17246
17142
|
projectId,
|
|
17247
17143
|
key: spec.key,
|
|
@@ -17249,7 +17145,8 @@ var buildPipelineDefinitionsClient = (pipelineDefinitions) => {
|
|
|
17249
17145
|
description: spec.description,
|
|
17250
17146
|
status: spec.status,
|
|
17251
17147
|
inputSchemaJson: spec.inputSchemaJson,
|
|
17252
|
-
|
|
17148
|
+
nodeDefinitions,
|
|
17149
|
+
dependencyEdges
|
|
17253
17150
|
};
|
|
17254
17151
|
const result = await pipelineDefinitions.upsertPipelineDefinition({
|
|
17255
17152
|
body,
|
|
@@ -17307,17 +17204,17 @@ function buildWorkItemAccessor() {
|
|
|
17307
17204
|
}
|
|
17308
17205
|
return accessor;
|
|
17309
17206
|
}
|
|
17310
|
-
function makeAssign(
|
|
17311
|
-
if (typeof
|
|
17312
|
-
throw new Error("assign() requires a pipeline spec produced by
|
|
17207
|
+
function makeAssign(pipeline) {
|
|
17208
|
+
if (typeof pipeline !== "object" || typeof pipeline["key"] !== "string" || !Array.isArray(pipeline["nodeDefinitions"])) {
|
|
17209
|
+
throw new Error("assign() requires a pipeline spec produced by definePipeline(). " + "Pass the default-exported value from a pipeline definition file.");
|
|
17313
17210
|
}
|
|
17314
|
-
return { _tag: "assign", pipeline
|
|
17211
|
+
return { _tag: "assign", pipeline };
|
|
17315
17212
|
}
|
|
17316
|
-
function
|
|
17213
|
+
function extractCondition(ref) {
|
|
17317
17214
|
return ref._condition;
|
|
17318
17215
|
}
|
|
17319
17216
|
function makeGroup(mode, refs) {
|
|
17320
|
-
const conditions = refs.map(
|
|
17217
|
+
const conditions = refs.map(extractCondition);
|
|
17321
17218
|
const condition = { _tag: "group", mode, conditions };
|
|
17322
17219
|
return {
|
|
17323
17220
|
_condition: condition,
|
|
@@ -17718,61 +17615,59 @@ async function parseBoboddyConfig(workspacePath) {
|
|
|
17718
17615
|
};
|
|
17719
17616
|
}
|
|
17720
17617
|
export {
|
|
17721
|
-
|
|
17722
|
-
stripJsoncComments,
|
|
17723
|
-
serializeDefaultPipelineAssignment,
|
|
17724
|
-
resolveWorkItemFieldPath,
|
|
17725
|
-
renderPromptTemplate,
|
|
17726
|
-
pipeline,
|
|
17727
|
-
parseJsonc,
|
|
17728
|
-
parseBoboddyConfig,
|
|
17729
|
-
openCodeMcpServersSchema,
|
|
17730
|
-
openCodeMcpServerConfigSchema,
|
|
17731
|
-
openCodeMcpRemoteConfigSchema,
|
|
17732
|
-
openCodeMcpOAuthConfigSchema,
|
|
17733
|
-
openCodeMcpLocalConfigSchema,
|
|
17734
|
-
openCodeMcpEnabledOverrideSchema,
|
|
17735
|
-
materializeAccessor,
|
|
17736
|
-
literal2 as literal,
|
|
17737
|
-
isInputAccessor,
|
|
17738
|
-
isDefaultPipelineAssignmentSpec,
|
|
17739
|
-
defineStep,
|
|
17740
|
-
defaultPipelineAssignment,
|
|
17741
|
-
createStepExecutionPlaneClient,
|
|
17742
|
-
createStepDefinitionsClient,
|
|
17743
|
-
createPromptTemplateContext,
|
|
17744
|
-
createPromptInputProxy,
|
|
17745
|
-
createPipelineDefinitionsClient,
|
|
17746
|
-
createInputAccessor,
|
|
17747
|
-
createBoboddyClient,
|
|
17748
|
-
buildPipelineSpec,
|
|
17749
|
-
artifactKindSchema,
|
|
17750
|
-
WorkItems,
|
|
17751
|
-
WorkItemComments,
|
|
17752
|
-
WorkItemBlocks,
|
|
17753
|
-
WORK_ITEM_TOP_LEVEL_FIELDS,
|
|
17754
|
-
WORK_ITEM_FIELDS_PATH_PREFIX,
|
|
17755
|
-
Username,
|
|
17756
|
-
UserNotifications,
|
|
17757
|
-
StepExecutions,
|
|
17758
|
-
StepDefinitions,
|
|
17759
|
-
StepDefinitionTemplates,
|
|
17760
|
-
Rule,
|
|
17761
|
-
Projects,
|
|
17762
|
-
ProjectInvites,
|
|
17763
|
-
ProjectIntegrations,
|
|
17764
|
-
ProjectContext,
|
|
17765
|
-
PipelineStepBuilder,
|
|
17766
|
-
PipelineExecutions,
|
|
17767
|
-
PipelineDefinitions,
|
|
17768
|
-
PipelineBuilder,
|
|
17769
|
-
NotificationRules,
|
|
17770
|
-
GitHubIntegrations,
|
|
17771
|
-
Features,
|
|
17772
|
-
DEFAULT_PIPELINE_ASSIGNMENT_FILENAME,
|
|
17773
|
-
Computed,
|
|
17774
|
-
BoboddyClient,
|
|
17775
|
-
Billing,
|
|
17618
|
+
Api,
|
|
17776
17619
|
BOBODDY_CONFIG_RELATIVE_PATH,
|
|
17777
|
-
|
|
17620
|
+
Billing,
|
|
17621
|
+
BoboddyClient,
|
|
17622
|
+
Computed,
|
|
17623
|
+
DEFAULT_PIPELINE_ASSIGNMENT_FILENAME,
|
|
17624
|
+
Features,
|
|
17625
|
+
GitHubIntegrations,
|
|
17626
|
+
NotificationRules,
|
|
17627
|
+
PipelineDefinitions,
|
|
17628
|
+
PipelineExecutions,
|
|
17629
|
+
ProjectContext,
|
|
17630
|
+
ProjectIntegrations,
|
|
17631
|
+
ProjectInvites,
|
|
17632
|
+
Projects,
|
|
17633
|
+
Rule,
|
|
17634
|
+
StepDefinitionTemplates,
|
|
17635
|
+
StepDefinitions,
|
|
17636
|
+
StepExecutions,
|
|
17637
|
+
UserNotifications,
|
|
17638
|
+
Username,
|
|
17639
|
+
WORK_ITEM_FIELDS_PATH_PREFIX,
|
|
17640
|
+
WORK_ITEM_TOP_LEVEL_FIELDS,
|
|
17641
|
+
WorkItemBlocks,
|
|
17642
|
+
WorkItemComments,
|
|
17643
|
+
WorkItems,
|
|
17644
|
+
artifactKindSchema,
|
|
17645
|
+
codeStep,
|
|
17646
|
+
createBoboddyClient,
|
|
17647
|
+
createPipelineDefinitionsClient,
|
|
17648
|
+
createPromptInputProxy,
|
|
17649
|
+
createPromptTemplateContext,
|
|
17650
|
+
createStepDefinitionsClient,
|
|
17651
|
+
createStepExecutionPlaneClient,
|
|
17652
|
+
defaultPipelineAssignment,
|
|
17653
|
+
definePipeline,
|
|
17654
|
+
defineStep,
|
|
17655
|
+
isDefaultPipelineAssignmentSpec,
|
|
17656
|
+
isWorkingNodeDefinition,
|
|
17657
|
+
makeFanOutNodeInputCtx,
|
|
17658
|
+
makeNodeInputCtx,
|
|
17659
|
+
openCodeMcpEnabledOverrideSchema,
|
|
17660
|
+
openCodeMcpLocalConfigSchema,
|
|
17661
|
+
openCodeMcpOAuthConfigSchema,
|
|
17662
|
+
openCodeMcpRemoteConfigSchema,
|
|
17663
|
+
openCodeMcpServerConfigSchema,
|
|
17664
|
+
openCodeMcpServersSchema,
|
|
17665
|
+
parseBoboddyConfig,
|
|
17666
|
+
parseJsonc,
|
|
17667
|
+
renderPromptTemplate,
|
|
17668
|
+
resolveWorkItemFieldPath,
|
|
17669
|
+
serializeDefaultPipelineAssignment,
|
|
17670
|
+
serializeInputBindings,
|
|
17671
|
+
stripJsoncComments,
|
|
17672
|
+
stripTrailingCommas
|
|
17778
17673
|
};
|