@osdk/maker 0.13.0-beta.13 → 0.13.0-beta.15
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/CHANGELOG.md +18 -0
- package/README.md +49 -11
- package/build/browser/api/defineLink.js +30 -9
- package/build/browser/api/defineLink.js.map +1 -1
- package/build/browser/api/defineOntology.js +3 -3
- package/build/browser/api/defineOntology.js.map +1 -1
- package/build/browser/api/links/LinkType.js.map +1 -1
- package/build/browser/api/overall.test.js +596 -31
- package/build/browser/api/overall.test.js.map +1 -1
- package/build/browser/cli/main.js +10 -1
- package/build/browser/cli/main.js.map +1 -1
- package/build/browser/conversion/toMarketplace/convertLink.js +14 -1
- package/build/browser/conversion/toMarketplace/convertLink.js.map +1 -1
- package/build/browser/conversion/toMarketplace/convertOntologyDefinition.js +3 -2
- package/build/browser/conversion/toMarketplace/convertOntologyDefinition.js.map +1 -1
- package/build/browser/conversion/toMarketplace/convertOntologyDefinitionToWireBlockData.js +2 -2
- package/build/browser/conversion/toMarketplace/convertOntologyDefinitionToWireBlockData.js.map +1 -1
- package/build/cjs/index.cjs +61 -17
- package/build/cjs/index.cjs.map +1 -1
- package/build/cjs/index.d.cts +30 -1
- package/build/esm/api/defineLink.js +30 -9
- package/build/esm/api/defineLink.js.map +1 -1
- package/build/esm/api/defineOntology.js +3 -3
- package/build/esm/api/defineOntology.js.map +1 -1
- package/build/esm/api/links/LinkType.js.map +1 -1
- package/build/esm/api/overall.test.js +596 -31
- package/build/esm/api/overall.test.js.map +1 -1
- package/build/esm/cli/main.js +10 -1
- package/build/esm/cli/main.js.map +1 -1
- package/build/esm/conversion/toMarketplace/convertLink.js +14 -1
- package/build/esm/conversion/toMarketplace/convertLink.js.map +1 -1
- package/build/esm/conversion/toMarketplace/convertOntologyDefinition.js +3 -2
- package/build/esm/conversion/toMarketplace/convertOntologyDefinition.js.map +1 -1
- package/build/esm/conversion/toMarketplace/convertOntologyDefinitionToWireBlockData.js +2 -2
- package/build/esm/conversion/toMarketplace/convertOntologyDefinitionToWireBlockData.js.map +1 -1
- package/build/types/api/defineLink.d.ts.map +1 -1
- package/build/types/api/defineOntology.d.ts +1 -1
- package/build/types/api/defineOntology.d.ts.map +1 -1
- package/build/types/api/links/LinkType.d.ts +29 -0
- package/build/types/api/links/LinkType.d.ts.map +1 -1
- package/build/types/cli/main.d.ts.map +1 -1
- package/build/types/conversion/toMarketplace/convertOntologyDefinition.d.ts +1 -1
- package/build/types/conversion/toMarketplace/convertOntologyDefinition.d.ts.map +1 -1
- package/build/types/conversion/toMarketplace/convertOntologyDefinitionToWireBlockData.d.ts.map +1 -1
- package/package.json +5 -4
package/build/esm/cli/main.js
CHANGED
|
@@ -18,12 +18,13 @@ import { consola } from "consola";
|
|
|
18
18
|
import * as fs from "node:fs/promises";
|
|
19
19
|
import * as path from "node:path";
|
|
20
20
|
import invariant from "tiny-invariant";
|
|
21
|
+
import { validate as validateUuid } from "uuid";
|
|
21
22
|
import yargs from "yargs";
|
|
22
23
|
import { hideBin } from "yargs/helpers";
|
|
23
24
|
import { defineOntology } from "../api/defineOntology.js";
|
|
24
25
|
const apiNamespaceRegex = /^[a-z0-9-]+(\.[a-z0-9-]+)*\.$/;
|
|
25
26
|
export default async function main(args = process.argv) {
|
|
26
|
-
const commandLineOpts = await yargs(hideBin(args)).version("0.13.0-beta.
|
|
27
|
+
const commandLineOpts = await yargs(hideBin(args)).version("0.13.0-beta.15" ?? "").wrap(Math.min(150, yargs().terminalWidth())).strict().help().options({
|
|
27
28
|
input: {
|
|
28
29
|
alias: "i",
|
|
29
30
|
describe: "Input file",
|
|
@@ -66,6 +67,11 @@ export default async function main(args = process.argv) {
|
|
|
66
67
|
describe: "File to write dependencies to",
|
|
67
68
|
type: "string",
|
|
68
69
|
coerce: path.resolve
|
|
70
|
+
},
|
|
71
|
+
randomnessKey: {
|
|
72
|
+
describe: "Value used to assure uniqueness of entities",
|
|
73
|
+
type: "string",
|
|
74
|
+
coerce: path.resolve
|
|
69
75
|
}
|
|
70
76
|
}).parseAsync();
|
|
71
77
|
let apiNamespace = "";
|
|
@@ -75,6 +81,9 @@ export default async function main(args = process.argv) {
|
|
|
75
81
|
!apiNamespaceRegex.test(apiNamespace) ? process.env.NODE_ENV !== "production" ? invariant(false, "API namespace is invalid! It is expected to conform to ^[a-z0-9-]+(\.[a-z0-9-]+)*\.$") : invariant(false) : void 0;
|
|
76
82
|
}
|
|
77
83
|
consola.info(`Loading ontology from ${commandLineOpts.input}`);
|
|
84
|
+
if (commandLineOpts.randomnessKey !== undefined) {
|
|
85
|
+
!validateUuid(commandLineOpts.randomnessKey) ? process.env.NODE_ENV !== "production" ? invariant(false, "Supplied randomness key is not a uuid and shouldn't be used as a uniqueness guarantee") : invariant(false) : void 0;
|
|
86
|
+
}
|
|
78
87
|
const ontologyIr = await loadOntology(commandLineOpts.input, apiNamespace, commandLineOpts.outputDir, commandLineOpts.dependencies);
|
|
79
88
|
consola.info(`Saving ontology to ${commandLineOpts.output}`);
|
|
80
89
|
await fs.writeFile(commandLineOpts.output, JSON.stringify(ontologyIr, null, 2));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"main.js","names":["consola","fs","path","invariant","yargs","hideBin","defineOntology","apiNamespaceRegex","main","args","process","argv","commandLineOpts","version","wrap","Math","min","terminalWidth","strict","help","options","input","alias","describe","type","default","coerce","resolve","output","apiNamespace","snapshotDir","outputDir","valueTypesOutput","dependencies","parseAsync","length","slice","env","NODE_ENV","test","info","ontologyIr","loadOntology","writeFile","JSON","stringify","valueTypes","importedValueTypes","dependencyFile","q"],"sources":["main.ts"],"sourcesContent":["/*\n * Copyright 2024 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { consola } from \"consola\";\nimport * as fs from \"node:fs/promises\";\nimport * as path from \"node:path\";\nimport invariant from \"tiny-invariant\";\nimport yargs from \"yargs\";\nimport { hideBin } from \"yargs/helpers\";\nimport { defineOntology } from \"../api/defineOntology.js\";\n\nconst apiNamespaceRegex = /^[a-z0-9-]+(\\.[a-z0-9-]+)*\\.$/;\n\nexport default async function main(\n args: string[] = process.argv,\n): Promise<void> {\n const commandLineOpts: {\n input: string;\n output: string;\n apiNamespace: string;\n snapshotDir: string;\n valueTypesOutput: string;\n outputDir?: string;\n dependencies?: string;\n } = await yargs(hideBin(args))\n .version(process.env.PACKAGE_VERSION ?? \"\")\n .wrap(Math.min(150, yargs().terminalWidth()))\n .strict()\n .help()\n .options({\n input: {\n alias: \"i\",\n describe: \"Input file\",\n type: \"string\",\n default: \".ontology/ontology.ts\",\n coerce: path.resolve,\n },\n output: {\n alias: \"o\",\n describe: \"Output file\",\n type: \"string\",\n default: \"ontology.json\",\n coerce: path.resolve,\n },\n apiNamespace: {\n describe: \"Api name prefix for namespaced ontology types\",\n type: \"string\",\n default: \"\",\n },\n snapshotDir: {\n alias: \"s\",\n describe: \"Snapshot directory\",\n type: \"string\",\n default: \"snapshots\",\n coerce: path.resolve,\n },\n outputDir: {\n alias: \"d\",\n describe: \"Directory for generated ontology entities\",\n type: \"string\",\n coerce: path.resolve,\n },\n valueTypesOutput: {\n describe: \"Value Type Output File\",\n type: \"string\",\n default: \"value-types.json\",\n coerce: path.resolve,\n },\n dependencies: {\n describe: \"File to write dependencies to\",\n type: \"string\",\n coerce: path.resolve,\n },\n })\n .parseAsync();\n let apiNamespace = \"\";\n if (commandLineOpts.apiNamespace.length !== 0) {\n apiNamespace = (commandLineOpts.apiNamespace.slice(-1) !== \".\")\n ? commandLineOpts.apiNamespace + \".\"\n : commandLineOpts.apiNamespace;\n invariant(apiNamespace.length < 1024, \"API namespace is too long.\");\n invariant(\n apiNamespaceRegex.test(apiNamespace),\n \"API namespace is invalid! It is expected to conform to ^[a-z0-9-]+(\\.[a-z0-9-]+)*\\.$\",\n );\n }\n consola.info(`Loading ontology from ${commandLineOpts.input}`);\n\n const ontologyIr = await loadOntology(\n commandLineOpts.input,\n apiNamespace,\n commandLineOpts.outputDir,\n commandLineOpts.dependencies,\n );\n\n consola.info(`Saving ontology to ${commandLineOpts.output}`);\n await fs.writeFile(\n commandLineOpts.output,\n JSON.stringify(\n ontologyIr,\n null,\n 2,\n ),\n );\n // No point in generating block if there aren't any value types\n if (\n ontologyIr.valueTypes.valueTypes.length > 0\n || ontologyIr.importedValueTypes.valueTypes.length > 0\n ) {\n await fs.writeFile(\n commandLineOpts.valueTypesOutput,\n JSON.stringify(\n ontologyIr.valueTypes,\n null,\n 2,\n ),\n );\n }\n}\n\nasync function loadOntology(\n input: string,\n apiNamespace: string,\n outputDir: string | undefined,\n dependencyFile: string | undefined,\n) {\n const q = await defineOntology(\n apiNamespace,\n async () => await import(input),\n outputDir,\n dependencyFile,\n );\n return q;\n}\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,SAASA,OAAO,QAAQ,SAAS;AACjC,OAAO,KAAKC,EAAE,MAAM,kBAAkB;AACtC,OAAO,KAAKC,IAAI,MAAM,WAAW;AACjC,OAAOC,SAAS,MAAM,gBAAgB;AACtC,OAAOC,KAAK,MAAM,OAAO;AACzB,SAASC,OAAO,QAAQ,eAAe;AACvC,SAASC,cAAc,QAAQ,0BAA0B;AAEzD,MAAMC,iBAAiB,GAAG,+BAA+B;AAEzD,eAAe,eAAeC,IAAIA,CAChCC,IAAc,GAAGC,OAAO,CAACC,IAAI,EACd;EACf,MAAMC,
|
|
1
|
+
{"version":3,"file":"main.js","names":["consola","fs","path","invariant","validate","validateUuid","yargs","hideBin","defineOntology","apiNamespaceRegex","main","args","process","argv","commandLineOpts","version","wrap","Math","min","terminalWidth","strict","help","options","input","alias","describe","type","default","coerce","resolve","output","apiNamespace","snapshotDir","outputDir","valueTypesOutput","dependencies","randomnessKey","parseAsync","length","slice","env","NODE_ENV","test","info","undefined","ontologyIr","loadOntology","writeFile","JSON","stringify","valueTypes","importedValueTypes","dependencyFile","q"],"sources":["main.ts"],"sourcesContent":["/*\n * Copyright 2024 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { consola } from \"consola\";\nimport * as fs from \"node:fs/promises\";\nimport * as path from \"node:path\";\nimport invariant from \"tiny-invariant\";\nimport { validate as validateUuid } from \"uuid\";\nimport yargs from \"yargs\";\nimport { hideBin } from \"yargs/helpers\";\nimport { defineOntology } from \"../api/defineOntology.js\";\n\nconst apiNamespaceRegex = /^[a-z0-9-]+(\\.[a-z0-9-]+)*\\.$/;\n\nexport default async function main(\n args: string[] = process.argv,\n): Promise<void> {\n const commandLineOpts: {\n input: string;\n output: string;\n apiNamespace: string;\n snapshotDir: string;\n valueTypesOutput: string;\n outputDir?: string;\n dependencies?: string;\n randomnessKey?: string;\n } = await yargs(hideBin(args))\n .version(process.env.PACKAGE_VERSION ?? \"\")\n .wrap(Math.min(150, yargs().terminalWidth()))\n .strict()\n .help()\n .options({\n input: {\n alias: \"i\",\n describe: \"Input file\",\n type: \"string\",\n default: \".ontology/ontology.ts\",\n coerce: path.resolve,\n },\n output: {\n alias: \"o\",\n describe: \"Output file\",\n type: \"string\",\n default: \"ontology.json\",\n coerce: path.resolve,\n },\n apiNamespace: {\n describe: \"Api name prefix for namespaced ontology types\",\n type: \"string\",\n default: \"\",\n },\n snapshotDir: {\n alias: \"s\",\n describe: \"Snapshot directory\",\n type: \"string\",\n default: \"snapshots\",\n coerce: path.resolve,\n },\n outputDir: {\n alias: \"d\",\n describe: \"Directory for generated ontology entities\",\n type: \"string\",\n coerce: path.resolve,\n },\n valueTypesOutput: {\n describe: \"Value Type Output File\",\n type: \"string\",\n default: \"value-types.json\",\n coerce: path.resolve,\n },\n dependencies: {\n describe: \"File to write dependencies to\",\n type: \"string\",\n coerce: path.resolve,\n },\n randomnessKey: {\n describe: \"Value used to assure uniqueness of entities\",\n type: \"string\",\n coerce: path.resolve,\n },\n })\n .parseAsync();\n let apiNamespace = \"\";\n if (commandLineOpts.apiNamespace.length !== 0) {\n apiNamespace = (commandLineOpts.apiNamespace.slice(-1) !== \".\")\n ? commandLineOpts.apiNamespace + \".\"\n : commandLineOpts.apiNamespace;\n invariant(apiNamespace.length < 1024, \"API namespace is too long.\");\n invariant(\n apiNamespaceRegex.test(apiNamespace),\n \"API namespace is invalid! It is expected to conform to ^[a-z0-9-]+(\\.[a-z0-9-]+)*\\.$\",\n );\n }\n consola.info(`Loading ontology from ${commandLineOpts.input}`);\n\n if (commandLineOpts.randomnessKey !== undefined) {\n invariant(\n validateUuid(commandLineOpts.randomnessKey),\n \"Supplied randomness key is not a uuid and shouldn't be used as a uniqueness guarantee\",\n );\n }\n\n const ontologyIr = await loadOntology(\n commandLineOpts.input,\n apiNamespace,\n commandLineOpts.outputDir,\n commandLineOpts.dependencies,\n );\n\n consola.info(`Saving ontology to ${commandLineOpts.output}`);\n await fs.writeFile(\n commandLineOpts.output,\n JSON.stringify(\n ontologyIr,\n null,\n 2,\n ),\n );\n // No point in generating block if there aren't any value types\n if (\n ontologyIr.valueTypes.valueTypes.length > 0\n || ontologyIr.importedValueTypes.valueTypes.length > 0\n ) {\n await fs.writeFile(\n commandLineOpts.valueTypesOutput,\n JSON.stringify(\n ontologyIr.valueTypes,\n null,\n 2,\n ),\n );\n }\n}\n\nasync function loadOntology(\n input: string,\n apiNamespace: string,\n outputDir: string | undefined,\n dependencyFile: string | undefined,\n) {\n const q = await defineOntology(\n apiNamespace,\n async () => await import(input),\n outputDir,\n dependencyFile,\n );\n return q;\n}\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,SAASA,OAAO,QAAQ,SAAS;AACjC,OAAO,KAAKC,EAAE,MAAM,kBAAkB;AACtC,OAAO,KAAKC,IAAI,MAAM,WAAW;AACjC,OAAOC,SAAS,MAAM,gBAAgB;AACtC,SAASC,QAAQ,IAAIC,YAAY,QAAQ,MAAM;AAC/C,OAAOC,KAAK,MAAM,OAAO;AACzB,SAASC,OAAO,QAAQ,eAAe;AACvC,SAASC,cAAc,QAAQ,0BAA0B;AAEzD,MAAMC,iBAAiB,GAAG,+BAA+B;AAEzD,eAAe,eAAeC,IAAIA,CAChCC,IAAc,GAAGC,OAAO,CAACC,IAAI,EACd;EACf,MAAMC,eASL,GAAG,MAAMR,KAAK,CAACC,OAAO,CAACI,IAAI,CAAC,CAAC,CAC3BI,OAAO,CAAC,oBAA+B,EAAE,CAAC,CAC1CC,IAAI,CAACC,IAAI,CAACC,GAAG,CAAC,GAAG,EAAEZ,KAAK,CAAC,CAAC,CAACa,aAAa,CAAC,CAAC,CAAC,CAAC,CAC5CC,MAAM,CAAC,CAAC,CACRC,IAAI,CAAC,CAAC,CACNC,OAAO,CAAC;IACPC,KAAK,EAAE;MACLC,KAAK,EAAE,GAAG;MACVC,QAAQ,EAAE,YAAY;MACtBC,IAAI,EAAE,QAAQ;MACdC,OAAO,EAAE,uBAAuB;MAChCC,MAAM,EAAE1B,IAAI,CAAC2B;IACf,CAAC;IACDC,MAAM,EAAE;MACNN,KAAK,EAAE,GAAG;MACVC,QAAQ,EAAE,aAAa;MACvBC,IAAI,EAAE,QAAQ;MACdC,OAAO,EAAE,eAAe;MACxBC,MAAM,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ACZ,YAAY,MAAM,MAAM,CAACR,KAAK,CAAC,EAC/BU,SAAS,EACTmB,cACF,CAAC;EACD,OAAOC,CAAC;AACV","ignoreList":[]}
|
|
@@ -40,6 +40,19 @@ export function convertLink(linkType) {
|
|
|
40
40
|
}]
|
|
41
41
|
}
|
|
42
42
|
};
|
|
43
|
+
} else if ("intermediaryObjectType" in linkType) {
|
|
44
|
+
definition = {
|
|
45
|
+
type: "intermediary",
|
|
46
|
+
intermediary: {
|
|
47
|
+
objectTypeAToBLinkMetadata: linkType.many.metadata,
|
|
48
|
+
objectTypeBToALinkMetadata: linkType.toMany.metadata,
|
|
49
|
+
objectTypeRidA: linkType.many.object.apiName,
|
|
50
|
+
objectTypeRidB: linkType.toMany.object.apiName,
|
|
51
|
+
intermediaryObjectTypeRid: linkType.intermediaryObjectType.apiName,
|
|
52
|
+
aToIntermediaryLinkTypeRid: cleanAndValidateLinkTypeId(linkType.many.linkToIntermediary.apiName),
|
|
53
|
+
intermediaryToBLinkTypeRid: cleanAndValidateLinkTypeId(linkType.toMany.linkToIntermediary.apiName)
|
|
54
|
+
}
|
|
55
|
+
};
|
|
43
56
|
} else {
|
|
44
57
|
definition = {
|
|
45
58
|
type: "manyToMany",
|
|
@@ -72,7 +85,7 @@ export function convertLink(linkType) {
|
|
|
72
85
|
}
|
|
73
86
|
};
|
|
74
87
|
datasource = {
|
|
75
|
-
|
|
88
|
+
datasourceName: linkType.apiName,
|
|
76
89
|
datasource: {
|
|
77
90
|
type: "dataset",
|
|
78
91
|
dataset: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"convertLink.js","names":["cleanAndValidateLinkTypeId","convertCardinality","convertLink","linkType","definition","datasource","undefined","type","oneToMany","cardinalityHint","cardinality","manyToOneLinkMetadata","toMany","metadata","objectTypeRidManySide","object","apiName","objectTypeRidOneSide","one","oneToManyLinkMetadata","oneSidePrimaryKeyToManySidePropertyMapping","from","primaryKeyPropertyApiName","to","manyForeignKeyProperty","
|
|
1
|
+
{"version":3,"file":"convertLink.js","names":["cleanAndValidateLinkTypeId","convertCardinality","convertLink","linkType","definition","datasource","undefined","type","oneToMany","cardinalityHint","cardinality","manyToOneLinkMetadata","toMany","metadata","objectTypeRidManySide","object","apiName","objectTypeRidOneSide","one","oneToManyLinkMetadata","oneSidePrimaryKeyToManySidePropertyMapping","from","primaryKeyPropertyApiName","to","manyForeignKeyProperty","intermediary","objectTypeAToBLinkMetadata","many","objectTypeBToALinkMetadata","objectTypeRidA","objectTypeRidB","intermediaryObjectTypeRid","intermediaryObjectType","aToIntermediaryLinkTypeRid","linkToIntermediary","intermediaryToBLinkTypeRid","manyToMany","peeringMetadata","objectTypeAPrimaryKeyPropertyMapping","objectTypeBPrimaryKeyPropertyMapping","datasourceName","dataset","datasetRid","concat","writebackDatasetRid","objectTypeAPrimaryKeyMapping","property","column","objectTypeBPrimaryKeyMapping","editsConfiguration","onlyAllowPrivilegedEdits","redacted","id","status","active","datasources","entityMetadata","arePatchesEnabled","editsEnabled"],"sources":["convertLink.ts"],"sourcesContent":["/*\n * Copyright 2025 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport type {\n OntologyIrLinkDefinition,\n OntologyIrLinkTypeBlockDataV2,\n OntologyIrManyToManyLinkTypeDatasource,\n} from \"@osdk/client.unstable\";\nimport { cleanAndValidateLinkTypeId } from \"../../api/defineOntology.js\";\nimport type { LinkType } from \"../../api/links/LinkType.js\";\nimport { convertCardinality } from \"./convertCardinality.js\";\n\nexport function convertLink(\n linkType: LinkType,\n): OntologyIrLinkTypeBlockDataV2 {\n let definition: OntologyIrLinkDefinition;\n let datasource: OntologyIrManyToManyLinkTypeDatasource | undefined =\n undefined;\n if (\"one\" in linkType) {\n definition = {\n type: \"oneToMany\",\n oneToMany: {\n cardinalityHint: convertCardinality(linkType.cardinality),\n manyToOneLinkMetadata: linkType.toMany.metadata,\n objectTypeRidManySide: linkType.toMany.object.apiName,\n objectTypeRidOneSide: linkType.one.object.apiName,\n oneToManyLinkMetadata: linkType.one.metadata,\n oneSidePrimaryKeyToManySidePropertyMapping: [{\n from: {\n apiName: linkType.one.object.primaryKeyPropertyApiName,\n object: linkType.one.object.apiName,\n },\n to: {\n apiName: linkType.manyForeignKeyProperty,\n object: linkType.toMany.object.apiName,\n },\n }],\n },\n };\n } else if (\"intermediaryObjectType\" in linkType) {\n definition = {\n type: \"intermediary\",\n intermediary: {\n objectTypeAToBLinkMetadata: linkType.many.metadata,\n objectTypeBToALinkMetadata: linkType.toMany.metadata,\n objectTypeRidA: linkType.many.object.apiName,\n objectTypeRidB: linkType.toMany.object.apiName,\n intermediaryObjectTypeRid: linkType.intermediaryObjectType.apiName,\n aToIntermediaryLinkTypeRid: cleanAndValidateLinkTypeId(\n linkType.many.linkToIntermediary.apiName,\n ),\n intermediaryToBLinkTypeRid: cleanAndValidateLinkTypeId(\n linkType.toMany.linkToIntermediary.apiName,\n ),\n },\n };\n } else {\n definition = {\n type: \"manyToMany\",\n manyToMany: {\n objectTypeAToBLinkMetadata: linkType.many.metadata,\n objectTypeBToALinkMetadata: linkType.toMany.metadata,\n objectTypeRidA: linkType.many.object.apiName,\n objectTypeRidB: linkType.toMany.object.apiName,\n peeringMetadata: undefined,\n objectTypeAPrimaryKeyPropertyMapping: [{\n from: {\n apiName: linkType.many.object.primaryKeyPropertyApiName,\n object: linkType.many.object.apiName,\n },\n to: {\n apiName: linkType.many.object.primaryKeyPropertyApiName,\n object: linkType.many.object.apiName,\n },\n }],\n objectTypeBPrimaryKeyPropertyMapping: [{\n from: {\n apiName: linkType.toMany.object.primaryKeyPropertyApiName,\n object: linkType.toMany.object.apiName,\n },\n to: {\n apiName: linkType.toMany.object.primaryKeyPropertyApiName,\n object: linkType.toMany.object.apiName,\n },\n }],\n },\n };\n\n datasource = {\n datasourceName: linkType.apiName,\n datasource: {\n type: \"dataset\",\n dataset: {\n datasetRid: \"link-\".concat(linkType.apiName),\n writebackDatasetRid: undefined,\n objectTypeAPrimaryKeyMapping: [{\n property: {\n apiName: linkType.many.object.primaryKeyPropertyApiName,\n object: linkType.many.object.apiName,\n },\n column: linkType.many.object.primaryKeyPropertyApiName,\n }],\n objectTypeBPrimaryKeyMapping: [{\n property: {\n apiName: linkType.toMany.object.primaryKeyPropertyApiName,\n object: linkType.toMany.object.apiName,\n },\n column: linkType.toMany.object.primaryKeyPropertyApiName,\n }],\n },\n },\n editsConfiguration: {\n onlyAllowPrivilegedEdits: false,\n },\n redacted: linkType.redacted,\n };\n }\n\n return {\n linkType: {\n definition: definition,\n id: cleanAndValidateLinkTypeId(linkType.apiName),\n status: linkType.status ?? { type: \"active\", active: {} },\n redacted: linkType.redacted ?? false,\n },\n datasources: datasource !== undefined ? [datasource] : [],\n entityMetadata: {\n arePatchesEnabled: linkType.editsEnabled ?? false,\n },\n };\n}\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAOA,SAASA,0BAA0B,QAAQ,6BAA6B;AAExE,SAASC,kBAAkB,QAAQ,yBAAyB;AAE5D,OAAO,SAASC,WAAWA,CACzBC,QAAkB,EACa;EAC/B,IAAIC,UAAoC;EACxC,IAAIC,UAA8D,GAChEC,SAAS;EACX,IAAI,KAAK,IAAIH,QAAQ,EAAE;IACrBC,UAAU,GAAG;MACXG,IAAI,EAAE,WAAW;MACjBC,SAAS,EAAE;QACTC,eAAe,EAAER,kBAAkB,CAACE,QAAQ,CAACO,WAAW,CAAC;QACzDC,qBAAqB,EAAER,QAAQ,CAACS,MAAM,CAACC,QAAQ;QAC/CC,qB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B,EAAE,CAAC;YAC7BC,QAAQ,EAAE;cACR9B,OAAO,EAAEb,QAAQ,CAACwB,IAAI,CAACZ,MAAM,CAACO,yBAAyB;cACvDP,MAAM,EAAEZ,QAAQ,CAACwB,IAAI,CAACZ,MAAM,CAACC;YAC/B,CAAC;YACD+B,MAAM,EAAE5C,QAAQ,CAACwB,IAAI,CAACZ,MAAM,CAACO;UAC/B,CAAC,CAAC;UACF0B,4BAA4B,EAAE,CAAC;YAC7BF,QAAQ,EAAE;cACR9B,OAAO,EAAEb,QAAQ,CAACS,MAAM,CAACG,MAAM,CAACO,yBAAyB;cACzDP,MAAM,EAAEZ,QAAQ,CAACS,MAAM,CAACG,MAAM,CAACC;YACjC,CAAC;YACD+B,MAAM,EAAE5C,QAAQ,CAACS,MAAM,CAACG,MAAM,CAACO;UACjC,CAAC;QACH;MACF,CAAC;MACD2B,kBAAkB,EAAE;QAClBC,wBAAwB,EAAE;MAC5B,CAAC;MACDC,QAAQ,EAAEhD,QAAQ,CAACgD;IACrB,CAAC;EACH;EAEA,OAAO;IACLhD,QAAQ,EAAE;MACRC,UAAU,EAAEA,UAAU;MACtBgD,EAAE,EAAEpD,0BAA0B,CAACG,QAAQ,CAACa,OAAO,CAAC;MAChDqC,MAAM,EAAElD,QAAQ,CAACkD,MAAM,IAAI;QAAE9C,IAAI,EAAE,QAAQ;QAAE+C,MAAM,EAAE,CAAC;MAAE,CAAC;MACzDH,QAAQ,EAAEhD,QAAQ,CAACgD,QAAQ,IAAI;IACjC,CAAC;IACDI,WAAW,EAAElD,UAAU,KAAKC,SAAS,GAAG,CAACD,UAAU,CAAC,GAAG,EAAE;IACzDmD,cAAc,EAAE;MACdC,iBAAiB,EAAEtD,QAAQ,CAACuD,YAAY,IAAI;IAC9C;EACF,CAAC;AACH","ignoreList":[]}
|
|
@@ -17,12 +17,13 @@
|
|
|
17
17
|
import { importedTypes } from "../../api/defineOntology.js";
|
|
18
18
|
import { convertOntologyDefinitionToWireBlockData } from "./convertOntologyDefinitionToWireBlockData.js";
|
|
19
19
|
import { convertOntologyToValueTypeIr } from "./convertOntologyToValueTypeIr.js";
|
|
20
|
-
export function convertOntologyDefinition(ontology) {
|
|
20
|
+
export function convertOntologyDefinition(ontology, randomnessKey) {
|
|
21
21
|
return {
|
|
22
22
|
ontology: convertOntologyDefinitionToWireBlockData(ontology),
|
|
23
23
|
importedOntology: convertOntologyDefinitionToWireBlockData(importedTypes),
|
|
24
24
|
valueTypes: convertOntologyToValueTypeIr(ontology),
|
|
25
|
-
importedValueTypes: convertOntologyToValueTypeIr(importedTypes)
|
|
25
|
+
importedValueTypes: convertOntologyToValueTypeIr(importedTypes),
|
|
26
|
+
randomnessKey
|
|
26
27
|
};
|
|
27
28
|
}
|
|
28
29
|
//# sourceMappingURL=convertOntologyDefinition.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"convertOntologyDefinition.js","names":["importedTypes","convertOntologyDefinitionToWireBlockData","convertOntologyToValueTypeIr","convertOntologyDefinition","ontology","importedOntology","valueTypes","importedValueTypes"],"sources":["convertOntologyDefinition.ts"],"sourcesContent":["/*\n * Copyright 2025 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport type { OntologyIr } from \"@osdk/client.unstable\";\nimport type { OntologyDefinition } from \"../../api/common/OntologyDefinition.js\";\nimport { importedTypes } from \"../../api/defineOntology.js\";\nimport { convertOntologyDefinitionToWireBlockData } from \"./convertOntologyDefinitionToWireBlockData.js\";\nimport { convertOntologyToValueTypeIr } from \"./convertOntologyToValueTypeIr.js\";\n\nexport function convertOntologyDefinition(\n ontology: OntologyDefinition,\n): OntologyIr {\n return {\n ontology: convertOntologyDefinitionToWireBlockData(ontology),\n importedOntology: convertOntologyDefinitionToWireBlockData(importedTypes),\n valueTypes: convertOntologyToValueTypeIr(ontology),\n importedValueTypes: convertOntologyToValueTypeIr(importedTypes),\n };\n}\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAIA,SAASA,aAAa,QAAQ,6BAA6B;AAC3D,SAASC,wCAAwC,QAAQ,+CAA+C;AACxG,SAASC,4BAA4B,QAAQ,mCAAmC;AAEhF,OAAO,SAASC,yBAAyBA,CACvCC,QAA4B,
|
|
1
|
+
{"version":3,"file":"convertOntologyDefinition.js","names":["importedTypes","convertOntologyDefinitionToWireBlockData","convertOntologyToValueTypeIr","convertOntologyDefinition","ontology","randomnessKey","importedOntology","valueTypes","importedValueTypes"],"sources":["convertOntologyDefinition.ts"],"sourcesContent":["/*\n * Copyright 2025 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport type { OntologyIr } from \"@osdk/client.unstable\";\nimport type { OntologyDefinition } from \"../../api/common/OntologyDefinition.js\";\nimport { importedTypes } from \"../../api/defineOntology.js\";\nimport { convertOntologyDefinitionToWireBlockData } from \"./convertOntologyDefinitionToWireBlockData.js\";\nimport { convertOntologyToValueTypeIr } from \"./convertOntologyToValueTypeIr.js\";\n\nexport function convertOntologyDefinition(\n ontology: OntologyDefinition,\n randomnessKey?: string,\n): OntologyIr {\n return {\n ontology: convertOntologyDefinitionToWireBlockData(ontology),\n importedOntology: convertOntologyDefinitionToWireBlockData(importedTypes),\n valueTypes: convertOntologyToValueTypeIr(ontology),\n importedValueTypes: convertOntologyToValueTypeIr(importedTypes),\n randomnessKey,\n };\n}\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAIA,SAASA,aAAa,QAAQ,6BAA6B;AAC3D,SAASC,wCAAwC,QAAQ,+CAA+C;AACxG,SAASC,4BAA4B,QAAQ,mCAAmC;AAEhF,OAAO,SAASC,yBAAyBA,CACvCC,QAA4B,EAC5BC,aAAsB,EACV;EACZ,OAAO;IACLD,QAAQ,EAAEH,wCAAwC,CAACG,QAAQ,CAAC;IAC5DE,gBAAgB,EAAEL,wCAAwC,CAACD,aAAa,CAAC;IACzEO,UAAU,EAAEL,4BAA4B,CAACE,QAAQ,CAAC;IAClDI,kBAAkB,EAAEN,4BAA4B,CAACF,aAAa,CAAC;IAC/DK;EACF,CAAC;AACH","ignoreList":[]}
|
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
*/
|
|
16
16
|
|
|
17
17
|
import { OntologyEntityTypeEnum } from "../../api/common/OntologyEntityTypeEnum.js";
|
|
18
|
-
import { convertAction } from "../../api/defineOntology.js";
|
|
18
|
+
import { cleanAndValidateLinkTypeId, convertAction } from "../../api/defineOntology.js";
|
|
19
19
|
import { convertInterface } from "./convertInterface.js";
|
|
20
20
|
import { convertLink } from "./convertLink.js";
|
|
21
21
|
import { convertObject } from "./convertObject.js";
|
|
@@ -34,7 +34,7 @@ export function convertOntologyDefinitionToWireBlockData(ontology) {
|
|
|
34
34
|
}];
|
|
35
35
|
})),
|
|
36
36
|
linkTypes: Object.fromEntries(Object.entries(ontology[OntologyEntityTypeEnum.LINK_TYPE]).map(([id, link]) => {
|
|
37
|
-
return [id, convertLink(link)];
|
|
37
|
+
return [cleanAndValidateLinkTypeId(id), convertLink(link)];
|
|
38
38
|
})),
|
|
39
39
|
actionTypes: Object.fromEntries(Object.entries(ontology[OntologyEntityTypeEnum.ACTION_TYPE]).map(([apiName, action]) => {
|
|
40
40
|
return [apiName, convertAction(action)];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"convertOntologyDefinitionToWireBlockData.js","names":["OntologyEntityTypeEnum","convertAction","convertInterface","convertLink","convertObject","convertSpt","convertOntologyDefinitionToWireBlockData","ontology","objectTypes","Object","fromEntries","entries","OBJECT_TYPE","map","apiName","objectType","sharedPropertyTypes","SHARED_PROPERTY_TYPE","spt","sharedPropertyType","interfaceTypes","INTERFACE_TYPE","interfaceType","linkTypes","LINK_TYPE","id","link","actionTypes","ACTION_TYPE","action","blockPermissionInformation","filter","validation","restrictionStatus","hasRolesApplied","ontologyPackageRid","publicProject"],"sources":["convertOntologyDefinitionToWireBlockData.ts"],"sourcesContent":["/*\n * Copyright 2025 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport type {\n ActionTypePermissionInformation,\n OntologyIrActionTypeBlockDataV2,\n OntologyIrInterfaceTypeBlockDataV2,\n OntologyIrLinkTypeBlockDataV2,\n OntologyIrObjectTypeBlockDataV2,\n OntologyIrOntologyBlockDataV2,\n OntologyIrSharedPropertyTypeBlockDataV2,\n} from \"@osdk/client.unstable\";\nimport { type OntologyDefinition } from \"../../api/common/OntologyDefinition.js\";\nimport { OntologyEntityTypeEnum } from \"../../api/common/OntologyEntityTypeEnum.js\";\nimport {
|
|
1
|
+
{"version":3,"file":"convertOntologyDefinitionToWireBlockData.js","names":["OntologyEntityTypeEnum","cleanAndValidateLinkTypeId","convertAction","convertInterface","convertLink","convertObject","convertSpt","convertOntologyDefinitionToWireBlockData","ontology","objectTypes","Object","fromEntries","entries","OBJECT_TYPE","map","apiName","objectType","sharedPropertyTypes","SHARED_PROPERTY_TYPE","spt","sharedPropertyType","interfaceTypes","INTERFACE_TYPE","interfaceType","linkTypes","LINK_TYPE","id","link","actionTypes","ACTION_TYPE","action","blockPermissionInformation","filter","validation","restrictionStatus","hasRolesApplied","ontologyPackageRid","publicProject"],"sources":["convertOntologyDefinitionToWireBlockData.ts"],"sourcesContent":["/*\n * Copyright 2025 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport type {\n ActionTypePermissionInformation,\n OntologyIrActionTypeBlockDataV2,\n OntologyIrInterfaceTypeBlockDataV2,\n OntologyIrLinkTypeBlockDataV2,\n OntologyIrObjectTypeBlockDataV2,\n OntologyIrOntologyBlockDataV2,\n OntologyIrSharedPropertyTypeBlockDataV2,\n} from \"@osdk/client.unstable\";\nimport { type OntologyDefinition } from \"../../api/common/OntologyDefinition.js\";\nimport { OntologyEntityTypeEnum } from \"../../api/common/OntologyEntityTypeEnum.js\";\nimport {\n cleanAndValidateLinkTypeId,\n convertAction,\n} from \"../../api/defineOntology.js\";\nimport { convertInterface } from \"./convertInterface.js\";\nimport { convertLink } from \"./convertLink.js\";\nimport { convertObject } from \"./convertObject.js\";\nimport { convertSpt } from \"./convertSpt.js\";\n\nexport function convertOntologyDefinitionToWireBlockData(\n ontology: OntologyDefinition,\n): OntologyIrOntologyBlockDataV2 {\n return ({\n objectTypes: Object.fromEntries(\n Object.entries(ontology[OntologyEntityTypeEnum.OBJECT_TYPE]).map<\n [string, OntologyIrObjectTypeBlockDataV2]\n >(([apiName, objectType]) => {\n return [apiName, convertObject(objectType)];\n }),\n ),\n sharedPropertyTypes: Object.fromEntries(\n Object.entries(\n ontology[OntologyEntityTypeEnum.SHARED_PROPERTY_TYPE],\n )\n .map<[string, OntologyIrSharedPropertyTypeBlockDataV2]>((\n [apiName, spt],\n ) => [apiName, { sharedPropertyType: convertSpt(spt) }]),\n ),\n interfaceTypes: Object.fromEntries(\n Object.entries(\n ontology[OntologyEntityTypeEnum.INTERFACE_TYPE],\n )\n .map<[string, OntologyIrInterfaceTypeBlockDataV2]>(\n ([apiName, interfaceType]) => {\n return [apiName, {\n interfaceType: convertInterface(interfaceType),\n }];\n },\n ),\n ),\n linkTypes: Object.fromEntries(\n Object.entries(ontology[OntologyEntityTypeEnum.LINK_TYPE]).map<\n [string, OntologyIrLinkTypeBlockDataV2]\n >(([id, link]) => {\n return [cleanAndValidateLinkTypeId(id), convertLink(link)];\n }),\n ),\n actionTypes: Object.fromEntries(\n Object.entries(ontology[OntologyEntityTypeEnum.ACTION_TYPE]).map<\n [string, OntologyIrActionTypeBlockDataV2]\n >(([apiName, action]) => {\n return [apiName, convertAction(action)];\n }),\n ),\n blockPermissionInformation: {\n actionTypes: Object.fromEntries(\n Object.entries(ontology[OntologyEntityTypeEnum.ACTION_TYPE])\n .filter(([apiName, action]) => action.validation)\n .map<\n [string, ActionTypePermissionInformation]\n >(([apiName, action]) => {\n return [apiName, {\n restrictionStatus: {\n hasRolesApplied: true,\n ontologyPackageRid: null,\n publicProject: false,\n },\n }];\n }),\n ),\n linkTypes: {},\n objectTypes: {},\n },\n });\n}\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAYA,SAASA,sBAAsB,QAAQ,4CAA4C;AACnF,SACEC,0BAA0B,EAC1BC,aAAa,QACR,6BAA6B;AACpC,SAASC,gBAAgB,QAA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E,CAAC,EAAEtB,WAAW,CAACuB,IAAI,CAAC,CAAC;IAC5D,CAAC,CACH,CAAC;IACDC,WAAW,EAAElB,MAAM,CAACC,WAAW,CAC7BD,MAAM,CAACE,OAAO,CAACJ,QAAQ,CAACR,sBAAsB,CAAC6B,WAAW,CAAC,CAAC,CAACf,GAAG,CAE9D,CAAC,CAACC,OAAO,EAAEe,MAAM,CAAC,KAAK;MACvB,OAAO,CAACf,OAAO,EAAEb,aAAa,CAAC4B,MAAM,CAAC,CAAC;IACzC,CAAC,CACH,CAAC;IACDC,0BAA0B,EAAE;MAC1BH,WAAW,EAAElB,MAAM,CAACC,WAAW,CAC7BD,MAAM,CAACE,OAAO,CAACJ,QAAQ,CAACR,sBAAsB,CAAC6B,WAAW,CAAC,CAAC,CACzDG,MAAM,CAAC,CAAC,CAACjB,OAAO,EAAEe,MAAM,CAAC,KAAKA,MAAM,CAACG,UAAU,CAAC,CAChDnB,GAAG,CAEF,CAAC,CAACC,OAAO,EAAEe,MAAM,CAAC,KAAK;QACvB,OAAO,CAACf,OAAO,EAAE;UACfmB,iBAAiB,EAAE;YACjBC,eAAe,EAAE,IAAI;YACrBC,kBAAkB,EAAE,IAAI;YACxBC,aAAa,EAAE;UACjB;QACF,CAAC,CAAC;MACJ,CAAC,CACL,CAAC;MACDb,SAAS,EAAE,CAAC,CAAC;MACbf,WAAW,EAAE,CAAC;IAChB;EACF,CAAC;AACH","ignoreList":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":"AAwBA,
|
|
1
|
+
{"mappings":"AAwBA,cAGE,UACA,0BAMK,qBAAsB;AAI7B,OAAO,iBAAS,WACdA,gBAAgB,qBACf","names":["linkDefinition: LinkTypeDefinition"],"sources":["../../../src/api/defineLink.ts"],"version":3,"file":"defineLink.d.ts"}
|
|
@@ -4,7 +4,7 @@ import type { ActionParameterAllowedValues } from "./action/ActionParameterAllow
|
|
|
4
4
|
import type { ActionType } from "./action/ActionType.js";
|
|
5
5
|
import type { OntologyEntityType } from "./common/OntologyEntityTypeMapping.js";
|
|
6
6
|
export declare function updateOntology<T extends OntologyEntityType>(entity: T): void;
|
|
7
|
-
export declare function defineOntology(ns: string, body: () => void | Promise<void>, outputDir: string | undefined, dependencyFile?: string): Promise<OntologyIr>;
|
|
7
|
+
export declare function defineOntology(ns: string, body: () => void | Promise<void>, outputDir: string | undefined, dependencyFile?: string, randomnessKey?: string): Promise<OntologyIr>;
|
|
8
8
|
export declare function writeStaticObjects(outputDir: string): void;
|
|
9
9
|
export declare function buildDatasource(apiName: string, definition: OntologyIrObjectTypeDatasourceDefinition, classificationMarkingGroupName?: string, mandatoryMarkingGroupName?: string): OntologyIrObjectTypeDatasource;
|
|
10
10
|
export declare function cleanAndValidateLinkTypeId(apiName: string): string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":"AAgBA,cAEE,YACA,iCACA,kCACA,gCACA,0CAGA,8BAEA,2BAEK,uBAAwB;AAS/B,cAAc,uBAAuB,6BAA8B;AACnE,cAAc,oCAAoC,0CAA2C;AAC7F,cAAc,kBAAkB,wBAAyB;AAGzD,cAAc,0BAA0B,uCAAwC;AAiBhF,OAAO,iBAAS,eACd,UAAU,oBAEVA,QAAQ;AAiBV,OAAO,iBAAe,eACpBC,YACAC,mBAAmB,eACnBC,+BACAC,
|
|
1
|
+
{"mappings":"AAgBA,cAEE,YACA,iCACA,kCACA,gCACA,0CAGA,8BAEA,2BAEK,uBAAwB;AAS/B,cAAc,uBAAuB,6BAA8B;AACnE,cAAc,oCAAoC,0CAA2C;AAC7F,cAAc,kBAAkB,wBAAyB;AAGzD,cAAc,0BAA0B,uCAAwC;AAiBhF,OAAO,iBAAS,eACd,UAAU,oBAEVA,QAAQ;AAiBV,OAAO,iBAAe,eACpBC,YACAC,mBAAmB,eACnBC,+BACAC,yBACAC,yBACC,QAAQ;AAuCX,OAAO,iBAAS,mBAAmBC;AA+EnC,OAAO,iBAAS,gBACdC,iBACAC,YAAY,0CACZC,yCACAC,qCACC;AA6BH,OAAO,iBAAS,2BAA2BH;AAkB3C,OAAO,iBAAS,4BAA4B;AAI5C,OAAO,iBAAS,yBAAyB;AAIzC,OAAO,iBAAS,oBAAoBI;AAoCpC,OAAO,iBAAS,cACdC,QAAQ,aACP;AAwEH,OAAO,iBAAS,qBACdC,eAAe,+BACd;AAoGH,OAAO,iBAAS,uBACdC,WAAW,kBACV;AAgEH,OAAO,iBAAS,iBAAiBP;AAIjC,OAAO,iBAAS,iBAAiBA;AA8CjC,OAAO,iBAAS,mBAAmBA","names":["entity: T","ns: string","body: () => void | Promise<void>","outputDir: string | undefined","dependencyFile?: string","randomnessKey?: string","outputDir: string","apiName: string","definition: OntologyIrObjectTypeDatasourceDefinition","classificationMarkingGroupName?: string","mandatoryMarkingGroupName?: string","status: any","action: ActionType","allowedValues: ActionParameterAllowedValues","parameter: ActionParameter"],"sources":["../../../src/api/defineOntology.ts"],"version":3,"file":"defineOntology.d.ts"}
|
|
@@ -8,11 +8,15 @@ export type LinkType = (OntologyEntityBase & OneToManyLinkTypeDefinition & {
|
|
|
8
8
|
__type: OntologyEntityTypeEnum.LINK_TYPE
|
|
9
9
|
}) | (OntologyEntityBase & ManyToManyLinkTypeDefinition & {
|
|
10
10
|
__type: OntologyEntityTypeEnum.LINK_TYPE
|
|
11
|
+
}) | (OntologyEntityBase & IntermediaryLinkTypeDefinition & {
|
|
12
|
+
__type: OntologyEntityTypeEnum.LINK_TYPE
|
|
11
13
|
});
|
|
12
14
|
export type LinkTypeDefinition = Omit<OntologyEntityBase & OneToManyLinkTypeUserDefinition & {
|
|
13
15
|
__type: OntologyEntityTypeEnum.LINK_TYPE
|
|
14
16
|
}, "__type"> | Omit<OntologyEntityBase & ManyToManyLinkTypeUserDefinition & {
|
|
15
17
|
__type: OntologyEntityTypeEnum.LINK_TYPE
|
|
18
|
+
}, "__type"> | Omit<OntologyEntityBase & IntermediaryLinkTypeUserDefinition & {
|
|
19
|
+
__type: OntologyEntityTypeEnum.LINK_TYPE
|
|
16
20
|
}, "__type">;
|
|
17
21
|
export type ObjectTypePropertyApiName = string;
|
|
18
22
|
export interface OneToManyLinkTypeDefinition {
|
|
@@ -61,6 +65,31 @@ export interface ManyToManyObjectLinkReferenceUserDefinition {
|
|
|
61
65
|
object: ObjectTypeDefinition;
|
|
62
66
|
metadata: LinkTypeMetadataUserDefinition;
|
|
63
67
|
}
|
|
68
|
+
export interface IntermediaryLinkTypeDefinition {
|
|
69
|
+
apiName: string;
|
|
70
|
+
many: IntermediaryObjectLinkReference;
|
|
71
|
+
toMany: IntermediaryObjectLinkReference;
|
|
72
|
+
intermediaryObjectType: ObjectTypeDefinition;
|
|
73
|
+
editsEnabled?: boolean;
|
|
74
|
+
status?: OntologyIrLinkTypeStatus;
|
|
75
|
+
redacted?: boolean;
|
|
76
|
+
}
|
|
77
|
+
export interface IntermediaryObjectLinkReference {
|
|
78
|
+
object: ObjectTypeDefinition;
|
|
79
|
+
metadata: LinkTypeMetadata;
|
|
80
|
+
linkToIntermediary: LinkType;
|
|
81
|
+
}
|
|
82
|
+
export interface IntermediaryLinkTypeUserDefinition {
|
|
83
|
+
apiName: string;
|
|
84
|
+
many: IntermediaryObjectLinkReferenceUserDefinition;
|
|
85
|
+
toMany: IntermediaryObjectLinkReferenceUserDefinition;
|
|
86
|
+
intermediaryObjectType: ObjectTypeDefinition;
|
|
87
|
+
}
|
|
88
|
+
export interface IntermediaryObjectLinkReferenceUserDefinition {
|
|
89
|
+
object: ObjectTypeDefinition;
|
|
90
|
+
metadata: LinkTypeMetadataUserDefinition;
|
|
91
|
+
linkToIntermediary: LinkType;
|
|
92
|
+
}
|
|
64
93
|
export interface LinkTypeMetadataUserDefinition {
|
|
65
94
|
apiName: string;
|
|
66
95
|
displayName?: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":"AAgBA,cACE,yBACA,kBACA,0BACA,kBACK,uBAAwB;AAC/B,cAAc,sBAAsB,8BAA+B;AACnE,cAAc,sBAAsB,8BAA+B;AACnE,cAAc,0BAA0B,iCAAkC;AAC1E,cAAc,8BAA8B,qCAAsC;AAClF,cAAc,4BAA4B,mCAAoC;AAE9E,YAAY,YACP,qBAAqB,8BAA8B;CACpD,QAAQ,uBAAuB;AAChC,MACE,qBAAqB,+BAA+B;CACrD,QAAQ,uBAAuB;AAChC;AAEH,YAAY,qBACR,KACA,qBAAqB,kCAAkC;CACrD,QAAQ,uBAAuB;AAChC,GACD,YAEA,KACA,qBAAqB,mCAAmC;CACtD,QAAQ,uBAAuB;AAChC,GACD;AAGJ,YAAY;AAEZ,iBAAiB,4BAA4B;CAC3C;CACA,KAAK;CACL,QAAQ;CACR,wBAAwB;CACxB,aAAa,cAAc;CAC3B;CACA,SAAS;CACT;AACD;AAED,iBAAiB,6BAA6B;CAC5C,QAAQ;CACR,UAAU;AACX;AAED,iBAAiB,gCAAgC;CAC/C;CACA,KAAK;CACL,QAAQ;CACR,wBAAwB;CACxB,cAAc,cAAc;AAC7B;AAED,iBAAiB,2CAA2C;CAC1D,QAAQ;CACR,UAAU;AACX;AAED,iBAAiB,6BAA6B;CAC5C;CACA,MAAM;CACN,QAAQ;CACR;CACA,SAAS;CACT;AACD;AAED,iBAAiB,8BAA8B;CAC7C,QAAQ;CACR,UAAU;AACX;AAED,iBAAiB,iCAAiC;CAChD;CACA,MAAM;CACN,QAAQ;AACT;AAED,iBAAiB,4CAA4C;CAC3D,QAAQ;CACR,UAAU;AACX;AAED,iBAAiB,+BAA+B;CAC9C;CACA;CACA;CACA,aAAa;CACb;AACD;AAED,YAAY,mBAAmB,eAC7B,eACE,KAAK,kBAAkB,qBAAqB,yBAC5C,YAEF,eAAe","names":[],"sources":["../../../../src/api/links/LinkType.ts"],"version":3,"file":"LinkType.d.ts"}
|
|
1
|
+
{"mappings":"AAgBA,cACE,yBACA,kBACA,0BACA,kBACK,uBAAwB;AAC/B,cAAc,sBAAsB,8BAA+B;AACnE,cAAc,sBAAsB,8BAA+B;AACnE,cAAc,0BAA0B,iCAA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Q;CACR,UAAU;CACV,oBAAoB;AACrB;AAED,iBAAiB,+BAA+B;CAC9C;CACA;CACA;CACA,aAAa;CACb;AACD;AAED,YAAY,mBAAmB,eAC7B,eACE,KAAK,kBAAkB,qBAAqB,yBAC5C,YAEF,eAAe","names":[],"sources":["../../../../src/api/links/LinkType.ts"],"version":3,"file":"LinkType.d.ts"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":"
|
|
1
|
+
{"mappings":"eA2Be,SAAe,KAC5BA,kBACC","names":["args: string[]"],"sources":["../../../src/cli/main.ts"],"version":3,"file":"main.d.ts"}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import type { OntologyIr } from "@osdk/client.unstable";
|
|
2
2
|
import type { OntologyDefinition } from "../../api/common/OntologyDefinition.js";
|
|
3
|
-
export declare function convertOntologyDefinition(ontology: OntologyDefinition): OntologyIr;
|
|
3
|
+
export declare function convertOntologyDefinition(ontology: OntologyDefinition, randomnessKey?: string): OntologyIr;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":"AAgBA,cAAc,kBAAkB,uBAAwB;AACxD,cAAc,0BAA0B,wCAAyC;AAKjF,OAAO,iBAAS,0BACdA,UAAU,
|
|
1
|
+
{"mappings":"AAgBA,cAAc,kBAAkB,uBAAwB;AACxD,cAAc,0BAA0B,wCAAyC;AAKjF,OAAO,iBAAS,0BACdA,UAAU,oBACVC,yBACC","names":["ontology: OntologyDefinition","randomnessKey?: string"],"sources":["../../../../src/conversion/toMarketplace/convertOntologyDefinition.ts"],"version":3,"file":"convertOntologyDefinition.d.ts"}
|
package/build/types/conversion/toMarketplace/convertOntologyDefinitionToWireBlockData.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":"AAgBA,cAME,qCAEK,uBAAwB;AAC/B,cAAc,0BAA0B,wCAAyC;
|
|
1
|
+
{"mappings":"AAgBA,cAME,qCAEK,uBAAwB;AAC/B,cAAc,0BAA0B,wCAAyC;AAWjF,OAAO,iBAAS,yCACdA,UAAU,qBACT","names":["ontology: OntologyDefinition"],"sources":["../../../../src/conversion/toMarketplace/convertOntologyDefinitionToWireBlockData.ts"],"version":3,"file":"convertOntologyDefinitionToWireBlockData.d.ts"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@osdk/maker",
|
|
3
|
-
"version": "0.13.0-beta.
|
|
3
|
+
"version": "0.13.0-beta.15",
|
|
4
4
|
"license": "Apache-2.0",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -32,17 +32,18 @@
|
|
|
32
32
|
"semver-ts": "^1.0.3",
|
|
33
33
|
"tiny-invariant": "^1.3.3",
|
|
34
34
|
"ts-node": "^10.9.2",
|
|
35
|
+
"uuid": "^13.0.0",
|
|
35
36
|
"yargs": "^17.7.2",
|
|
36
|
-
"@osdk/api": "~2.5.0-beta.
|
|
37
|
+
"@osdk/api": "~2.5.0-beta.14"
|
|
37
38
|
},
|
|
38
39
|
"devDependencies": {
|
|
39
40
|
"@types/node": "^20.19.13",
|
|
40
41
|
"@types/yargs": "^17.0.33",
|
|
41
42
|
"typescript": "~5.5.4",
|
|
42
43
|
"vitest": "^3.2.4",
|
|
43
|
-
"@osdk/
|
|
44
|
+
"@osdk/client.unstable": "~2.5.0-beta.14",
|
|
44
45
|
"@osdk/monorepo.api-extractor": "~0.4.0-beta.1",
|
|
45
|
-
"@osdk/
|
|
46
|
+
"@osdk/monorepo.tsconfig": "~0.4.0-beta.1"
|
|
46
47
|
},
|
|
47
48
|
"publishConfig": {
|
|
48
49
|
"access": "public"
|