@tec.pet/tecpet-sdk 0.0.171 → 0.0.172

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.
@@ -0,0 +1,7 @@
1
+ import { HttpClient } from "infra/http/client.http";
2
+ import { PaSetCustomFieldValuesInput, PaSetCustomFieldValuesResponse } from "./dto/pa.set-custom-field-values.dto";
3
+ export declare class CustomFieldService {
4
+ private readonly api;
5
+ constructor(api: HttpClient);
6
+ setValues(body: PaSetCustomFieldValuesInput, shopId: number): Promise<PaSetCustomFieldValuesResponse>;
7
+ }
@@ -0,0 +1,13 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.CustomFieldService = void 0;
4
+ class CustomFieldService {
5
+ api;
6
+ constructor(api) {
7
+ this.api = api;
8
+ }
9
+ async setValues(body, shopId) {
10
+ return await this.api.post(`/custom-fields/values`, body, shopId);
11
+ }
12
+ }
13
+ exports.CustomFieldService = CustomFieldService;
@@ -0,0 +1,17 @@
1
+ export declare enum PaCustomFieldTargetEnum {
2
+ CLIENT = "CLIENT",
3
+ PET = "PET"
4
+ }
5
+ export interface PaCustomFieldValueInput {
6
+ customFieldId: string;
7
+ value: string | null;
8
+ }
9
+ export interface PaSetCustomFieldValuesInput {
10
+ type: PaCustomFieldTargetEnum;
11
+ entityId: number;
12
+ fieldsValues: PaCustomFieldValueInput[];
13
+ }
14
+ export interface PaSetCustomFieldValuesResponse {
15
+ success: boolean;
16
+ message: string;
17
+ }
@@ -0,0 +1,8 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.PaCustomFieldTargetEnum = void 0;
4
+ var PaCustomFieldTargetEnum;
5
+ (function (PaCustomFieldTargetEnum) {
6
+ PaCustomFieldTargetEnum["CLIENT"] = "CLIENT";
7
+ PaCustomFieldTargetEnum["PET"] = "PET";
8
+ })(PaCustomFieldTargetEnum || (exports.PaCustomFieldTargetEnum = PaCustomFieldTargetEnum = {}));
@@ -0,0 +1 @@
1
+ export * from './dto/pa.set-custom-field-values.dto';
@@ -0,0 +1,17 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
+ };
16
+ Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./dto/pa.set-custom-field-values.dto"), exports);
package/dist/index.d.ts CHANGED
@@ -4,6 +4,7 @@ import { BookingService } from "./domain/booking/booking.service";
4
4
  import { BreedService } from "./domain/breed/breed.service";
5
5
  import { ChatbotService } from "./domain/chatbot/chatbotService";
6
6
  import { ClientService } from "./domain/client/client.service";
7
+ import { CustomFieldService } from "./domain/customField/customField.service";
7
8
  import { ComboService } from "./domain/combo/combo.service";
8
9
  import { EmployeeService } from "./domain/employee/employee.service";
9
10
  import { PetService } from "./domain/pet/pet.service";
@@ -46,6 +47,7 @@ export declare class TecpetSDK {
46
47
  serviceRecommendation: ServiceRecommendationService;
47
48
  blockedTime: BlockedTimeService;
48
49
  cep: CepService;
50
+ customField: CustomFieldService;
49
51
  constructor(baseURL: string, apiKey?: string);
50
52
  }
51
53
  export * from './domain/availableTimes';
@@ -71,6 +73,7 @@ export * from './domain/invoice';
71
73
  export * from './domain/serviceRecommendation';
72
74
  export * from './domain/blockedTime';
73
75
  export * from './domain/cep';
76
+ export * from './domain/customField';
74
77
  export * from './utils/index';
75
78
  export * from './domain/petPlan';
76
79
  export * from './domain/chain';
package/dist/index.js CHANGED
@@ -21,6 +21,7 @@ const booking_service_1 = require("./domain/booking/booking.service");
21
21
  const breed_service_1 = require("./domain/breed/breed.service");
22
22
  const chatbotService_1 = require("./domain/chatbot/chatbotService");
23
23
  const client_service_1 = require("./domain/client/client.service");
24
+ const customField_service_1 = require("./domain/customField/customField.service");
24
25
  const combo_service_1 = require("./domain/combo/combo.service");
25
26
  const employee_service_1 = require("./domain/employee/employee.service");
26
27
  const pet_service_1 = require("./domain/pet/pet.service");
@@ -64,9 +65,11 @@ class TecpetSDK {
64
65
  serviceRecommendation;
65
66
  blockedTime;
66
67
  cep;
68
+ customField;
67
69
  constructor(baseURL, apiKey) {
68
70
  this.api = new client_http_1.HttpClient(baseURL, apiKey);
69
71
  this.client = new client_service_1.ClientService(this.api);
72
+ this.customField = new customField_service_1.CustomFieldService(this.api);
70
73
  this.pet = new pet_service_1.PetService(this.api);
71
74
  this.breed = new breed_service_1.BreedService(this.api);
72
75
  this.chatbot = new chatbotService_1.ChatbotService(this.api);
@@ -115,6 +118,7 @@ __exportStar(require("./domain/invoice"), exports);
115
118
  __exportStar(require("./domain/serviceRecommendation"), exports);
116
119
  __exportStar(require("./domain/blockedTime"), exports);
117
120
  __exportStar(require("./domain/cep"), exports);
121
+ __exportStar(require("./domain/customField"), exports);
118
122
  __exportStar(require("./utils/index"), exports);
119
123
  __exportStar(require("./domain/petPlan"), exports);
120
124
  __exportStar(require("./domain/chain"), exports);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tec.pet/tecpet-sdk",
3
- "version": "0.0.171",
3
+ "version": "0.0.172",
4
4
  "description": "TecPet SDK for integration with TecPet services",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",