@osdk/react-sdk-docs 0.3.0 → 0.3.1-main-aa78c78b2364b0ff1fa351531cab0e85efdcc1c5
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 +6 -0
- package/build/browser/docs.js +1 -1
- package/build/browser/docs.js.map +1 -1
- package/build/cjs/index.cjs +1 -1
- package/build/cjs/index.cjs.map +1 -1
- package/build/esm/docs.js +1 -1
- package/build/esm/docs.js.map +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
# @osdk/react-sdk-docs
|
|
2
2
|
|
|
3
|
+
## 0.3.1-main-aa78c78b2364b0ff1fa351531cab0e85efdcc1c5
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- f522327: Render the object-action-parameter alternative hint as a block comment so the trailing comma the template appends after non-last entries isn't swallowed by a line comment
|
|
8
|
+
|
|
3
9
|
## 0.3.0
|
|
4
10
|
|
|
5
11
|
### Minor Changes
|
package/build/browser/docs.js
CHANGED
|
@@ -103,7 +103,7 @@ function renderType(type) {
|
|
|
103
103
|
return `"${offsetDate.toISOString()}"`;
|
|
104
104
|
}
|
|
105
105
|
case "object":
|
|
106
|
-
return `"primaryKeyValue"
|
|
106
|
+
return `"primaryKeyValue" /* or myObjectInstance */`;
|
|
107
107
|
case "objectSet":
|
|
108
108
|
return `client(${type.objectTypeApiName}).where({ /* filter conditions */ })`;
|
|
109
109
|
case "anonymousCustomType":
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"docs.js","names":["snippets","REACT_OSDK_SNIPPETS","computedVariables","actionParameterSampleValuesV2","handleActionParameterSampleValuesV2","propertyValueV2","handlePropertyValueV2","primaryKeyPropertyV2","handlePrimaryKeyPropertyV2","linkedPrimaryKeyPropertyV2","handleLinkedPrimaryKeyPropertyV2","rawActionTypeParameterValues","Error","map","param","index","array","key","value","renderType","last","length","rawPropertyValue","renderPropertyValue","rawPrimaryKeyProperty","apiName","rawLinkedPrimaryKeyProperty","type","propertyValue","subtype","toString","offsetDate","Date","setDate","getDate","daysOffset","toISOString","slice","objectTypeApiName","entries","Object","parameters","rendered","name","join","hasAttachments","valueType"],"sources":["docs.ts"],"sourcesContent":["/*\n * Copyright 2026 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 { SdkSnippets } from \"@osdk/docs-spec-core\";\nimport type {\n ActionParameterSampleValuesIR,\n ActionParameterSampleValueTypeIR,\n FunctionSampleValueTypeIR,\n OSDK_SNIPPETS_SPEC,\n PropertySampleIR,\n PropertySampleValueTypeIR,\n} from \"@osdk/docs-spec-sdk\";\nimport { snippets } from \"./generatedNoCheck/docsNoComputedVariables.js\";\n\nexport const REACT_OSDK_SNIPPETS: SdkSnippets<typeof OSDK_SNIPPETS_SPEC> = {\n ...snippets,\n computedVariables: {\n actionParameterSampleValuesV2: handleActionParameterSampleValuesV2,\n propertyValueV2: handlePropertyValueV2,\n primaryKeyPropertyV2: handlePrimaryKeyPropertyV2,\n linkedPrimaryKeyPropertyV2: handleLinkedPrimaryKeyPropertyV2,\n },\n};\n\nfunction handleActionParameterSampleValuesV2({\n rawActionTypeParameterValues,\n}: {\n rawActionTypeParameterValues?: ActionParameterSampleValuesIR;\n}): Array<{ key: string; value: string; last: boolean }> {\n if (rawActionTypeParameterValues == null) {\n throw new Error(\"Cannot render a null rawActionTypeParameterValues\");\n }\n\n return rawActionTypeParameterValues.map((param, index, array) => ({\n key: param.key,\n value: renderType(param.value),\n last: index === array.length - 1,\n }));\n}\n\nfunction handlePropertyValueV2({\n rawPropertyValue,\n}: {\n rawPropertyValue?: PropertySampleValueTypeIR;\n}): string {\n return renderPropertyValue(rawPropertyValue);\n}\n\nfunction handlePrimaryKeyPropertyV2({\n rawPrimaryKeyProperty,\n}: {\n rawPrimaryKeyProperty?: PropertySampleIR;\n}): { apiName: string; value: string } {\n if (rawPrimaryKeyProperty == null) {\n throw new Error(\"Cannot render with null rawPrimaryKeyProperty\");\n }\n\n return {\n apiName: rawPrimaryKeyProperty.apiName,\n value: renderPropertyValue(rawPrimaryKeyProperty.value),\n };\n}\n\nfunction handleLinkedPrimaryKeyPropertyV2({\n rawLinkedPrimaryKeyProperty,\n}: {\n rawLinkedPrimaryKeyProperty?: {\n apiName: string;\n value: PropertySampleValueTypeIR;\n type: string;\n };\n}): { apiName: string; value: string; type: string } {\n if (rawLinkedPrimaryKeyProperty == null) {\n throw new Error(\"Cannot render with null rawLinkedPrimaryKeyProperty\");\n }\n\n return {\n apiName: rawLinkedPrimaryKeyProperty.apiName,\n value: renderPropertyValue(rawLinkedPrimaryKeyProperty.value),\n type: rawLinkedPrimaryKeyProperty.type,\n };\n}\n\nfunction renderPropertyValue(\n propertyValue: PropertySampleValueTypeIR | undefined,\n): string {\n if (propertyValue == null) {\n throw new Error(\"Cannot render a null property value\");\n }\n\n return renderType(propertyValue);\n}\n\nfunction renderType(\n type:\n | ActionParameterSampleValueTypeIR\n | FunctionSampleValueTypeIR\n | PropertySampleValueTypeIR,\n): string {\n if (type == null) {\n throw new Error(\"Cannot render a null type value\");\n }\n\n switch (type.type) {\n case \"array\":\n case \"set\":\n case \"list\":\n return `[${renderType(type.subtype)}]`;\n case \"boolean\":\n return type.value ? \"true\" : \"false\";\n case \"byte\":\n case \"integer\":\n case \"long\":\n case \"short\":\n return type.value.toString();\n case \"decimal\":\n case \"double\":\n case \"float\":\n return type.value.toString();\n case \"date\": {\n const offsetDate = new Date();\n offsetDate.setDate(offsetDate.getDate() + (type.daysOffset ?? 0));\n return `\"${offsetDate.toISOString().slice(0, 10)}\"`;\n }\n case \"timestamp\": {\n const offsetDate = new Date();\n offsetDate.setDate(offsetDate.getDate() + (type.daysOffset ?? 0));\n return `\"${offsetDate.toISOString()}\"`;\n }\n case \"object\":\n return `\"primaryKeyValue\"
|
|
1
|
+
{"version":3,"file":"docs.js","names":["snippets","REACT_OSDK_SNIPPETS","computedVariables","actionParameterSampleValuesV2","handleActionParameterSampleValuesV2","propertyValueV2","handlePropertyValueV2","primaryKeyPropertyV2","handlePrimaryKeyPropertyV2","linkedPrimaryKeyPropertyV2","handleLinkedPrimaryKeyPropertyV2","rawActionTypeParameterValues","Error","map","param","index","array","key","value","renderType","last","length","rawPropertyValue","renderPropertyValue","rawPrimaryKeyProperty","apiName","rawLinkedPrimaryKeyProperty","type","propertyValue","subtype","toString","offsetDate","Date","setDate","getDate","daysOffset","toISOString","slice","objectTypeApiName","entries","Object","parameters","rendered","name","join","hasAttachments","valueType"],"sources":["docs.ts"],"sourcesContent":["/*\n * Copyright 2026 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 { SdkSnippets } from \"@osdk/docs-spec-core\";\nimport type {\n ActionParameterSampleValuesIR,\n ActionParameterSampleValueTypeIR,\n FunctionSampleValueTypeIR,\n OSDK_SNIPPETS_SPEC,\n PropertySampleIR,\n PropertySampleValueTypeIR,\n} from \"@osdk/docs-spec-sdk\";\nimport { snippets } from \"./generatedNoCheck/docsNoComputedVariables.js\";\n\nexport const REACT_OSDK_SNIPPETS: SdkSnippets<typeof OSDK_SNIPPETS_SPEC> = {\n ...snippets,\n computedVariables: {\n actionParameterSampleValuesV2: handleActionParameterSampleValuesV2,\n propertyValueV2: handlePropertyValueV2,\n primaryKeyPropertyV2: handlePrimaryKeyPropertyV2,\n linkedPrimaryKeyPropertyV2: handleLinkedPrimaryKeyPropertyV2,\n },\n};\n\nfunction handleActionParameterSampleValuesV2({\n rawActionTypeParameterValues,\n}: {\n rawActionTypeParameterValues?: ActionParameterSampleValuesIR;\n}): Array<{ key: string; value: string; last: boolean }> {\n if (rawActionTypeParameterValues == null) {\n throw new Error(\"Cannot render a null rawActionTypeParameterValues\");\n }\n\n return rawActionTypeParameterValues.map((param, index, array) => ({\n key: param.key,\n value: renderType(param.value),\n last: index === array.length - 1,\n }));\n}\n\nfunction handlePropertyValueV2({\n rawPropertyValue,\n}: {\n rawPropertyValue?: PropertySampleValueTypeIR;\n}): string {\n return renderPropertyValue(rawPropertyValue);\n}\n\nfunction handlePrimaryKeyPropertyV2({\n rawPrimaryKeyProperty,\n}: {\n rawPrimaryKeyProperty?: PropertySampleIR;\n}): { apiName: string; value: string } {\n if (rawPrimaryKeyProperty == null) {\n throw new Error(\"Cannot render with null rawPrimaryKeyProperty\");\n }\n\n return {\n apiName: rawPrimaryKeyProperty.apiName,\n value: renderPropertyValue(rawPrimaryKeyProperty.value),\n };\n}\n\nfunction handleLinkedPrimaryKeyPropertyV2({\n rawLinkedPrimaryKeyProperty,\n}: {\n rawLinkedPrimaryKeyProperty?: {\n apiName: string;\n value: PropertySampleValueTypeIR;\n type: string;\n };\n}): { apiName: string; value: string; type: string } {\n if (rawLinkedPrimaryKeyProperty == null) {\n throw new Error(\"Cannot render with null rawLinkedPrimaryKeyProperty\");\n }\n\n return {\n apiName: rawLinkedPrimaryKeyProperty.apiName,\n value: renderPropertyValue(rawLinkedPrimaryKeyProperty.value),\n type: rawLinkedPrimaryKeyProperty.type,\n };\n}\n\nfunction renderPropertyValue(\n propertyValue: PropertySampleValueTypeIR | undefined,\n): string {\n if (propertyValue == null) {\n throw new Error(\"Cannot render a null property value\");\n }\n\n return renderType(propertyValue);\n}\n\nfunction renderType(\n type:\n | ActionParameterSampleValueTypeIR\n | FunctionSampleValueTypeIR\n | PropertySampleValueTypeIR,\n): string {\n if (type == null) {\n throw new Error(\"Cannot render a null type value\");\n }\n\n switch (type.type) {\n case \"array\":\n case \"set\":\n case \"list\":\n return `[${renderType(type.subtype)}]`;\n case \"boolean\":\n return type.value ? \"true\" : \"false\";\n case \"byte\":\n case \"integer\":\n case \"long\":\n case \"short\":\n return type.value.toString();\n case \"decimal\":\n case \"double\":\n case \"float\":\n return type.value.toString();\n case \"date\": {\n const offsetDate = new Date();\n offsetDate.setDate(offsetDate.getDate() + (type.daysOffset ?? 0));\n return `\"${offsetDate.toISOString().slice(0, 10)}\"`;\n }\n case \"timestamp\": {\n const offsetDate = new Date();\n offsetDate.setDate(offsetDate.getDate() + (type.daysOffset ?? 0));\n return `\"${offsetDate.toISOString()}\"`;\n }\n case \"object\":\n return `\"primaryKeyValue\" /* or myObjectInstance */`;\n case \"objectSet\":\n return `client(${type.objectTypeApiName}).where({ /* filter conditions */ })`;\n case \"anonymousCustomType\":\n case \"customType\": {\n const entries = Object.entries(type.parameters ?? {});\n if (entries.length > 0) {\n const rendered = entries\n .map(([name, value]) => `\"${name}\": ${renderType(value)}`)\n .join(\", \");\n return `{ ${rendered} }`;\n }\n return \"{}\";\n }\n case \"interface\":\n case \"marking\":\n return \"{}\";\n case \"attachment\":\n return type.hasAttachments ? \"attachment\" : \"{}\";\n case \"mediaReference\":\n return \"mediaUpload\";\n case \"objectType\":\n return `\"${type.objectTypeApiName}\"`;\n case \"map\":\n return `{key: ${renderType(type.valueType)}}`;\n case \"string\":\n return `\"${type.value ?? \"value\"}\"`;\n case \"unknown\":\n default:\n return `\"value\"`;\n }\n}\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAWA,SAASA,QAAQ,QAAQ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CAACF,UAAU,CAACG,OAAO,CAAC,CAAC,IAAIP,IAAI,CAACQ,UAAU,IAAI,CAAC,CAAC,CAAC;QACjE,OAAO,IAAIJ,UAAU,CAACK,WAAW,CAAC,CAAC,GAAG;MACxC;IACA,KAAK,QAAQ;MACX,OAAO,6CAA6C;IACtD,KAAK,WAAW;MACd,OAAO,UAAUT,IAAI,CAACW,iBAAiB,sCAAsC;IAC/E,KAAK,qBAAqB;IAC1B,KAAK,YAAY;MAAE;QACjB,MAAMC,OAAO,GAAGC,MAAM,CAACD,OAAO,CAACZ,IAAI,CAACc,UAAU,IAAI,CAAC,CAAC,CAAC;QACrD,IAAIF,OAAO,CAAClB,MAAM,GAAG,CAAC,EAAE;UACtB,MAAMqB,QAAQ,GAAGH,OAAO,CACrB1B,GAAG,CAAC,CAAC,CAAC8B,IAAI,EAAEzB,KAAK,CAAC,KAAK,IAAIyB,IAAI,MAAMxB,UAAU,CAACD,KAAK,CAAC,EAAE,CAAC,CACzD0B,IAAI,CAAC,IAAI,CAAC;UACb,OAAO,KAAKF,QAAQ,IAAI;QAC1B;QACA,OAAO,IAAI;MACb;IACA,KAAK,WAAW;IAChB,KAAK,SAAS;MACZ,OAAO,IAAI;IACb,KAAK,YAAY;MACf,OAAOf,IAAI,CAACkB,cAAc,GAAG,YAAY,GAAG,IAAI;IAClD,KAAK,gBAAgB;MACnB,OAAO,aAAa;IACtB,KAAK,YAAY;MACf,OAAO,IAAIlB,IAAI,CAACW,iBAAiB,GAAG;IACtC,KAAK,KAAK;MACR,OAAO,SAASnB,UAAU,CAACQ,IAAI,CAACmB,SAAS,CAAC,GAAG;IAC/C,KAAK,QAAQ;MACX,OAAO,IAAInB,IAAI,CAACT,KAAK,IAAI,OAAO,GAAG;IACrC,KAAK,SAAS;IACd;MACE,OAAO,SAAS;EACpB;AACF","ignoreList":[]}
|
package/build/cjs/index.cjs
CHANGED
|
@@ -402,7 +402,7 @@ function renderType(type) {
|
|
|
402
402
|
return `"${offsetDate.toISOString()}"`;
|
|
403
403
|
}
|
|
404
404
|
case "object":
|
|
405
|
-
return `"primaryKeyValue"
|
|
405
|
+
return `"primaryKeyValue" /* or myObjectInstance */`;
|
|
406
406
|
case "objectSet":
|
|
407
407
|
return `client(${type.objectTypeApiName}).where({ /* filter conditions */ })`;
|
|
408
408
|
case "anonymousCustomType":
|
package/build/cjs/index.cjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/generatedNoCheck/docsNoComputedVariables.ts","../../src/docs.ts"],"names":[],"mappings":";;;AAGO,IAAM,QAAA,GAAW;AAAA,EACtB,MAAA,EAAQ,KAAA;AAAA,EACR,UAAA,EAAY;AAAA,IACV,OAAA,EAAS;AAAA,MACP,UAAA,EAAY;AAAA,QACV,sBAAsB,CAAC;AAAA,UACrB,UAAA,EAAY;AAAA,SACb,CAAA;AAAA,QACD,4BAA4B,CAAC;AAAA,UAC3B,UAAA,EAAY;AAAA,SACb,CAAA;AAAA,QACD,6BAA6B,CAAC;AAAA,UAC5B,UAAA,EAAY;AAAA,SACb,CAAA;AAAA,QACD,kCAAkC,CAAC;AAAA,UACjC,UAAA,EAAY;AAAA,SACb,CAAA;AAAA,QACD,sBAAsB,CAAC;AAAA,UACrB,UAAA,EAAY;AAAA,SACb,CAAA;AAAA,QACD,2BAA2B,CAAC;AAAA,UAC1B,UAAA,EAAY,ouBAAA;AAAA,UACZ,mBAAA,EAAqB,CAAC,+BAA+B;AAAA,SACtD,CAAA;AAAA,QACD,gCAAgC,CAAC;AAAA,UAC/B,UAAA,EAAY;AAAA,SACb,CAAA;AAAA,QACD,8BAA8B,CAAC;AAAA,UAC7B,UAAA,EAAY;AAAA,SACb,CAAA;AAAA,QACD,yBAAyB,CAAC;AAAA,UACxB,UAAA,EAAY;AAAA,SACb,CAAA;AAAA,QACD,uBAAuB,CAAC;AAAA,UACtB,UAAA,EAAY;AAAA,SACb,CAAA;AAAA,QACD,qBAAqB,CAAC;AAAA,UACpB,UAAA,E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;AAAA;AAEb","file":"index.cjs","sourcesContent":["// THIS FILE IS GENERATED. DO NOT MODIFY.\n// You probably want to modify ../documentation.yml instead.\n\nexport const snippets = {\n \"kind\": \"sdk\",\n \"versions\": {\n \"2.0.0\": {\n \"snippets\": {\n \"reactProviderSetup\": [{\n \"template\": \"import { OsdkProvider2 } from \\\"@osdk/react/experimental\\\";\\nimport { createClient } from \\\"@osdk/client\\\";\\n\\nconst client = createClient(\\n \\\"https://your-stack.palantirfoundry.com\\\",\\n \\\"{{{packageName}}}\\\",\\n async () => \\\"your-token\\\"\\n);\\n\\nfunction App() {\\n return (\\n <OsdkProvider2 client={client}>\\n <YourApp />\\n </OsdkProvider2>\\n );\\n}\"\n }],\n \"reactUseOsdkObjectsBasic\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}List() {\\n const { data, isLoading, error, fetchMore } = useOsdkObjects({{objectType}});\\n\\n return (\\n <div>\\n {error && <div className=\\\"error-banner\\\">Error: {error.message}</div>}\\n {isLoading && !data && <div className=\\\"skeleton\\\">Loading...</div>}\\n <ul>\\n {data?.map(obj => (\\n <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>\\n ))}\\n </ul>\\n {isLoading && data && <span className=\\\"refresh-indicator\\\">Refreshing...</span>}\\n {fetchMore && <button onClick={fetchMore}>Load more</button>}\\n </div>\\n );\\n}\"\n }],\n \"reactUseOsdkObjectsFilter\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction Filtered{{objectType}}List() {\\n const { data, isLoading, error } = useOsdkObjects({{objectType}}, {\\n where: {\\n {{titleProperty}}: { $isNotNull: true }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div className=\\\"error-banner\\\">Error: {error.message}</div>}\\n {isLoading && !data && <div className=\\\"skeleton\\\">Loading...</div>}\\n <ul>\\n {data?.map(obj => (\\n <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>\\n ))}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"reactUseOsdkObjectByPrimaryKey\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObject } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}Detail({ primaryKey }: { primaryKey: string }) {\\n const { object, isLoading, error } = useOsdkObject({{objectType}}, primaryKey);\\n\\n return (\\n <div>\\n {error && <div className=\\\"error-banner\\\">Error: {error.message}</div>}\\n {isLoading && !object && <div className=\\\"skeleton\\\">Loading...</div>}\\n {object && (\\n <div>\\n <h2>{object.{{titleProperty}}}</h2>\\n </div>\\n )}\\n </div>\\n );\\n}\"\n }],\n \"reactUseLinksBasic\": [{\n \"template\": \"import { {{sourceObjectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useLinks } from \\\"@osdk/react/experimental\\\";\\n\\nfunction Linked{{linkedObjectType}}({ source }: { source: {{sourceObjectType}}.OsdkInstance }) {\\n const { links, isLoading, error } = useLinks(source, \\\"{{linkApiName}}\\\");\\n\\n return (\\n <div>\\n {error && <div className=\\\"error-banner\\\">Error: {error.message}</div>}\\n {isLoading && !links && <div className=\\\"skeleton\\\">Loading...</div>}\\n <ul>\\n {links?.map(linked => (\\n <li key={linked.$primaryKey}>{linked.$primaryKey}</li>\\n ))}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"reactUseOsdkActionBasic\": [{\n \"template\": \"import { {{actionApiName}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkAction } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{actionApiName}}Button() {\\n const { applyAction, isPending, error } = useOsdkAction({{actionApiName}});\\n\\n const handleClick = async () => {\\n await applyAction({\\n {{#actionParameterSampleValuesV2}}\\n {{key}}: {{value}}{{^last}},{{/last}}\\n {{/actionParameterSampleValuesV2}}\\n });\\n };\\n\\n return (\\n <div>\\n {error && <div className=\\\"error-banner\\\">Error: {String(error.unknown ?? error.actionValidation)}</div>}\\n <button onClick={handleClick} disabled={isPending}>\\n {isPending ? \\\"Applying...\\\" : \\\"Apply {{actionApiName}}\\\"}\\n </button>\\n </div>\\n );\\n}\",\n \"computedVariables\": [\"actionParameterSampleValuesV2\"]\n }],\n \"reactUseOsdkAggregationBasic\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkAggregation } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}Count() {\\n const { data, isLoading, error } = useOsdkAggregation({{objectType}}, {\\n aggregate: { $select: { $count: \\\"unordered\\\" } }\\n });\\n\\n return (\\n <div>\\n {error && <div className=\\\"error-banner\\\">Error: {error.message}</div>}\\n {isLoading && data == null && <div className=\\\"skeleton\\\">Loading...</div>}\\n {data != null && <span>Total: {data}</span>}\\n </div>\\n );\\n}\"\n }],\n \"reactUseOsdkObjectsEnabled\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction Conditional{{objectType}}List({ shouldFetch }: { shouldFetch: boolean }) {\\n const { data, isLoading, error } = useOsdkObjects({{objectType}}, {\\n enabled: shouldFetch\\n });\\n\\n return (\\n <div>\\n {!shouldFetch && <div>Select criteria to load data</div>}\\n {error && <div className=\\\"error-banner\\\">Error: {error.message}</div>}\\n {isLoading && !data && <div className=\\\"skeleton\\\">Loading...</div>}\\n <ul>\\n {data?.map(obj => (\\n <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>\\n ))}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"loadSingleObjectGuide\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObject } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}Detail({ primaryKey }: { primaryKey: string }) {\\n const { object, isLoading, error } = useOsdkObject({{objectType}}, primaryKey);\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !object && <div>Loading...</div>}\\n {object && <div>{object.{{titleProperty}}}</div>}\\n </div>\\n );\\n}\"\n }],\n \"loadObjectPageGuide\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}List() {\\n const { data, isLoading, error, fetchMore } = useOsdkObjects({{objectType}}, {\\n pageSize: 30\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>)}\\n </ul>\\n {fetchMore && <button onClick={fetchMore}>Load more</button>}\\n </div>\\n );\\n}\"\n }],\n \"orderObjectsGuide\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction Sorted{{objectType}}List() {\\n const { data, isLoading, error } = useOsdkObjects({{objectType}}, {\\n orderBy: { {{titleProperty}}: \\\"asc\\\" }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"searchObjectsGuide\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction Filtered{{objectType}}List() {\\n const { data, isLoading, error } = useOsdkObjects({{objectType}}, {\\n where: {\\n {{titleProperty}}: { $isNotNull: true }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"loadSingleObjectReference\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObject } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}Detail({ primaryKey }: { primaryKey: string }) {\\n const { object, isLoading, error } = useOsdkObject({{objectType}}, primaryKey);\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !object && <div>Loading...</div>}\\n {object && <div>{object.{{titleProperty}}}</div>}\\n </div>\\n );\\n}\"\n }],\n \"loadObjectsReference\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}List() {\\n const { data, isLoading, error, fetchMore } = useOsdkObjects({{objectType}}, {\\n pageSize: 30\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>)}\\n </ul>\\n {fetchMore && <button onClick={fetchMore}>Load more</button>}\\n </div>\\n );\\n}\"\n }],\n \"loadAllObjectsReference\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\n// Note: For large datasets, consider using pagination with fetchMore\\nfunction All{{objectType}}List() {\\n const { data, isLoading, error, fetchMore } = useOsdkObjects({{objectType}});\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>)}\\n </ul>\\n {fetchMore && <button onClick={fetchMore}>Load more</button>}\\n </div>\\n );\\n}\"\n }],\n \"loadLinkedObjectReference\": [{\n \"template\": \"import { {{sourceObjectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useLinks } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{linkedObjectType}}Detail({ source }: { source: {{sourceObjectType}}.OsdkInstance }) {\\n const { links, isLoading, error } = useLinks(source, \\\"{{linkApiName}}\\\");\\n const linkedObject = links?.[0];\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !links && <div>Loading...</div>}\\n {linkedObject && <div>{linkedObject.$primaryKey}</div>}\\n </div>\\n );\\n}\"\n }],\n \"loadLinkedObjectsReference\": [{\n \"template\": \"import { {{sourceObjectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useLinks } from \\\"@osdk/react/experimental\\\";\\n\\nfunction Linked{{linkedObjectType}}List({ source }: { source: {{sourceObjectType}}.OsdkInstance }) {\\n const { links, isLoading, error, fetchMore } = useLinks(source, \\\"{{linkApiName}}\\\");\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !links && <div>Loading...</div>}\\n <ul>\\n {links?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n {fetchMore && <button onClick={fetchMore}>Load more</button>}\\n </div>\\n );\\n}\"\n }],\n \"aggregationTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkAggregation } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}Aggregation() {\\n const { data, isLoading, error } = useOsdkAggregation({{objectType}}, {\\n where: { {{property}}: { $isNull: false } },\\n aggregate: {\\n $select: { $count: \\\"unordered\\\" },\\n $groupBy: { {{property}}: \\\"exact\\\" }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && data == null && <div>Loading...</div>}\\n {data != null && <pre>{JSON.stringify(data, null, 2)}</pre>}\\n </div>\\n );\\n}\"\n }],\n \"countAggregationTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkAggregation } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}Count() {\\n const { data, isLoading, error } = useOsdkAggregation({{objectType}}, {\\n aggregate: { $select: { $count: \\\"unordered\\\" } }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && data == null && <div>Loading...</div>}\\n {data != null && <span>Total: {data}</span>}\\n </div>\\n );\\n}\"\n }],\n \"approximateDistinctAggregationTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkAggregation } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}DistinctCount() {\\n const { data, isLoading, error } = useOsdkAggregation({{objectType}}, {\\n aggregate: { $select: { \\\"{{property}}:approximateDistinct\\\": \\\"unordered\\\" } }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && data == null && <div>Loading...</div>}\\n {data != null && <span>Distinct count: {data}</span>}\\n </div>\\n );\\n}\"\n }],\n \"exactDistinctAggregationTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkAggregation } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}ExactDistinctCount() {\\n const { data, isLoading, error } = useOsdkAggregation({{objectType}}, {\\n aggregate: { $select: { \\\"{{property}}:exactDistinct\\\": \\\"unordered\\\" } }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && data == null && <div>Loading...</div>}\\n {data != null && <span>Exact distinct count: {data}</span>}\\n </div>\\n );\\n}\"\n }],\n \"numericAggregationTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkAggregation } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}{{operation}}() {\\n const { data, isLoading, error } = useOsdkAggregation({{objectType}}, {\\n aggregate: { $select: { \\\"{{property}}:{{operation}}\\\": \\\"unordered\\\" } }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && data == null && <div>Loading...</div>}\\n {data != null && <span>{{operation}}: {data}</span>}\\n </div>\\n );\\n}\"\n }],\n \"fixedWidthGroupByTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkAggregation } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}GroupedByFixedWidth() {\\n const { data, isLoading, error } = useOsdkAggregation({{objectType}}, {\\n aggregate: {\\n $select: { $count: \\\"unordered\\\" },\\n $groupBy: { {{property}}: { $fixedWidth: 10 } }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && data == null && <div>Loading...</div>}\\n {data != null && <pre>{JSON.stringify(data, null, 2)}</pre>}\\n </div>\\n );\\n}\"\n }],\n \"durationGroupByTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkAggregation } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}GroupedByDuration() {\\n const { data, isLoading, error } = useOsdkAggregation({{objectType}}, {\\n aggregate: {\\n $select: { $count: \\\"unordered\\\" },\\n $groupBy: { {{property}}: { $duration: [{{#durationText}}{{arg}}{{/durationText}}, \\\"{{#durationText}}{{unit}}{{/durationText}}\\\"] } }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && data == null && <div>Loading...</div>}\\n {data != null && <pre>{JSON.stringify(data, null, 2)}</pre>}\\n </div>\\n );\\n}\"\n }],\n \"exactGroupByTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkAggregation } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}GroupedByExact() {\\n const { data, isLoading, error } = useOsdkAggregation({{objectType}}, {\\n aggregate: {\\n $select: { $count: \\\"unordered\\\" },\\n $groupBy: { {{property}}: \\\"exact\\\" }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && data == null && <div>Loading...</div>}\\n {data != null && <pre>{JSON.stringify(data, null, 2)}</pre>}\\n </div>\\n );\\n}\"\n }],\n \"rangeGroupByTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkAggregation } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}GroupedByRange() {\\n const { data, isLoading, error } = useOsdkAggregation({{objectType}}, {\\n aggregate: {\\n $select: { $count: \\\"unordered\\\" },\\n $groupBy: { {{property}}: { $ranges: [[{{{propertyValueV2}}}, {{{propertyValueV2}}}]] } }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && data == null && <div>Loading...</div>}\\n {data != null && <pre>{JSON.stringify(data, null, 2)}</pre>}\\n </div>\\n );\\n}\",\n \"computedVariables\": [\"propertyValueV2\"]\n }],\n \"applyAction\": [{\n \"template\": \"import { {{actionApiName}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkAction } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{actionApiName}}Button() {\\n const { applyAction, isPending, error } = useOsdkAction({{actionApiName}});\\n\\n const handleClick = async () => {\\n await applyAction({\\n {{#actionParameterSampleValuesV2}}\\n {{key}}: {{value}}{{^last}},{{/last}}\\n {{/actionParameterSampleValuesV2}}\\n });\\n };\\n\\n return (\\n <div>\\n {error && <div>Error: {String(error.unknown ?? error.actionValidation)}</div>}\\n <button onClick={handleClick} disabled={isPending}>\\n {isPending ? \\\"Applying...\\\" : \\\"Apply\\\"}\\n </button>\\n </div>\\n );\\n}\",\n \"computedVariables\": [\"actionParameterSampleValuesV2\"]\n }],\n \"applyActionResponse\": [{\n \"template\": \"import { {{actionApiName}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkAction } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{actionApiName}}WithResult() {\\n const { applyAction, isPending, error, data } = useOsdkAction({{actionApiName}});\\n\\n const handleClick = async () => {\\n await applyAction({\\n {{#actionParameterSampleValuesV2}}\\n {{key}}: {{value}}{{^last}},{{/last}}\\n {{/actionParameterSampleValuesV2}}\\n });\\n };\\n\\n return (\\n <div>\\n {error && <div className=\\\"error-banner\\\">Error: {String(error.unknown ?? error.actionValidation)}</div>}\\n {data && <div>Action completed successfully</div>}\\n <button onClick={handleClick} disabled={isPending}>\\n {isPending ? \\\"Applying...\\\" : \\\"Apply {{actionApiName}}\\\"}\\n </button>\\n </div>\\n );\\n}\",\n \"computedVariables\": [\"actionParameterSampleValuesV2\"]\n }],\n \"validateAction\": [{\n \"template\": \"import { {{actionApiName}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkAction, useDebouncedCallback } from \\\"@osdk/react/experimental\\\";\\nimport { useState } from \\\"react\\\";\\n\\nfunction {{actionApiName}}WithValidation() {\\n const { validateAction, applyAction, isPending, validationResult } = useOsdkAction({{actionApiName}});\\n const [params, setParams] = useState<Record<string, string>>({});\\n\\n const debouncedValidate = useDebouncedCallback(\\n (nextParams: Record<string, string>) => { validateAction(nextParams); },\\n 300\\n );\\n\\n const handleParamChange = (key: string, value: string) => {\\n const nextParams = { ...params, [key]: value };\\n setParams(nextParams);\\n debouncedValidate(nextParams);\\n };\\n\\n return (\\n <div>\\n <input\\n placeholder=\\\"Parameter value\\\"\\n onChange={(e) => handleParamChange(\\\"paramName\\\", e.target.value)}\\n />\\n {validationResult?.result === \\\"INVALID\\\" && (\\n <div>Validation errors present</div>\\n )}\\n <button\\n onClick={() => applyAction(params)}\\n disabled={isPending || validationResult?.result === \\\"INVALID\\\"}\\n >\\n {isPending ? \\\"Applying...\\\" : \\\"Apply\\\"}\\n </button>\\n </div>\\n );\\n}\"\n }],\n \"batchApplyAction\": [{\n \"template\": \"// Batch actions in React should be handled with multiple hook calls\\n// or by using the client directly for batch operations\\nimport { {{actionApiName}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkAction } from \\\"@osdk/react/experimental\\\";\\n\\nfunction Batch{{actionApiName}}() {\\n const { applyAction, isPending } = useOsdkAction({{actionApiName}});\\n\\n const handleBatchApply = async (items: Array<Parameters<typeof applyAction>[0]>) => {\\n await Promise.all(items.map(item => applyAction(item)));\\n };\\n\\n return (\\n <button onClick={() => handleBatchApply([])} disabled={isPending}>\\n Apply Batch\\n </button>\\n );\\n}\"\n }],\n \"clientSetup\": [{\n \"template\": \"import { OsdkProvider2 } from \\\"@osdk/react/experimental\\\";\\nimport { createClient } from \\\"@osdk/client\\\";\\n\\nconst client = createClient(\\n \\\"https://your-stack.palantirfoundry.com\\\",\\n \\\"{{{packageName}}}\\\",\\n async () => \\\"your-token\\\"\\n);\\n\\nfunction App() {\\n return (\\n <OsdkProvider2 client={client}>\\n <YourApp />\\n </OsdkProvider2>\\n );\\n}\"\n }],\n \"callFunction\": [{\n \"template\": \"import { {{funcApiName}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkFunction } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{funcApiName}}Caller() {\\n const { data, isLoading, error, refetch } = useOsdkFunction({{funcApiName}}, {\\n params: { /* function parameters */ }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n {data && <pre>{JSON.stringify(data, null, 2)}</pre>}\\n <button onClick={refetch}>Refresh</button>\\n </div>\\n );\\n}\"\n }],\n \"executeFunction\": [{\n \"template\": \"import { {{funcApiName}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkFunction } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{funcApiName}}Executor() {\\n const { data, isLoading, error, refetch } = useOsdkFunction({{funcApiName}}, {\\n params: { /* function parameters */ }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n {data && <pre>{JSON.stringify(data, null, 2)}</pre>}\\n <button onClick={refetch}>Refresh</button>\\n </div>\\n );\\n}\"\n }],\n \"stringStartsWithTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}StartsWith() {\\n const { data, isLoading, error } = useOsdkObjects({{objectType}}, {\\n where: {\\n {{property}}: { $startsWith: \\\"foo\\\" }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"containsAnyTermTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}ContainsAnyTerm() {\\n const { data, isLoading, error } = useOsdkObjects({{objectType}}, {\\n where: {\\n {{property}}: { $containsAnyTerm: \\\"foo bar\\\" }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"containsAllTermsTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}ContainsAllTerms() {\\n const { data, isLoading, error } = useOsdkObjects({{objectType}}, {\\n where: {\\n {{property}}: { $containsAllTerms: \\\"foo bar\\\" }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"containsAllTermsInOrderTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}ContainsAllTermsInOrder() {\\n const { data, isLoading, error } = useOsdkObjects({{objectType}}, {\\n where: {\\n {{property}}: { $containsAllTermsInOrder: \\\"foo bar\\\" }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"containsTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}Contains() {\\n const { data, isLoading, error } = useOsdkObjects({{objectType}}, {\\n where: {\\n {{property}}: { $contains: \\\"value\\\" }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"equalityTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}Equality() {\\n const { data, isLoading, error } = useOsdkObjects({{objectType}}, {\\n where: {\\n {{property}}: { $eq: {{{propertyValueV2}}} }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>)}\\n </ul>\\n </div>\\n );\\n}\",\n \"computedVariables\": [\"propertyValueV2\"]\n }],\n \"inFilterTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}InFilter() {\\n const { data, isLoading, error } = useOsdkObjects({{objectType}}, {\\n where: {\\n {{property}}: { $in: [{{{propertyValueV2}}}] }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>)}\\n </ul>\\n </div>\\n );\\n}\",\n \"computedVariables\": [\"propertyValueV2\"]\n }],\n \"rangeTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}Range() {\\n const { data, isLoading, error } = useOsdkObjects({{objectType}}, {\\n where: {\\n {{property}}: { ${{operation}}: {{{propertyValueV2}}} }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>)}\\n </ul>\\n </div>\\n );\\n}\",\n \"computedVariables\": [\"propertyValueV2\"]\n }],\n \"nullTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}NullFilter() {\\n const { data, isLoading, error } = useOsdkObjects({{objectType}}, {\\n where: {\\n {{property}}: { $isNull: true }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"andTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}AndFilter() {\\n const { data, isLoading, error } = useOsdkObjects({{objectType}}, {\\n where: {\\n $and: [\\n { $not: { {{primaryKeyPropertyV2.apiName}}: { $isNull: true } } },\\n { {{property}}: { $eq: {{{propertyValueV2}}} } }\\n ]\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>)}\\n </ul>\\n </div>\\n );\\n}\",\n \"computedVariables\": [\"primaryKeyPropertyV2\", \"propertyValueV2\"]\n }],\n \"orTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}OrFilter() {\\n const { data, isLoading, error } = useOsdkObjects({{objectType}}, {\\n where: {\\n $or: [\\n { $not: { {{primaryKeyPropertyV2.apiName}}: { $isNull: true } } },\\n { {{property}}: { $eq: {{{propertyValueV2}}} } }\\n ]\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>)}\\n </ul>\\n </div>\\n );\\n}\",\n \"computedVariables\": [\"primaryKeyPropertyV2\", \"propertyValueV2\"]\n }],\n \"notTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}NotFilter() {\\n const { data, isLoading, error } = useOsdkObjects({{objectType}}, {\\n where: {\\n $not: { {{property}}: { $eq: {{{propertyValueV2}}} } }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>)}\\n </ul>\\n </div>\\n );\\n}\",\n \"computedVariables\": [\"propertyValueV2\"]\n }],\n \"withinDistanceTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}WithinDistance() {\\n const { data, isLoading, error } = useOsdkObjects({{objectType}}, {\\n where: {\\n {{property}}: { $within: { $distance: [100, \\\"{{distanceUnit}}\\\"], $of: [-74.0060, 40.7128] } }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"withinBoundingBoxTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}WithinBoundingBox() {\\n const { data, isLoading, error } = useOsdkObjects({{objectType}}, {\\n where: {\\n {{property}}: { $within: { $bbox: [-74.0060, 25.123, 80.4231, 40.7128] } }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"withinPolygonTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}WithinPolygon() {\\n const { data, isLoading, error } = useOsdkObjects({{objectType}}, {\\n where: {\\n {{property}}: { $within: { type: \\\"Polygon\\\", coordinates: [[[10.0, 40.0], [20.0, 50.0], [20.0, 30.0], [10.0, 40.0]]] } }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"intersectsPolygonTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}IntersectsPolygon() {\\n const { data, isLoading, error } = useOsdkObjects({{objectType}}, {\\n where: {\\n {{property}}: { $intersects: { type: \\\"Polygon\\\", coordinates: [[[10.0, 40.0], [20.0, 50.0], [20.0, 30.0], [10.0, 40.0]]] } }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"intersectsBboxTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}IntersectsBbox() {\\n const { data, isLoading, error } = useOsdkObjects({{objectType}}, {\\n where: {\\n {{property}}: { $intersects: { $bbox: [-74.0060, 25.123, 80.4231, 40.7128] } }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"objectSetOperationsGuide\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkClient, useObjectSet } from \\\"@osdk/react/experimental\\\";\\nimport { useMemo } from \\\"react\\\";\\n\\nfunction {{objectType}}SetOperations() {\\n const client = useOsdkClient();\\n const combinedSet = useMemo(() => {\\n const setA = client({{objectType}}).where({ {{titleProperty}}: { $containsAnyTerm: \\\"a\\\" } });\\n const setB = client({{objectType}}).where({ {{titleProperty}}: { $containsAnyTerm: \\\"b\\\" } });\\n const setC = client({{objectType}}).where({ {{titleProperty}}: { $containsAnyTerm: \\\"c\\\" } });\\n return setA.intersect(setB).subtract(setC);\\n }, [client]);\\n\\n const { data, isLoading, error } = useObjectSet(combinedSet);\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"objectSetOperationsUnion\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkClient, useObjectSet } from \\\"@osdk/react/experimental\\\";\\nimport { useMemo } from \\\"react\\\";\\n\\nfunction {{objectType}}Union() {\\n const client = useOsdkClient();\\n const unionSet = useMemo(() => {\\n const setA = client({{objectType}}).where({ {{titleProperty}}: { $containsAnyTerm: \\\"a\\\" } });\\n const setB = client({{objectType}}).where({ {{titleProperty}}: { $containsAnyTerm: \\\"b\\\" } });\\n const setC = client({{objectType}}).where({ {{titleProperty}}: { $containsAnyTerm: \\\"c\\\" } });\\n return setA.union(setB).union(setC);\\n }, [client]);\\n\\n const { data, isLoading, error } = useObjectSet(unionSet);\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"objectSetOperationsSubtract\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkClient, useObjectSet } from \\\"@osdk/react/experimental\\\";\\nimport { useMemo } from \\\"react\\\";\\n\\nfunction {{objectType}}Subtract() {\\n const client = useOsdkClient();\\n const subtractedSet = useMemo(() => {\\n const setA = client({{objectType}}).where({ {{titleProperty}}: { $containsAnyTerm: \\\"a\\\" } });\\n const setB = client({{objectType}}).where({ {{titleProperty}}: { $containsAnyTerm: \\\"b\\\" } });\\n const setC = client({{objectType}}).where({ {{titleProperty}}: { $containsAnyTerm: \\\"c\\\" } });\\n return setA.subtract(setB).subtract(setC);\\n }, [client]);\\n\\n const { data, isLoading, error } = useObjectSet(subtractedSet);\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"objectSetOperationsIntersect\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkClient, useObjectSet } from \\\"@osdk/react/experimental\\\";\\nimport { useMemo } from \\\"react\\\";\\n\\nfunction {{objectType}}Intersect() {\\n const client = useOsdkClient();\\n const intersectedSet = useMemo(() => {\\n const setA = client({{objectType}}).where({ {{titleProperty}}: { $containsAnyTerm: \\\"a\\\" } });\\n const setB = client({{objectType}}).where({ {{titleProperty}}: { $containsAnyTerm: \\\"b\\\" } });\\n const setC = client({{objectType}}).where({ {{titleProperty}}: { $containsAnyTerm: \\\"c\\\" } });\\n return setA.intersect(setB).intersect(setC);\\n }, [client]);\\n\\n const { data, isLoading, error } = useObjectSet(intersectedSet);\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"derivedPropertyBaseExample\": [{\n \"template\": \"import { {{sourceObjectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkClient, useObjectSet } from \\\"@osdk/react/experimental\\\";\\nimport { useMemo } from \\\"react\\\";\\n\\nfunction {{sourceObjectType}}DerivedProperty() {\\n const client = useOsdkClient();\\n const derivedSet = useMemo(() =>\\n client({{sourceObjectType}}).withProperties({\\n \\\"newPropertyName\\\": (baseObjectSet) =>\\n baseObjectSet.pivotTo(\\\"{{linkApiName}}\\\").aggregate(\\\"$count\\\")\\n }), [client]);\\n\\n const { data, isLoading, error } = useObjectSet(derivedSet);\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"derivedPropertyCountAggregation\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkClient, useObjectSet } from \\\"@osdk/react/experimental\\\";\\nimport { useMemo } from \\\"react\\\";\\n\\nfunction {{objectType}}DerivedCount() {\\n const client = useOsdkClient();\\n const derivedSet = useMemo(() =>\\n client({{objectType}}).withProperties({\\n \\\"newPropertyName\\\": (baseObjectSet) =>\\n baseObjectSet.pivotTo(\\\"{{linkApiName}}\\\").aggregate(\\\"$count\\\")\\n }), [client]);\\n\\n const { data, isLoading, error } = useObjectSet(derivedSet);\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"derivedPropertyNumericAggregation\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkClient, useObjectSet } from \\\"@osdk/react/experimental\\\";\\nimport { useMemo } from \\\"react\\\";\\n\\nfunction {{objectType}}DerivedNumeric() {\\n const client = useOsdkClient();\\n const derivedSet = useMemo(() =>\\n client({{objectType}}).withProperties({\\n \\\"newPropertyName\\\": (baseObjectSet) =>\\n baseObjectSet.pivotTo(\\\"{{linkApiName}}\\\").aggregate(\\\"{{property}}:{{operation}}\\\")\\n }), [client]);\\n\\n const { data, isLoading, error } = useObjectSet(derivedSet);\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"derivedPropertySelectPropertyAggregation\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkClient, useObjectSet } from \\\"@osdk/react/experimental\\\";\\nimport { useMemo } from \\\"react\\\";\\n\\nfunction {{objectType}}DerivedSelectProperty() {\\n const client = useOsdkClient();\\n const derivedSet = useMemo(() =>\\n client({{objectType}}).withProperties({\\n \\\"newPropertyName\\\": (baseObjectSet) =>\\n baseObjectSet.pivotTo(\\\"{{linkApiName}}\\\").selectProperty(\\\"{{property}}\\\")\\n }), [client]);\\n\\n const { data, isLoading, error } = useObjectSet(derivedSet);\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"derivedPropertyApproximateDistinctAggregation\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkClient, useObjectSet } from \\\"@osdk/react/experimental\\\";\\nimport { useMemo } from \\\"react\\\";\\n\\nfunction {{objectType}}DerivedApproxDistinct() {\\n const client = useOsdkClient();\\n const derivedSet = useMemo(() =>\\n client({{objectType}}).withProperties({\\n \\\"newPropertyName\\\": (baseObjectSet) =>\\n baseObjectSet.pivotTo(\\\"{{linkApiName}}\\\").aggregate(\\\"{{property}}:approximateDistinct\\\")\\n }), [client]);\\n\\n const { data, isLoading, error } = useObjectSet(derivedSet);\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"derivedPropertyExactDistinctAggregation\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkClient, useObjectSet } from \\\"@osdk/react/experimental\\\";\\nimport { useMemo } from \\\"react\\\";\\n\\nfunction {{objectType}}DerivedExactDistinct() {\\n const client = useOsdkClient();\\n const derivedSet = useMemo(() =>\\n client({{objectType}}).withProperties({\\n \\\"newPropertyName\\\": (baseObjectSet) =>\\n baseObjectSet.pivotTo(\\\"{{linkApiName}}\\\").aggregate(\\\"{{property}}:exactDistinct\\\")\\n }), [client]);\\n\\n const { data, isLoading, error } = useObjectSet(derivedSet);\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"derivedPropertyApproximatePercentileAggregation\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkClient, useObjectSet } from \\\"@osdk/react/experimental\\\";\\nimport { useMemo } from \\\"react\\\";\\n\\nfunction {{objectType}}DerivedPercentile() {\\n const client = useOsdkClient();\\n const derivedSet = useMemo(() =>\\n client({{objectType}}).withProperties({\\n \\\"newPropertyName\\\": (baseObjectSet) =>\\n baseObjectSet.pivotTo(\\\"{{linkApiName}}\\\").aggregate(\\\"{{property}}:approximatePercentile\\\", { percentile: 95 })\\n }), [client]);\\n\\n const { data, isLoading, error } = useObjectSet(derivedSet);\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"derivedPropertyCollectToListAggregation\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkClient, useObjectSet } from \\\"@osdk/react/experimental\\\";\\nimport { useMemo } from \\\"react\\\";\\n\\nfunction {{objectType}}DerivedCollectList() {\\n const client = useOsdkClient();\\n const maxObjectsInList = 75;\\n const derivedSet = useMemo(() =>\\n client({{objectType}}).withProperties({\\n \\\"newPropertyName\\\": (baseObjectSet) =>\\n baseObjectSet.pivotTo(\\\"{{linkApiName}}\\\").aggregate(\\\"{{property}}:collectList\\\", { limit: maxObjectsInList })\\n }), [client]);\\n\\n const { data, isLoading, error } = useObjectSet(derivedSet);\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"derivedPropertyCollectToSetAggregation\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkClient, useObjectSet } from \\\"@osdk/react/experimental\\\";\\nimport { useMemo } from \\\"react\\\";\\n\\nfunction {{objectType}}DerivedCollectSet() {\\n const client = useOsdkClient();\\n const maxObjectsInSet = 75;\\n const derivedSet = useMemo(() =>\\n client({{objectType}}).withProperties({\\n \\\"newPropertyName\\\": (baseObjectSet) =>\\n baseObjectSet.pivotTo(\\\"{{linkApiName}}\\\").aggregate(\\\"{{property}}:collectSet\\\", { limit: maxObjectsInSet })\\n }), [client]);\\n\\n const { data, isLoading, error } = useObjectSet(derivedSet);\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"loadObjectMetadataSnippet\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkMetadata } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}Metadata() {\\n const { loading, metadata, error } = useOsdkMetadata({{objectType}});\\n\\n return (\\n <div>\\n {error && <div className=\\\"error-banner\\\">Error: {error}</div>}\\n {loading && !metadata && <div className=\\\"skeleton\\\">Loading...</div>}\\n {metadata && (\\n <div>\\n <div>Description: {metadata.description}</div>\\n <div>Visibility: {metadata.visibility}</div>\\n </div>\\n )}\\n </div>\\n );\\n}\"\n }],\n \"loadInterfaceMetadataSnippet\": [{\n \"template\": \"import { {{interfaceApiName}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkMetadata } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{interfaceApiName}}Metadata() {\\n const { loading, metadata, error } = useOsdkMetadata({{interfaceApiName}});\\n\\n return (\\n <div>\\n {error && <div className=\\\"error-banner\\\">Error: {error}</div>}\\n {loading && !metadata && <div className=\\\"skeleton\\\">Loading...</div>}\\n {metadata && (\\n <div>\\n <div>RID: {metadata.rid}</div>\\n <div>Implemented by: {metadata.implementedBy?.join(\\\", \\\")}</div>\\n </div>\\n )}\\n </div>\\n );\\n}\"\n }],\n \"loadInterfacesReference\": [{\n \"template\": \"import { {{interfaceApiName}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{interfaceApiName}}List() {\\n const { data, isLoading, error, fetchMore } = useOsdkObjects({{interfaceApiName}}, {\\n pageSize: 30\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n {fetchMore && <button onClick={fetchMore}>Load more</button>}\\n </div>\\n );\\n}\"\n }],\n \"loadAllInterfacesReference\": [{\n \"template\": \"import { {{interfaceApiName}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction All{{interfaceApiName}}List() {\\n const { data, isLoading, error, fetchMore } = useOsdkObjects({{interfaceApiName}});\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n {fetchMore && <button onClick={fetchMore}>Load more</button>}\\n </div>\\n );\\n}\"\n }],\n \"loadOrderedInterfacesReference\": [{\n \"template\": \"import { {{interfaceApiName}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction Ordered{{interfaceApiName}}List() {\\n const { data, isLoading, error } = useOsdkObjects({{interfaceApiName}}, {\\n orderBy: { {{property}}: \\\"asc\\\" },\\n pageSize: 30\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"searchInterfacesReference\": [{\n \"template\": \"import { {{interfaceApiName}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction Search{{interfaceApiName}}() {\\n const { data, isLoading, error } = useOsdkObjects({{interfaceApiName}}, {\\n where: {\\n {{property}}: { $startsWith: \\\"foo\\\" }\\n },\\n pageSize: 30\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"castInterfaceToObjectReference\": [{\n \"template\": \"import { {{objectTypeApiName}}, {{interfaceApiName}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction CastInterface() {\\n const { data, isLoading, error } = useOsdkObjects({{interfaceApiName}}, {\\n pageSize: 10\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => {\\n const casted = obj.$as({{objectTypeApiName}});\\n return <li key={casted.$primaryKey}>{casted.$primaryKey}</li>;\\n })}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"subscribeToObjectSetInstructions\": [{\n \"template\": \"import { {{objectOrInterfaceApiName}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectOrInterfaceApiName}}LiveList() {\\n const { data, isLoading, error } = useOsdkObjects({{objectOrInterfaceApiName}}, {\\n streamUpdates: true\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"loadTimeSeriesPointsSnippet\": [{\n \"template\": \"// Timeseries does not have a dedicated React hook yet.\\n// Use the client API directly with a loaded OSDK object.\\nimport type { Osdk } from \\\"@osdk/client\\\";\\nimport type { {{objectType}} } from \\\"{{{packageName}}}\\\";\\n\\nasync function getAllTimeSeriesPoints(obj: Osdk.Instance<typeof {{objectType}}>) {\\n return obj.{{property}}?.getAllPoints();\\n}\"\n }],\n \"loadTimeSeriesFirstPointSnippet\": [{\n \"template\": \"// Timeseries does not have a dedicated React hook yet.\\n// Use the client API directly with a loaded OSDK object.\\nimport type { Osdk } from \\\"@osdk/client\\\";\\nimport type { {{objectType}} } from \\\"{{{packageName}}}\\\";\\n\\nasync function getFirstTimeSeriesPoint(obj: Osdk.Instance<typeof {{objectType}}>) {\\n return obj.{{property}}?.getFirstPoint();\\n}\"\n }],\n \"loadTimeSeriesLastPointSnippet\": [{\n \"template\": \"// Timeseries does not have a dedicated React hook yet.\\n// Use the client API directly with a loaded OSDK object.\\nimport type { Osdk } from \\\"@osdk/client\\\";\\nimport type { {{objectType}} } from \\\"{{{packageName}}}\\\";\\n\\nasync function getLastTimeSeriesPoint(obj: Osdk.Instance<typeof {{objectType}}>) {\\n return obj.{{property}}?.getLastPoint();\\n}\"\n }],\n \"loadAbsoluteTimeSeriesPointsSnippet\": [{\n \"template\": \"// Timeseries does not have a dedicated React hook yet.\\n// Use the client API directly with a loaded OSDK object.\\nimport type { Osdk } from \\\"@osdk/client\\\";\\nimport type { {{objectType}} } from \\\"{{{packageName}}}\\\";\\n\\nasync function getAbsoluteTimeSeriesPoints(obj: Osdk.Instance<typeof {{objectType}}>) {\\n return obj.{{property}}?.getAllPoints({\\n $startTime: \\\"2022-08-13T12:34:56Z\\\",\\n $endTime: \\\"2022-08-14T12:34:56Z\\\",\\n });\\n}\"\n }],\n \"loadRelativeTimeSeriesPointsSnippet\": [{\n \"template\": \"// Timeseries does not have a dedicated React hook yet.\\n// Use the client API directly with a loaded OSDK object.\\nimport type { Osdk } from \\\"@osdk/client\\\";\\nimport type { {{objectType}} } from \\\"{{{packageName}}}\\\";\\n\\nasync function getRelativeTimeSeriesPoints(obj: Osdk.Instance<typeof {{objectType}}>) {\\n return obj.{{property}}?.getAllPoints({\\n $before: 1,\\n $unit: \\\"{{timeUnit}}\\\",\\n });\\n}\"\n }],\n \"loadGeotimeSeriesPointsSnippet\": [{\n \"template\": \"// Geo-time series does not have a dedicated React hook yet.\\n// Use the client API directly with a loaded OSDK object.\\nimport type { Osdk } from \\\"@osdk/client\\\";\\nimport type { {{objectType}} } from \\\"{{{packageName}}}\\\";\\n\\nasync function getAllGeotimeSeriesPoints(obj: Osdk.Instance<typeof {{objectType}}>) {\\n return obj.{{property}}?.getAllValues();\\n}\"\n }],\n \"loadGeotimeSeriesLastPointSnippet\": [{\n \"template\": \"// Geo-time series does not have a dedicated React hook yet.\\n// Use the client API directly with a loaded OSDK object.\\nimport type { Osdk } from \\\"@osdk/client\\\";\\nimport type { {{objectType}} } from \\\"{{{packageName}}}\\\";\\n\\nasync function getLatestGeotimeSeriesPoint(obj: Osdk.Instance<typeof {{objectType}}>) {\\n return obj.{{property}}?.getLatestValue();\\n}\"\n }],\n \"loadAbsoluteGeotimeSeriesPointsSnippet\": [{\n \"template\": \"// Geo-time series does not have a dedicated React hook yet.\\n// Use the client API directly with a loaded OSDK object.\\nimport type { Osdk } from \\\"@osdk/client\\\";\\nimport type { {{objectType}} } from \\\"{{{packageName}}}\\\";\\n\\nasync function getAbsoluteGeotimeSeriesPoints(obj: Osdk.Instance<typeof {{objectType}}>) {\\n return obj.{{property}}?.getAllValues({\\n $startTime: \\\"2022-08-13T12:34:56Z\\\",\\n $endTime: \\\"2022-08-14T12:34:56Z\\\",\\n });\\n}\"\n }],\n \"loadRelativeGeotimeSeriesPointsSnippet\": [{\n \"template\": \"// Geo-time series does not have a dedicated React hook yet.\\n// Use the client API directly with a loaded OSDK object.\\nimport type { Osdk } from \\\"@osdk/client\\\";\\nimport type { {{objectType}} } from \\\"{{{packageName}}}\\\";\\n\\nasync function getRelativeGeotimeSeriesPoints(obj: Osdk.Instance<typeof {{objectType}}>) {\\n return obj.{{property}}?.getAllValues({\\n $before: 1,\\n $unit: \\\"{{timeUnit}}\\\",\\n });\\n}\"\n }],\n \"uploadAttachment\": [{\n \"template\": \"import { useOsdkClient } from \\\"@osdk/react/experimental\\\";\\nimport { createAttachmentUpload } from \\\"@osdk/client\\\";\\nimport { {{actionApiName}} } from \\\"{{{packageName}}}\\\";\\n\\nfunction AttachmentUploader() {\\n const client = useOsdkClient();\\n\\n const handleUpload = async (file: File) => {\\n const attachment = createAttachmentUpload(file, file.name);\\n await client({{actionApiName}}).applyAction({\\n {{primaryKeyPropertyV2.apiName}}: {{{propertyValueV2}}},\\n {{property}}: attachment\\n });\\n };\\n\\n return (\\n <input type=\\\"file\\\" onChange={e => {\\n const file = e.target.files?.[0];\\n if (file) {\\n handleUpload(file);\\n }\\n }} />\\n );\\n}\",\n \"computedVariables\": [\"propertyValueV2\", \"primaryKeyPropertyV2\"]\n }],\n \"readMedia\": [{\n \"template\": \"// Media does not have a dedicated React hook yet.\\n// Use the client API directly with a loaded OSDK object.\\nimport type { Osdk } from \\\"@osdk/client\\\";\\nimport type { {{objectType}} } from \\\"{{{packageName}}}\\\";\\n\\nasync function readMediaContent(obj: Osdk.Instance<typeof {{objectType}}>) {\\n const contents = await obj.{{property}}?.fetchContents();\\n if (contents?.ok) {\\n return contents.blob();\\n }\\n}\"\n }],\n \"uploadMedia\": [{\n \"template\": \"import { useOsdkClient } from \\\"@osdk/react/experimental\\\";\\nimport { __EXPERIMENTAL__NOT_SUPPORTED_YET__createMediaReference } from \\\"@osdk/api/unstable\\\";\\nimport type { MediaReference } from \\\"@osdk/api\\\";\\nimport { {{actionApiName}}, {{objectType}} } from \\\"{{{packageName}}}\\\";\\n\\nfunction MediaUploader() {\\n const client = useOsdkClient();\\n\\n const handleUpload = async (file: File) => {\\n const mediaReference: MediaReference = await client(\\n __EXPERIMENTAL__NOT_SUPPORTED_YET__createMediaReference,\\n ).createMediaReference({\\n data: file,\\n fileName: file.name,\\n objectType: {{objectType}},\\n propertyType: \\\"{{property}}\\\",\\n });\\n await client({{actionApiName}}).applyAction({\\n // Pass the required action parameters including the primary key\\n {{mediaParameter}}: mediaReference\\n });\\n };\\n\\n return (\\n <input type=\\\"file\\\" onChange={e => {\\n const file = e.target.files?.[0];\\n if (file) {\\n handleUpload(file);\\n }\\n }} />\\n );\\n}\"\n }],\n \"uploadMediaOntologyEdits\": [{\n \"template\": \"import { useOsdkClient } from \\\"@osdk/react/experimental\\\";\\nimport { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { createEditBatch, uploadMedia } from \\\"@osdk/functions\\\";\\n\\nfunction MediaOntologyEditsUploader() {\\n const client = useOsdkClient();\\n\\n const handleUpload = async (file: File) => {\\n const batch = createEditBatch(client);\\n const mediaReference = await uploadMedia(client, { data: file, fileName: file.name });\\n // @ts-expect-error - batch.create types don't support media references yet\\n batch.create({{objectType}}, { {{property}}: mediaReference });\\n return batch.getEdits();\\n };\\n\\n return (\\n <input type=\\\"file\\\" onChange={e => {\\n const file = e.target.files?.[0];\\n if (file) {\\n handleUpload(file);\\n }\\n }} />\\n );\\n}\"\n }],\n \"uploadMediaEphemeral\": [{\n \"template\": \"// Ephemeral media upload is not yet supported in the React SDK\"\n }],\n \"derivedPropertyNumericExpression\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkClient, useObjectSet } from \\\"@osdk/react/experimental\\\";\\nimport { useMemo } from \\\"react\\\";\\n\\nfunction {{objectType}}DerivedNumericExpression() {\\n const client = useOsdkClient();\\n const derivedSet = useMemo(() =>\\n client({{objectType}}).withProperties({\\n {{^isUnary}}\\n \\\"newPropertyName\\\": (baseObjectSet) =>\\n baseObjectSet.pivotTo(\\\"{{linkApiName}}\\\")\\n .aggregate(\\\"{{property}}\\\").{{operation}}(\\n baseObjectSet.pivotTo(\\\"{{linkApiName}}\\\").aggregate(\\\"$count\\\"))\\n {{/isUnary}}\\n {{#isUnary}}\\n \\\"{{operation}}_{{property}}\\\": (baseObjectSet) =>\\n baseObjectSet.pivotTo(\\\"{{linkApiName}}\\\")\\n .selectProperty(\\\"{{property}}\\\").{{operation}}()\\n {{/isUnary}}\\n }), [client]);\\n\\n const { data, isLoading, error } = useObjectSet(derivedSet);\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"derivedPropertyDatetimeExpression\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkClient, useObjectSet } from \\\"@osdk/react/experimental\\\";\\nimport { useMemo } from \\\"react\\\";\\n\\nfunction {{objectType}}DerivedDatetimeExpression() {\\n const client = useOsdkClient();\\n const derivedSet = useMemo(() =>\\n client({{objectType}}).withProperties({\\n {{^isExtractPart}}\\n \\\"derivedPropertyDatetime_{{operation}}\\\": (baseObjectSet) =>\\n baseObjectSet.pivotTo(\\\"{{linkApiName}}\\\")\\n .selectProperty(\\\"{{property}}\\\")\\n .{{operation}}(baseObjectSet.pivotTo(\\\"{{linkApiName}}\\\").selectProperty(\\\"{{property}}\\\"))\\n {{/isExtractPart}}\\n {{#isExtractPart}}\\n \\\"YEARS_part_of_{{property}}_of_{{linkApiName}}\\\": (baseObjectSet) =>\\n baseObjectSet.pivotTo(\\\"{{linkApiName}}\\\")\\n .selectProperty(\\\"{{property}}\\\").extractPart(\\\"YEARS\\\")\\n {{/isExtractPart}}\\n }), [client]);\\n\\n const { data, isLoading, error } = useObjectSet(derivedSet);\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"nearestNeighborsTextQuery\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkClient, useObjectSet } from \\\"@osdk/react/experimental\\\";\\nimport { useMemo } from \\\"react\\\";\\n\\nfunction {{objectType}}NearestNeighborsText() {\\n const client = useOsdkClient();\\n const resultSet = useMemo(() =>\\n client({{objectType}}).nearestNeighbors(\\\"coffee\\\", 5, \\\"{{property}}\\\"),\\n [client]);\\n\\n const { data, isLoading, error } = useObjectSet(resultSet);\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"nearestNeighborsVectorQuery\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkClient, useObjectSet } from \\\"@osdk/react/experimental\\\";\\nimport { useMemo } from \\\"react\\\";\\n\\nfunction {{objectType}}NearestNeighborsVector() {\\n const client = useOsdkClient();\\n // Note that this vector maps to an arbitrary string\\n // It must match the dimension of the \\\"{{property}}\\\" property: {{vectorDimensionSize}}\\n const vectorQuery = useMemo(() =>\\n Array.from({ length: {{vectorDimensionSize}} }, () => 0.3),\\n []);\\n const resultSet = useMemo(() =>\\n client({{objectType}}).nearestNeighbors(vectorQuery, 5, \\\"{{property}}\\\"),\\n [client, vectorQuery]);\\n\\n const { data, isLoading, error } = useObjectSet(resultSet);\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"searchAround\": [{\n \"template\": \"import { {{sourceObjectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkClient, useObjectSet } from \\\"@osdk/react/experimental\\\";\\nimport { useMemo } from \\\"react\\\";\\n\\nfunction SearchAround{{linkedObjectType}}() {\\n const client = useOsdkClient();\\n const linkedSet = useMemo(() =>\\n client({{sourceObjectType}})\\n .where({ {{rawLinkedPrimaryKeyProperty.apiName}}: { $in: [\\\"a\\\", \\\"b\\\", \\\"c\\\"] } })\\n .pivotTo(\\\"{{linkApiName}}\\\"),\\n [client]);\\n\\n const { data, isLoading, error } = useObjectSet(linkedSet);\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }]\n }\n }\n }\n};","/*\n * Copyright 2026 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 { snippets } from \"./generatedNoCheck/docsNoComputedVariables.js\";\nexport const REACT_OSDK_SNIPPETS = {\n ...snippets,\n computedVariables: {\n actionParameterSampleValuesV2: handleActionParameterSampleValuesV2,\n propertyValueV2: handlePropertyValueV2,\n primaryKeyPropertyV2: handlePrimaryKeyPropertyV2,\n linkedPrimaryKeyPropertyV2: handleLinkedPrimaryKeyPropertyV2\n }\n};\nfunction handleActionParameterSampleValuesV2({\n rawActionTypeParameterValues\n}) {\n if (rawActionTypeParameterValues == null) {\n throw new Error(\"Cannot render a null rawActionTypeParameterValues\");\n }\n return rawActionTypeParameterValues.map((param, index, array) => ({\n key: param.key,\n value: renderType(param.value),\n last: index === array.length - 1\n }));\n}\nfunction handlePropertyValueV2({\n rawPropertyValue\n}) {\n return renderPropertyValue(rawPropertyValue);\n}\nfunction handlePrimaryKeyPropertyV2({\n rawPrimaryKeyProperty\n}) {\n if (rawPrimaryKeyProperty == null) {\n throw new Error(\"Cannot render with null rawPrimaryKeyProperty\");\n }\n return {\n apiName: rawPrimaryKeyProperty.apiName,\n value: renderPropertyValue(rawPrimaryKeyProperty.value)\n };\n}\nfunction handleLinkedPrimaryKeyPropertyV2({\n rawLinkedPrimaryKeyProperty\n}) {\n if (rawLinkedPrimaryKeyProperty == null) {\n throw new Error(\"Cannot render with null rawLinkedPrimaryKeyProperty\");\n }\n return {\n apiName: rawLinkedPrimaryKeyProperty.apiName,\n value: renderPropertyValue(rawLinkedPrimaryKeyProperty.value),\n type: rawLinkedPrimaryKeyProperty.type\n };\n}\nfunction renderPropertyValue(propertyValue) {\n if (propertyValue == null) {\n throw new Error(\"Cannot render a null property value\");\n }\n return renderType(propertyValue);\n}\nfunction renderType(type) {\n if (type == null) {\n throw new Error(\"Cannot render a null type value\");\n }\n switch (type.type) {\n case \"array\":\n case \"set\":\n case \"list\":\n return `[${renderType(type.subtype)}]`;\n case \"boolean\":\n return type.value ? \"true\" : \"false\";\n case \"byte\":\n case \"integer\":\n case \"long\":\n case \"short\":\n return type.value.toString();\n case \"decimal\":\n case \"double\":\n case \"float\":\n return type.value.toString();\n case \"date\":\n {\n const offsetDate = new Date();\n offsetDate.setDate(offsetDate.getDate() + (type.daysOffset ?? 0));\n return `\"${offsetDate.toISOString().slice(0, 10)}\"`;\n }\n case \"timestamp\":\n {\n const offsetDate = new Date();\n offsetDate.setDate(offsetDate.getDate() + (type.daysOffset ?? 0));\n return `\"${offsetDate.toISOString()}\"`;\n }\n case \"object\":\n return `\"primaryKeyValue\" // or myObjectInstance`;\n case \"objectSet\":\n return `client(${type.objectTypeApiName}).where({ /* filter conditions */ })`;\n case \"anonymousCustomType\":\n case \"customType\":\n {\n const entries = Object.entries(type.parameters ?? {});\n if (entries.length > 0) {\n const rendered = entries.map(([name, value]) => `\"${name}\": ${renderType(value)}`).join(\", \");\n return `{ ${rendered} }`;\n }\n return \"{}\";\n }\n case \"interface\":\n case \"marking\":\n return \"{}\";\n case \"attachment\":\n return type.hasAttachments ? \"attachment\" : \"{}\";\n case \"mediaReference\":\n return \"mediaUpload\";\n case \"objectType\":\n return `\"${type.objectTypeApiName}\"`;\n case \"map\":\n return `{key: ${renderType(type.valueType)}}`;\n case \"string\":\n return `\"${type.value ?? \"value\"}\"`;\n case \"unknown\":\n default:\n return `\"value\"`;\n }\n}"]}
|
|
1
|
+
{"version":3,"sources":["../../src/generatedNoCheck/docsNoComputedVariables.ts","../../src/docs.ts"],"names":[],"mappings":";;;AAGO,IAAM,QAAA,GAAW;AAAA,EACtB,MAAA,EAAQ,KAAA;AAAA,EACR,UAAA,EAAY;AAAA,IACV,OAAA,EAAS;A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AK,CAAA,KAAM,CAAA,CAAA,EAAI,IAAI,MAAM,UAAA,CAAW,KAAK,CAAC,CAAA,CAAE,CAAA,CAAE,KAAK,IAAI,CAAA;AAC5F,QAAA,OAAO,KAAK,QAAQ,CAAA,EAAA,CAAA;AAAA,MACtB;AACA,MAAA,OAAO,IAAA;AAAA,IACT;AAAA,IACF,KAAK,WAAA;AAAA,IACL,KAAK,SAAA;AACH,MAAA,OAAO,IAAA;AAAA,IACT,KAAK,YAAA;AACH,MAAA,OAAO,IAAA,CAAK,iBAAiB,YAAA,GAAe,IAAA;AAAA,IAC9C,KAAK,gBAAA;AACH,MAAA,OAAO,aAAA;AAAA,IACT,KAAK,YAAA;AACH,MAAA,OAAO,CAAA,CAAA,EAAI,KAAK,iBAAiB,CAAA,CAAA,CAAA;AAAA,IACnC,KAAK,KAAA;AACH,MAAA,OAAO,CAAA,MAAA,EAAS,UAAA,CAAW,IAAA,CAAK,SAAS,CAAC,CAAA,CAAA,CAAA;AAAA,IAC5C,KAAK,QAAA;AACH,MAAA,OAAO,CAAA,CAAA,EAAI,IAAA,CAAK,KAAA,IAAS,OAAO,CAAA,CAAA,CAAA;AAAA,IAClC,KAAK,SAAA;AAAA,IACL;AACE,MAAA,OAAO,CAAA,OAAA,CAAA;AAAA;AAEb","file":"index.cjs","sourcesContent":["// THIS FILE IS GENERATED. DO NOT MODIFY.\n// You probably want to modify ../documentation.yml instead.\n\nexport const snippets = {\n \"kind\": \"sdk\",\n \"versions\": {\n \"2.0.0\": {\n \"snippets\": {\n \"reactProviderSetup\": [{\n \"template\": \"import { OsdkProvider2 } from \\\"@osdk/react/experimental\\\";\\nimport { createClient } from \\\"@osdk/client\\\";\\n\\nconst client = createClient(\\n \\\"https://your-stack.palantirfoundry.com\\\",\\n \\\"{{{packageName}}}\\\",\\n async () => \\\"your-token\\\"\\n);\\n\\nfunction App() {\\n return (\\n <OsdkProvider2 client={client}>\\n <YourApp />\\n </OsdkProvider2>\\n );\\n}\"\n }],\n \"reactUseOsdkObjectsBasic\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}List() {\\n const { data, isLoading, error, fetchMore } = useOsdkObjects({{objectType}});\\n\\n return (\\n <div>\\n {error && <div className=\\\"error-banner\\\">Error: {error.message}</div>}\\n {isLoading && !data && <div className=\\\"skeleton\\\">Loading...</div>}\\n <ul>\\n {data?.map(obj => (\\n <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>\\n ))}\\n </ul>\\n {isLoading && data && <span className=\\\"refresh-indicator\\\">Refreshing...</span>}\\n {fetchMore && <button onClick={fetchMore}>Load more</button>}\\n </div>\\n );\\n}\"\n }],\n \"reactUseOsdkObjectsFilter\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction Filtered{{objectType}}List() {\\n const { data, isLoading, error } = useOsdkObjects({{objectType}}, {\\n where: {\\n {{titleProperty}}: { $isNotNull: true }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div className=\\\"error-banner\\\">Error: {error.message}</div>}\\n {isLoading && !data && <div className=\\\"skeleton\\\">Loading...</div>}\\n <ul>\\n {data?.map(obj => (\\n <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>\\n ))}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"reactUseOsdkObjectByPrimaryKey\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObject } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}Detail({ primaryKey }: { primaryKey: string }) {\\n const { object, isLoading, error } = useOsdkObject({{objectType}}, primaryKey);\\n\\n return (\\n <div>\\n {error && <div className=\\\"error-banner\\\">Error: {error.message}</div>}\\n {isLoading && !object && <div className=\\\"skeleton\\\">Loading...</div>}\\n {object && (\\n <div>\\n <h2>{object.{{titleProperty}}}</h2>\\n </div>\\n )}\\n </div>\\n );\\n}\"\n }],\n \"reactUseLinksBasic\": [{\n \"template\": \"import { {{sourceObjectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useLinks } from \\\"@osdk/react/experimental\\\";\\n\\nfunction Linked{{linkedObjectType}}({ source }: { source: {{sourceObjectType}}.OsdkInstance }) {\\n const { links, isLoading, error } = useLinks(source, \\\"{{linkApiName}}\\\");\\n\\n return (\\n <div>\\n {error && <div className=\\\"error-banner\\\">Error: {error.message}</div>}\\n {isLoading && !links && <div className=\\\"skeleton\\\">Loading...</div>}\\n <ul>\\n {links?.map(linked => (\\n <li key={linked.$primaryKey}>{linked.$primaryKey}</li>\\n ))}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"reactUseOsdkActionBasic\": [{\n \"template\": \"import { {{actionApiName}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkAction } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{actionApiName}}Button() {\\n const { applyAction, isPending, error } = useOsdkAction({{actionApiName}});\\n\\n const handleClick = async () => {\\n await applyAction({\\n {{#actionParameterSampleValuesV2}}\\n {{key}}: {{value}}{{^last}},{{/last}}\\n {{/actionParameterSampleValuesV2}}\\n });\\n };\\n\\n return (\\n <div>\\n {error && <div className=\\\"error-banner\\\">Error: {String(error.unknown ?? error.actionValidation)}</div>}\\n <button onClick={handleClick} disabled={isPending}>\\n {isPending ? \\\"Applying...\\\" : \\\"Apply {{actionApiName}}\\\"}\\n </button>\\n </div>\\n );\\n}\",\n \"computedVariables\": [\"actionParameterSampleValuesV2\"]\n }],\n \"reactUseOsdkAggregationBasic\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkAggregation } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}Count() {\\n const { data, isLoading, error } = useOsdkAggregation({{objectType}}, {\\n aggregate: { $select: { $count: \\\"unordered\\\" } }\\n });\\n\\n return (\\n <div>\\n {error && <div className=\\\"error-banner\\\">Error: {error.message}</div>}\\n {isLoading && data == null && <div className=\\\"skeleton\\\">Loading...</div>}\\n {data != null && <span>Total: {data}</span>}\\n </div>\\n );\\n}\"\n }],\n \"reactUseOsdkObjectsEnabled\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction Conditional{{objectType}}List({ shouldFetch }: { shouldFetch: boolean }) {\\n const { data, isLoading, error } = useOsdkObjects({{objectType}}, {\\n enabled: shouldFetch\\n });\\n\\n return (\\n <div>\\n {!shouldFetch && <div>Select criteria to load data</div>}\\n {error && <div className=\\\"error-banner\\\">Error: {error.message}</div>}\\n {isLoading && !data && <div className=\\\"skeleton\\\">Loading...</div>}\\n <ul>\\n {data?.map(obj => (\\n <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>\\n ))}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"loadSingleObjectGuide\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObject } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}Detail({ primaryKey }: { primaryKey: string }) {\\n const { object, isLoading, error } = useOsdkObject({{objectType}}, primaryKey);\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !object && <div>Loading...</div>}\\n {object && <div>{object.{{titleProperty}}}</div>}\\n </div>\\n );\\n}\"\n }],\n \"loadObjectPageGuide\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}List() {\\n const { data, isLoading, error, fetchMore } = useOsdkObjects({{objectType}}, {\\n pageSize: 30\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>)}\\n </ul>\\n {fetchMore && <button onClick={fetchMore}>Load more</button>}\\n </div>\\n );\\n}\"\n }],\n \"orderObjectsGuide\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction Sorted{{objectType}}List() {\\n const { data, isLoading, error } = useOsdkObjects({{objectType}}, {\\n orderBy: { {{titleProperty}}: \\\"asc\\\" }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"searchObjectsGuide\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction Filtered{{objectType}}List() {\\n const { data, isLoading, error } = useOsdkObjects({{objectType}}, {\\n where: {\\n {{titleProperty}}: { $isNotNull: true }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"loadSingleObjectReference\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObject } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}Detail({ primaryKey }: { primaryKey: string }) {\\n const { object, isLoading, error } = useOsdkObject({{objectType}}, primaryKey);\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !object && <div>Loading...</div>}\\n {object && <div>{object.{{titleProperty}}}</div>}\\n </div>\\n );\\n}\"\n }],\n \"loadObjectsReference\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}List() {\\n const { data, isLoading, error, fetchMore } = useOsdkObjects({{objectType}}, {\\n pageSize: 30\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>)}\\n </ul>\\n {fetchMore && <button onClick={fetchMore}>Load more</button>}\\n </div>\\n );\\n}\"\n }],\n \"loadAllObjectsReference\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\n// Note: For large datasets, consider using pagination with fetchMore\\nfunction All{{objectType}}List() {\\n const { data, isLoading, error, fetchMore } = useOsdkObjects({{objectType}});\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>)}\\n </ul>\\n {fetchMore && <button onClick={fetchMore}>Load more</button>}\\n </div>\\n );\\n}\"\n }],\n \"loadLinkedObjectReference\": [{\n \"template\": \"import { {{sourceObjectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useLinks } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{linkedObjectType}}Detail({ source }: { source: {{sourceObjectType}}.OsdkInstance }) {\\n const { links, isLoading, error } = useLinks(source, \\\"{{linkApiName}}\\\");\\n const linkedObject = links?.[0];\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !links && <div>Loading...</div>}\\n {linkedObject && <div>{linkedObject.$primaryKey}</div>}\\n </div>\\n );\\n}\"\n }],\n \"loadLinkedObjectsReference\": [{\n \"template\": \"import { {{sourceObjectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useLinks } from \\\"@osdk/react/experimental\\\";\\n\\nfunction Linked{{linkedObjectType}}List({ source }: { source: {{sourceObjectType}}.OsdkInstance }) {\\n const { links, isLoading, error, fetchMore } = useLinks(source, \\\"{{linkApiName}}\\\");\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !links && <div>Loading...</div>}\\n <ul>\\n {links?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n {fetchMore && <button onClick={fetchMore}>Load more</button>}\\n </div>\\n );\\n}\"\n }],\n \"aggregationTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkAggregation } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}Aggregation() {\\n const { data, isLoading, error } = useOsdkAggregation({{objectType}}, {\\n where: { {{property}}: { $isNull: false } },\\n aggregate: {\\n $select: { $count: \\\"unordered\\\" },\\n $groupBy: { {{property}}: \\\"exact\\\" }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && data == null && <div>Loading...</div>}\\n {data != null && <pre>{JSON.stringify(data, null, 2)}</pre>}\\n </div>\\n );\\n}\"\n }],\n \"countAggregationTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkAggregation } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}Count() {\\n const { data, isLoading, error } = useOsdkAggregation({{objectType}}, {\\n aggregate: { $select: { $count: \\\"unordered\\\" } }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && data == null && <div>Loading...</div>}\\n {data != null && <span>Total: {data}</span>}\\n </div>\\n );\\n}\"\n }],\n \"approximateDistinctAggregationTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkAggregation } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}DistinctCount() {\\n const { data, isLoading, error } = useOsdkAggregation({{objectType}}, {\\n aggregate: { $select: { \\\"{{property}}:approximateDistinct\\\": \\\"unordered\\\" } }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && data == null && <div>Loading...</div>}\\n {data != null && <span>Distinct count: {data}</span>}\\n </div>\\n );\\n}\"\n }],\n \"exactDistinctAggregationTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkAggregation } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}ExactDistinctCount() {\\n const { data, isLoading, error } = useOsdkAggregation({{objectType}}, {\\n aggregate: { $select: { \\\"{{property}}:exactDistinct\\\": \\\"unordered\\\" } }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && data == null && <div>Loading...</div>}\\n {data != null && <span>Exact distinct count: {data}</span>}\\n </div>\\n );\\n}\"\n }],\n \"numericAggregationTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkAggregation } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}{{operation}}() {\\n const { data, isLoading, error } = useOsdkAggregation({{objectType}}, {\\n aggregate: { $select: { \\\"{{property}}:{{operation}}\\\": \\\"unordered\\\" } }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && data == null && <div>Loading...</div>}\\n {data != null && <span>{{operation}}: {data}</span>}\\n </div>\\n );\\n}\"\n }],\n \"fixedWidthGroupByTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkAggregation } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}GroupedByFixedWidth() {\\n const { data, isLoading, error } = useOsdkAggregation({{objectType}}, {\\n aggregate: {\\n $select: { $count: \\\"unordered\\\" },\\n $groupBy: { {{property}}: { $fixedWidth: 10 } }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && data == null && <div>Loading...</div>}\\n {data != null && <pre>{JSON.stringify(data, null, 2)}</pre>}\\n </div>\\n );\\n}\"\n }],\n \"durationGroupByTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkAggregation } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}GroupedByDuration() {\\n const { data, isLoading, error } = useOsdkAggregation({{objectType}}, {\\n aggregate: {\\n $select: { $count: \\\"unordered\\\" },\\n $groupBy: { {{property}}: { $duration: [{{#durationText}}{{arg}}{{/durationText}}, \\\"{{#durationText}}{{unit}}{{/durationText}}\\\"] } }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && data == null && <div>Loading...</div>}\\n {data != null && <pre>{JSON.stringify(data, null, 2)}</pre>}\\n </div>\\n );\\n}\"\n }],\n \"exactGroupByTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkAggregation } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}GroupedByExact() {\\n const { data, isLoading, error } = useOsdkAggregation({{objectType}}, {\\n aggregate: {\\n $select: { $count: \\\"unordered\\\" },\\n $groupBy: { {{property}}: \\\"exact\\\" }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && data == null && <div>Loading...</div>}\\n {data != null && <pre>{JSON.stringify(data, null, 2)}</pre>}\\n </div>\\n );\\n}\"\n }],\n \"rangeGroupByTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkAggregation } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}GroupedByRange() {\\n const { data, isLoading, error } = useOsdkAggregation({{objectType}}, {\\n aggregate: {\\n $select: { $count: \\\"unordered\\\" },\\n $groupBy: { {{property}}: { $ranges: [[{{{propertyValueV2}}}, {{{propertyValueV2}}}]] } }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && data == null && <div>Loading...</div>}\\n {data != null && <pre>{JSON.stringify(data, null, 2)}</pre>}\\n </div>\\n );\\n}\",\n \"computedVariables\": [\"propertyValueV2\"]\n }],\n \"applyAction\": [{\n \"template\": \"import { {{actionApiName}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkAction } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{actionApiName}}Button() {\\n const { applyAction, isPending, error } = useOsdkAction({{actionApiName}});\\n\\n const handleClick = async () => {\\n await applyAction({\\n {{#actionParameterSampleValuesV2}}\\n {{key}}: {{value}}{{^last}},{{/last}}\\n {{/actionParameterSampleValuesV2}}\\n });\\n };\\n\\n return (\\n <div>\\n {error && <div>Error: {String(error.unknown ?? error.actionValidation)}</div>}\\n <button onClick={handleClick} disabled={isPending}>\\n {isPending ? \\\"Applying...\\\" : \\\"Apply\\\"}\\n </button>\\n </div>\\n );\\n}\",\n \"computedVariables\": [\"actionParameterSampleValuesV2\"]\n }],\n \"applyActionResponse\": [{\n \"template\": \"import { {{actionApiName}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkAction } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{actionApiName}}WithResult() {\\n const { applyAction, isPending, error, data } = useOsdkAction({{actionApiName}});\\n\\n const handleClick = async () => {\\n await applyAction({\\n {{#actionParameterSampleValuesV2}}\\n {{key}}: {{value}}{{^last}},{{/last}}\\n {{/actionParameterSampleValuesV2}}\\n });\\n };\\n\\n return (\\n <div>\\n {error && <div className=\\\"error-banner\\\">Error: {String(error.unknown ?? error.actionValidation)}</div>}\\n {data && <div>Action completed successfully</div>}\\n <button onClick={handleClick} disabled={isPending}>\\n {isPending ? \\\"Applying...\\\" : \\\"Apply {{actionApiName}}\\\"}\\n </button>\\n </div>\\n );\\n}\",\n \"computedVariables\": [\"actionParameterSampleValuesV2\"]\n }],\n \"validateAction\": [{\n \"template\": \"import { {{actionApiName}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkAction, useDebouncedCallback } from \\\"@osdk/react/experimental\\\";\\nimport { useState } from \\\"react\\\";\\n\\nfunction {{actionApiName}}WithValidation() {\\n const { validateAction, applyAction, isPending, validationResult } = useOsdkAction({{actionApiName}});\\n const [params, setParams] = useState<Record<string, string>>({});\\n\\n const debouncedValidate = useDebouncedCallback(\\n (nextParams: Record<string, string>) => { validateAction(nextParams); },\\n 300\\n );\\n\\n const handleParamChange = (key: string, value: string) => {\\n const nextParams = { ...params, [key]: value };\\n setParams(nextParams);\\n debouncedValidate(nextParams);\\n };\\n\\n return (\\n <div>\\n <input\\n placeholder=\\\"Parameter value\\\"\\n onChange={(e) => handleParamChange(\\\"paramName\\\", e.target.value)}\\n />\\n {validationResult?.result === \\\"INVALID\\\" && (\\n <div>Validation errors present</div>\\n )}\\n <button\\n onClick={() => applyAction(params)}\\n disabled={isPending || validationResult?.result === \\\"INVALID\\\"}\\n >\\n {isPending ? \\\"Applying...\\\" : \\\"Apply\\\"}\\n </button>\\n </div>\\n );\\n}\"\n }],\n \"batchApplyAction\": [{\n \"template\": \"// Batch actions in React should be handled with multiple hook calls\\n// or by using the client directly for batch operations\\nimport { {{actionApiName}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkAction } from \\\"@osdk/react/experimental\\\";\\n\\nfunction Batch{{actionApiName}}() {\\n const { applyAction, isPending } = useOsdkAction({{actionApiName}});\\n\\n const handleBatchApply = async (items: Array<Parameters<typeof applyAction>[0]>) => {\\n await Promise.all(items.map(item => applyAction(item)));\\n };\\n\\n return (\\n <button onClick={() => handleBatchApply([])} disabled={isPending}>\\n Apply Batch\\n </button>\\n );\\n}\"\n }],\n \"clientSetup\": [{\n \"template\": \"import { OsdkProvider2 } from \\\"@osdk/react/experimental\\\";\\nimport { createClient } from \\\"@osdk/client\\\";\\n\\nconst client = createClient(\\n \\\"https://your-stack.palantirfoundry.com\\\",\\n \\\"{{{packageName}}}\\\",\\n async () => \\\"your-token\\\"\\n);\\n\\nfunction App() {\\n return (\\n <OsdkProvider2 client={client}>\\n <YourApp />\\n </OsdkProvider2>\\n );\\n}\"\n }],\n \"callFunction\": [{\n \"template\": \"import { {{funcApiName}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkFunction } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{funcApiName}}Caller() {\\n const { data, isLoading, error, refetch } = useOsdkFunction({{funcApiName}}, {\\n params: { /* function parameters */ }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n {data && <pre>{JSON.stringify(data, null, 2)}</pre>}\\n <button onClick={refetch}>Refresh</button>\\n </div>\\n );\\n}\"\n }],\n \"executeFunction\": [{\n \"template\": \"import { {{funcApiName}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkFunction } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{funcApiName}}Executor() {\\n const { data, isLoading, error, refetch } = useOsdkFunction({{funcApiName}}, {\\n params: { /* function parameters */ }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n {data && <pre>{JSON.stringify(data, null, 2)}</pre>}\\n <button onClick={refetch}>Refresh</button>\\n </div>\\n );\\n}\"\n }],\n \"stringStartsWithTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}StartsWith() {\\n const { data, isLoading, error } = useOsdkObjects({{objectType}}, {\\n where: {\\n {{property}}: { $startsWith: \\\"foo\\\" }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"containsAnyTermTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}ContainsAnyTerm() {\\n const { data, isLoading, error } = useOsdkObjects({{objectType}}, {\\n where: {\\n {{property}}: { $containsAnyTerm: \\\"foo bar\\\" }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"containsAllTermsTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}ContainsAllTerms() {\\n const { data, isLoading, error } = useOsdkObjects({{objectType}}, {\\n where: {\\n {{property}}: { $containsAllTerms: \\\"foo bar\\\" }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"containsAllTermsInOrderTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}ContainsAllTermsInOrder() {\\n const { data, isLoading, error } = useOsdkObjects({{objectType}}, {\\n where: {\\n {{property}}: { $containsAllTermsInOrder: \\\"foo bar\\\" }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"containsTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}Contains() {\\n const { data, isLoading, error } = useOsdkObjects({{objectType}}, {\\n where: {\\n {{property}}: { $contains: \\\"value\\\" }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"equalityTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}Equality() {\\n const { data, isLoading, error } = useOsdkObjects({{objectType}}, {\\n where: {\\n {{property}}: { $eq: {{{propertyValueV2}}} }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>)}\\n </ul>\\n </div>\\n );\\n}\",\n \"computedVariables\": [\"propertyValueV2\"]\n }],\n \"inFilterTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}InFilter() {\\n const { data, isLoading, error } = useOsdkObjects({{objectType}}, {\\n where: {\\n {{property}}: { $in: [{{{propertyValueV2}}}] }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>)}\\n </ul>\\n </div>\\n );\\n}\",\n \"computedVariables\": [\"propertyValueV2\"]\n }],\n \"rangeTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}Range() {\\n const { data, isLoading, error } = useOsdkObjects({{objectType}}, {\\n where: {\\n {{property}}: { ${{operation}}: {{{propertyValueV2}}} }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>)}\\n </ul>\\n </div>\\n );\\n}\",\n \"computedVariables\": [\"propertyValueV2\"]\n }],\n \"nullTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}NullFilter() {\\n const { data, isLoading, error } = useOsdkObjects({{objectType}}, {\\n where: {\\n {{property}}: { $isNull: true }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"andTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}AndFilter() {\\n const { data, isLoading, error } = useOsdkObjects({{objectType}}, {\\n where: {\\n $and: [\\n { $not: { {{primaryKeyPropertyV2.apiName}}: { $isNull: true } } },\\n { {{property}}: { $eq: {{{propertyValueV2}}} } }\\n ]\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>)}\\n </ul>\\n </div>\\n );\\n}\",\n \"computedVariables\": [\"primaryKeyPropertyV2\", \"propertyValueV2\"]\n }],\n \"orTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}OrFilter() {\\n const { data, isLoading, error } = useOsdkObjects({{objectType}}, {\\n where: {\\n $or: [\\n { $not: { {{primaryKeyPropertyV2.apiName}}: { $isNull: true } } },\\n { {{property}}: { $eq: {{{propertyValueV2}}} } }\\n ]\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>)}\\n </ul>\\n </div>\\n );\\n}\",\n \"computedVariables\": [\"primaryKeyPropertyV2\", \"propertyValueV2\"]\n }],\n \"notTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}NotFilter() {\\n const { data, isLoading, error } = useOsdkObjects({{objectType}}, {\\n where: {\\n $not: { {{property}}: { $eq: {{{propertyValueV2}}} } }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>)}\\n </ul>\\n </div>\\n );\\n}\",\n \"computedVariables\": [\"propertyValueV2\"]\n }],\n \"withinDistanceTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}WithinDistance() {\\n const { data, isLoading, error } = useOsdkObjects({{objectType}}, {\\n where: {\\n {{property}}: { $within: { $distance: [100, \\\"{{distanceUnit}}\\\"], $of: [-74.0060, 40.7128] } }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"withinBoundingBoxTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}WithinBoundingBox() {\\n const { data, isLoading, error } = useOsdkObjects({{objectType}}, {\\n where: {\\n {{property}}: { $within: { $bbox: [-74.0060, 25.123, 80.4231, 40.7128] } }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"withinPolygonTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}WithinPolygon() {\\n const { data, isLoading, error } = useOsdkObjects({{objectType}}, {\\n where: {\\n {{property}}: { $within: { type: \\\"Polygon\\\", coordinates: [[[10.0, 40.0], [20.0, 50.0], [20.0, 30.0], [10.0, 40.0]]] } }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"intersectsPolygonTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}IntersectsPolygon() {\\n const { data, isLoading, error } = useOsdkObjects({{objectType}}, {\\n where: {\\n {{property}}: { $intersects: { type: \\\"Polygon\\\", coordinates: [[[10.0, 40.0], [20.0, 50.0], [20.0, 30.0], [10.0, 40.0]]] } }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"intersectsBboxTemplate\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}IntersectsBbox() {\\n const { data, isLoading, error } = useOsdkObjects({{objectType}}, {\\n where: {\\n {{property}}: { $intersects: { $bbox: [-74.0060, 25.123, 80.4231, 40.7128] } }\\n }\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"objectSetOperationsGuide\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkClient, useObjectSet } from \\\"@osdk/react/experimental\\\";\\nimport { useMemo } from \\\"react\\\";\\n\\nfunction {{objectType}}SetOperations() {\\n const client = useOsdkClient();\\n const combinedSet = useMemo(() => {\\n const setA = client({{objectType}}).where({ {{titleProperty}}: { $containsAnyTerm: \\\"a\\\" } });\\n const setB = client({{objectType}}).where({ {{titleProperty}}: { $containsAnyTerm: \\\"b\\\" } });\\n const setC = client({{objectType}}).where({ {{titleProperty}}: { $containsAnyTerm: \\\"c\\\" } });\\n return setA.intersect(setB).subtract(setC);\\n }, [client]);\\n\\n const { data, isLoading, error } = useObjectSet(combinedSet);\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"objectSetOperationsUnion\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkClient, useObjectSet } from \\\"@osdk/react/experimental\\\";\\nimport { useMemo } from \\\"react\\\";\\n\\nfunction {{objectType}}Union() {\\n const client = useOsdkClient();\\n const unionSet = useMemo(() => {\\n const setA = client({{objectType}}).where({ {{titleProperty}}: { $containsAnyTerm: \\\"a\\\" } });\\n const setB = client({{objectType}}).where({ {{titleProperty}}: { $containsAnyTerm: \\\"b\\\" } });\\n const setC = client({{objectType}}).where({ {{titleProperty}}: { $containsAnyTerm: \\\"c\\\" } });\\n return setA.union(setB).union(setC);\\n }, [client]);\\n\\n const { data, isLoading, error } = useObjectSet(unionSet);\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"objectSetOperationsSubtract\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkClient, useObjectSet } from \\\"@osdk/react/experimental\\\";\\nimport { useMemo } from \\\"react\\\";\\n\\nfunction {{objectType}}Subtract() {\\n const client = useOsdkClient();\\n const subtractedSet = useMemo(() => {\\n const setA = client({{objectType}}).where({ {{titleProperty}}: { $containsAnyTerm: \\\"a\\\" } });\\n const setB = client({{objectType}}).where({ {{titleProperty}}: { $containsAnyTerm: \\\"b\\\" } });\\n const setC = client({{objectType}}).where({ {{titleProperty}}: { $containsAnyTerm: \\\"c\\\" } });\\n return setA.subtract(setB).subtract(setC);\\n }, [client]);\\n\\n const { data, isLoading, error } = useObjectSet(subtractedSet);\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"objectSetOperationsIntersect\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkClient, useObjectSet } from \\\"@osdk/react/experimental\\\";\\nimport { useMemo } from \\\"react\\\";\\n\\nfunction {{objectType}}Intersect() {\\n const client = useOsdkClient();\\n const intersectedSet = useMemo(() => {\\n const setA = client({{objectType}}).where({ {{titleProperty}}: { $containsAnyTerm: \\\"a\\\" } });\\n const setB = client({{objectType}}).where({ {{titleProperty}}: { $containsAnyTerm: \\\"b\\\" } });\\n const setC = client({{objectType}}).where({ {{titleProperty}}: { $containsAnyTerm: \\\"c\\\" } });\\n return setA.intersect(setB).intersect(setC);\\n }, [client]);\\n\\n const { data, isLoading, error } = useObjectSet(intersectedSet);\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.{{titleProperty}}}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"derivedPropertyBaseExample\": [{\n \"template\": \"import { {{sourceObjectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkClient, useObjectSet } from \\\"@osdk/react/experimental\\\";\\nimport { useMemo } from \\\"react\\\";\\n\\nfunction {{sourceObjectType}}DerivedProperty() {\\n const client = useOsdkClient();\\n const derivedSet = useMemo(() =>\\n client({{sourceObjectType}}).withProperties({\\n \\\"newPropertyName\\\": (baseObjectSet) =>\\n baseObjectSet.pivotTo(\\\"{{linkApiName}}\\\").aggregate(\\\"$count\\\")\\n }), [client]);\\n\\n const { data, isLoading, error } = useObjectSet(derivedSet);\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"derivedPropertyCountAggregation\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkClient, useObjectSet } from \\\"@osdk/react/experimental\\\";\\nimport { useMemo } from \\\"react\\\";\\n\\nfunction {{objectType}}DerivedCount() {\\n const client = useOsdkClient();\\n const derivedSet = useMemo(() =>\\n client({{objectType}}).withProperties({\\n \\\"newPropertyName\\\": (baseObjectSet) =>\\n baseObjectSet.pivotTo(\\\"{{linkApiName}}\\\").aggregate(\\\"$count\\\")\\n }), [client]);\\n\\n const { data, isLoading, error } = useObjectSet(derivedSet);\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"derivedPropertyNumericAggregation\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkClient, useObjectSet } from \\\"@osdk/react/experimental\\\";\\nimport { useMemo } from \\\"react\\\";\\n\\nfunction {{objectType}}DerivedNumeric() {\\n const client = useOsdkClient();\\n const derivedSet = useMemo(() =>\\n client({{objectType}}).withProperties({\\n \\\"newPropertyName\\\": (baseObjectSet) =>\\n baseObjectSet.pivotTo(\\\"{{linkApiName}}\\\").aggregate(\\\"{{property}}:{{operation}}\\\")\\n }), [client]);\\n\\n const { data, isLoading, error } = useObjectSet(derivedSet);\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"derivedPropertySelectPropertyAggregation\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkClient, useObjectSet } from \\\"@osdk/react/experimental\\\";\\nimport { useMemo } from \\\"react\\\";\\n\\nfunction {{objectType}}DerivedSelectProperty() {\\n const client = useOsdkClient();\\n const derivedSet = useMemo(() =>\\n client({{objectType}}).withProperties({\\n \\\"newPropertyName\\\": (baseObjectSet) =>\\n baseObjectSet.pivotTo(\\\"{{linkApiName}}\\\").selectProperty(\\\"{{property}}\\\")\\n }), [client]);\\n\\n const { data, isLoading, error } = useObjectSet(derivedSet);\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"derivedPropertyApproximateDistinctAggregation\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkClient, useObjectSet } from \\\"@osdk/react/experimental\\\";\\nimport { useMemo } from \\\"react\\\";\\n\\nfunction {{objectType}}DerivedApproxDistinct() {\\n const client = useOsdkClient();\\n const derivedSet = useMemo(() =>\\n client({{objectType}}).withProperties({\\n \\\"newPropertyName\\\": (baseObjectSet) =>\\n baseObjectSet.pivotTo(\\\"{{linkApiName}}\\\").aggregate(\\\"{{property}}:approximateDistinct\\\")\\n }), [client]);\\n\\n const { data, isLoading, error } = useObjectSet(derivedSet);\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"derivedPropertyExactDistinctAggregation\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkClient, useObjectSet } from \\\"@osdk/react/experimental\\\";\\nimport { useMemo } from \\\"react\\\";\\n\\nfunction {{objectType}}DerivedExactDistinct() {\\n const client = useOsdkClient();\\n const derivedSet = useMemo(() =>\\n client({{objectType}}).withProperties({\\n \\\"newPropertyName\\\": (baseObjectSet) =>\\n baseObjectSet.pivotTo(\\\"{{linkApiName}}\\\").aggregate(\\\"{{property}}:exactDistinct\\\")\\n }), [client]);\\n\\n const { data, isLoading, error } = useObjectSet(derivedSet);\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"derivedPropertyApproximatePercentileAggregation\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkClient, useObjectSet } from \\\"@osdk/react/experimental\\\";\\nimport { useMemo } from \\\"react\\\";\\n\\nfunction {{objectType}}DerivedPercentile() {\\n const client = useOsdkClient();\\n const derivedSet = useMemo(() =>\\n client({{objectType}}).withProperties({\\n \\\"newPropertyName\\\": (baseObjectSet) =>\\n baseObjectSet.pivotTo(\\\"{{linkApiName}}\\\").aggregate(\\\"{{property}}:approximatePercentile\\\", { percentile: 95 })\\n }), [client]);\\n\\n const { data, isLoading, error } = useObjectSet(derivedSet);\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"derivedPropertyCollectToListAggregation\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkClient, useObjectSet } from \\\"@osdk/react/experimental\\\";\\nimport { useMemo } from \\\"react\\\";\\n\\nfunction {{objectType}}DerivedCollectList() {\\n const client = useOsdkClient();\\n const maxObjectsInList = 75;\\n const derivedSet = useMemo(() =>\\n client({{objectType}}).withProperties({\\n \\\"newPropertyName\\\": (baseObjectSet) =>\\n baseObjectSet.pivotTo(\\\"{{linkApiName}}\\\").aggregate(\\\"{{property}}:collectList\\\", { limit: maxObjectsInList })\\n }), [client]);\\n\\n const { data, isLoading, error } = useObjectSet(derivedSet);\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"derivedPropertyCollectToSetAggregation\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkClient, useObjectSet } from \\\"@osdk/react/experimental\\\";\\nimport { useMemo } from \\\"react\\\";\\n\\nfunction {{objectType}}DerivedCollectSet() {\\n const client = useOsdkClient();\\n const maxObjectsInSet = 75;\\n const derivedSet = useMemo(() =>\\n client({{objectType}}).withProperties({\\n \\\"newPropertyName\\\": (baseObjectSet) =>\\n baseObjectSet.pivotTo(\\\"{{linkApiName}}\\\").aggregate(\\\"{{property}}:collectSet\\\", { limit: maxObjectsInSet })\\n }), [client]);\\n\\n const { data, isLoading, error } = useObjectSet(derivedSet);\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"loadObjectMetadataSnippet\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkMetadata } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectType}}Metadata() {\\n const { loading, metadata, error } = useOsdkMetadata({{objectType}});\\n\\n return (\\n <div>\\n {error && <div className=\\\"error-banner\\\">Error: {error}</div>}\\n {loading && !metadata && <div className=\\\"skeleton\\\">Loading...</div>}\\n {metadata && (\\n <div>\\n <div>Description: {metadata.description}</div>\\n <div>Visibility: {metadata.visibility}</div>\\n </div>\\n )}\\n </div>\\n );\\n}\"\n }],\n \"loadInterfaceMetadataSnippet\": [{\n \"template\": \"import { {{interfaceApiName}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkMetadata } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{interfaceApiName}}Metadata() {\\n const { loading, metadata, error } = useOsdkMetadata({{interfaceApiName}});\\n\\n return (\\n <div>\\n {error && <div className=\\\"error-banner\\\">Error: {error}</div>}\\n {loading && !metadata && <div className=\\\"skeleton\\\">Loading...</div>}\\n {metadata && (\\n <div>\\n <div>RID: {metadata.rid}</div>\\n <div>Implemented by: {metadata.implementedBy?.join(\\\", \\\")}</div>\\n </div>\\n )}\\n </div>\\n );\\n}\"\n }],\n \"loadInterfacesReference\": [{\n \"template\": \"import { {{interfaceApiName}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{interfaceApiName}}List() {\\n const { data, isLoading, error, fetchMore } = useOsdkObjects({{interfaceApiName}}, {\\n pageSize: 30\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n {fetchMore && <button onClick={fetchMore}>Load more</button>}\\n </div>\\n );\\n}\"\n }],\n \"loadAllInterfacesReference\": [{\n \"template\": \"import { {{interfaceApiName}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction All{{interfaceApiName}}List() {\\n const { data, isLoading, error, fetchMore } = useOsdkObjects({{interfaceApiName}});\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n {fetchMore && <button onClick={fetchMore}>Load more</button>}\\n </div>\\n );\\n}\"\n }],\n \"loadOrderedInterfacesReference\": [{\n \"template\": \"import { {{interfaceApiName}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction Ordered{{interfaceApiName}}List() {\\n const { data, isLoading, error } = useOsdkObjects({{interfaceApiName}}, {\\n orderBy: { {{property}}: \\\"asc\\\" },\\n pageSize: 30\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"searchInterfacesReference\": [{\n \"template\": \"import { {{interfaceApiName}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction Search{{interfaceApiName}}() {\\n const { data, isLoading, error } = useOsdkObjects({{interfaceApiName}}, {\\n where: {\\n {{property}}: { $startsWith: \\\"foo\\\" }\\n },\\n pageSize: 30\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"castInterfaceToObjectReference\": [{\n \"template\": \"import { {{objectTypeApiName}}, {{interfaceApiName}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction CastInterface() {\\n const { data, isLoading, error } = useOsdkObjects({{interfaceApiName}}, {\\n pageSize: 10\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => {\\n const casted = obj.$as({{objectTypeApiName}});\\n return <li key={casted.$primaryKey}>{casted.$primaryKey}</li>;\\n })}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"subscribeToObjectSetInstructions\": [{\n \"template\": \"import { {{objectOrInterfaceApiName}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkObjects } from \\\"@osdk/react/experimental\\\";\\n\\nfunction {{objectOrInterfaceApiName}}LiveList() {\\n const { data, isLoading, error } = useOsdkObjects({{objectOrInterfaceApiName}}, {\\n streamUpdates: true\\n });\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"loadTimeSeriesPointsSnippet\": [{\n \"template\": \"// Timeseries does not have a dedicated React hook yet.\\n// Use the client API directly with a loaded OSDK object.\\nimport type { Osdk } from \\\"@osdk/client\\\";\\nimport type { {{objectType}} } from \\\"{{{packageName}}}\\\";\\n\\nasync function getAllTimeSeriesPoints(obj: Osdk.Instance<typeof {{objectType}}>) {\\n return obj.{{property}}?.getAllPoints();\\n}\"\n }],\n \"loadTimeSeriesFirstPointSnippet\": [{\n \"template\": \"// Timeseries does not have a dedicated React hook yet.\\n// Use the client API directly with a loaded OSDK object.\\nimport type { Osdk } from \\\"@osdk/client\\\";\\nimport type { {{objectType}} } from \\\"{{{packageName}}}\\\";\\n\\nasync function getFirstTimeSeriesPoint(obj: Osdk.Instance<typeof {{objectType}}>) {\\n return obj.{{property}}?.getFirstPoint();\\n}\"\n }],\n \"loadTimeSeriesLastPointSnippet\": [{\n \"template\": \"// Timeseries does not have a dedicated React hook yet.\\n// Use the client API directly with a loaded OSDK object.\\nimport type { Osdk } from \\\"@osdk/client\\\";\\nimport type { {{objectType}} } from \\\"{{{packageName}}}\\\";\\n\\nasync function getLastTimeSeriesPoint(obj: Osdk.Instance<typeof {{objectType}}>) {\\n return obj.{{property}}?.getLastPoint();\\n}\"\n }],\n \"loadAbsoluteTimeSeriesPointsSnippet\": [{\n \"template\": \"// Timeseries does not have a dedicated React hook yet.\\n// Use the client API directly with a loaded OSDK object.\\nimport type { Osdk } from \\\"@osdk/client\\\";\\nimport type { {{objectType}} } from \\\"{{{packageName}}}\\\";\\n\\nasync function getAbsoluteTimeSeriesPoints(obj: Osdk.Instance<typeof {{objectType}}>) {\\n return obj.{{property}}?.getAllPoints({\\n $startTime: \\\"2022-08-13T12:34:56Z\\\",\\n $endTime: \\\"2022-08-14T12:34:56Z\\\",\\n });\\n}\"\n }],\n \"loadRelativeTimeSeriesPointsSnippet\": [{\n \"template\": \"// Timeseries does not have a dedicated React hook yet.\\n// Use the client API directly with a loaded OSDK object.\\nimport type { Osdk } from \\\"@osdk/client\\\";\\nimport type { {{objectType}} } from \\\"{{{packageName}}}\\\";\\n\\nasync function getRelativeTimeSeriesPoints(obj: Osdk.Instance<typeof {{objectType}}>) {\\n return obj.{{property}}?.getAllPoints({\\n $before: 1,\\n $unit: \\\"{{timeUnit}}\\\",\\n });\\n}\"\n }],\n \"loadGeotimeSeriesPointsSnippet\": [{\n \"template\": \"// Geo-time series does not have a dedicated React hook yet.\\n// Use the client API directly with a loaded OSDK object.\\nimport type { Osdk } from \\\"@osdk/client\\\";\\nimport type { {{objectType}} } from \\\"{{{packageName}}}\\\";\\n\\nasync function getAllGeotimeSeriesPoints(obj: Osdk.Instance<typeof {{objectType}}>) {\\n return obj.{{property}}?.getAllValues();\\n}\"\n }],\n \"loadGeotimeSeriesLastPointSnippet\": [{\n \"template\": \"// Geo-time series does not have a dedicated React hook yet.\\n// Use the client API directly with a loaded OSDK object.\\nimport type { Osdk } from \\\"@osdk/client\\\";\\nimport type { {{objectType}} } from \\\"{{{packageName}}}\\\";\\n\\nasync function getLatestGeotimeSeriesPoint(obj: Osdk.Instance<typeof {{objectType}}>) {\\n return obj.{{property}}?.getLatestValue();\\n}\"\n }],\n \"loadAbsoluteGeotimeSeriesPointsSnippet\": [{\n \"template\": \"// Geo-time series does not have a dedicated React hook yet.\\n// Use the client API directly with a loaded OSDK object.\\nimport type { Osdk } from \\\"@osdk/client\\\";\\nimport type { {{objectType}} } from \\\"{{{packageName}}}\\\";\\n\\nasync function getAbsoluteGeotimeSeriesPoints(obj: Osdk.Instance<typeof {{objectType}}>) {\\n return obj.{{property}}?.getAllValues({\\n $startTime: \\\"2022-08-13T12:34:56Z\\\",\\n $endTime: \\\"2022-08-14T12:34:56Z\\\",\\n });\\n}\"\n }],\n \"loadRelativeGeotimeSeriesPointsSnippet\": [{\n \"template\": \"// Geo-time series does not have a dedicated React hook yet.\\n// Use the client API directly with a loaded OSDK object.\\nimport type { Osdk } from \\\"@osdk/client\\\";\\nimport type { {{objectType}} } from \\\"{{{packageName}}}\\\";\\n\\nasync function getRelativeGeotimeSeriesPoints(obj: Osdk.Instance<typeof {{objectType}}>) {\\n return obj.{{property}}?.getAllValues({\\n $before: 1,\\n $unit: \\\"{{timeUnit}}\\\",\\n });\\n}\"\n }],\n \"uploadAttachment\": [{\n \"template\": \"import { useOsdkClient } from \\\"@osdk/react/experimental\\\";\\nimport { createAttachmentUpload } from \\\"@osdk/client\\\";\\nimport { {{actionApiName}} } from \\\"{{{packageName}}}\\\";\\n\\nfunction AttachmentUploader() {\\n const client = useOsdkClient();\\n\\n const handleUpload = async (file: File) => {\\n const attachment = createAttachmentUpload(file, file.name);\\n await client({{actionApiName}}).applyAction({\\n {{primaryKeyPropertyV2.apiName}}: {{{propertyValueV2}}},\\n {{property}}: attachment\\n });\\n };\\n\\n return (\\n <input type=\\\"file\\\" onChange={e => {\\n const file = e.target.files?.[0];\\n if (file) {\\n handleUpload(file);\\n }\\n }} />\\n );\\n}\",\n \"computedVariables\": [\"propertyValueV2\", \"primaryKeyPropertyV2\"]\n }],\n \"readMedia\": [{\n \"template\": \"// Media does not have a dedicated React hook yet.\\n// Use the client API directly with a loaded OSDK object.\\nimport type { Osdk } from \\\"@osdk/client\\\";\\nimport type { {{objectType}} } from \\\"{{{packageName}}}\\\";\\n\\nasync function readMediaContent(obj: Osdk.Instance<typeof {{objectType}}>) {\\n const contents = await obj.{{property}}?.fetchContents();\\n if (contents?.ok) {\\n return contents.blob();\\n }\\n}\"\n }],\n \"uploadMedia\": [{\n \"template\": \"import { useOsdkClient } from \\\"@osdk/react/experimental\\\";\\nimport { __EXPERIMENTAL__NOT_SUPPORTED_YET__createMediaReference } from \\\"@osdk/api/unstable\\\";\\nimport type { MediaReference } from \\\"@osdk/api\\\";\\nimport { {{actionApiName}}, {{objectType}} } from \\\"{{{packageName}}}\\\";\\n\\nfunction MediaUploader() {\\n const client = useOsdkClient();\\n\\n const handleUpload = async (file: File) => {\\n const mediaReference: MediaReference = await client(\\n __EXPERIMENTAL__NOT_SUPPORTED_YET__createMediaReference,\\n ).createMediaReference({\\n data: file,\\n fileName: file.name,\\n objectType: {{objectType}},\\n propertyType: \\\"{{property}}\\\",\\n });\\n await client({{actionApiName}}).applyAction({\\n // Pass the required action parameters including the primary key\\n {{mediaParameter}}: mediaReference\\n });\\n };\\n\\n return (\\n <input type=\\\"file\\\" onChange={e => {\\n const file = e.target.files?.[0];\\n if (file) {\\n handleUpload(file);\\n }\\n }} />\\n );\\n}\"\n }],\n \"uploadMediaOntologyEdits\": [{\n \"template\": \"import { useOsdkClient } from \\\"@osdk/react/experimental\\\";\\nimport { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { createEditBatch, uploadMedia } from \\\"@osdk/functions\\\";\\n\\nfunction MediaOntologyEditsUploader() {\\n const client = useOsdkClient();\\n\\n const handleUpload = async (file: File) => {\\n const batch = createEditBatch(client);\\n const mediaReference = await uploadMedia(client, { data: file, fileName: file.name });\\n // @ts-expect-error - batch.create types don't support media references yet\\n batch.create({{objectType}}, { {{property}}: mediaReference });\\n return batch.getEdits();\\n };\\n\\n return (\\n <input type=\\\"file\\\" onChange={e => {\\n const file = e.target.files?.[0];\\n if (file) {\\n handleUpload(file);\\n }\\n }} />\\n );\\n}\"\n }],\n \"uploadMediaEphemeral\": [{\n \"template\": \"// Ephemeral media upload is not yet supported in the React SDK\"\n }],\n \"derivedPropertyNumericExpression\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkClient, useObjectSet } from \\\"@osdk/react/experimental\\\";\\nimport { useMemo } from \\\"react\\\";\\n\\nfunction {{objectType}}DerivedNumericExpression() {\\n const client = useOsdkClient();\\n const derivedSet = useMemo(() =>\\n client({{objectType}}).withProperties({\\n {{^isUnary}}\\n \\\"newPropertyName\\\": (baseObjectSet) =>\\n baseObjectSet.pivotTo(\\\"{{linkApiName}}\\\")\\n .aggregate(\\\"{{property}}\\\").{{operation}}(\\n baseObjectSet.pivotTo(\\\"{{linkApiName}}\\\").aggregate(\\\"$count\\\"))\\n {{/isUnary}}\\n {{#isUnary}}\\n \\\"{{operation}}_{{property}}\\\": (baseObjectSet) =>\\n baseObjectSet.pivotTo(\\\"{{linkApiName}}\\\")\\n .selectProperty(\\\"{{property}}\\\").{{operation}}()\\n {{/isUnary}}\\n }), [client]);\\n\\n const { data, isLoading, error } = useObjectSet(derivedSet);\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"derivedPropertyDatetimeExpression\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkClient, useObjectSet } from \\\"@osdk/react/experimental\\\";\\nimport { useMemo } from \\\"react\\\";\\n\\nfunction {{objectType}}DerivedDatetimeExpression() {\\n const client = useOsdkClient();\\n const derivedSet = useMemo(() =>\\n client({{objectType}}).withProperties({\\n {{^isExtractPart}}\\n \\\"derivedPropertyDatetime_{{operation}}\\\": (baseObjectSet) =>\\n baseObjectSet.pivotTo(\\\"{{linkApiName}}\\\")\\n .selectProperty(\\\"{{property}}\\\")\\n .{{operation}}(baseObjectSet.pivotTo(\\\"{{linkApiName}}\\\").selectProperty(\\\"{{property}}\\\"))\\n {{/isExtractPart}}\\n {{#isExtractPart}}\\n \\\"YEARS_part_of_{{property}}_of_{{linkApiName}}\\\": (baseObjectSet) =>\\n baseObjectSet.pivotTo(\\\"{{linkApiName}}\\\")\\n .selectProperty(\\\"{{property}}\\\").extractPart(\\\"YEARS\\\")\\n {{/isExtractPart}}\\n }), [client]);\\n\\n const { data, isLoading, error } = useObjectSet(derivedSet);\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"nearestNeighborsTextQuery\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkClient, useObjectSet } from \\\"@osdk/react/experimental\\\";\\nimport { useMemo } from \\\"react\\\";\\n\\nfunction {{objectType}}NearestNeighborsText() {\\n const client = useOsdkClient();\\n const resultSet = useMemo(() =>\\n client({{objectType}}).nearestNeighbors(\\\"coffee\\\", 5, \\\"{{property}}\\\"),\\n [client]);\\n\\n const { data, isLoading, error } = useObjectSet(resultSet);\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"nearestNeighborsVectorQuery\": [{\n \"template\": \"import { {{objectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkClient, useObjectSet } from \\\"@osdk/react/experimental\\\";\\nimport { useMemo } from \\\"react\\\";\\n\\nfunction {{objectType}}NearestNeighborsVector() {\\n const client = useOsdkClient();\\n // Note that this vector maps to an arbitrary string\\n // It must match the dimension of the \\\"{{property}}\\\" property: {{vectorDimensionSize}}\\n const vectorQuery = useMemo(() =>\\n Array.from({ length: {{vectorDimensionSize}} }, () => 0.3),\\n []);\\n const resultSet = useMemo(() =>\\n client({{objectType}}).nearestNeighbors(vectorQuery, 5, \\\"{{property}}\\\"),\\n [client, vectorQuery]);\\n\\n const { data, isLoading, error } = useObjectSet(resultSet);\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }],\n \"searchAround\": [{\n \"template\": \"import { {{sourceObjectType}} } from \\\"{{{packageName}}}\\\";\\nimport { useOsdkClient, useObjectSet } from \\\"@osdk/react/experimental\\\";\\nimport { useMemo } from \\\"react\\\";\\n\\nfunction SearchAround{{linkedObjectType}}() {\\n const client = useOsdkClient();\\n const linkedSet = useMemo(() =>\\n client({{sourceObjectType}})\\n .where({ {{rawLinkedPrimaryKeyProperty.apiName}}: { $in: [\\\"a\\\", \\\"b\\\", \\\"c\\\"] } })\\n .pivotTo(\\\"{{linkApiName}}\\\"),\\n [client]);\\n\\n const { data, isLoading, error } = useObjectSet(linkedSet);\\n\\n return (\\n <div>\\n {error && <div>Error: {error.message}</div>}\\n {isLoading && !data && <div>Loading...</div>}\\n <ul>\\n {data?.map(obj => <li key={obj.$primaryKey}>{obj.$primaryKey}</li>)}\\n </ul>\\n </div>\\n );\\n}\"\n }]\n }\n }\n }\n};","/*\n * Copyright 2026 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 { snippets } from \"./generatedNoCheck/docsNoComputedVariables.js\";\nexport const REACT_OSDK_SNIPPETS = {\n ...snippets,\n computedVariables: {\n actionParameterSampleValuesV2: handleActionParameterSampleValuesV2,\n propertyValueV2: handlePropertyValueV2,\n primaryKeyPropertyV2: handlePrimaryKeyPropertyV2,\n linkedPrimaryKeyPropertyV2: handleLinkedPrimaryKeyPropertyV2\n }\n};\nfunction handleActionParameterSampleValuesV2({\n rawActionTypeParameterValues\n}) {\n if (rawActionTypeParameterValues == null) {\n throw new Error(\"Cannot render a null rawActionTypeParameterValues\");\n }\n return rawActionTypeParameterValues.map((param, index, array) => ({\n key: param.key,\n value: renderType(param.value),\n last: index === array.length - 1\n }));\n}\nfunction handlePropertyValueV2({\n rawPropertyValue\n}) {\n return renderPropertyValue(rawPropertyValue);\n}\nfunction handlePrimaryKeyPropertyV2({\n rawPrimaryKeyProperty\n}) {\n if (rawPrimaryKeyProperty == null) {\n throw new Error(\"Cannot render with null rawPrimaryKeyProperty\");\n }\n return {\n apiName: rawPrimaryKeyProperty.apiName,\n value: renderPropertyValue(rawPrimaryKeyProperty.value)\n };\n}\nfunction handleLinkedPrimaryKeyPropertyV2({\n rawLinkedPrimaryKeyProperty\n}) {\n if (rawLinkedPrimaryKeyProperty == null) {\n throw new Error(\"Cannot render with null rawLinkedPrimaryKeyProperty\");\n }\n return {\n apiName: rawLinkedPrimaryKeyProperty.apiName,\n value: renderPropertyValue(rawLinkedPrimaryKeyProperty.value),\n type: rawLinkedPrimaryKeyProperty.type\n };\n}\nfunction renderPropertyValue(propertyValue) {\n if (propertyValue == null) {\n throw new Error(\"Cannot render a null property value\");\n }\n return renderType(propertyValue);\n}\nfunction renderType(type) {\n if (type == null) {\n throw new Error(\"Cannot render a null type value\");\n }\n switch (type.type) {\n case \"array\":\n case \"set\":\n case \"list\":\n return `[${renderType(type.subtype)}]`;\n case \"boolean\":\n return type.value ? \"true\" : \"false\";\n case \"byte\":\n case \"integer\":\n case \"long\":\n case \"short\":\n return type.value.toString();\n case \"decimal\":\n case \"double\":\n case \"float\":\n return type.value.toString();\n case \"date\":\n {\n const offsetDate = new Date();\n offsetDate.setDate(offsetDate.getDate() + (type.daysOffset ?? 0));\n return `\"${offsetDate.toISOString().slice(0, 10)}\"`;\n }\n case \"timestamp\":\n {\n const offsetDate = new Date();\n offsetDate.setDate(offsetDate.getDate() + (type.daysOffset ?? 0));\n return `\"${offsetDate.toISOString()}\"`;\n }\n case \"object\":\n return `\"primaryKeyValue\" /* or myObjectInstance */`;\n case \"objectSet\":\n return `client(${type.objectTypeApiName}).where({ /* filter conditions */ })`;\n case \"anonymousCustomType\":\n case \"customType\":\n {\n const entries = Object.entries(type.parameters ?? {});\n if (entries.length > 0) {\n const rendered = entries.map(([name, value]) => `\"${name}\": ${renderType(value)}`).join(\", \");\n return `{ ${rendered} }`;\n }\n return \"{}\";\n }\n case \"interface\":\n case \"marking\":\n return \"{}\";\n case \"attachment\":\n return type.hasAttachments ? \"attachment\" : \"{}\";\n case \"mediaReference\":\n return \"mediaUpload\";\n case \"objectType\":\n return `\"${type.objectTypeApiName}\"`;\n case \"map\":\n return `{key: ${renderType(type.valueType)}}`;\n case \"string\":\n return `\"${type.value ?? \"value\"}\"`;\n case \"unknown\":\n default:\n return `\"value\"`;\n }\n}"]}
|
package/build/esm/docs.js
CHANGED
|
@@ -103,7 +103,7 @@ function renderType(type) {
|
|
|
103
103
|
return `"${offsetDate.toISOString()}"`;
|
|
104
104
|
}
|
|
105
105
|
case "object":
|
|
106
|
-
return `"primaryKeyValue"
|
|
106
|
+
return `"primaryKeyValue" /* or myObjectInstance */`;
|
|
107
107
|
case "objectSet":
|
|
108
108
|
return `client(${type.objectTypeApiName}).where({ /* filter conditions */ })`;
|
|
109
109
|
case "anonymousCustomType":
|
package/build/esm/docs.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"docs.js","names":["snippets","REACT_OSDK_SNIPPETS","computedVariables","actionParameterSampleValuesV2","handleActionParameterSampleValuesV2","propertyValueV2","handlePropertyValueV2","primaryKeyPropertyV2","handlePrimaryKeyPropertyV2","linkedPrimaryKeyPropertyV2","handleLinkedPrimaryKeyPropertyV2","rawActionTypeParameterValues","Error","map","param","index","array","key","value","renderType","last","length","rawPropertyValue","renderPropertyValue","rawPrimaryKeyProperty","apiName","rawLinkedPrimaryKeyProperty","type","propertyValue","subtype","toString","offsetDate","Date","setDate","getDate","daysOffset","toISOString","slice","objectTypeApiName","entries","Object","parameters","rendered","name","join","hasAttachments","valueType"],"sources":["docs.ts"],"sourcesContent":["/*\n * Copyright 2026 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 { SdkSnippets } from \"@osdk/docs-spec-core\";\nimport type {\n ActionParameterSampleValuesIR,\n ActionParameterSampleValueTypeIR,\n FunctionSampleValueTypeIR,\n OSDK_SNIPPETS_SPEC,\n PropertySampleIR,\n PropertySampleValueTypeIR,\n} from \"@osdk/docs-spec-sdk\";\nimport { snippets } from \"./generatedNoCheck/docsNoComputedVariables.js\";\n\nexport const REACT_OSDK_SNIPPETS: SdkSnippets<typeof OSDK_SNIPPETS_SPEC> = {\n ...snippets,\n computedVariables: {\n actionParameterSampleValuesV2: handleActionParameterSampleValuesV2,\n propertyValueV2: handlePropertyValueV2,\n primaryKeyPropertyV2: handlePrimaryKeyPropertyV2,\n linkedPrimaryKeyPropertyV2: handleLinkedPrimaryKeyPropertyV2,\n },\n};\n\nfunction handleActionParameterSampleValuesV2({\n rawActionTypeParameterValues,\n}: {\n rawActionTypeParameterValues?: ActionParameterSampleValuesIR;\n}): Array<{ key: string; value: string; last: boolean }> {\n if (rawActionTypeParameterValues == null) {\n throw new Error(\"Cannot render a null rawActionTypeParameterValues\");\n }\n\n return rawActionTypeParameterValues.map((param, index, array) => ({\n key: param.key,\n value: renderType(param.value),\n last: index === array.length - 1,\n }));\n}\n\nfunction handlePropertyValueV2({\n rawPropertyValue,\n}: {\n rawPropertyValue?: PropertySampleValueTypeIR;\n}): string {\n return renderPropertyValue(rawPropertyValue);\n}\n\nfunction handlePrimaryKeyPropertyV2({\n rawPrimaryKeyProperty,\n}: {\n rawPrimaryKeyProperty?: PropertySampleIR;\n}): { apiName: string; value: string } {\n if (rawPrimaryKeyProperty == null) {\n throw new Error(\"Cannot render with null rawPrimaryKeyProperty\");\n }\n\n return {\n apiName: rawPrimaryKeyProperty.apiName,\n value: renderPropertyValue(rawPrimaryKeyProperty.value),\n };\n}\n\nfunction handleLinkedPrimaryKeyPropertyV2({\n rawLinkedPrimaryKeyProperty,\n}: {\n rawLinkedPrimaryKeyProperty?: {\n apiName: string;\n value: PropertySampleValueTypeIR;\n type: string;\n };\n}): { apiName: string; value: string; type: string } {\n if (rawLinkedPrimaryKeyProperty == null) {\n throw new Error(\"Cannot render with null rawLinkedPrimaryKeyProperty\");\n }\n\n return {\n apiName: rawLinkedPrimaryKeyProperty.apiName,\n value: renderPropertyValue(rawLinkedPrimaryKeyProperty.value),\n type: rawLinkedPrimaryKeyProperty.type,\n };\n}\n\nfunction renderPropertyValue(\n propertyValue: PropertySampleValueTypeIR | undefined,\n): string {\n if (propertyValue == null) {\n throw new Error(\"Cannot render a null property value\");\n }\n\n return renderType(propertyValue);\n}\n\nfunction renderType(\n type:\n | ActionParameterSampleValueTypeIR\n | FunctionSampleValueTypeIR\n | PropertySampleValueTypeIR,\n): string {\n if (type == null) {\n throw new Error(\"Cannot render a null type value\");\n }\n\n switch (type.type) {\n case \"array\":\n case \"set\":\n case \"list\":\n return `[${renderType(type.subtype)}]`;\n case \"boolean\":\n return type.value ? \"true\" : \"false\";\n case \"byte\":\n case \"integer\":\n case \"long\":\n case \"short\":\n return type.value.toString();\n case \"decimal\":\n case \"double\":\n case \"float\":\n return type.value.toString();\n case \"date\": {\n const offsetDate = new Date();\n offsetDate.setDate(offsetDate.getDate() + (type.daysOffset ?? 0));\n return `\"${offsetDate.toISOString().slice(0, 10)}\"`;\n }\n case \"timestamp\": {\n const offsetDate = new Date();\n offsetDate.setDate(offsetDate.getDate() + (type.daysOffset ?? 0));\n return `\"${offsetDate.toISOString()}\"`;\n }\n case \"object\":\n return `\"primaryKeyValue\"
|
|
1
|
+
{"version":3,"file":"docs.js","names":["snippets","REACT_OSDK_SNIPPETS","computedVariables","actionParameterSampleValuesV2","handleActionParameterSampleValuesV2","propertyValueV2","handlePropertyValueV2","primaryKeyPropertyV2","handlePrimaryKeyPropertyV2","linkedPrimaryKeyPropertyV2","handleLinkedPrimaryKeyPropertyV2","rawActionTypeParameterValues","Error","map","param","index","array","key","value","renderType","last","length","rawPropertyValue","renderPropertyValue","rawPrimaryKeyProperty","apiName","rawLinkedPrimaryKeyProperty","type","propertyValue","subtype","toString","offsetDate","Date","setDate","getDate","daysOffset","toISOString","slice","objectTypeApiName","entries","Object","parameters","rendered","name","join","hasAttachments","valueType"],"sources":["docs.ts"],"sourcesContent":["/*\n * Copyright 2026 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 { SdkSnippets } from \"@osdk/docs-spec-core\";\nimport type {\n ActionParameterSampleValuesIR,\n ActionParameterSampleValueTypeIR,\n FunctionSampleValueTypeIR,\n OSDK_SNIPPETS_SPEC,\n PropertySampleIR,\n PropertySampleValueTypeIR,\n} from \"@osdk/docs-spec-sdk\";\nimport { snippets } from \"./generatedNoCheck/docsNoComputedVariables.js\";\n\nexport const REACT_OSDK_SNIPPETS: SdkSnippets<typeof OSDK_SNIPPETS_SPEC> = {\n ...snippets,\n computedVariables: {\n actionParameterSampleValuesV2: handleActionParameterSampleValuesV2,\n propertyValueV2: handlePropertyValueV2,\n primaryKeyPropertyV2: handlePrimaryKeyPropertyV2,\n linkedPrimaryKeyPropertyV2: handleLinkedPrimaryKeyPropertyV2,\n },\n};\n\nfunction handleActionParameterSampleValuesV2({\n rawActionTypeParameterValues,\n}: {\n rawActionTypeParameterValues?: ActionParameterSampleValuesIR;\n}): Array<{ key: string; value: string; last: boolean }> {\n if (rawActionTypeParameterValues == null) {\n throw new Error(\"Cannot render a null rawActionTypeParameterValues\");\n }\n\n return rawActionTypeParameterValues.map((param, index, array) => ({\n key: param.key,\n value: renderType(param.value),\n last: index === array.length - 1,\n }));\n}\n\nfunction handlePropertyValueV2({\n rawPropertyValue,\n}: {\n rawPropertyValue?: PropertySampleValueTypeIR;\n}): string {\n return renderPropertyValue(rawPropertyValue);\n}\n\nfunction handlePrimaryKeyPropertyV2({\n rawPrimaryKeyProperty,\n}: {\n rawPrimaryKeyProperty?: PropertySampleIR;\n}): { apiName: string; value: string } {\n if (rawPrimaryKeyProperty == null) {\n throw new Error(\"Cannot render with null rawPrimaryKeyProperty\");\n }\n\n return {\n apiName: rawPrimaryKeyProperty.apiName,\n value: renderPropertyValue(rawPrimaryKeyProperty.value),\n };\n}\n\nfunction handleLinkedPrimaryKeyPropertyV2({\n rawLinkedPrimaryKeyProperty,\n}: {\n rawLinkedPrimaryKeyProperty?: {\n apiName: string;\n value: PropertySampleValueTypeIR;\n type: string;\n };\n}): { apiName: string; value: string; type: string } {\n if (rawLinkedPrimaryKeyProperty == null) {\n throw new Error(\"Cannot render with null rawLinkedPrimaryKeyProperty\");\n }\n\n return {\n apiName: rawLinkedPrimaryKeyProperty.apiName,\n value: renderPropertyValue(rawLinkedPrimaryKeyProperty.value),\n type: rawLinkedPrimaryKeyProperty.type,\n };\n}\n\nfunction renderPropertyValue(\n propertyValue: PropertySampleValueTypeIR | undefined,\n): string {\n if (propertyValue == null) {\n throw new Error(\"Cannot render a null property value\");\n }\n\n return renderType(propertyValue);\n}\n\nfunction renderType(\n type:\n | ActionParameterSampleValueTypeIR\n | FunctionSampleValueTypeIR\n | PropertySampleValueTypeIR,\n): string {\n if (type == null) {\n throw new Error(\"Cannot render a null type value\");\n }\n\n switch (type.type) {\n case \"array\":\n case \"set\":\n case \"list\":\n return `[${renderType(type.subtype)}]`;\n case \"boolean\":\n return type.value ? \"true\" : \"false\";\n case \"byte\":\n case \"integer\":\n case \"long\":\n case \"short\":\n return type.value.toString();\n case \"decimal\":\n case \"double\":\n case \"float\":\n return type.value.toString();\n case \"date\": {\n const offsetDate = new Date();\n offsetDate.setDate(offsetDate.getDate() + (type.daysOffset ?? 0));\n return `\"${offsetDate.toISOString().slice(0, 10)}\"`;\n }\n case \"timestamp\": {\n const offsetDate = new Date();\n offsetDate.setDate(offsetDate.getDate() + (type.daysOffset ?? 0));\n return `\"${offsetDate.toISOString()}\"`;\n }\n case \"object\":\n return `\"primaryKeyValue\" /* or myObjectInstance */`;\n case \"objectSet\":\n return `client(${type.objectTypeApiName}).where({ /* filter conditions */ })`;\n case \"anonymousCustomType\":\n case \"customType\": {\n const entries = Object.entries(type.parameters ?? {});\n if (entries.length > 0) {\n const rendered = entries\n .map(([name, value]) => `\"${name}\": ${renderType(value)}`)\n .join(\", \");\n return `{ ${rendered} }`;\n }\n return \"{}\";\n }\n case \"interface\":\n case \"marking\":\n return \"{}\";\n case \"attachment\":\n return type.hasAttachments ? \"attachment\" : \"{}\";\n case \"mediaReference\":\n return \"mediaUpload\";\n case \"objectType\":\n return `\"${type.objectTypeApiName}\"`;\n case \"map\":\n return `{key: ${renderType(type.valueType)}}`;\n case \"string\":\n return `\"${type.value ?? \"value\"}\"`;\n case \"unknown\":\n default:\n return `\"value\"`;\n }\n}\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAWA,SAASA,QAAQ,QAAQ,+CAA+C;AAExE,OAAO,MAAMC,mBAA2D,GAAG;EACzE,G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