@parra/parra-js-sdk 0.3.234 → 0.3.236

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.
@@ -2520,12 +2520,32 @@ export interface UpdateTenantUserRequestBody {
2520
2520
  first_name?: string | null;
2521
2521
  last_name?: string | null;
2522
2522
  properties?: object | null;
2523
+ metadata?: object | null;
2523
2524
  }
2525
+ export interface UserDevice {
2526
+ id: string;
2527
+ created_at: string;
2528
+ updated_at: string;
2529
+ deleted_at?: string | null;
2530
+ platform: string;
2531
+ platform_agent: string;
2532
+ device_id?: string | null;
2533
+ bundle_id?: string | null;
2534
+ ad_id?: string | null;
2535
+ manufacturer?: string | null;
2536
+ model?: string | null;
2537
+ }
2538
+ export type UserDeviceListResponse = Array<UserDevice>;
2524
2539
  export interface UserProperties {
2525
2540
  }
2526
2541
  export interface UpdateUserPropertyValueRequestBody {
2527
2542
  value: number | string | number | boolean;
2528
2543
  }
2544
+ export interface UserMetadata {
2545
+ }
2546
+ export interface UpdateUserMetadataValueRequestBody {
2547
+ value: number | string | number | boolean;
2548
+ }
2529
2549
  export interface CreateTenantUserRequestBody {
2530
2550
  identity?: string | null;
2531
2551
  name?: string | null;
@@ -3231,11 +3251,16 @@ declare class ParraAPI {
3231
3251
  }, options?: Options) => Promise<TenantUser>;
3232
3252
  updateUserForTenantById: (tenant_id: string, user_id: string, body?: UpdateTenantUserRequestBody, options?: Options) => Promise<TenantUser>;
3233
3253
  deleteUserForTenantById: (tenant_id: string, user_id: string, options?: Options) => Promise<Response>;
3254
+ listDevicesForTenantUser: (tenant_id: string, user_id: string, options?: Options) => Promise<Array<UserDevice>>;
3234
3255
  getPropertiesForTenantUser: (tenant_id: string, user_id: string, options?: Options) => Promise<UserProperties>;
3235
3256
  updatePropertiesForTenantUser: (tenant_id: string, user_id: string, body?: UserProperties, options?: Options) => Promise<UserProperties>;
3236
3257
  deletePropertiesForTenantUser: (tenant_id: string, user_id: string, options?: Options) => Promise<UserProperties>;
3237
- updatePropertyForTenantUser: (tenant_id: string, user_id: string, user_property_key: string, body: UpdateUserPropertyValueRequestBody, options?: Options) => Promise<UserProperties>;
3238
- deletePropertyForTenantUser: (tenant_id: string, user_id: string, user_property_key: string, options?: Options) => Promise<UserProperties>;
3258
+ updatePropertyValueForTenantUser: (tenant_id: string, user_id: string, user_property_key: string, body: UpdateUserPropertyValueRequestBody, options?: Options) => Promise<UserProperties>;
3259
+ deletePropertyValueForTenantUser: (tenant_id: string, user_id: string, user_property_key: string, options?: Options) => Promise<UserProperties>;
3260
+ getMetadataForTenantUser: (tenant_id: string, user_id: string, options?: Options) => Promise<UserMetadata>;
3261
+ updateMetadataForTenantUser: (tenant_id: string, user_id: string, body?: UserMetadata, options?: Options) => Promise<UserMetadata>;
3262
+ updateMetadataValueForTenantUser: (tenant_id: string, user_id: string, user_metadata_key: string, body: UpdateUserMetadataValueRequestBody, options?: Options) => Promise<UserMetadata>;
3263
+ deleteMetadataValueForTenantUser: (tenant_id: string, user_id: string, user_metadata_key: string, options?: Options) => Promise<UserMetadata>;
3239
3264
  updateAvatarForTenantUserById: (tenant_id: string, user_id: string, body: ImageAssetStub, options?: Options) => Promise<Response>;
3240
3265
  deleteAvatarForTenantUserById: (tenant_id: string, user_id: string, options?: Options) => Promise<Response>;
3241
3266
  createUserForTenantById: (tenant_id: string, body?: CreateTenantUserRequestBody, options?: Options) => Promise<TenantUser>;
package/dist/ParraAPI.js CHANGED
@@ -1168,6 +1168,10 @@ var ParraAPI = /** @class */ (function () {
1168
1168
  if (options === void 0) { options = {}; }
1169
1169
  return _this.http.execute("".concat(_this.options.baseUrl, "/v1/tenants/").concat(tenant_id, "/users/").concat(user_id), __assign({ method: "delete" }, options));
1170
1170
  };
1171
+ this.listDevicesForTenantUser = function (tenant_id, user_id, options) {
1172
+ if (options === void 0) { options = {}; }
1173
+ return _this.http.execute("".concat(_this.options.baseUrl, "/v1/tenants/").concat(tenant_id, "/users/").concat(user_id, "/devices"), __assign({ method: "get" }, options));
1174
+ };
1171
1175
  this.getPropertiesForTenantUser = function (tenant_id, user_id, options) {
1172
1176
  if (options === void 0) { options = {}; }
1173
1177
  return _this.http.execute("".concat(_this.options.baseUrl, "/v1/tenants/").concat(tenant_id, "/users/").concat(user_id, "/properties"), __assign({ method: "get" }, options));
@@ -1182,16 +1186,36 @@ var ParraAPI = /** @class */ (function () {
1182
1186
  if (options === void 0) { options = {}; }
1183
1187
  return _this.http.execute("".concat(_this.options.baseUrl, "/v1/tenants/").concat(tenant_id, "/users/").concat(user_id, "/properties"), __assign({ method: "delete" }, options));
1184
1188
  };
1185
- this.updatePropertyForTenantUser = function (tenant_id, user_id, user_property_key, body, options) {
1189
+ this.updatePropertyValueForTenantUser = function (tenant_id, user_id, user_property_key, body, options) {
1186
1190
  if (options === void 0) { options = {}; }
1187
1191
  return _this.http.execute("".concat(_this.options.baseUrl, "/v1/tenants/").concat(tenant_id, "/users/").concat(user_id, "/properties/").concat(user_property_key), __assign({ method: "put", body: JSON.stringify(body), headers: {
1188
1192
  "content-type": "application/json",
1189
1193
  } }, options));
1190
1194
  };
1191
- this.deletePropertyForTenantUser = function (tenant_id, user_id, user_property_key, options) {
1195
+ this.deletePropertyValueForTenantUser = function (tenant_id, user_id, user_property_key, options) {
1192
1196
  if (options === void 0) { options = {}; }
1193
1197
  return _this.http.execute("".concat(_this.options.baseUrl, "/v1/tenants/").concat(tenant_id, "/users/").concat(user_id, "/properties/").concat(user_property_key), __assign({ method: "delete" }, options));
1194
1198
  };
1199
+ this.getMetadataForTenantUser = function (tenant_id, user_id, options) {
1200
+ if (options === void 0) { options = {}; }
1201
+ return _this.http.execute("".concat(_this.options.baseUrl, "/v1/tenants/").concat(tenant_id, "/users/").concat(user_id, "/metadata"), __assign({ method: "get" }, options));
1202
+ };
1203
+ this.updateMetadataForTenantUser = function (tenant_id, user_id, body, options) {
1204
+ if (options === void 0) { options = {}; }
1205
+ return _this.http.execute("".concat(_this.options.baseUrl, "/v1/tenants/").concat(tenant_id, "/users/").concat(user_id, "/metadata"), __assign({ method: "put", body: JSON.stringify(body), headers: {
1206
+ "content-type": "application/json",
1207
+ } }, options));
1208
+ };
1209
+ this.updateMetadataValueForTenantUser = function (tenant_id, user_id, user_metadata_key, body, options) {
1210
+ if (options === void 0) { options = {}; }
1211
+ return _this.http.execute("".concat(_this.options.baseUrl, "/v1/tenants/").concat(tenant_id, "/users/").concat(user_id, "/metadata/").concat(user_metadata_key), __assign({ method: "put", body: JSON.stringify(body), headers: {
1212
+ "content-type": "application/json",
1213
+ } }, options));
1214
+ };
1215
+ this.deleteMetadataValueForTenantUser = function (tenant_id, user_id, user_metadata_key, options) {
1216
+ if (options === void 0) { options = {}; }
1217
+ return _this.http.execute("".concat(_this.options.baseUrl, "/v1/tenants/").concat(tenant_id, "/users/").concat(user_id, "/metadata/").concat(user_metadata_key), __assign({ method: "delete" }, options));
1218
+ };
1195
1219
  this.updateAvatarForTenantUserById = function (tenant_id, user_id, body, options) {
1196
1220
  if (options === void 0) { options = {}; }
1197
1221
  return _this.http.execute("".concat(_this.options.baseUrl, "/v1/tenants/").concat(tenant_id, "/users/").concat(user_id, "/avatar"), __assign({ method: "put", body: JSON.stringify(body), headers: {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@parra/parra-js-sdk",
3
- "version": "0.3.234",
3
+ "version": "0.3.236",
4
4
  "description": "",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",