@justins-home/api-services 1.1.3 → 1.1.4
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/.turbo/turbo-build.log +5 -5
- package/CHANGELOG.md +6 -0
- package/dist/index.js +24 -0
- package/dist/index.mjs +23 -0
- package/package.json +1 -1
- package/src/generated/booking.ts +26 -0
- package/src/generated/landlord.ts +10 -0
- package/src/index.ts +1 -0
package/.turbo/turbo-build.log
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
|
|
2
|
-
> @justins-home/api-services@1.1.
|
|
2
|
+
> @justins-home/api-services@1.1.4 build /home/runner/work/justins-home-platform-ui/justins-home-platform-ui/packages/api-services
|
|
3
3
|
> tsup src/index.ts --format esm,cjs
|
|
4
4
|
|
|
5
5
|
[34mCLI[39m Building entry: src/index.ts
|
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
[34mCLI[39m Target: node16
|
|
8
8
|
[34mESM[39m Build start
|
|
9
9
|
[34mCJS[39m Build start
|
|
10
|
-
[32mCJS[39m [1mdist/index.js [22m[
|
|
11
|
-
[32mCJS[39m ⚡️ Build success in
|
|
12
|
-
[32mESM[39m [1mdist/index.mjs [22m[
|
|
13
|
-
[32mESM[39m ⚡️ Build success in
|
|
10
|
+
[32mCJS[39m [1mdist/index.js [22m[32m26.73 KB[39m
|
|
11
|
+
[32mCJS[39m ⚡️ Build success in 68ms
|
|
12
|
+
[32mESM[39m [1mdist/index.mjs [22m[32m25.11 KB[39m
|
|
13
|
+
[32mESM[39m ⚡️ Build success in 69ms
|
package/CHANGELOG.md
CHANGED
package/dist/index.js
CHANGED
|
@@ -25,6 +25,7 @@ __export(index_exports, {
|
|
|
25
25
|
api: () => api,
|
|
26
26
|
appointment: () => appointment,
|
|
27
27
|
auth: () => auth,
|
|
28
|
+
booking: () => booking,
|
|
28
29
|
conversations: () => conversations,
|
|
29
30
|
customer: () => customer,
|
|
30
31
|
feature: () => feature,
|
|
@@ -321,6 +322,22 @@ var auth = {
|
|
|
321
322
|
}
|
|
322
323
|
};
|
|
323
324
|
|
|
325
|
+
// src/generated/booking.ts
|
|
326
|
+
var booking = {
|
|
327
|
+
create: (payload) => {
|
|
328
|
+
return api.post("createBooking", "/api/v1/public/booking/create", payload);
|
|
329
|
+
},
|
|
330
|
+
confirm: (params) => {
|
|
331
|
+
return api.post("confirmBooking", `/api/v1/public/booking/${params.booking_id}/confirm`);
|
|
332
|
+
},
|
|
333
|
+
cancel: (params) => {
|
|
334
|
+
return api.post("cancelBooking", `/api/v1/public/booking/${params.booking_id}/cancel`);
|
|
335
|
+
},
|
|
336
|
+
get: (params) => {
|
|
337
|
+
return api.get("getBooking", `/api/v1/public/booking/fetch-one/${params.booking_id}`);
|
|
338
|
+
}
|
|
339
|
+
};
|
|
340
|
+
|
|
324
341
|
// src/generated/agent.ts
|
|
325
342
|
var agent = {
|
|
326
343
|
getApiV1PortalAgentTest: () => {
|
|
@@ -405,6 +422,9 @@ var landlord = {
|
|
|
405
422
|
new: (payload) => {
|
|
406
423
|
return api.post("newLandlord", "/api/v1/portal/landlord/create-landlord", payload);
|
|
407
424
|
},
|
|
425
|
+
basicLogin: (payload) => {
|
|
426
|
+
return api.post("basicLoginLandlord", "/api/v1/portal/landlord/login", payload);
|
|
427
|
+
},
|
|
408
428
|
createListingDraft: (payload) => {
|
|
409
429
|
return api.post("createListingDraft", "/api/v1/portal/landlord/listing", payload);
|
|
410
430
|
},
|
|
@@ -426,6 +446,9 @@ var landlord = {
|
|
|
426
446
|
saveTenancyDetails: (params, payload) => {
|
|
427
447
|
return api.post("saveTenancyDetails", `/api/v1/portal/landlord/listing/${params.listing_uid}/tenancy-details`, payload);
|
|
428
448
|
},
|
|
449
|
+
saveShortLetDetails: (params, payload) => {
|
|
450
|
+
return api.post("saveShortLetDetails", `/api/v1/portal/landlord/listing/${params.listing_uid}/shortlet-details`, payload);
|
|
451
|
+
},
|
|
429
452
|
saveListingFeatures: (params, payload) => {
|
|
430
453
|
return api.post("saveListingFeatures", `/api/v1/portal/landlord/listing/${params.listing_uid}/features`, payload);
|
|
431
454
|
},
|
|
@@ -639,6 +662,7 @@ var wishlist = {
|
|
|
639
662
|
api,
|
|
640
663
|
appointment,
|
|
641
664
|
auth,
|
|
665
|
+
booking,
|
|
642
666
|
conversations,
|
|
643
667
|
customer,
|
|
644
668
|
feature,
|
package/dist/index.mjs
CHANGED
|
@@ -275,6 +275,22 @@ var auth = {
|
|
|
275
275
|
}
|
|
276
276
|
};
|
|
277
277
|
|
|
278
|
+
// src/generated/booking.ts
|
|
279
|
+
var booking = {
|
|
280
|
+
create: (payload) => {
|
|
281
|
+
return api.post("createBooking", "/api/v1/public/booking/create", payload);
|
|
282
|
+
},
|
|
283
|
+
confirm: (params) => {
|
|
284
|
+
return api.post("confirmBooking", `/api/v1/public/booking/${params.booking_id}/confirm`);
|
|
285
|
+
},
|
|
286
|
+
cancel: (params) => {
|
|
287
|
+
return api.post("cancelBooking", `/api/v1/public/booking/${params.booking_id}/cancel`);
|
|
288
|
+
},
|
|
289
|
+
get: (params) => {
|
|
290
|
+
return api.get("getBooking", `/api/v1/public/booking/fetch-one/${params.booking_id}`);
|
|
291
|
+
}
|
|
292
|
+
};
|
|
293
|
+
|
|
278
294
|
// src/generated/agent.ts
|
|
279
295
|
var agent = {
|
|
280
296
|
getApiV1PortalAgentTest: () => {
|
|
@@ -359,6 +375,9 @@ var landlord = {
|
|
|
359
375
|
new: (payload) => {
|
|
360
376
|
return api.post("newLandlord", "/api/v1/portal/landlord/create-landlord", payload);
|
|
361
377
|
},
|
|
378
|
+
basicLogin: (payload) => {
|
|
379
|
+
return api.post("basicLoginLandlord", "/api/v1/portal/landlord/login", payload);
|
|
380
|
+
},
|
|
362
381
|
createListingDraft: (payload) => {
|
|
363
382
|
return api.post("createListingDraft", "/api/v1/portal/landlord/listing", payload);
|
|
364
383
|
},
|
|
@@ -380,6 +399,9 @@ var landlord = {
|
|
|
380
399
|
saveTenancyDetails: (params, payload) => {
|
|
381
400
|
return api.post("saveTenancyDetails", `/api/v1/portal/landlord/listing/${params.listing_uid}/tenancy-details`, payload);
|
|
382
401
|
},
|
|
402
|
+
saveShortLetDetails: (params, payload) => {
|
|
403
|
+
return api.post("saveShortLetDetails", `/api/v1/portal/landlord/listing/${params.listing_uid}/shortlet-details`, payload);
|
|
404
|
+
},
|
|
383
405
|
saveListingFeatures: (params, payload) => {
|
|
384
406
|
return api.post("saveListingFeatures", `/api/v1/portal/landlord/listing/${params.listing_uid}/features`, payload);
|
|
385
407
|
},
|
|
@@ -592,6 +614,7 @@ export {
|
|
|
592
614
|
api,
|
|
593
615
|
appointment,
|
|
594
616
|
auth,
|
|
617
|
+
booking,
|
|
595
618
|
conversations,
|
|
596
619
|
customer,
|
|
597
620
|
feature,
|
package/package.json
CHANGED
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
|
|
2
|
+
import { api } from "../api-client";
|
|
3
|
+
import type { ApiRequest, ApiPathParams, Expand } from "../types/openapi";
|
|
4
|
+
|
|
5
|
+
export const booking = {
|
|
6
|
+
|
|
7
|
+
create: (payload: ApiRequest<'createBooking'>) => {
|
|
8
|
+
return api.post('createBooking', "/api/v1/public/booking/create", payload);
|
|
9
|
+
}
|
|
10
|
+
,
|
|
11
|
+
|
|
12
|
+
confirm: (params: ApiPathParams<'confirmBooking'>) => {
|
|
13
|
+
return api.post('confirmBooking', `/api/v1/public/booking/${params.booking_id}/confirm`);
|
|
14
|
+
}
|
|
15
|
+
,
|
|
16
|
+
|
|
17
|
+
cancel: (params: ApiPathParams<'cancelBooking'>) => {
|
|
18
|
+
return api.post('cancelBooking', `/api/v1/public/booking/${params.booking_id}/cancel`);
|
|
19
|
+
}
|
|
20
|
+
,
|
|
21
|
+
|
|
22
|
+
get: (params: ApiPathParams<'getBooking'>) => {
|
|
23
|
+
return api.get('getBooking', `/api/v1/public/booking/fetch-one/${params.booking_id}`);
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
};
|
|
@@ -9,6 +9,11 @@ export const landlord = {
|
|
|
9
9
|
}
|
|
10
10
|
,
|
|
11
11
|
|
|
12
|
+
basicLogin: (payload: ApiRequest<'basicLoginLandlord'>) => {
|
|
13
|
+
return api.post('basicLoginLandlord', "/api/v1/portal/landlord/login", payload);
|
|
14
|
+
}
|
|
15
|
+
,
|
|
16
|
+
|
|
12
17
|
createListingDraft: (payload: ApiRequest<'createListingDraft'>) => {
|
|
13
18
|
return api.post('createListingDraft', "/api/v1/portal/landlord/listing", payload);
|
|
14
19
|
}
|
|
@@ -44,6 +49,11 @@ export const landlord = {
|
|
|
44
49
|
}
|
|
45
50
|
,
|
|
46
51
|
|
|
52
|
+
saveShortLetDetails: (params: ApiPathParams<'saveShortLetDetails'>, payload: ApiRequest<'saveShortLetDetails'>) => {
|
|
53
|
+
return api.post('saveShortLetDetails', `/api/v1/portal/landlord/listing/${params.listing_uid}/shortlet-details`, payload);
|
|
54
|
+
}
|
|
55
|
+
,
|
|
56
|
+
|
|
47
57
|
saveListingFeatures: (params: ApiPathParams<'saveListingFeatures'>, payload: ApiRequest<'saveListingFeatures'>) => {
|
|
48
58
|
return api.post('saveListingFeatures', `/api/v1/portal/landlord/listing/${params.listing_uid}/features`, payload);
|
|
49
59
|
}
|
package/src/index.ts
CHANGED
|
@@ -16,6 +16,7 @@ export * from './types/openapi';
|
|
|
16
16
|
export * from './generated/admin';
|
|
17
17
|
export * from './generated/appointment';
|
|
18
18
|
export * from './generated/auth';
|
|
19
|
+
export * from './generated/booking';
|
|
19
20
|
export * from './generated/agent';
|
|
20
21
|
export * from './generated/tenant';
|
|
21
22
|
export * from './generated/customer';
|