@kajidog/connpass-api-client 0.1.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.
- package/LICENCE +21 -0
- package/README.md +184 -0
- package/dist/application/ConnpassClient.d.ts +41 -0
- package/dist/application/ConnpassClient.d.ts.map +1 -0
- package/dist/application/ConnpassClient.js +108 -0
- package/dist/application/ConnpassClient.js.map +1 -0
- package/dist/application/services/EventService.d.ts +10 -0
- package/dist/application/services/EventService.d.ts.map +1 -0
- package/dist/application/services/EventService.js +45 -0
- package/dist/application/services/EventService.js.map +1 -0
- package/dist/application/services/GroupService.d.ts +9 -0
- package/dist/application/services/GroupService.d.ts.map +1 -0
- package/dist/application/services/GroupService.js +39 -0
- package/dist/application/services/GroupService.js.map +1 -0
- package/dist/application/services/UserService.d.ts +25 -0
- package/dist/application/services/UserService.d.ts.map +1 -0
- package/dist/application/services/UserService.js +76 -0
- package/dist/application/services/UserService.js.map +1 -0
- package/dist/application/services/index.d.ts +4 -0
- package/dist/application/services/index.d.ts.map +1 -0
- package/dist/application/services/index.js +20 -0
- package/dist/application/services/index.js.map +1 -0
- package/dist/domain/entities/Event.d.ts +46 -0
- package/dist/domain/entities/Event.d.ts.map +1 -0
- package/dist/domain/entities/Event.js +3 -0
- package/dist/domain/entities/Event.js.map +1 -0
- package/dist/domain/entities/Group.d.ts +28 -0
- package/dist/domain/entities/Group.d.ts.map +1 -0
- package/dist/domain/entities/Group.js +3 -0
- package/dist/domain/entities/Group.js.map +1 -0
- package/dist/domain/entities/Presentation.d.ts +17 -0
- package/dist/domain/entities/Presentation.d.ts.map +1 -0
- package/dist/domain/entities/Presentation.js +3 -0
- package/dist/domain/entities/Presentation.js.map +1 -0
- package/dist/domain/entities/User.d.ts +23 -0
- package/dist/domain/entities/User.d.ts.map +1 -0
- package/dist/domain/entities/User.js +3 -0
- package/dist/domain/entities/User.js.map +1 -0
- package/dist/domain/entities/index.d.ts +5 -0
- package/dist/domain/entities/index.d.ts.map +1 -0
- package/dist/domain/entities/index.js +21 -0
- package/dist/domain/entities/index.js.map +1 -0
- package/dist/domain/errors/ConnpassError.d.ts +18 -0
- package/dist/domain/errors/ConnpassError.d.ts.map +1 -0
- package/dist/domain/errors/ConnpassError.js +46 -0
- package/dist/domain/errors/ConnpassError.js.map +1 -0
- package/dist/domain/errors/index.d.ts +2 -0
- package/dist/domain/errors/index.d.ts.map +1 -0
- package/dist/domain/errors/index.js +18 -0
- package/dist/domain/errors/index.js.map +1 -0
- package/dist/domain/repositories/IEventRepository.d.ts +6 -0
- package/dist/domain/repositories/IEventRepository.d.ts.map +1 -0
- package/dist/domain/repositories/IEventRepository.js +3 -0
- package/dist/domain/repositories/IEventRepository.js.map +1 -0
- package/dist/domain/repositories/IGroupRepository.d.ts +5 -0
- package/dist/domain/repositories/IGroupRepository.d.ts.map +1 -0
- package/dist/domain/repositories/IGroupRepository.js +3 -0
- package/dist/domain/repositories/IGroupRepository.js.map +1 -0
- package/dist/domain/repositories/IUserRepository.d.ts +19 -0
- package/dist/domain/repositories/IUserRepository.d.ts.map +1 -0
- package/dist/domain/repositories/IUserRepository.js +3 -0
- package/dist/domain/repositories/IUserRepository.js.map +1 -0
- package/dist/domain/repositories/index.d.ts +4 -0
- package/dist/domain/repositories/index.d.ts.map +1 -0
- package/dist/domain/repositories/index.js +20 -0
- package/dist/domain/repositories/index.js.map +1 -0
- package/dist/domain/utils/validators.d.ts +9 -0
- package/dist/domain/utils/validators.d.ts.map +1 -0
- package/dist/domain/utils/validators.js +76 -0
- package/dist/domain/utils/validators.js.map +1 -0
- package/dist/index.d.ts +6 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +24 -0
- package/dist/index.js.map +1 -0
- package/dist/infrastructure/cache/PresentationCache.d.ts +20 -0
- package/dist/infrastructure/cache/PresentationCache.d.ts.map +1 -0
- package/dist/infrastructure/cache/PresentationCache.js +91 -0
- package/dist/infrastructure/cache/PresentationCache.js.map +1 -0
- package/dist/infrastructure/http/HttpClient.d.ts +17 -0
- package/dist/infrastructure/http/HttpClient.d.ts.map +1 -0
- package/dist/infrastructure/http/HttpClient.js +75 -0
- package/dist/infrastructure/http/HttpClient.js.map +1 -0
- package/dist/infrastructure/repositories/EventRepository.d.ts +14 -0
- package/dist/infrastructure/repositories/EventRepository.d.ts.map +1 -0
- package/dist/infrastructure/repositories/EventRepository.js +117 -0
- package/dist/infrastructure/repositories/EventRepository.js.map +1 -0
- package/dist/infrastructure/repositories/GroupRepository.d.ts +10 -0
- package/dist/infrastructure/repositories/GroupRepository.d.ts.map +1 -0
- package/dist/infrastructure/repositories/GroupRepository.js +35 -0
- package/dist/infrastructure/repositories/GroupRepository.js.map +1 -0
- package/dist/infrastructure/repositories/UserRepository.d.ts +24 -0
- package/dist/infrastructure/repositories/UserRepository.d.ts.map +1 -0
- package/dist/infrastructure/repositories/UserRepository.js +68 -0
- package/dist/infrastructure/repositories/UserRepository.js.map +1 -0
- package/dist/infrastructure/repositories/index.d.ts +4 -0
- package/dist/infrastructure/repositories/index.d.ts.map +1 -0
- package/dist/infrastructure/repositories/index.js +20 -0
- package/dist/infrastructure/repositories/index.js.map +1 -0
- package/package.json +51 -0
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
export interface Event {
|
|
2
|
+
id: number;
|
|
3
|
+
title: string;
|
|
4
|
+
catchPhrase: string;
|
|
5
|
+
description: string;
|
|
6
|
+
url: string;
|
|
7
|
+
imageUrl?: string;
|
|
8
|
+
hashTag: string;
|
|
9
|
+
startedAt: string;
|
|
10
|
+
endedAt: string;
|
|
11
|
+
limit?: number;
|
|
12
|
+
participantCount: number;
|
|
13
|
+
waitingCount: number;
|
|
14
|
+
ownerNickname: string;
|
|
15
|
+
ownerDisplayName: string;
|
|
16
|
+
place?: string;
|
|
17
|
+
address?: string;
|
|
18
|
+
lat?: number;
|
|
19
|
+
lon?: number;
|
|
20
|
+
groupId?: number;
|
|
21
|
+
groupTitle?: string;
|
|
22
|
+
groupUrl?: string;
|
|
23
|
+
updatedAt: string;
|
|
24
|
+
}
|
|
25
|
+
export interface EventSearchParams {
|
|
26
|
+
eventId?: number[];
|
|
27
|
+
keyword?: string;
|
|
28
|
+
keywordOr?: string;
|
|
29
|
+
ymd?: string[];
|
|
30
|
+
ymdFrom?: string;
|
|
31
|
+
ymdTo?: string;
|
|
32
|
+
nickname?: string;
|
|
33
|
+
ownerNickname?: string;
|
|
34
|
+
groupId?: number[];
|
|
35
|
+
prefecture?: string[];
|
|
36
|
+
count?: number;
|
|
37
|
+
order?: 1 | 2 | 3;
|
|
38
|
+
start?: number;
|
|
39
|
+
}
|
|
40
|
+
export interface EventsResponse {
|
|
41
|
+
eventsReturned: number;
|
|
42
|
+
eventsAvailable: number;
|
|
43
|
+
eventsStart: number;
|
|
44
|
+
events: Event[];
|
|
45
|
+
}
|
|
46
|
+
//# sourceMappingURL=Event.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Event.d.ts","sourceRoot":"","sources":["../../../src/domain/entities/Event.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,KAAK;IACpB,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,EAAE,MAAM,CAAC;IACpB,WAAW,EAAE,MAAM,CAAC;IACpB,GAAG,EAAE,MAAM,CAAC;IAEZ,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,OAAO,EAAE,MAAM,CAAC;IAChB,SAAS,EAAE,MAAM,CAAC;IAClB,OAAO,EAAE,MAAM,CAAC;IAChB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,gBAAgB,EAAE,MAAM,CAAC;IACzB,YAAY,EAAE,MAAM,CAAC;IACrB,aAAa,EAAE,MAAM,CAAC;IACtB,gBAAgB,EAAE,MAAM,CAAC;IACzB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,SAAS,EAAE,MAAM,CAAC;CACnB;AAED,MAAM,WAAW,iBAAiB;IAChC,OAAO,CAAC,EAAE,MAAM,EAAE,CAAC;IACnB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,GAAG,CAAC,EAAE,MAAM,EAAE,CAAC;IACf,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,OAAO,CAAC,EAAE,MAAM,EAAE,CAAC;IACnB,UAAU,CAAC,EAAE,MAAM,EAAE,CAAC;IACtB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;IAClB,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED,MAAM,WAAW,cAAc;IAC7B,cAAc,EAAE,MAAM,CAAC;IACvB,eAAe,EAAE,MAAM,CAAC;IACxB,WAAW,EAAE,MAAM,CAAC;IACpB,MAAM,EAAE,KAAK,EAAE,CAAC;CACjB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Event.js","sourceRoot":"","sources":["../../../src/domain/entities/Event.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
export interface Group {
|
|
2
|
+
id: number;
|
|
3
|
+
title: string;
|
|
4
|
+
description: string;
|
|
5
|
+
url: string;
|
|
6
|
+
countryCode: string;
|
|
7
|
+
prefecture: string;
|
|
8
|
+
place: string;
|
|
9
|
+
lat?: number;
|
|
10
|
+
lon?: number;
|
|
11
|
+
updatedAt: string;
|
|
12
|
+
}
|
|
13
|
+
export interface GroupSearchParams {
|
|
14
|
+
groupId?: number[];
|
|
15
|
+
keyword?: string;
|
|
16
|
+
countryCode?: string;
|
|
17
|
+
prefecture?: string;
|
|
18
|
+
count?: number;
|
|
19
|
+
order?: 1 | 2 | 3;
|
|
20
|
+
start?: number;
|
|
21
|
+
}
|
|
22
|
+
export interface GroupsResponse {
|
|
23
|
+
groupsReturned: number;
|
|
24
|
+
groupsAvailable: number;
|
|
25
|
+
groupsStart: number;
|
|
26
|
+
groups: Group[];
|
|
27
|
+
}
|
|
28
|
+
//# sourceMappingURL=Group.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Group.d.ts","sourceRoot":"","sources":["../../../src/domain/entities/Group.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,KAAK;IACpB,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,EAAE,MAAM,CAAC;IACpB,GAAG,EAAE,MAAM,CAAC;IACZ,WAAW,EAAE,MAAM,CAAC;IACpB,UAAU,EAAE,MAAM,CAAC;IACnB,KAAK,EAAE,MAAM,CAAC;IACd,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,SAAS,EAAE,MAAM,CAAC;CACnB;AAED,MAAM,WAAW,iBAAiB;IAChC,OAAO,CAAC,EAAE,MAAM,EAAE,CAAC;IACnB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;IAClB,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED,MAAM,WAAW,cAAc;IAC7B,cAAc,EAAE,MAAM,CAAC;IACvB,eAAe,EAAE,MAAM,CAAC;IACxB,WAAW,EAAE,MAAM,CAAC;IACpB,MAAM,EAAE,KAAK,EAAE,CAAC;CACjB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Group.js","sourceRoot":"","sources":["../../../src/domain/entities/Group.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
export interface Presentation {
|
|
2
|
+
id: number;
|
|
3
|
+
title: string;
|
|
4
|
+
speakerName: string;
|
|
5
|
+
description: string;
|
|
6
|
+
url?: string;
|
|
7
|
+
slideshareUrl?: string;
|
|
8
|
+
youtubeUrl?: string;
|
|
9
|
+
twitterUrl?: string;
|
|
10
|
+
order: number;
|
|
11
|
+
updatedAt: string;
|
|
12
|
+
}
|
|
13
|
+
export interface PresentationsResponse {
|
|
14
|
+
presentationsReturned: number;
|
|
15
|
+
presentations: Presentation[];
|
|
16
|
+
}
|
|
17
|
+
//# sourceMappingURL=Presentation.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Presentation.d.ts","sourceRoot":"","sources":["../../../src/domain/entities/Presentation.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,YAAY;IAC3B,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,EAAE,MAAM,CAAC;IACpB,WAAW,EAAE,MAAM,CAAC;IACpB,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,KAAK,EAAE,MAAM,CAAC;IACd,SAAS,EAAE,MAAM,CAAC;CACnB;AAED,MAAM,WAAW,qBAAqB;IACpC,qBAAqB,EAAE,MAAM,CAAC;IAC9B,aAAa,EAAE,YAAY,EAAE,CAAC;CAC/B"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Presentation.js","sourceRoot":"","sources":["../../../src/domain/entities/Presentation.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
export interface User {
|
|
2
|
+
id: number;
|
|
3
|
+
nickname: string;
|
|
4
|
+
displayName: string;
|
|
5
|
+
twitterUsername?: string;
|
|
6
|
+
githubUsername?: string;
|
|
7
|
+
url?: string;
|
|
8
|
+
updatedAt: string;
|
|
9
|
+
}
|
|
10
|
+
export interface UserSearchParams {
|
|
11
|
+
userId?: number[];
|
|
12
|
+
nickname?: string;
|
|
13
|
+
count?: number;
|
|
14
|
+
order?: 1 | 2 | 3;
|
|
15
|
+
start?: number;
|
|
16
|
+
}
|
|
17
|
+
export interface UsersResponse {
|
|
18
|
+
usersReturned: number;
|
|
19
|
+
usersAvailable: number;
|
|
20
|
+
usersStart: number;
|
|
21
|
+
users: User[];
|
|
22
|
+
}
|
|
23
|
+
//# sourceMappingURL=User.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"User.d.ts","sourceRoot":"","sources":["../../../src/domain/entities/User.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,IAAI;IACnB,EAAE,EAAE,MAAM,CAAC;IACX,QAAQ,EAAE,MAAM,CAAC;IACjB,WAAW,EAAE,MAAM,CAAC;IACpB,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,SAAS,EAAE,MAAM,CAAC;CACnB;AAED,MAAM,WAAW,gBAAgB;IAC/B,MAAM,CAAC,EAAE,MAAM,EAAE,CAAC;IAClB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;IAClB,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED,MAAM,WAAW,aAAa;IAC5B,aAAa,EAAE,MAAM,CAAC;IACtB,cAAc,EAAE,MAAM,CAAC;IACvB,UAAU,EAAE,MAAM,CAAC;IACnB,KAAK,EAAE,IAAI,EAAE,CAAC;CACf"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"User.js","sourceRoot":"","sources":["../../../src/domain/entities/User.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/domain/entities/index.ts"],"names":[],"mappings":"AAAA,cAAc,SAAS,CAAC;AACxB,cAAc,SAAS,CAAC;AACxB,cAAc,QAAQ,CAAC;AACvB,cAAc,gBAAgB,CAAC"}
|
|
@@ -0,0 +1,21 @@
|
|
|
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("./Event"), exports);
|
|
18
|
+
__exportStar(require("./Group"), exports);
|
|
19
|
+
__exportStar(require("./User"), exports);
|
|
20
|
+
__exportStar(require("./Presentation"), exports);
|
|
21
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/domain/entities/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,0CAAwB;AACxB,0CAAwB;AACxB,yCAAuB;AACvB,iDAA+B"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
export declare class ConnpassError extends Error {
|
|
2
|
+
readonly statusCode?: number | undefined;
|
|
3
|
+
readonly response?: any | undefined;
|
|
4
|
+
constructor(message: string, statusCode?: number | undefined, response?: any | undefined);
|
|
5
|
+
}
|
|
6
|
+
export declare class ConnpassApiError extends ConnpassError {
|
|
7
|
+
constructor(message: string, statusCode: number, response: any);
|
|
8
|
+
}
|
|
9
|
+
export declare class ConnpassRateLimitError extends ConnpassError {
|
|
10
|
+
constructor(message?: string);
|
|
11
|
+
}
|
|
12
|
+
export declare class ConnpassValidationError extends ConnpassError {
|
|
13
|
+
constructor(message: string);
|
|
14
|
+
}
|
|
15
|
+
export declare class ConnpassTimeoutError extends ConnpassError {
|
|
16
|
+
constructor(message?: string);
|
|
17
|
+
}
|
|
18
|
+
//# sourceMappingURL=ConnpassError.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ConnpassError.d.ts","sourceRoot":"","sources":["../../../src/domain/errors/ConnpassError.ts"],"names":[],"mappings":"AAAA,qBAAa,aAAc,SAAQ,KAAK;aAGpB,UAAU,CAAC,EAAE,MAAM;aACnB,QAAQ,CAAC,EAAE,GAAG;gBAF9B,OAAO,EAAE,MAAM,EACC,UAAU,CAAC,EAAE,MAAM,YAAA,EACnB,QAAQ,CAAC,EAAE,GAAG,YAAA;CAMjC;AAED,qBAAa,gBAAiB,SAAQ,aAAa;gBACrC,OAAO,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,EAAE,QAAQ,EAAE,GAAG;CAK/D;AAED,qBAAa,sBAAuB,SAAQ,aAAa;gBAC3C,OAAO,SAAwB;CAK5C;AAED,qBAAa,uBAAwB,SAAQ,aAAa;gBAC5C,OAAO,EAAE,MAAM;CAK5B;AAED,qBAAa,oBAAqB,SAAQ,aAAa;gBACzC,OAAO,SAAoB;CAKxC"}
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ConnpassTimeoutError = exports.ConnpassValidationError = exports.ConnpassRateLimitError = exports.ConnpassApiError = exports.ConnpassError = void 0;
|
|
4
|
+
class ConnpassError extends Error {
|
|
5
|
+
constructor(message, statusCode, response) {
|
|
6
|
+
super(message);
|
|
7
|
+
this.statusCode = statusCode;
|
|
8
|
+
this.response = response;
|
|
9
|
+
this.name = 'ConnpassError';
|
|
10
|
+
Object.setPrototypeOf(this, ConnpassError.prototype);
|
|
11
|
+
}
|
|
12
|
+
}
|
|
13
|
+
exports.ConnpassError = ConnpassError;
|
|
14
|
+
class ConnpassApiError extends ConnpassError {
|
|
15
|
+
constructor(message, statusCode, response) {
|
|
16
|
+
super(`API Error: ${message}`, statusCode, response);
|
|
17
|
+
this.name = 'ConnpassApiError';
|
|
18
|
+
Object.setPrototypeOf(this, ConnpassApiError.prototype);
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
exports.ConnpassApiError = ConnpassApiError;
|
|
22
|
+
class ConnpassRateLimitError extends ConnpassError {
|
|
23
|
+
constructor(message = 'Rate limit exceeded') {
|
|
24
|
+
super(message, 429);
|
|
25
|
+
this.name = 'ConnpassRateLimitError';
|
|
26
|
+
Object.setPrototypeOf(this, ConnpassRateLimitError.prototype);
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
exports.ConnpassRateLimitError = ConnpassRateLimitError;
|
|
30
|
+
class ConnpassValidationError extends ConnpassError {
|
|
31
|
+
constructor(message) {
|
|
32
|
+
super(`Validation Error: ${message}`);
|
|
33
|
+
this.name = 'ConnpassValidationError';
|
|
34
|
+
Object.setPrototypeOf(this, ConnpassValidationError.prototype);
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
exports.ConnpassValidationError = ConnpassValidationError;
|
|
38
|
+
class ConnpassTimeoutError extends ConnpassError {
|
|
39
|
+
constructor(message = 'Request timeout') {
|
|
40
|
+
super(message);
|
|
41
|
+
this.name = 'ConnpassTimeoutError';
|
|
42
|
+
Object.setPrototypeOf(this, ConnpassTimeoutError.prototype);
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
exports.ConnpassTimeoutError = ConnpassTimeoutError;
|
|
46
|
+
//# sourceMappingURL=ConnpassError.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ConnpassError.js","sourceRoot":"","sources":["../../../src/domain/errors/ConnpassError.ts"],"names":[],"mappings":";;;AAAA,MAAa,aAAc,SAAQ,KAAK;IACtC,YACE,OAAe,EACC,UAAmB,EACnB,QAAc;QAE9B,KAAK,CAAC,OAAO,CAAC,CAAC;QAHC,eAAU,GAAV,UAAU,CAAS;QACnB,aAAQ,GAAR,QAAQ,CAAM;QAG9B,IAAI,CAAC,IAAI,GAAG,eAAe,CAAC;QAC5B,MAAM,CAAC,cAAc,CAAC,IAAI,EAAE,aAAa,CAAC,SAAS,CAAC,CAAC;IACvD,CAAC;CACF;AAVD,sCAUC;AAED,MAAa,gBAAiB,SAAQ,aAAa;IACjD,YAAY,OAAe,EAAE,UAAkB,EAAE,QAAa;QAC5D,KAAK,CAAC,cAAc,OAAO,EAAE,EAAE,UAAU,EAAE,QAAQ,CAAC,CAAC;QACrD,IAAI,CAAC,IAAI,GAAG,kBAAkB,CAAC;QAC/B,MAAM,CAAC,cAAc,CAAC,IAAI,EAAE,gBAAgB,CAAC,SAAS,CAAC,CAAC;IAC1D,CAAC;CACF;AAND,4CAMC;AAED,MAAa,sBAAuB,SAAQ,aAAa;IACvD,YAAY,OAAO,GAAG,qBAAqB;QACzC,KAAK,CAAC,OAAO,EAAE,GAAG,CAAC,CAAC;QACpB,IAAI,CAAC,IAAI,GAAG,wBAAwB,CAAC;QACrC,MAAM,CAAC,cAAc,CAAC,IAAI,EAAE,sBAAsB,CAAC,SAAS,CAAC,CAAC;IAChE,CAAC;CACF;AAND,wDAMC;AAED,MAAa,uBAAwB,SAAQ,aAAa;IACxD,YAAY,OAAe;QACzB,KAAK,CAAC,qBAAqB,OAAO,EAAE,CAAC,CAAC;QACtC,IAAI,CAAC,IAAI,GAAG,yBAAyB,CAAC;QACtC,MAAM,CAAC,cAAc,CAAC,IAAI,EAAE,uBAAuB,CAAC,SAAS,CAAC,CAAC;IACjE,CAAC;CACF;AAND,0DAMC;AAED,MAAa,oBAAqB,SAAQ,aAAa;IACrD,YAAY,OAAO,GAAG,iBAAiB;QACrC,KAAK,CAAC,OAAO,CAAC,CAAC;QACf,IAAI,CAAC,IAAI,GAAG,sBAAsB,CAAC;QACnC,MAAM,CAAC,cAAc,CAAC,IAAI,EAAE,oBAAoB,CAAC,SAAS,CAAC,CAAC;IAC9D,CAAC;CACF;AAND,oDAMC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/domain/errors/index.ts"],"names":[],"mappings":"AAAA,cAAc,iBAAiB,CAAC"}
|
|
@@ -0,0 +1,18 @@
|
|
|
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("./ConnpassError"), exports);
|
|
18
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/domain/errors/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,kDAAgC"}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { EventSearchParams, EventsResponse, PresentationsResponse } from '../entities';
|
|
2
|
+
export interface IEventRepository {
|
|
3
|
+
searchEvents(params: EventSearchParams): Promise<EventsResponse>;
|
|
4
|
+
getEventPresentations(eventId: number): Promise<PresentationsResponse>;
|
|
5
|
+
}
|
|
6
|
+
//# sourceMappingURL=IEventRepository.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"IEventRepository.d.ts","sourceRoot":"","sources":["../../../src/domain/repositories/IEventRepository.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,cAAc,EAAE,qBAAqB,EAAE,MAAM,aAAa,CAAC;AAEvF,MAAM,WAAW,gBAAgB;IAC/B,YAAY,CAAC,MAAM,EAAE,iBAAiB,GAAG,OAAO,CAAC,cAAc,CAAC,CAAC;IACjE,qBAAqB,CAAC,OAAO,EAAE,MAAM,GAAG,OAAO,CAAC,qBAAqB,CAAC,CAAC;CACxE"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"IEventRepository.js","sourceRoot":"","sources":["../../../src/domain/repositories/IEventRepository.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"IGroupRepository.d.ts","sourceRoot":"","sources":["../../../src/domain/repositories/IGroupRepository.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAEhE,MAAM,WAAW,gBAAgB;IAC/B,YAAY,CAAC,MAAM,EAAE,iBAAiB,GAAG,OAAO,CAAC,cAAc,CAAC,CAAC;CAClE"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"IGroupRepository.js","sourceRoot":"","sources":["../../../src/domain/repositories/IGroupRepository.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { UserSearchParams, UsersResponse, GroupsResponse, EventsResponse } from '../entities';
|
|
2
|
+
export interface IUserRepository {
|
|
3
|
+
searchUsers(params: UserSearchParams): Promise<UsersResponse>;
|
|
4
|
+
getUserGroups(nickname: string, params?: {
|
|
5
|
+
count?: number;
|
|
6
|
+
start?: number;
|
|
7
|
+
}): Promise<GroupsResponse>;
|
|
8
|
+
getUserAttendedEvents(nickname: string, params?: {
|
|
9
|
+
count?: number;
|
|
10
|
+
order?: 1 | 2 | 3;
|
|
11
|
+
start?: number;
|
|
12
|
+
}): Promise<EventsResponse>;
|
|
13
|
+
getUserPresenterEvents(nickname: string, params?: {
|
|
14
|
+
count?: number;
|
|
15
|
+
order?: 1 | 2 | 3;
|
|
16
|
+
start?: number;
|
|
17
|
+
}): Promise<EventsResponse>;
|
|
18
|
+
}
|
|
19
|
+
//# sourceMappingURL=IUserRepository.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"IUserRepository.d.ts","sourceRoot":"","sources":["../../../src/domain/repositories/IUserRepository.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,aAAa,EAAE,cAAc,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAE9F,MAAM,WAAW,eAAe;IAC9B,WAAW,CAAC,MAAM,EAAE,gBAAgB,GAAG,OAAO,CAAC,aAAa,CAAC,CAAC;IAC9D,aAAa,CAAC,QAAQ,EAAE,MAAM,EAAE,MAAM,CAAC,EAAE;QAAE,KAAK,CAAC,EAAE,MAAM,CAAC;QAAC,KAAK,CAAC,EAAE,MAAM,CAAA;KAAE,GAAG,OAAO,CAAC,cAAc,CAAC,CAAC;IACtG,qBAAqB,CACnB,QAAQ,EAAE,MAAM,EAChB,MAAM,CAAC,EAAE;QAAE,KAAK,CAAC,EAAE,MAAM,CAAC;QAAC,KAAK,CAAC,EAAE,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;QAAC,KAAK,CAAC,EAAE,MAAM,CAAA;KAAE,GAC7D,OAAO,CAAC,cAAc,CAAC,CAAC;IAC3B,sBAAsB,CACpB,QAAQ,EAAE,MAAM,EAChB,MAAM,CAAC,EAAE;QAAE,KAAK,CAAC,EAAE,MAAM,CAAC;QAAC,KAAK,CAAC,EAAE,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;QAAC,KAAK,CAAC,EAAE,MAAM,CAAA;KAAE,GAC7D,OAAO,CAAC,cAAc,CAAC,CAAC;CAC5B"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"IUserRepository.js","sourceRoot":"","sources":["../../../src/domain/repositories/IUserRepository.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/domain/repositories/index.ts"],"names":[],"mappings":"AAAA,cAAc,oBAAoB,CAAC;AACnC,cAAc,oBAAoB,CAAC;AACnC,cAAc,mBAAmB,CAAC"}
|
|
@@ -0,0 +1,20 @@
|
|
|
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("./IEventRepository"), exports);
|
|
18
|
+
__exportStar(require("./IGroupRepository"), exports);
|
|
19
|
+
__exportStar(require("./IUserRepository"), exports);
|
|
20
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/domain/repositories/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,qDAAmC;AACnC,qDAAmC;AACnC,oDAAkC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { EventSearchParams, GroupSearchParams, UserSearchParams } from '../../domain/entities';
|
|
2
|
+
export declare class Validators {
|
|
3
|
+
static validateEventSearchParams(params: EventSearchParams): void;
|
|
4
|
+
static validateGroupSearchParams(params: GroupSearchParams): void;
|
|
5
|
+
static validateUserSearchParams(params: UserSearchParams): void;
|
|
6
|
+
static validatePositiveInteger(value: number, fieldName: string): void;
|
|
7
|
+
static validateNickname(value: string, fieldName?: string): void;
|
|
8
|
+
}
|
|
9
|
+
//# sourceMappingURL=validators.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"validators.d.ts","sourceRoot":"","sources":["../../../src/domain/utils/validators.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,iBAAiB,EAAE,iBAAiB,EAAE,gBAAgB,EAAE,MAAM,uBAAuB,CAAC;AAE/F,qBAAa,UAAU;IACrB,MAAM,CAAC,yBAAyB,CAAC,MAAM,EAAE,iBAAiB,GAAG,IAAI;IAsCjE,MAAM,CAAC,yBAAyB,CAAC,MAAM,EAAE,iBAAiB,GAAG,IAAI;IAkBjE,MAAM,CAAC,wBAAwB,CAAC,MAAM,EAAE,gBAAgB,GAAG,IAAI;IAkB/D,MAAM,CAAC,uBAAuB,CAAC,KAAK,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,GAAG,IAAI;IAMtE,MAAM,CAAC,gBAAgB,CAAC,KAAK,EAAE,MAAM,EAAE,SAAS,GAAE,MAAmB,GAAG,IAAI;CAK7E"}
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.Validators = void 0;
|
|
4
|
+
const errors_1 = require("../../domain/errors");
|
|
5
|
+
class Validators {
|
|
6
|
+
static validateEventSearchParams(params) {
|
|
7
|
+
if (params.count !== undefined && (params.count < 1 || params.count > 100)) {
|
|
8
|
+
throw new errors_1.ConnpassValidationError('Count must be between 1 and 100');
|
|
9
|
+
}
|
|
10
|
+
if (params.start !== undefined && params.start < 1) {
|
|
11
|
+
throw new errors_1.ConnpassValidationError('Start must be greater than 0');
|
|
12
|
+
}
|
|
13
|
+
if (params.order !== undefined && ![1, 2, 3].includes(params.order)) {
|
|
14
|
+
throw new errors_1.ConnpassValidationError('Order must be 1 (updated_at desc), 2 (started_at asc), or 3 (started_at desc)');
|
|
15
|
+
}
|
|
16
|
+
if (params.eventId && params.eventId.some(id => id <= 0)) {
|
|
17
|
+
throw new errors_1.ConnpassValidationError('All event IDs must be positive numbers');
|
|
18
|
+
}
|
|
19
|
+
if (params.groupId && params.groupId.some(id => id <= 0)) {
|
|
20
|
+
throw new errors_1.ConnpassValidationError('All group IDs must be positive numbers');
|
|
21
|
+
}
|
|
22
|
+
if (params.ymdFrom && !/^\d{4}-\d{2}-\d{2}$/.test(params.ymdFrom)) {
|
|
23
|
+
throw new errors_1.ConnpassValidationError('ymdFrom must be in YYYY-MM-DD format');
|
|
24
|
+
}
|
|
25
|
+
if (params.ymdTo && !/^\d{4}-\d{2}-\d{2}$/.test(params.ymdTo)) {
|
|
26
|
+
throw new errors_1.ConnpassValidationError('ymdTo must be in YYYY-MM-DD format');
|
|
27
|
+
}
|
|
28
|
+
if (params.ymd) {
|
|
29
|
+
for (const d of params.ymd) {
|
|
30
|
+
if (!/^\d{8}$/.test(d)) {
|
|
31
|
+
throw new errors_1.ConnpassValidationError('ymd must be an array of dates in YYYYMMDD format');
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
static validateGroupSearchParams(params) {
|
|
37
|
+
if (params.count !== undefined && (params.count < 1 || params.count > 100)) {
|
|
38
|
+
throw new errors_1.ConnpassValidationError('Count must be between 1 and 100');
|
|
39
|
+
}
|
|
40
|
+
if (params.start !== undefined && params.start < 1) {
|
|
41
|
+
throw new errors_1.ConnpassValidationError('Start must be greater than 0');
|
|
42
|
+
}
|
|
43
|
+
if (params.order !== undefined && ![1, 2, 3].includes(params.order)) {
|
|
44
|
+
throw new errors_1.ConnpassValidationError('Order must be 1 (updated_at desc), 2 (started_at asc), or 3 (started_at desc)');
|
|
45
|
+
}
|
|
46
|
+
if (params.groupId && params.groupId.some(id => id <= 0)) {
|
|
47
|
+
throw new errors_1.ConnpassValidationError('All group IDs must be positive numbers');
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
static validateUserSearchParams(params) {
|
|
51
|
+
if (params.count !== undefined && (params.count < 1 || params.count > 100)) {
|
|
52
|
+
throw new errors_1.ConnpassValidationError('Count must be between 1 and 100');
|
|
53
|
+
}
|
|
54
|
+
if (params.start !== undefined && params.start < 1) {
|
|
55
|
+
throw new errors_1.ConnpassValidationError('Start must be greater than 0');
|
|
56
|
+
}
|
|
57
|
+
if (params.order !== undefined && ![1, 2, 3].includes(params.order)) {
|
|
58
|
+
throw new errors_1.ConnpassValidationError('Order must be 1 (updated_at desc), 2 (started_at asc), or 3 (started_at desc)');
|
|
59
|
+
}
|
|
60
|
+
if (params.userId && params.userId.some(id => id <= 0)) {
|
|
61
|
+
throw new errors_1.ConnpassValidationError('All user IDs must be positive numbers');
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
static validatePositiveInteger(value, fieldName) {
|
|
65
|
+
if (!Number.isInteger(value) || value <= 0) {
|
|
66
|
+
throw new errors_1.ConnpassValidationError(`${fieldName} must be a positive integer`);
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
static validateNickname(value, fieldName = 'nickname') {
|
|
70
|
+
if (typeof value !== 'string' || value.trim().length === 0) {
|
|
71
|
+
throw new errors_1.ConnpassValidationError(`${fieldName} must be a non-empty string`);
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
exports.Validators = Validators;
|
|
76
|
+
//# sourceMappingURL=validators.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"validators.js","sourceRoot":"","sources":["../../../src/domain/utils/validators.ts"],"names":[],"mappings":"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"}
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
export { ConnpassClient, ConnpassClientConfig } from './application/ConnpassClient';
|
|
2
|
+
export * from './domain/entities';
|
|
3
|
+
export * from './domain/errors';
|
|
4
|
+
import { ConnpassClient } from './application/ConnpassClient';
|
|
5
|
+
export default ConnpassClient;
|
|
6
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,oBAAoB,EAAE,MAAM,8BAA8B,CAAC;AACpF,cAAc,mBAAmB,CAAC;AAClC,cAAc,iBAAiB,CAAC;AAEhC,OAAO,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AAC9D,eAAe,cAAc,CAAC"}
|
package/dist/index.js
ADDED
|
@@ -0,0 +1,24 @@
|
|
|
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
|
+
exports.ConnpassClient = void 0;
|
|
18
|
+
var ConnpassClient_1 = require("./application/ConnpassClient");
|
|
19
|
+
Object.defineProperty(exports, "ConnpassClient", { enumerable: true, get: function () { return ConnpassClient_1.ConnpassClient; } });
|
|
20
|
+
__exportStar(require("./domain/entities"), exports);
|
|
21
|
+
__exportStar(require("./domain/errors"), exports);
|
|
22
|
+
const ConnpassClient_2 = require("./application/ConnpassClient");
|
|
23
|
+
exports.default = ConnpassClient_2.ConnpassClient;
|
|
24
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;AAAA,+DAAoF;AAA3E,gHAAA,cAAc,OAAA;AACvB,oDAAkC;AAClC,kDAAgC;AAEhC,iEAA8D;AAC9D,kBAAe,+BAAc,CAAC"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { PresentationsResponse } from '../../domain/entities';
|
|
2
|
+
export interface PresentationCacheOptions {
|
|
3
|
+
filePath: string;
|
|
4
|
+
ttlMs: number;
|
|
5
|
+
enabled: boolean;
|
|
6
|
+
}
|
|
7
|
+
export declare class PresentationCache {
|
|
8
|
+
private cache;
|
|
9
|
+
private isLoaded;
|
|
10
|
+
private readonly filePath;
|
|
11
|
+
private readonly ttlMs;
|
|
12
|
+
private readonly enabled;
|
|
13
|
+
constructor(options: PresentationCacheOptions);
|
|
14
|
+
get(eventId: number): Promise<PresentationsResponse | undefined>;
|
|
15
|
+
set(eventId: number, data: PresentationsResponse): Promise<void>;
|
|
16
|
+
clear(): Promise<void>;
|
|
17
|
+
private ensureLoaded;
|
|
18
|
+
private persist;
|
|
19
|
+
}
|
|
20
|
+
//# sourceMappingURL=PresentationCache.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"PresentationCache.d.ts","sourceRoot":"","sources":["../../../src/infrastructure/cache/PresentationCache.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,qBAAqB,EAAE,MAAM,uBAAuB,CAAC;AAO9D,MAAM,WAAW,wBAAwB;IACvC,QAAQ,EAAE,MAAM,CAAC;IACjB,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,OAAO,CAAC;CAClB;AAED,qBAAa,iBAAiB;IAC5B,OAAO,CAAC,KAAK,CAAiC;IAC9C,OAAO,CAAC,QAAQ,CAAS;IACzB,OAAO,CAAC,QAAQ,CAAC,QAAQ,CAAS;IAClC,OAAO,CAAC,QAAQ,CAAC,KAAK,CAAS;IAC/B,OAAO,CAAC,QAAQ,CAAC,OAAO,CAAU;gBAEtB,OAAO,EAAE,wBAAwB;IAMvC,GAAG,CAAC,OAAO,EAAE,MAAM,GAAG,OAAO,CAAC,qBAAqB,GAAG,SAAS,CAAC;IAoBhE,GAAG,CAAC,OAAO,EAAE,MAAM,EAAE,IAAI,EAAE,qBAAqB,GAAG,OAAO,CAAC,IAAI,CAAC;IAWhE,KAAK,IAAI,OAAO,CAAC,IAAI,CAAC;YASd,YAAY;YA4BZ,OAAO;CAetB"}
|