@osdk/client 2.4.0-beta.9 → 2.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +191 -0
- package/build/browser/MinimalClientContext.js.map +1 -1
- package/build/browser/createClient.js +5 -5
- package/build/browser/createClient.js.map +1 -1
- package/build/browser/createClient.test.js +3 -3
- package/build/browser/createClient.test.js.map +1 -1
- package/build/browser/createMinimalClient.js +1 -0
- package/build/browser/createMinimalClient.js.map +1 -1
- package/build/browser/derivedProperties/createWithPropertiesObjectSet.js +0 -17
- package/build/browser/derivedProperties/createWithPropertiesObjectSet.js.map +1 -1
- package/build/browser/fetchMetadata.test.js +7 -1
- package/build/browser/fetchMetadata.test.js.map +1 -1
- package/build/browser/index.js +2 -1
- package/build/browser/index.js.map +1 -1
- package/build/browser/object/convertWireToOsdkObjects.js +3 -2
- package/build/browser/object/convertWireToOsdkObjects.js.map +1 -1
- package/build/browser/object/convertWireToOsdkObjects.test.js +36 -24
- package/build/browser/object/convertWireToOsdkObjects.test.js.map +1 -1
- package/build/browser/object/fetchPage.js +9 -2
- package/build/browser/object/fetchPage.js.map +1 -1
- package/build/browser/object/mediaUpload.js +0 -3
- package/build/browser/object/mediaUpload.js.map +1 -1
- package/build/browser/objectSet/InterfaceObjectSet.test.js +5 -1
- package/build/browser/objectSet/InterfaceObjectSet.test.js.map +1 -1
- package/build/browser/objectSet/createObjectSet.js +5 -1
- package/build/browser/objectSet/createObjectSet.js.map +1 -1
- package/build/browser/observable/internal/ActionApplication.js +1 -1
- package/build/browser/observable/internal/ActionApplication.js.map +1 -1
- package/build/browser/observable/internal/Store.test.js +3 -0
- package/build/browser/observable/internal/Store.test.js.map +1 -1
- package/build/browser/ontology/StandardOntologyProvider.test.js +1 -1
- package/build/browser/ontology/StandardOntologyProvider.test.js.map +1 -1
- package/build/browser/public/unstable-do-not-use.js +1 -0
- package/build/browser/public/unstable-do-not-use.js.map +1 -1
- package/build/browser/public-utils/hydrateObjectSetFromObjectRids.js +4 -1
- package/build/browser/public-utils/hydrateObjectSetFromObjectRids.js.map +1 -1
- package/build/browser/public-utils/hydrateObjectSetFromRid.js +4 -1
- package/build/browser/public-utils/hydrateObjectSetFromRid.js.map +1 -1
- package/build/browser/queries/applyQuery.js +24 -1
- package/build/browser/queries/applyQuery.js.map +1 -1
- package/build/browser/queries/queries.test.js +27 -2
- package/build/browser/queries/queries.test.js.map +1 -1
- package/build/browser/queries/types.js.map +1 -1
- package/build/browser/util/UserAgent.js +2 -2
- package/build/browser/util/UserAgent.js.map +1 -1
- package/build/browser/util/WireObjectSet.js +1 -1
- package/build/browser/util/WireObjectSet.js.map +1 -1
- package/build/browser/util/extractObjectOrInterfaceType.js +96 -0
- package/build/browser/util/extractObjectOrInterfaceType.js.map +1 -0
- package/build/browser/util/extractObjectOrInterfaceType.test.js +135 -0
- package/build/browser/util/extractObjectOrInterfaceType.test.js.map +1 -0
- package/build/browser/util/interfaceUtils.js +10 -0
- package/build/browser/util/interfaceUtils.js.map +1 -1
- package/build/browser/util/objectSpecifierUtils.js +12 -0
- package/build/browser/util/objectSpecifierUtils.js.map +1 -1
- package/build/browser/util/toDataValue.js +1 -15
- package/build/browser/util/toDataValue.js.map +1 -1
- package/build/browser/util/toDataValue.test.js +2 -42
- package/build/browser/util/toDataValue.test.js.map +1 -1
- package/build/browser/util/toDataValueQueries.js +11 -0
- package/build/browser/util/toDataValueQueries.js.map +1 -1
- package/build/cjs/{Client-CgL2LKN9.d.cts → Client-CF85LpFu.d.cts} +2 -2
- package/build/cjs/{chunk-E5BQ7757.cjs → chunk-DSQAJPW5.cjs} +120 -64
- package/build/cjs/chunk-DSQAJPW5.cjs.map +1 -0
- package/build/cjs/chunk-Q7SFCCGT.cjs +11 -0
- package/build/cjs/chunk-Q7SFCCGT.cjs.map +1 -0
- package/build/cjs/{chunk-YZHCDIYC.cjs → chunk-RLFLBDLT.cjs} +117 -85
- package/build/cjs/chunk-RLFLBDLT.cjs.map +1 -0
- package/build/cjs/createClient-BJo8T7Js.d.cts +9 -0
- package/build/cjs/delay-QK4T7RVX.cjs +74 -0
- package/build/cjs/delay-QK4T7RVX.cjs.map +1 -0
- package/build/cjs/index.cjs +9 -8
- package/build/cjs/index.cjs.map +1 -1
- package/build/cjs/index.d.cts +15 -8
- package/build/cjs/public/internal.cjs +17 -10
- package/build/cjs/public/internal.cjs.map +1 -1
- package/build/cjs/public/internal.d.cts +1 -1
- package/build/cjs/public/unstable-do-not-use.cjs +22 -71
- package/build/cjs/public/unstable-do-not-use.cjs.map +1 -1
- package/build/cjs/public/unstable-do-not-use.d.cts +2 -1
- package/build/esm/MinimalClientContext.js.map +1 -1
- package/build/esm/createClient.js +5 -5
- package/build/esm/createClient.js.map +1 -1
- package/build/esm/createClient.test.js +3 -3
- package/build/esm/createClient.test.js.map +1 -1
- package/build/esm/createMinimalClient.js +1 -0
- package/build/esm/createMinimalClient.js.map +1 -1
- package/build/esm/derivedProperties/createWithPropertiesObjectSet.js +0 -17
- package/build/esm/derivedProperties/createWithPropertiesObjectSet.js.map +1 -1
- package/build/esm/fetchMetadata.test.js +7 -1
- package/build/esm/fetchMetadata.test.js.map +1 -1
- package/build/esm/index.js +2 -1
- package/build/esm/index.js.map +1 -1
- package/build/esm/object/convertWireToOsdkObjects.js +3 -2
- package/build/esm/object/convertWireToOsdkObjects.js.map +1 -1
- package/build/esm/object/convertWireToOsdkObjects.test.js +36 -24
- package/build/esm/object/convertWireToOsdkObjects.test.js.map +1 -1
- package/build/esm/object/fetchPage.js +9 -2
- package/build/esm/object/fetchPage.js.map +1 -1
- package/build/esm/object/mediaUpload.js +0 -3
- package/build/esm/object/mediaUpload.js.map +1 -1
- package/build/esm/objectSet/InterfaceObjectSet.test.js +5 -1
- package/build/esm/objectSet/InterfaceObjectSet.test.js.map +1 -1
- package/build/esm/objectSet/createObjectSet.js +5 -1
- package/build/esm/objectSet/createObjectSet.js.map +1 -1
- package/build/esm/observable/internal/ActionApplication.js +1 -1
- package/build/esm/observable/internal/ActionApplication.js.map +1 -1
- package/build/esm/observable/internal/Store.test.js +3 -0
- package/build/esm/observable/internal/Store.test.js.map +1 -1
- package/build/esm/ontology/StandardOntologyProvider.test.js +1 -1
- package/build/esm/ontology/StandardOntologyProvider.test.js.map +1 -1
- package/build/esm/public/unstable-do-not-use.js +1 -0
- package/build/esm/public/unstable-do-not-use.js.map +1 -1
- package/build/esm/public-utils/hydrateObjectSetFromObjectRids.js +4 -1
- package/build/esm/public-utils/hydrateObjectSetFromObjectRids.js.map +1 -1
- package/build/esm/public-utils/hydrateObjectSetFromRid.js +4 -1
- package/build/esm/public-utils/hydrateObjectSetFromRid.js.map +1 -1
- package/build/esm/queries/applyQuery.js +24 -1
- package/build/esm/queries/applyQuery.js.map +1 -1
- package/build/esm/queries/queries.test.js +27 -2
- package/build/esm/queries/queries.test.js.map +1 -1
- package/build/esm/queries/types.js.map +1 -1
- package/build/esm/util/UserAgent.js +2 -2
- package/build/esm/util/UserAgent.js.map +1 -1
- package/build/esm/util/WireObjectSet.js +1 -1
- package/build/esm/util/WireObjectSet.js.map +1 -1
- package/build/esm/util/extractObjectOrInterfaceType.js +96 -0
- package/build/esm/util/extractObjectOrInterfaceType.js.map +1 -0
- package/build/esm/util/extractObjectOrInterfaceType.test.js +135 -0
- package/build/esm/util/extractObjectOrInterfaceType.test.js.map +1 -0
- package/build/esm/util/interfaceUtils.js +10 -0
- package/build/esm/util/interfaceUtils.js.map +1 -1
- package/build/esm/util/objectSpecifierUtils.js +12 -0
- package/build/esm/util/objectSpecifierUtils.js.map +1 -1
- package/build/esm/util/toDataValue.js +1 -15
- package/build/esm/util/toDataValue.js.map +1 -1
- package/build/esm/util/toDataValue.test.js +2 -42
- package/build/esm/util/toDataValue.test.js.map +1 -1
- package/build/esm/util/toDataValueQueries.js +11 -0
- package/build/esm/util/toDataValueQueries.js.map +1 -1
- package/build/types/MinimalClientContext.d.ts +1 -0
- package/build/types/MinimalClientContext.d.ts.map +1 -1
- package/build/types/createClient.d.ts +1 -0
- package/build/types/createClient.d.ts.map +1 -1
- package/build/types/index.d.ts +3 -2
- package/build/types/index.d.ts.map +1 -1
- package/build/types/object/fetchPage.d.ts.map +1 -1
- package/build/types/object/mediaUpload.d.ts +1 -2
- package/build/types/object/mediaUpload.d.ts.map +1 -1
- package/build/types/observable/internal/ActionApplication.d.ts.map +1 -1
- package/build/types/public/unstable-do-not-use.d.ts +1 -0
- package/build/types/public/unstable-do-not-use.d.ts.map +1 -1
- package/build/types/queries/applyQuery.d.ts +5 -1
- package/build/types/queries/applyQuery.d.ts.map +1 -1
- package/build/types/queries/types.d.ts +2 -2
- package/build/types/queries/types.d.ts.map +1 -1
- package/build/types/util/extractObjectOrInterfaceType.d.ts +1 -0
- package/build/types/util/extractObjectOrInterfaceType.d.ts.map +1 -0
- package/build/types/util/extractObjectOrInterfaceType.test.d.ts +1 -0
- package/build/types/util/extractObjectOrInterfaceType.test.d.ts.map +1 -0
- package/build/types/util/objectSpecifierUtils.d.ts +13 -1
- package/build/types/util/objectSpecifierUtils.d.ts.map +1 -1
- package/package.json +11 -11
- package/build/cjs/chunk-E5BQ7757.cjs.map +0 -1
- package/build/cjs/chunk-YZHCDIYC.cjs.map +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"toDataValueQueries.js","names":["OntologiesV2","isAttachmentFile","isAttachmentUpload","getWireObjectSet","isObjectSet","isObjectSpecifiersObject","extractPrimaryKeyFromObjectSpecifier","isWireObjectSet","toDataValueQueries","value","client","desiredType","Array","isArray","multiplicity","values","from","some","dataValue","converted","push","promiseArray","innerValue","Promise","all","type","attachment","Attachments","upload","data","filename","name","rid","groups","Set","$primaryKey","entrySet","key","mapValue","Object","entries","keyType","valueType","structMap","structValue"],"sources":["toDataValueQueries.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 type { QueryDataTypeDefinition } from \"@osdk/api\";\nimport { type DataValue } from \"@osdk/foundry.ontologies\";\nimport * as OntologiesV2 from \"@osdk/foundry.ontologies\";\nimport type { MinimalClient } from \"../MinimalClientContext.js\";\nimport {\n isAttachmentFile,\n isAttachmentUpload,\n} from \"../object/AttachmentUpload.js\";\nimport { getWireObjectSet, isObjectSet } from \"../objectSet/createObjectSet.js\";\nimport { isObjectSpecifiersObject } from \"./isObjectSpecifiersObject.js\";\nimport { extractPrimaryKeyFromObjectSpecifier } from \"./objectSpecifierUtils.js\";\nimport { isWireObjectSet } from \"./WireObjectSet.js\";\n\n/**\n * Marshall user-facing data into the wire DataValue type\n *\n * @see DataValue for the expected payloads\n * @internal\n */\nexport async function toDataValueQueries(\n value: unknown,\n client: MinimalClient,\n desiredType: QueryDataTypeDefinition,\n): Promise<DataValue> {\n if (value == null) {\n return value;\n }\n\n if (Array.isArray(value) && desiredType.multiplicity) {\n const values = Array.from(value);\n if (\n values.some((dataValue) =>\n isAttachmentUpload(dataValue) || isAttachmentFile(dataValue)\n )\n ) {\n const converted = [];\n for (const value of values) {\n converted.push(await toDataValueQueries(value, client, desiredType));\n }\n return converted;\n }\n const promiseArray = Array.from(\n value,\n async (innerValue) =>\n await toDataValueQueries(innerValue, client, desiredType),\n );\n return Promise.all(promiseArray);\n }\n\n switch (desiredType.type) {\n case \"attachment\": {\n if (isAttachmentUpload(value)) {\n const attachment = await OntologiesV2.Attachments.upload(\n client,\n value.data,\n {\n filename: value.name,\n },\n );\n return attachment.rid;\n }\n\n if (\n isAttachmentFile(value)\n ) {\n const attachment = await OntologiesV2.Attachments.upload(\n client,\n value,\n {\n filename: value.name as string,\n },\n );\n return attachment.rid;\n }\n\n // If it's not an upload, it's just an attachment rid string which we can pass through\n return value;\n }\n case \"twoDimensionalAggregation\": {\n return {\n groups: value,\n };\n }\n case \"threeDimensionalAggregation\": {\n return {\n groups: value,\n };\n }\n\n case \"set\": {\n if (value instanceof Set) {\n const promiseArray = Array.from(\n value,\n async (innerValue) =>\n await toDataValueQueries(innerValue, client, desiredType[\"set\"]),\n );\n return Promise.all(promiseArray);\n }\n break;\n }\n case \"object\": {\n if (isObjectSpecifiersObject(value)) {\n return value.$primaryKey;\n }\n break;\n }\n case \"objectSet\": {\n // object set (the rid as a string (passes through the last return), or the ObjectSet definition directly)\n if (isWireObjectSet(value)) {\n return value;\n }\n if (isObjectSet(value)) {\n return getWireObjectSet(value);\n }\n break;\n }\n\n case \"map\": {\n if (typeof value === \"object\") {\n const entrySet: Array<{ key: any; value: any }> = [];\n for (const [key, mapValue] of Object.entries(value)) {\n entrySet.push({\n key: desiredType.keyType.type === \"object\"\n ? extractPrimaryKeyFromObjectSpecifier(key as any)\n : await toDataValueQueries(\n key,\n client,\n desiredType.keyType,\n ),\n value: await toDataValueQueries(\n mapValue,\n client,\n desiredType.valueType,\n ),\n });\n }\n return entrySet;\n }\n break;\n }\n\n case \"struct\": {\n if (typeof value === \"object\") {\n const structMap: { [key: string]: unknown } = {};\n for (const [key, structValue] of Object.entries(value)) {\n structMap[key] = await toDataValueQueries(\n structValue,\n client,\n desiredType[\"struct\"][key],\n );\n }\n return structMap;\n }\n }\n\n case \"boolean\":\n case \"date\":\n case \"double\":\n case \"float\":\n case \"integer\":\n case \"long\":\n case \"string\":\n case \"timestamp\":\n return value;\n }\n return value;\n}\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAIA,OAAO,KAAKA,YAAY,MAAM,0BAA0B;AAExD,SACEC,gBAAgB,EAChBC,kBAAkB,QACb,+BAA+B;AACtC,SAASC,gBAAgB,EAAEC,WAAW,QAAQ,iCAAiC;AAC/E,SAASC,wBAAwB,QAAQ,+BAA+B;AACxE,SAASC,oCAAoC,QAAQ,2BAA2B;AAChF,SAASC,eAAe,QAAQ,oBAAoB;;AAEpD;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,eAAeC,kBAAkBA,CACtCC,KAAc,EACdC,MAAqB,EACrBC,WAAoC,EAChB;EACpB,IAAIF,KAAK,IAAI,IAAI,EAAE;IACjB,OAAOA,KAAK;EACd;EAEA,IAAIG,KAAK,CAACC,OAAO,CAACJ,KAAK,CAAC,IAAIE,WAAW,CAACG,YAAY,EAAE;IACpD,MAAMC,MAAM,GAAGH,KAAK,CAACI,IAAI,CAACP,KAAK,CAAC;IAChC,IACEM,MAAM,CAACE,IAAI,CAAEC,SAAS,
|
|
1
|
+
{"version":3,"file":"toDataValueQueries.js","names":["OntologiesV2","isAttachmentFile","isAttachmentUpload","getWireObjectSet","isObjectSet","isInterfaceQueryParam","isInterfaceSpecifier","isObjectSpecifiersObject","extractPrimaryKeyFromObjectSpecifier","isWireObjectSet","toDataValueQueries","value","client","desiredType","Array","isArray","multiplicity","values","from","some","dataValue","converted","push","promiseArray","innerValue","Promise","all","type","attachment","Attachments","upload","data","filename","name","rid","groups","Set","$primaryKey","objectTypeApiName","$objectType","primaryKeyValue","entrySet","key","mapValue","Object","entries","keyType","valueType","structMap","structValue"],"sources":["toDataValueQueries.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 type { QueryDataTypeDefinition } from \"@osdk/api\";\nimport { type DataValue } from \"@osdk/foundry.ontologies\";\nimport * as OntologiesV2 from \"@osdk/foundry.ontologies\";\nimport type { MinimalClient } from \"../MinimalClientContext.js\";\nimport {\n isAttachmentFile,\n isAttachmentUpload,\n} from \"../object/AttachmentUpload.js\";\nimport { getWireObjectSet, isObjectSet } from \"../objectSet/createObjectSet.js\";\nimport {\n isInterfaceQueryParam,\n isInterfaceSpecifier,\n} from \"./interfaceUtils.js\";\nimport { isObjectSpecifiersObject } from \"./isObjectSpecifiersObject.js\";\nimport { extractPrimaryKeyFromObjectSpecifier } from \"./objectSpecifierUtils.js\";\nimport { isWireObjectSet } from \"./WireObjectSet.js\";\n\n/**\n * Marshall user-facing data into the wire DataValue type\n *\n * @see DataValue for the expected payloads\n * @internal\n */\nexport async function toDataValueQueries(\n value: unknown,\n client: MinimalClient,\n desiredType: QueryDataTypeDefinition,\n): Promise<DataValue> {\n if (value == null) {\n return value;\n }\n\n if (Array.isArray(value) && desiredType.multiplicity) {\n const values = Array.from(value);\n if (\n values.some((dataValue) =>\n isAttachmentUpload(dataValue) || isAttachmentFile(dataValue)\n )\n ) {\n const converted = [];\n for (const value of values) {\n converted.push(await toDataValueQueries(value, client, desiredType));\n }\n return converted;\n }\n const promiseArray = Array.from(\n value,\n async (innerValue) =>\n await toDataValueQueries(innerValue, client, desiredType),\n );\n return Promise.all(promiseArray);\n }\n\n switch (desiredType.type) {\n case \"attachment\": {\n if (isAttachmentUpload(value)) {\n const attachment = await OntologiesV2.Attachments.upload(\n client,\n value.data,\n {\n filename: value.name,\n },\n );\n return attachment.rid;\n }\n\n if (\n isAttachmentFile(value)\n ) {\n const attachment = await OntologiesV2.Attachments.upload(\n client,\n value,\n {\n filename: value.name as string,\n },\n );\n return attachment.rid;\n }\n\n // If it's not an upload, it's just an attachment rid string which we can pass through\n return value;\n }\n case \"twoDimensionalAggregation\": {\n return {\n groups: value,\n };\n }\n case \"threeDimensionalAggregation\": {\n return {\n groups: value,\n };\n }\n\n case \"set\": {\n if (value instanceof Set) {\n const promiseArray = Array.from(\n value,\n async (innerValue) =>\n await toDataValueQueries(innerValue, client, desiredType[\"set\"]),\n );\n return Promise.all(promiseArray);\n }\n break;\n }\n case \"object\": {\n if (isObjectSpecifiersObject(value)) {\n return value.$primaryKey;\n }\n break;\n }\n case \"interface\": {\n if (isInterfaceSpecifier(value) || isInterfaceQueryParam(value)) {\n return {\n objectTypeApiName: value.$objectType,\n primaryKeyValue: value.$primaryKey,\n };\n }\n }\n case \"objectSet\":\n case \"interfaceObjectSet\": {\n // object set (the rid as a string (passes through the last return), or the ObjectSet definition directly)\n if (isWireObjectSet(value)) {\n return value;\n }\n if (isObjectSet(value)) {\n return getWireObjectSet(value);\n }\n break;\n }\n\n case \"map\": {\n if (typeof value === \"object\") {\n const entrySet: Array<{ key: any; value: any }> = [];\n for (const [key, mapValue] of Object.entries(value)) {\n entrySet.push({\n key: desiredType.keyType.type === \"object\"\n ? extractPrimaryKeyFromObjectSpecifier(key as any)\n : await toDataValueQueries(\n key,\n client,\n desiredType.keyType,\n ),\n value: await toDataValueQueries(\n mapValue,\n client,\n desiredType.valueType,\n ),\n });\n }\n return entrySet;\n }\n break;\n }\n\n case \"struct\": {\n if (typeof value === \"object\") {\n const structMap: { [key: string]: unknown } = {};\n for (const [key, structValue] of Object.entries(value)) {\n structMap[key] = await toDataValueQueries(\n structValue,\n client,\n desiredType[\"struct\"][key],\n );\n }\n return structMap;\n }\n }\n\n case \"boolean\":\n case \"date\":\n case \"double\":\n case \"float\":\n case \"integer\":\n case \"long\":\n case \"string\":\n case \"timestamp\":\n return value;\n }\n return value;\n}\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAIA,OAAO,KAAKA,YAAY,MAAM,0BAA0B;AAExD,SACEC,gBAAgB,EAChBC,kBAAkB,QACb,+BAA+B;AACtC,SAASC,gBAAgB,EAAEC,WAAW,QAAQ,iCAAiC;AAC/E,S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ignoreList":[]}
|
|
@@ -12,6 +12,7 @@ export interface MinimalClient extends SharedClientContext {
|
|
|
12
12
|
ontologyRid: string | Promise<string>;
|
|
13
13
|
ontologyProvider: OntologyProvider;
|
|
14
14
|
logger?: Logger;
|
|
15
|
+
transactionRid?: string;
|
|
15
16
|
clientCacheKey: ClientCacheKey;
|
|
16
17
|
requestContext: RequestContext;
|
|
17
18
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":"AAgBA,cAAc,cAAc,WAAY;AACxC,cAAc,2BAA2B,sBAAuB;AAMhE,cAAc,wBAAwB,gCAAiC;AAEvE,cAAcA;AAEd,YAAY,iBAAiB,CAAE,IAAG;WAAY;AAAY;AAE1D,YAAY,iBAAiB;CAC3B;AACD;AAED,iBAAiB,sBAAsB,oBAAoB;CACzD,sBAAsB;CACtB,kBAAkB;CAClB,SAAS;
|
|
1
|
+
{"mappings":"AAgBA,cAAc,cAAc,WAAY;AACxC,cAAc,2BAA2B,sBAAuB;AAMhE,cAAc,wBAAwB,gCAAiC;AAEvE,cAAcA;AAEd,YAAY,iBAAiB,CAAE,IAAG;WAAY;AAAY;AAE1D,YAAY,iBAAiB;CAC3B;AACD;AAED,iBAAiB,sBAAsB,oBAAoB;CACzD,sBAAsB;CACtB,kBAAkB;CAClB,SAAS;CACT;CAQA,gBAAgB;CAChB,gBAAgB;AACjB;AAED,YAAY,sBAAsB;CAChC,UAAU;CACV,UAAU;AACX;AAED,iBAAiB,sBAAsB;CACrC,sBAAsB;AACvB","names":["tag: unique symbol"],"sources":["../../src/MinimalClientContext.ts"],"version":3,"file":"MinimalClientContext.d.ts"}
|
|
@@ -3,3 +3,4 @@ import { type Client } from "./Client.js";
|
|
|
3
3
|
export declare const createClient: (baseUrl: string, ontologyRid: string | Promise<string>, tokenProvider: () => Promise<string>, options?: {
|
|
4
4
|
logger?: Logger
|
|
5
5
|
} | undefined, fetchFn?: typeof fetch | undefined) => Client;
|
|
6
|
+
export declare const createClientWithTransaction: (transactionRid: string, ...args: Parameters<typeof createClient>) => Client;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":"AAgBA,cAIE,cASK,WAAY;AAkBnB,cAAiC,cAAc,aAAc;
|
|
1
|
+
{"mappings":"AAgBA,cAIE,cASK,WAAY;AAkBnB,cAAiC,cAAc,aAAc;AAgP7D,OAAO,cAAMA,eACXC,iBACAC,sBAAsB,iBACtBC,qBAAqB,iBACrBC,UAAU;CACR,SAAS;AACV,eACDC,iBAAiB,sBACd;AAML,OAAO,cAAMC,8BACXC,wBACA,GAAG,MAAM,kBAAkB,kBACxB","names":["createClient: (\n baseUrl: string,\n ontologyRid: string | Promise<string>,\n tokenProvider: () => Promise<string>,\n options?: {\n logger?: Logger;\n } | undefined,\n fetchFn?: typeof fetch | undefined,\n) => Client","baseUrl: string","ontologyRid: string | Promise<string>","tokenProvider: () => Promise<string>","options?: {\n logger?: Logger;\n } | undefined","fetchFn?: typeof fetch | undefined","createClientWithTransaction: (\n transactionRid: string,\n ...args: Parameters<typeof createClient>\n) => Client","transactionRid: string"],"sources":["../../src/createClient.ts"],"version":3,"file":"createClient.d.ts"}
|
package/build/types/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export type { ActionDefinition, ActionEditResponse, ActionMetadata, ActionParam, ActionReturnTypeForOptions, ActionValidationResponse, ApplyActionOptions, ApplyBatchActionOptions, Attachment, CompileTimeMetadata, InterfaceDefinition, Logger, ObjectMetadata, ObjectSet, ObjectSpecifier, ObjectTypeDefinition, Osdk, OsdkObject, OsdkObjectCreatePropertyType, OsdkObjectPropertyType, PageResult, PropertyDef, PropertyKeys, PropertyValueWireToClient, QueryDefinition, QueryParam, QueryResult, Range, Result, SingleLinkAccessor, ThreeDimensionalAggregation, TwoDimensionalAggregation, VersionBound, WhereClause } from "@osdk/api";
|
|
2
|
-
export { isOk
|
|
1
|
+
export type { ActionDefinition, ActionEditResponse, ActionMetadata, ActionParam, ActionReturnTypeForOptions, ActionValidationResponse, ApplyActionOptions, ApplyBatchActionOptions, Attachment, CompileTimeMetadata, InterfaceDefinition, InterfaceMetadata, Logger, ObjectMetadata, ObjectSet, ObjectSpecifier, ObjectTypeDefinition, Osdk, OsdkObject, OsdkObjectCreatePropertyType, OsdkObjectPropertyType, PageResult, PropertyDef, PropertyKeys, PropertyValueWireToClient, QueryDefinition, QueryParam, QueryResult, Range, Result, SingleLinkAccessor, ThreeDimensionalAggregation, TwoDimensionalAggregation, VersionBound, WhereClause } from "@osdk/api";
|
|
2
|
+
export { isOk } from "@osdk/api";
|
|
3
3
|
export { PalantirApiError } from "@osdk/shared.net.errors";
|
|
4
4
|
export { ActionValidationError } from "./actions/ActionValidationError.js";
|
|
5
5
|
export type { Client } from "./Client.js";
|
|
@@ -9,3 +9,4 @@ export type { PlatformClient } from "./createPlatformClient.js";
|
|
|
9
9
|
export { createAttachmentUpload } from "./object/AttachmentUpload.js";
|
|
10
10
|
export type { ResultOrError } from "./ResultOrError.js";
|
|
11
11
|
export { extractDate, extractDateInLocalTime, extractDateInUTC } from "./util/datetimeConverters.js";
|
|
12
|
+
export { createObjectSpecifierFromPrimaryKey } from "./util/objectSpecifierUtils.js";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":"AAgBA,cACE,kBACA,oBACA,gBACA,aACA,4BACA,0BACA,oBACA,yBACA,YACA,qBACA,qBACA,QACA,gBACA,WACA,iBACA,sBACA,MACA,YACA,8BACA,wBACA,YACA,aACA,cACA,2BACA,iBACA,YACA,aACA,OACA,QACA,oBACA,6BACA,2BACA,cACA,mBACK;AACP,SAAS,
|
|
1
|
+
{"mappings":"AAgBA,cACE,kBACA,oBACA,gBACA,aACA,4BACA,0BACA,oBACA,yBACA,YACA,qBACA,qBACA,mBACA,QACA,gBACA,WACA,iBACA,sBACA,MACA,YACA,8BACA,wBACA,YACA,aACA,cACA,2BACA,iBACA,YACA,aACA,OACA,QACA,oBACA,6BACA,2BACA,cACA,mBACK;AACP,SAAS,YAAY;AACrB,SAAS,wBAAwB;AAEjC,SAAS,6BAA6B;AACtC,cAAc,cAAc;AAC5B,SAAS,oBAAoB;AAC7B,SAAS,4BAA4B;AACrC,cAAc,sBAAsB;AACpC,SAAS,8BAA8B;AACvC,cAAc,qBAAqB;AAEnC,SACE,aACA,wBACA,wBACK;AAEP,SAAS,2CAA2C","names":[],"sources":["../../src/index.ts"],"version":3,"file":"index.d.ts"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":"AAgBA,cACE,SAMA,6BAEA,oBAEK,WAAY;
|
|
1
|
+
{"mappings":"AAgBA,cACE,SAMA,6BAEA,oBAEK,WAAY;AAkBnB,OAAO,iBAAS;CACd,UAAU;CACV,UAAU,aAAa;EAEvBA,MAAM,GACN,GAAG,YAAY,MACd,QAAQ,GAAG","names":["type: Q"],"sources":["../../../src/object/fetchPage.ts"],"version":3,"file":"fetchPage.d.ts"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":"AAgBA,cAAc,
|
|
1
|
+
{"mappings":"AAgBA,cAAc,sBAAsB,WAAY;AAEhD,OAAO,iBAAS,iBAAiBA,SAAS,KAAK","names":["o: any"],"sources":["../../../src/object/mediaUpload.ts"],"version":3,"file":"mediaUpload.d.ts"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":"AAgBA,cACE,kBACA,0BAEK,WAAY;
|
|
1
|
+
{"mappings":"AAgBA,cACE,kBACA,0BAEK,WAAY;AACnB,cAAc,8BAA8B,8BAA+B;AAI3E,cAAc,aAAa,YAAa;AAIxC,OAAO,cAAM,kBAAkB;;CACjB;CAAZ,YAAoBA,OAAO;CAE3B,cAAc,UAAU,uBACtBC,QAAQ,GACRC,MACI,WAAW,uBAAuB,GAAG,gBAAgB,KACrD,MAAM,WAAW,uBAAuB,GAAG,gBAAgB,KAC/DC,OAAO,MAAM,uBACV,QAAQ;AAkGd","names":["store: Store","action: Q","args:\n | Parameters<ActionSignatureFromDef<Q>[\"applyAction\"]>[0]\n | Array<Parameters<ActionSignatureFromDef<Q>[\"applyAction\"]>[0]>","opts?: Store.ApplyActionOptions"],"sources":["../../../../src/observable/internal/ActionApplication.ts"],"version":3,"file":"ActionApplication.d.ts"}
|
|
@@ -4,3 +4,4 @@ export { createObservableClient } from "../observable/ObservableClient.js";
|
|
|
4
4
|
export type { ObservableClient, ObserveObjectArgs, ObserveObjectsArgs, Observer, Unsubscribable } from "../observable/ObservableClient.js";
|
|
5
5
|
export type { OsdkConfig } from "../public-utils/osdkConfig.js";
|
|
6
6
|
export { getMetaTagContent, getOsdkConfig } from "../public-utils/osdkConfig.js";
|
|
7
|
+
export { createClientWithTransaction } from "../createClient.js";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":"AAgBA,SAAS,eAAe;AAGxB,cAAc,8BAA8B;AAC5C,SAAS,8BAA8B;AACvC,cACE,kBACA,mBACA,oBACA,UACA,sBACK;AACP,cAAc,kBAAkB;AAChC,SACE,mBACA,qBACK","names":[],"sources":["../../../src/public/unstable-do-not-use.ts"],"version":3,"file":"unstable-do-not-use.d.ts"}
|
|
1
|
+
{"mappings":"AAgBA,SAAS,eAAe;AAGxB,cAAc,8BAA8B;AAC5C,SAAS,8BAA8B;AACvC,cACE,kBACA,mBACA,oBACA,UACA,sBACK;AACP,cAAc,kBAAkB;AAChC,SACE,mBACA,qBACK;AAEP,SAAS,mCAAmC","names":[],"sources":["../../../src/public/unstable-do-not-use.ts"],"version":3,"file":"unstable-do-not-use.d.ts"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { CompileTimeMetadata, ObjectTypeDefinition, OsdkBase, PrimaryKeyType, QueryDefinition } from "@osdk/api";
|
|
1
|
+
import type { CompileTimeMetadata, InterfaceDefinition, ObjectTypeDefinition, OsdkBase, PrimaryKeyType, QueryDefinition } from "@osdk/api";
|
|
2
2
|
import type { MinimalClient } from "../MinimalClientContext.js";
|
|
3
3
|
import type { QueryParameterType, QueryReturnType } from "./types.js";
|
|
4
4
|
export declare function applyQuery<
|
|
@@ -6,3 +6,7 @@ export declare function applyQuery<
|
|
|
6
6
|
P extends QueryParameterType<CompileTimeMetadata<QD>["parameters"]>
|
|
7
7
|
>(client: MinimalClient, query: QD, params?: P): Promise<QueryReturnType<CompileTimeMetadata<QD>["output"]>>;
|
|
8
8
|
export declare function createQueryObjectResponse<Q extends ObjectTypeDefinition>(primaryKey: PrimaryKeyType<Q>, objectDef: Q): OsdkBase<Q>;
|
|
9
|
+
export declare function createQueryInterfaceResponse<Q extends InterfaceDefinition>(interfaceSpecifier: {
|
|
10
|
+
objectTypeApiName: string
|
|
11
|
+
primaryKeyValue: PrimaryKeyType<Q>
|
|
12
|
+
}, interfaceDef: Q): OsdkBase<Q>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":"AAgBA,cAGE,qBAEA,sBACA,UACA,gBAEA,uBAEK,WAAY;AAInB,cAAc,qBAAqB,4BAA6B;
|
|
1
|
+
{"mappings":"AAgBA,cAGE,qBACA,qBAEA,sBACA,UACA,gBAEA,uBAEK,WAAY;AAInB,cAAc,qBAAqB,4BAA6B;AAUhE,cAAc,oBAAoB,uBAAuB,YAAa;AAEtE,OAAO,iBAAe;CACpB,WAAW;CACX,UAAU,mBAAmB,oBAAoB,IAAI;EAErDA,QAAQ,eACRC,OAAO,IACPC,SAAS,IACR,QACD,gBAAgB,oBAAoB,IAAI;AA+W1C,OAAO,iBAAS,0BACd,UAAU,sBAEVC,YAAY,eAAe,IAC3BC,WAAW,IACV,SAAS;AAaZ,OAAO,iBAAS,6BACd,UAAU,qBAEVC,oBAAoB;CAClB;CACA,iBAAiB,eAAe;AACjC,GACDC,cAAc,IACb,SAAS","names":["client: MinimalClient","query: QD","params?: P","primaryKey: PrimaryKeyType<Q>","objectDef: Q","interfaceSpecifier: {\n objectTypeApiName: string;\n primaryKeyValue: PrimaryKeyType<Q>;\n }","interfaceDef: Q"],"sources":["../../../src/queries/applyQuery.ts"],"version":3,"file":"applyQuery.d.ts"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { CompileTimeMetadata, DataValueClientToWire, DataValueWireToClient, ObjectQueryDataType, ObjectSetQueryDataType, QueryDataTypeDefinition, QueryDefinition, QueryParam, QueryResult } from "@osdk/api";
|
|
1
|
+
import type { CompileTimeMetadata, DataValueClientToWire, DataValueWireToClient, InterfaceQueryDataType, ObjectQueryDataType, ObjectSetQueryDataType, QueryDataTypeDefinition, QueryDefinition, QueryParam, QueryResult } from "@osdk/api";
|
|
2
2
|
import type { PartialByNotStrict } from "../util/partialBy.js";
|
|
3
3
|
export type QuerySignatureFromDef<T extends QueryDefinition<any>> = {
|
|
4
4
|
executeFunction: CompileTimeMetadata<T> extends never ? QuerySignature<T> : CompileTimeMetadata<T>["signature"]
|
|
@@ -11,5 +11,5 @@ type OptionalQueryParams<T extends Record<any, QueryDataTypeDefinition>> = { [K
|
|
|
11
11
|
} ? never : K }[keyof T];
|
|
12
12
|
type NotOptionalParams<T extends Record<any, QueryDataTypeDefinition>> = { [K in keyof T] : MaybeArrayType<T[K]> };
|
|
13
13
|
type MaybeArrayType<T extends QueryDataTypeDefinition> = T["multiplicity"] extends true ? ReadonlyArray<QueryBaseType<T>> : QueryBaseType<T>;
|
|
14
|
-
type QueryBaseType<T extends QueryDataTypeDefinition> = T extends ObjectQueryDataType<infer TTargetType> ? QueryParam.ObjectType<TTargetType> : T extends ObjectSetQueryDataType<infer TTargetType> ? QueryParam.ObjectSetType<TTargetType> : T["type"] extends keyof DataValueClientToWire ? QueryParam.PrimitiveType<T["type"]> : never;
|
|
14
|
+
type QueryBaseType<T extends QueryDataTypeDefinition> = T extends ObjectQueryDataType<infer TTargetType> ? QueryParam.ObjectType<TTargetType> : T extends InterfaceQueryDataType<infer TTargetType> ? QueryParam.ObjectType<TTargetType> : T extends ObjectSetQueryDataType<infer TTargetType> ? QueryParam.ObjectSetType<TTargetType> : T["type"] extends keyof DataValueClientToWire ? QueryParam.PrimitiveType<T["type"]> : never;
|
|
15
15
|
export {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":"AAgBA,cACE,qBACA,uBACA,uBACA,qBACA,wBACA,yBACA,iBACA,YACA,mBACK,WAAY;AACnB,cAAc,0BAA0B,sBAAuB;AAE/D,YAAY,sBAAsB,UAAU,wBAAwB;CAClE,iBAAiB,oBAAoB,mBAAmB,eAAe,KACnE,oBAAoB,GAAG;AAC5B;AAED,YAAY,eAAe,UAAU,8BAC7B,oBAAoB,GAAG,oCACnB,QAAQ,gBAAgB,oBAAoB,GAAG,eAErDA,QAAQ,mBAAmB,oBAAoB,GAAG,mBAC/C,QAAQ,gBAAgB,oBAAoB,GAAG;AAExD,YAAY,mBACV,UAAU,YAAY,4BACpB,mBAAmB,kBAAkB,IAAI,oBAAoB;AAEjE,YAAY,gBAAgB,UAAU,2BAA2B,UAC/D,0BAA0B,eAAe,YAAY,WAAW,eAC9D,UAAU,6BAA6B,eACrC,YAAY,cAAc,eAC5B,EAAE,sBAAsB,wBACtB,YAAY,cAAc,EAAE;KAG7B,oBACH,UAAU,YAAY,+BAErB,WAAW,KAAI,EAAE,WAAW;CAAE,UAAU;AAAM,YAAW,UACpD;KAEH,kBACH,UAAU,YAAY,+BAErB,WAAW,KAAI,eAAe,EAAE;KAG9B,eAAe,UAAU,2BAC5B,EAAE,wBAAwB,OAAO,cAAc,cAAc,MACzD,cAAc;KAEf,cAAc,UAAU,2BAA2B,UACtD,0BAA0B,eAAe,WAAW,WAAW,eAC7D,UAAU,6BAA6B,eACrC,WAAW,cAAc,eAC3B,EAAE,sBAAsB,wBACtB,WAAW,cAAc,EAAE","names":["params: QueryParameterType<CompileTimeMetadata<T>[\"parameters\"]>"],"sources":["../../../src/queries/types.ts"],"version":3,"file":"types.d.ts"}
|
|
1
|
+
{"mappings":"AAgBA,cACE,qBACA,uBACA,uBACA,wBACA,qBACA,wBACA,yBACA,iBACA,YACA,mBACK,WAAY;AACnB,cAAc,0BAA0B,sBAAuB;AAE/D,YAAY,sBAAsB,UAAU,wBAAwB;CAClE,iBAAiB,oBAAoB,mBAAmB,eAAe,KACnE,oBAAoB,GAAG;AAC5B;AAED,YAAY,eAAe,UAAU,8BAC7B,oBAAoB,GAAG,oCACnB,QAAQ,gBAAgB,oBAAoB,GAAG,eAErDA,QAAQ,mBAAmB,oBAAoB,GAAG,mBAC/C,QAAQ,gBAAgB,oBAAoB,GAAG;AAExD,YAAY,mBACV,UAAU,YAAY,4BACpB,mBAAmB,kBAAkB,IAAI,oBAAoB;AAEjE,YAAY,gBAAgB,UAAU,2BAA2B,UAC/D,0BAA0B,eAAe,YAAY,WAAW,eAC9D,UAAU,6BAA6B,eACrC,YAAY,cAAc,eAC5B,EAAE,sBAAsB,wBACtB,YAAY,cAAc,EAAE;KAG7B,oBACH,UAAU,YAAY,+BAErB,WAAW,KAAI,EAAE,WAAW;CAAE,UAAU;AAAM,YAAW,UACpD;KAEH,kBACH,UAAU,YAAY,+BAErB,WAAW,KAAI,eAAe,EAAE;KAG9B,eAAe,UAAU,2BAC5B,EAAE,wBAAwB,OAAO,cAAc,cAAc,MACzD,cAAc;KAEf,cAAc,UAAU,2BAA2B,UACtD,0BAA0B,eAAe,WAAW,WAAW,eAC7D,UAAU,6BAA6B,eACrC,WAAW,WAAW,eACxB,UAAU,6BAA6B,eACrC,WAAW,cAAc,eAC3B,EAAE,sBAAsB,wBACtB,WAAW,cAAc,EAAE","names":["params: QueryParameterType<CompileTimeMetadata<T>[\"parameters\"]>"],"sources":["../../../src/queries/types.ts"],"version":3,"file":"types.d.ts"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"mappings":"","names":[],"sources":["../../../src/util/extractObjectOrInterfaceType.ts"],"version":3,"file":"extractObjectOrInterfaceType.d.ts"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"mappings":"","names":[],"sources":["../../../src/util/extractObjectOrInterfaceType.test.ts"],"version":3,"file":"extractObjectOrInterfaceType.test.d.ts"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { ObjectSpecifier, ObjectTypeDefinition, PrimaryKeyType } from "@osdk/api";
|
|
1
|
+
import type { InterfaceDefinition, ObjectSpecifier, ObjectTypeDefinition, PrimaryKeyType } from "@osdk/api";
|
|
2
2
|
/**
|
|
3
3
|
* Creates an Object Specifier. An ObjectSpecifier is a string that uniquely identifies an object in the system,
|
|
4
4
|
* even when loading an interface object where primary key uniqueness is not guaranteed.
|
|
@@ -9,6 +9,18 @@ import type { ObjectSpecifier, ObjectTypeDefinition, PrimaryKeyType } from "@osd
|
|
|
9
9
|
*/
|
|
10
10
|
export declare function createObjectSpecifierFromPrimaryKey<Q extends ObjectTypeDefinition>(objectDef: Q, primaryKey: PrimaryKeyType<Q>): ObjectSpecifier<Q>;
|
|
11
11
|
/**
|
|
12
|
+
* Creates an Object Specifier. An ObjectSpecifier is a string that uniquely identifies an object in the system,
|
|
13
|
+
* even when loading an interface object where primary key uniqueness is not guaranteed.
|
|
14
|
+
*
|
|
15
|
+
* @param objectDef - An Object Type Definition
|
|
16
|
+
* @param primaryKey - The value you want to use as the primary key
|
|
17
|
+
* @returns An Object Specifier
|
|
18
|
+
*/
|
|
19
|
+
export declare function createObjectSpecifierFromInterfaceSpecifier<Q extends InterfaceDefinition>(interfaceDef: Q, interfaceSpecifier: {
|
|
20
|
+
objectTypeApiName: string
|
|
21
|
+
primaryKeyValue: PrimaryKeyType<Q>
|
|
22
|
+
}): ObjectSpecifier<Q>;
|
|
23
|
+
/**
|
|
12
24
|
* Extracts the primary key from an ObjectSpecifier on an OSDK object.
|
|
13
25
|
*
|
|
14
26
|
* @param ObjectSpecifier
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":"AAgBA,cACE,iBACA,sBACA,sBACK,WAAY;;;;;;;;;AAUnB,OAAO,iBAAS,oCACd,UAAU,sBACVA,WAAW,GAAGC,YAAY,eAAe,KAAK,gBAAgB;;;;;;;
|
|
1
|
+
{"mappings":"AAgBA,cACE,qBACA,iBACA,sBACA,sBACK,WAAY;;;;;;;;;AAUnB,OAAO,iBAAS,oCACd,UAAU,sBACVA,WAAW,GAAGC,YAAY,eAAe,KAAK,gBAAgB;;;;;;;;;AAYhE,OAAO,iBAAS,4CACd,UAAU,qBAEVC,cAAc,GACdC,oBAAoB;CAClB;CACA,iBAAiB,eAAe;AACjC,IACA,gBAAgB;;;;;;;AAYnB,OAAO,iBAAS,qCACdC,iBAAiB;;;;;;;AAWnB,OAAO,iBAAS,qCACdA,iBAAiB","names":["objectDef: Q","primaryKey: PrimaryKeyType<Q>","interfaceDef: Q","interfaceSpecifier: {\n objectTypeApiName: string;\n primaryKeyValue: PrimaryKeyType<Q>;\n }","ObjectSpecifier: ObjectSpecifier<any>"],"sources":["../../../src/util/objectSpecifierUtils.ts"],"version":3,"file":"objectSpecifierUtils.d.ts"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@osdk/client",
|
|
3
|
-
"version": "2.4.0
|
|
3
|
+
"version": "2.4.0",
|
|
4
4
|
"description": "",
|
|
5
5
|
"access": "public",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -65,12 +65,12 @@
|
|
|
65
65
|
"tiny-invariant": "^1.3.1",
|
|
66
66
|
"type-fest": "^4.18.2",
|
|
67
67
|
"ws": "^8.18.0",
|
|
68
|
-
"@osdk/
|
|
69
|
-
"@osdk/
|
|
70
|
-
"@osdk/
|
|
71
|
-
"@osdk/shared.client.impl": "~1.4.0
|
|
72
|
-
"@osdk/shared.net.
|
|
73
|
-
"@osdk/shared.net.
|
|
68
|
+
"@osdk/generator-converters": "2.4.0",
|
|
69
|
+
"@osdk/api": "~2.4.0",
|
|
70
|
+
"@osdk/client.unstable": "2.4.0",
|
|
71
|
+
"@osdk/shared.client.impl": "~1.4.0",
|
|
72
|
+
"@osdk/shared.net.errors": "~2.4.0",
|
|
73
|
+
"@osdk/shared.net.fetch": "~1.4.0"
|
|
74
74
|
},
|
|
75
75
|
"devDependencies": {
|
|
76
76
|
"@microsoft/api-documenter": "^7.26.5",
|
|
@@ -91,10 +91,10 @@
|
|
|
91
91
|
"ts-expect": "^1.3.0",
|
|
92
92
|
"typescript": "~5.5.4",
|
|
93
93
|
"zod": "^3.23.8",
|
|
94
|
-
"@osdk/client.test.ontology": "~2.4.0
|
|
95
|
-
"@osdk/
|
|
96
|
-
"@osdk/monorepo.tsconfig": "~0.3.0
|
|
97
|
-
"@osdk/
|
|
94
|
+
"@osdk/client.test.ontology": "~2.4.0",
|
|
95
|
+
"@osdk/monorepo.api-extractor": "~0.3.0",
|
|
96
|
+
"@osdk/monorepo.tsconfig": "~0.3.0",
|
|
97
|
+
"@osdk/shared.test": "~2.4.0"
|
|
98
98
|
},
|
|
99
99
|
"publishConfig": {
|
|
100
100
|
"access": "public"
|