@osdk/generator 1.12.0 → 1.12.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/CHANGELOG.md +7 -0
- package/build/browser/index.js +6 -5
- package/build/browser/index.js.map +1 -1
- package/build/cjs/index.cjs +6 -5
- package/build/cjs/index.cjs.map +1 -1
- package/build/cjs/shared/UNSTABLE_wireInterfaceTypeV2ToSdkObjectConst.d.cts +1 -4
- package/build/cjs/shared/UNSTABLE_wireInterfaceTypeV2ToSdkObjectConst.d.ts.map +1 -1
- package/build/cjs/shared/generatePerActionDataFiles.d.ts.map +1 -1
- package/build/cjs/shared/sanitizeMetadata.d.cts +1 -9
- package/build/cjs/shared/sanitizeMetadata.d.ts.map +1 -1
- package/build/cjs/shared/wireObjectTypeV2ToSdkObjectConst.d.cts +0 -3
- package/build/cjs/shared/wireObjectTypeV2ToSdkObjectConst.d.ts.map +1 -1
- package/build/esm/index.js +6 -5
- package/build/esm/index.js.map +1 -1
- package/build/esm/shared/UNSTABLE_wireInterfaceTypeV2ToSdkObjectConst.d.ts +1 -4
- package/build/esm/shared/UNSTABLE_wireInterfaceTypeV2ToSdkObjectConst.d.ts.map +1 -1
- package/build/esm/shared/generatePerActionDataFiles.d.ts.map +1 -1
- package/build/esm/shared/sanitizeMetadata.d.ts +1 -9
- package/build/esm/shared/sanitizeMetadata.d.ts.map +1 -1
- package/build/esm/shared/wireObjectTypeV2ToSdkObjectConst.d.ts +0 -3
- package/build/esm/shared/wireObjectTypeV2ToSdkObjectConst.d.ts.map +1 -1
- package/package.json +4 -4
package/CHANGELOG.md
CHANGED
package/build/browser/index.js
CHANGED
|
@@ -55,7 +55,7 @@ function isReservedKeyword(name) {
|
|
|
55
55
|
// src/v1.1/wireObjectTypeV2ToV1ObjectInterfaceString.ts
|
|
56
56
|
function wireObjectTypeV2ToObjectInterfaceStringV1(objectTypeWithLinks, importExt = "") {
|
|
57
57
|
const uniqueLinkTargets = new Set(objectTypeWithLinks.linkTypes.map((a) => a.objectTypeApiName).filter((a) => a !== objectTypeWithLinks.objectType.apiName));
|
|
58
|
-
return `import type { OntologyObject, LocalDate, Timestamp, GeoShape, GeoPoint, Attachment, TimeSeries, MultiLink, SingleLink } from "@osdk/legacy-client";
|
|
58
|
+
return `import type { OntologyObject, LocalDate, Timestamp, GeoShape, GeoPoint, Attachment, TimeSeries, MultiLink, SingleLink, StringLong } from "@osdk/legacy-client";
|
|
59
59
|
${Array.from(uniqueLinkTargets).map((linkTarget) => `import type { ${linkTarget} } from "./${linkTarget}${importExt}";`).join("\n")}
|
|
60
60
|
|
|
61
61
|
${getDescriptionIfPresent(objectTypeWithLinks.objectType.description)}
|
|
@@ -111,7 +111,7 @@ function wirePropertyTypeV2ToTypeScriptType(property) {
|
|
|
111
111
|
case "geoshape":
|
|
112
112
|
return "GeoShape";
|
|
113
113
|
case "long":
|
|
114
|
-
return "
|
|
114
|
+
return "StringLong";
|
|
115
115
|
case "short":
|
|
116
116
|
return "number";
|
|
117
117
|
case "timestamp":
|
|
@@ -378,7 +378,7 @@ async function generatePerActionDataFiles(ontology, fs2, outDir, importExt, v2)
|
|
|
378
378
|
|
|
379
379
|
|
|
380
380
|
// Represents the definition of the action
|
|
381
|
-
export interface ${actionDefIdentifier} extends ActionDefinition<"${action.apiName}", ${uniqueApiNamesString}, ${action.apiName}>{
|
|
381
|
+
export interface ${actionDefIdentifier} extends ActionDefinition<"${action.apiName}", ${uniqueApiNamesString}, ${action.apiName}>, VersionBound<$ExpectedClientVersion> {
|
|
382
382
|
${Object.entries(actionDefSansParameters).sort((a, b) => a[0].localeCompare(b[0])).map(([key, value]) => {
|
|
383
383
|
return `${key}: ${JSON.stringify(value)};`;
|
|
384
384
|
}).join("\n")}
|
|
@@ -410,9 +410,10 @@ async function generatePerActionDataFiles(ontology, fs2, outDir, importExt, v2)
|
|
|
410
410
|
}
|
|
411
411
|
const importObjects = referencedObjectDefs.size > 0 ? `import type {${[...referencedObjectDefs].join(",")}} from "../objects${importExt}";` : "";
|
|
412
412
|
await fs2.writeFile(path16__default.join(outDir, `${action.apiName}.ts`), await formatTs(`
|
|
413
|
-
import type { ActionDefinition, ObjectActionDataType, ObjectSetActionDataType } from "@osdk/api";
|
|
413
|
+
import type { ActionDefinition, ObjectActionDataType, ObjectSetActionDataType, VersionBound} from "@osdk/api";
|
|
414
414
|
import type { ActionSignature, ApplyActionOptions, ApplyBatchActionOptions, OsdkActionParameters,ActionReturnTypeForOptions, NOOP } from '@osdk/client.api';
|
|
415
415
|
import { $osdkMetadata} from "../../OntologyMetadata${importExt}";
|
|
416
|
+
import type { $ExpectedClientVersion } from "../../OntologyMetadata${importExt}";
|
|
416
417
|
${importObjects}
|
|
417
418
|
|
|
418
419
|
|
|
@@ -2028,5 +2029,5 @@ async function writeJson(minimalFs, filePath, body) {
|
|
|
2028
2029
|
}
|
|
2029
2030
|
|
|
2030
2031
|
export { generateClientSdkPackage as __UNSTABLE_generateClientSdkPackage, generateClientSdkVersionOneDotOne, generateClientSdkVersionTwoPointZero, getExpectedDependencies };
|
|
2031
|
-
//# sourceMappingURL=
|
|
2032
|
+
//# sourceMappingURL=index.js.map
|
|
2032
2033
|
//# sourceMappingURL=index.js.map
|