@viamrobotics/sdk 0.31.0 → 0.32.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -317,6 +317,21 @@ export declare class DataClient {
317
317
  */
318
318
  binaryDataCaptureUpload(binaryData: Uint8Array, partId: string, componentType: string, componentName: string, methodName: string, fileExtension: string, dataRequestTimes: [Date, Date], tags?: string[]): Promise<string>;
319
319
  createFilter(options: FilterOptions): Filter;
320
+ /**
321
+ * Gets the most recent tabular data captured from the specified data source,
322
+ * as long as it was synced within the last year.
323
+ *
324
+ * @param partId The ID of the part that owns the data
325
+ * @param resourceName The name of the requested resource that captured the
326
+ * data
327
+ * @param resourceSubtype The subtype of the requested resource that captured
328
+ * the data
329
+ * @param methodName The data capture method name
330
+ * @returns A tuple containing [timeCaptured, timeSynced, payload] or null if
331
+ * no data has been synced for the specified resource OR the most recently
332
+ * captured data was over a year ago
333
+ */
334
+ getLatestTabularData(partId: string, resourceName: string, resourceSubtype: string, methodName: string): Promise<[Date, Date, Record<string, JsonValue>] | null>;
320
335
  }
321
336
  export { type BinaryID, type Order } from '../gen/app/data/v1/data_pb';
322
337
  export { type UploadMetadata } from '../gen/app/datasync/v1/data_sync_pb';
@@ -717,6 +717,20 @@ export declare class GoSettings extends Message<GoSettings> {
717
717
  */
718
718
  common?: CommonLanguageSettings;
719
719
 
720
+ /**
721
+ * Map of service names to renamed services. Keys are the package relative
722
+ * service names and values are the name to be used for the service client
723
+ * and call options.
724
+ *
725
+ * publishing:
726
+ * go_settings:
727
+ * renamed_services:
728
+ * Publisher: TopicAdmin
729
+ *
730
+ * @generated from field: map<string, string> renamed_services = 2;
731
+ */
732
+ renamedServices: { [key: string]: string };
733
+
720
734
  constructor(data?: PartialMessage<GoSettings>);
721
735
 
722
736
  static readonly runtime: typeof proto3;
package/dist/main.es.js CHANGED
@@ -7108,7 +7108,7 @@ const fn = (t) => {
7108
7108
  );
7109
7109
  }
7110
7110
  }, Xv = "v0.1.367", Bt = new Headers({
7111
- "viam-client": `typescript;v0.31.0;${Xv}`
7111
+ "viam-client": `typescript;v0.32.0;${Xv}`
7112
7112
  }), x = async function(e, n, a, s = {}, i = {}) {
7113
7113
  const r = new U({
7114
7114
  name: n,
@@ -20781,6 +20781,33 @@ class Zh {
20781
20781
  const a = new To();
20782
20782
  return e.tags && (a.tags = e.tags, n.tagsFilter = a), n;
20783
20783
  }
20784
+ /**
20785
+ * Gets the most recent tabular data captured from the specified data source,
20786
+ * as long as it was synced within the last year.
20787
+ *
20788
+ * @param partId The ID of the part that owns the data
20789
+ * @param resourceName The name of the requested resource that captured the
20790
+ * data
20791
+ * @param resourceSubtype The subtype of the requested resource that captured
20792
+ * the data
20793
+ * @param methodName The data capture method name
20794
+ * @returns A tuple containing [timeCaptured, timeSynced, payload] or null if
20795
+ * no data has been synced for the specified resource OR the most recently
20796
+ * captured data was over a year ago
20797
+ */
20798
+ async getLatestTabularData(e, n, a, s) {
20799
+ const i = await this.dataClient.getLatestTabularData({
20800
+ partId: e,
20801
+ resourceName: n,
20802
+ resourceSubtype: a,
20803
+ methodName: s
20804
+ });
20805
+ return !i.payload || !i.timeCaptured || !i.timeSynced ? null : [
20806
+ i.timeCaptured.toDate(),
20807
+ i.timeSynced.toDate(),
20808
+ i.payload.toJson()
20809
+ ];
20810
+ }
20784
20811
  }
20785
20812
  const ef = {
20786
20813
  typeName: "viam.app.mltraining.v1.MLTrainingService",
@@ -23019,7 +23046,7 @@ class YR {
23019
23046
  );
23020
23047
  }
23021
23048
  }
23022
- const WR = "0.31.0";
23049
+ const WR = "0.32.0";
23023
23050
  export {
23024
23051
  Gf as AnalogValue,
23025
23052
  qf as ArmClient,