nylas 8.0.4 → 8.0.5
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/lib/cjs/resources/availability.js +19 -0
- package/lib/cjs/resources/scheduler.js +2 -0
- package/lib/cjs/version.js +1 -1
- package/lib/esm/resources/availability.js +15 -0
- package/lib/esm/resources/scheduler.js +2 -0
- package/lib/esm/version.js +1 -1
- package/lib/types/models/scheduler.d.ts +20 -0
- package/lib/types/resources/availability.d.ts +18 -0
- package/lib/types/resources/scheduler.d.ts +2 -0
- package/lib/types/version.d.ts +1 -1
- package/package.json +1 -1
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.SchedulerAvailability = void 0;
|
|
4
|
+
const resource_js_1 = require("./resource.js");
|
|
5
|
+
const utils_js_1 = require("../utils.js");
|
|
6
|
+
class SchedulerAvailability extends resource_js_1.Resource {
|
|
7
|
+
/**
|
|
8
|
+
* Get availability for a scheduling configuration
|
|
9
|
+
* @return The availability response with time slots
|
|
10
|
+
*/
|
|
11
|
+
get({ queryParams, overrides, }) {
|
|
12
|
+
return super._find({
|
|
13
|
+
path: (0, utils_js_1.makePathParams)('/v3/scheduling/availability', {}),
|
|
14
|
+
queryParams,
|
|
15
|
+
overrides,
|
|
16
|
+
});
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
exports.SchedulerAvailability = SchedulerAvailability;
|
|
@@ -4,11 +4,13 @@ exports.Scheduler = void 0;
|
|
|
4
4
|
const configurations_js_1 = require("./configurations.js");
|
|
5
5
|
const sessions_js_1 = require("./sessions.js");
|
|
6
6
|
const bookings_js_1 = require("./bookings.js");
|
|
7
|
+
const availability_js_1 = require("./availability.js");
|
|
7
8
|
class Scheduler {
|
|
8
9
|
constructor(apiClient) {
|
|
9
10
|
this.configurations = new configurations_js_1.Configurations(apiClient);
|
|
10
11
|
this.bookings = new bookings_js_1.Bookings(apiClient);
|
|
11
12
|
this.sessions = new sessions_js_1.Sessions(apiClient);
|
|
13
|
+
this.availability = new availability_js_1.SchedulerAvailability(apiClient);
|
|
12
14
|
}
|
|
13
15
|
}
|
|
14
16
|
exports.Scheduler = Scheduler;
|
package/lib/cjs/version.js
CHANGED
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { Resource } from './resource.js';
|
|
2
|
+
import { makePathParams } from '../utils.js';
|
|
3
|
+
export class SchedulerAvailability extends Resource {
|
|
4
|
+
/**
|
|
5
|
+
* Get availability for a scheduling configuration
|
|
6
|
+
* @return The availability response with time slots
|
|
7
|
+
*/
|
|
8
|
+
get({ queryParams, overrides, }) {
|
|
9
|
+
return super._find({
|
|
10
|
+
path: makePathParams('/v3/scheduling/availability', {}),
|
|
11
|
+
queryParams,
|
|
12
|
+
overrides,
|
|
13
|
+
});
|
|
14
|
+
}
|
|
15
|
+
}
|
|
@@ -1,10 +1,12 @@
|
|
|
1
1
|
import { Configurations } from './configurations.js';
|
|
2
2
|
import { Sessions } from './sessions.js';
|
|
3
3
|
import { Bookings } from './bookings.js';
|
|
4
|
+
import { SchedulerAvailability } from './availability.js';
|
|
4
5
|
export class Scheduler {
|
|
5
6
|
constructor(apiClient) {
|
|
6
7
|
this.configurations = new Configurations(apiClient);
|
|
7
8
|
this.bookings = new Bookings(apiClient);
|
|
8
9
|
this.sessions = new Sessions(apiClient);
|
|
10
|
+
this.availability = new SchedulerAvailability(apiClient);
|
|
9
11
|
}
|
|
10
12
|
}
|
package/lib/esm/version.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
// This file is generated by scripts/exportVersion.js
|
|
2
|
-
export const SDK_VERSION = '8.0.
|
|
2
|
+
export const SDK_VERSION = '8.0.5';
|
|
@@ -424,3 +424,23 @@ export interface FindBookingQueryParams {
|
|
|
424
424
|
export type ConfirmBookingQueryParams = FindBookingQueryParams;
|
|
425
425
|
export type RescheduleBookingQueryParams = FindBookingQueryParams;
|
|
426
426
|
export type DestroyBookingQueryParams = FindBookingQueryParams;
|
|
427
|
+
export interface SchedulerAvailabilityTimeSlot {
|
|
428
|
+
emails: string[];
|
|
429
|
+
startTime: number;
|
|
430
|
+
endTime: number;
|
|
431
|
+
eventId?: string;
|
|
432
|
+
masterId?: string;
|
|
433
|
+
calendarId?: string;
|
|
434
|
+
}
|
|
435
|
+
export interface SchedulerAvailabilityResponse {
|
|
436
|
+
order?: string[];
|
|
437
|
+
timeSlots: SchedulerAvailabilityTimeSlot[];
|
|
438
|
+
}
|
|
439
|
+
export interface GetSchedulerAvailabilityQueryParams {
|
|
440
|
+
startTime: number;
|
|
441
|
+
endTime: number;
|
|
442
|
+
configurationId?: string;
|
|
443
|
+
slug?: string;
|
|
444
|
+
clientId?: string;
|
|
445
|
+
bookingId?: string;
|
|
446
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { Overrides } from '../config.js';
|
|
2
|
+
import { NylasResponse } from '../models/response.js';
|
|
3
|
+
import { SchedulerAvailabilityResponse, GetSchedulerAvailabilityQueryParams } from '../models/scheduler.js';
|
|
4
|
+
import { Resource } from './resource.js';
|
|
5
|
+
/**
|
|
6
|
+
* The parameters for the {@link SchedulerAvailability.get} method
|
|
7
|
+
* @property queryParams The query parameters to include in the request
|
|
8
|
+
*/
|
|
9
|
+
export interface GetSchedulerAvailabilityParams {
|
|
10
|
+
queryParams: GetSchedulerAvailabilityQueryParams;
|
|
11
|
+
}
|
|
12
|
+
export declare class SchedulerAvailability extends Resource {
|
|
13
|
+
/**
|
|
14
|
+
* Get availability for a scheduling configuration
|
|
15
|
+
* @return The availability response with time slots
|
|
16
|
+
*/
|
|
17
|
+
get({ queryParams, overrides, }: GetSchedulerAvailabilityParams & Overrides): Promise<NylasResponse<SchedulerAvailabilityResponse>>;
|
|
18
|
+
}
|
|
@@ -1,10 +1,12 @@
|
|
|
1
1
|
import { Configurations } from './configurations.js';
|
|
2
2
|
import { Sessions } from './sessions.js';
|
|
3
3
|
import { Bookings } from './bookings.js';
|
|
4
|
+
import { SchedulerAvailability } from './availability.js';
|
|
4
5
|
import APIClient from '../apiClient.js';
|
|
5
6
|
export declare class Scheduler {
|
|
6
7
|
configurations: Configurations;
|
|
7
8
|
bookings: Bookings;
|
|
8
9
|
sessions: Sessions;
|
|
10
|
+
availability: SchedulerAvailability;
|
|
9
11
|
constructor(apiClient: APIClient);
|
|
10
12
|
}
|
package/lib/types/version.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const SDK_VERSION = "8.0.
|
|
1
|
+
export declare const SDK_VERSION = "8.0.5";
|