@ingestkorea/client-sens 1.0.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/LICENSE +21 -0
- package/README.md +83 -0
- package/dist-cjs/SensClient.js +60 -0
- package/dist-cjs/commands/GetRequestResultCommand.js +39 -0
- package/dist-cjs/commands/GetRequestStatusCommand.js +39 -0
- package/dist-cjs/commands/ListChannelsCommand.js +39 -0
- package/dist-cjs/commands/SendAlimtalkCommand.js +39 -0
- package/dist-cjs/commands/index.js +20 -0
- package/dist-cjs/index.js +18 -0
- package/dist-cjs/middleware/index.js +17 -0
- package/dist-cjs/middleware/signer.js +31 -0
- package/dist-cjs/models/GetRequestResult.js +5 -0
- package/dist-cjs/models/GetRequestStatus.js +5 -0
- package/dist-cjs/models/ListChannels.js +5 -0
- package/dist-cjs/models/SendAlimtalk.js +7 -0
- package/dist-cjs/models/SensCommand.js +11 -0
- package/dist-cjs/models/index.js +21 -0
- package/dist-cjs/protocols/GetRequestResult.js +77 -0
- package/dist-cjs/protocols/GetRequestStatus.js +76 -0
- package/dist-cjs/protocols/ListChannels.js +60 -0
- package/dist-cjs/protocols/SendAlimtalk.js +73 -0
- package/dist-cjs/protocols/constants.js +55 -0
- package/dist-cjs/protocols/index.js +20 -0
- package/dist-es/SensClient.js +45 -0
- package/dist-es/commands/GetRequestResultCommand.js +24 -0
- package/dist-es/commands/GetRequestStatusCommand.js +24 -0
- package/dist-es/commands/ListChannelsCommand.js +24 -0
- package/dist-es/commands/SendAlimtalkCommand.js +24 -0
- package/dist-es/commands/index.js +4 -0
- package/dist-es/index.js +2 -0
- package/dist-es/middleware/index.js +1 -0
- package/dist-es/middleware/signer.js +23 -0
- package/dist-es/models/GetRequestResult.js +4 -0
- package/dist-es/models/GetRequestStatus.js +4 -0
- package/dist-es/models/ListChannels.js +4 -0
- package/dist-es/models/SendAlimtalk.js +6 -0
- package/dist-es/models/SensCommand.js +7 -0
- package/dist-es/models/index.js +5 -0
- package/dist-es/protocols/GetRequestResult.js +63 -0
- package/dist-es/protocols/GetRequestStatus.js +62 -0
- package/dist-es/protocols/ListChannels.js +46 -0
- package/dist-es/protocols/SendAlimtalk.js +59 -0
- package/dist-es/protocols/constants.js +41 -0
- package/dist-es/protocols/index.js +4 -0
- package/dist-types/SensClient.d.ts +21 -0
- package/dist-types/commands/GetRequestResultCommand.d.ts +13 -0
- package/dist-types/commands/GetRequestStatusCommand.d.ts +13 -0
- package/dist-types/commands/ListChannelsCommand.d.ts +13 -0
- package/dist-types/commands/SendAlimtalkCommand.d.ts +13 -0
- package/dist-types/commands/index.d.ts +4 -0
- package/dist-types/index.d.ts +2 -0
- package/dist-types/middleware/index.d.ts +1 -0
- package/dist-types/middleware/signer.d.ts +3 -0
- package/dist-types/models/GetRequestResult.d.ts +20 -0
- package/dist-types/models/GetRequestStatus.d.ts +19 -0
- package/dist-types/models/ListChannels.d.ts +14 -0
- package/dist-types/models/SendAlimtalk.d.ts +33 -0
- package/dist-types/models/SensCommand.d.ts +7 -0
- package/dist-types/models/index.d.ts +5 -0
- package/dist-types/protocols/GetRequestResult.d.ts +8 -0
- package/dist-types/protocols/GetRequestStatus.d.ts +8 -0
- package/dist-types/protocols/ListChannels.d.ts +8 -0
- package/dist-types/protocols/SendAlimtalk.d.ts +8 -0
- package/dist-types/protocols/constants.d.ts +3 -0
- package/dist-types/protocols/index.d.ts +4 -0
- package/package.json +33 -0
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
import { HttpRequest } from '@ingestkorea/util-http-handler';
|
|
2
|
+
import { parseBody, parseErrorBody } from './constants';
|
|
3
|
+
export const serializeIngestkorea_restJson_SendAlimtalkCommand = async (input, config) => {
|
|
4
|
+
const hostname = "sens.apigw.ntruss.com";
|
|
5
|
+
const path = "/alimtalk/v2/services/" + config.serviceId + "/messages";
|
|
6
|
+
const headers = {
|
|
7
|
+
"content-type": "application/json; charset=utf-8",
|
|
8
|
+
"host": hostname
|
|
9
|
+
};
|
|
10
|
+
const body = JSON.stringify({
|
|
11
|
+
plusFriendId: input.plusFriendId,
|
|
12
|
+
templateCode: input.templateCode,
|
|
13
|
+
messages: input.messages
|
|
14
|
+
});
|
|
15
|
+
return new HttpRequest({
|
|
16
|
+
protocol: 'https:',
|
|
17
|
+
method: 'POST',
|
|
18
|
+
hostname: hostname,
|
|
19
|
+
path: path,
|
|
20
|
+
headers: headers,
|
|
21
|
+
body: body
|
|
22
|
+
});
|
|
23
|
+
};
|
|
24
|
+
export const deserializeIngestkorea_restJson_SendAlimtalkCommand = async (output) => {
|
|
25
|
+
if (output.statusCode > 300)
|
|
26
|
+
await parseErrorBody(output);
|
|
27
|
+
const data = await parseBody(output); // SendAlimtalkCommandOutput
|
|
28
|
+
let contents = {};
|
|
29
|
+
contents = await deserializeIngestkorea_restJson_SendMessageOutput(data);
|
|
30
|
+
const response = {
|
|
31
|
+
...contents
|
|
32
|
+
};
|
|
33
|
+
return response;
|
|
34
|
+
};
|
|
35
|
+
export const deserializeIngestkorea_restJson_SendMessageOutput = async (output) => {
|
|
36
|
+
return {
|
|
37
|
+
requestId: output.requestId != undefined ? output.requestId : undefined,
|
|
38
|
+
requestTime: output.requestTime != undefined ? output.requestTime : undefined,
|
|
39
|
+
statusCode: output.statusCode != undefined ? output.statusCode : undefined,
|
|
40
|
+
statusName: output.statusName != undefined ? output.statusName : undefined,
|
|
41
|
+
messages: output.messages != undefined ?
|
|
42
|
+
deserializeIngestkorea_restJson_ReceivedMessages(output.messages) : undefined,
|
|
43
|
+
};
|
|
44
|
+
};
|
|
45
|
+
export const deserializeIngestkorea_restJson_ReceivedMessages = (outputs) => {
|
|
46
|
+
const result = outputs.map(output => {
|
|
47
|
+
return {
|
|
48
|
+
messageId: output.messageId != undefined ? output.messageId : undefined,
|
|
49
|
+
to: output.to != undefined ? output.to : undefined,
|
|
50
|
+
countryCode: output.countryCode != undefined ? output.countryCode : undefined,
|
|
51
|
+
content: output.content != undefined ? output.content : undefined,
|
|
52
|
+
requestStatusCode: output.requestStatusCode != undefined ? output.requestStatusCode : undefined,
|
|
53
|
+
requestStatusName: output.requestStatusName != undefined ? output.requestStatusName : undefined,
|
|
54
|
+
requestStatusDesc: output.requestStatusDesc != undefined ? output.requestStatusDesc : undefined,
|
|
55
|
+
useSmsFailover: output.useSmsFailover != undefined ? output.useSmsFailover : undefined,
|
|
56
|
+
};
|
|
57
|
+
});
|
|
58
|
+
return result;
|
|
59
|
+
};
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import { IngestkoreaError, ingestkoreaErrorCodeChecker } from '@ingestkorea/util-error-handler';
|
|
2
|
+
import { collectBodyString, destroyStream } from '@ingestkorea/util-http-handler';
|
|
3
|
+
export const parseBody = async (output) => {
|
|
4
|
+
const { statusCode, headers, body: streamBody } = output;
|
|
5
|
+
const isValid = await verifyJsonHeader(headers['content-type']);
|
|
6
|
+
if (!isValid) {
|
|
7
|
+
await destroyStream(streamBody);
|
|
8
|
+
let customError = new IngestkoreaError({
|
|
9
|
+
code: 400, type: 'Bad Request',
|
|
10
|
+
message: 'Invalid Request', description: 'content-type is not application/json'
|
|
11
|
+
});
|
|
12
|
+
if (ingestkoreaErrorCodeChecker(statusCode))
|
|
13
|
+
customError.error.code = statusCode;
|
|
14
|
+
throw customError;
|
|
15
|
+
}
|
|
16
|
+
;
|
|
17
|
+
const data = await collectBodyString(streamBody);
|
|
18
|
+
if (data.length)
|
|
19
|
+
return JSON.parse(data);
|
|
20
|
+
return {};
|
|
21
|
+
};
|
|
22
|
+
export const parseErrorBody = async (output) => {
|
|
23
|
+
const { statusCode, headers, body: streamBody } = output;
|
|
24
|
+
const isValid = await verifyJsonHeader(headers['content-type']);
|
|
25
|
+
await destroyStream(streamBody);
|
|
26
|
+
let customError = new IngestkoreaError({
|
|
27
|
+
code: 400, type: 'Bad Request',
|
|
28
|
+
message: 'Invalid Request', description: 'content-type is not application/json'
|
|
29
|
+
});
|
|
30
|
+
if (ingestkoreaErrorCodeChecker(statusCode))
|
|
31
|
+
customError.error.code = statusCode;
|
|
32
|
+
if (!isValid)
|
|
33
|
+
throw customError;
|
|
34
|
+
const data = await collectBodyString(streamBody);
|
|
35
|
+
if (data.length)
|
|
36
|
+
customError.error.description = JSON.parse(data);
|
|
37
|
+
throw customError;
|
|
38
|
+
};
|
|
39
|
+
const verifyJsonHeader = async (contentType) => {
|
|
40
|
+
return /application\/json/gi.exec(contentType) ? true : false;
|
|
41
|
+
};
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { NodeHttpHandler } from '@ingestkorea/util-http-handler';
|
|
2
|
+
import { SensCommand } from './models';
|
|
3
|
+
export type Credentials = {
|
|
4
|
+
accessKey: string;
|
|
5
|
+
secretKey: string;
|
|
6
|
+
};
|
|
7
|
+
export type ServiceId = string;
|
|
8
|
+
export interface SensClientConfig {
|
|
9
|
+
credentials?: Credentials;
|
|
10
|
+
serviceId?: ServiceId;
|
|
11
|
+
}
|
|
12
|
+
export interface SensClientResolvedConfig {
|
|
13
|
+
credentials: Credentials;
|
|
14
|
+
serviceId: ServiceId;
|
|
15
|
+
}
|
|
16
|
+
export declare class SensClient {
|
|
17
|
+
config: SensClientResolvedConfig;
|
|
18
|
+
httpHandler: NodeHttpHandler;
|
|
19
|
+
constructor(config: SensClientConfig);
|
|
20
|
+
send<T, P>(command: SensCommand<T, P, SensClientResolvedConfig>): Promise<P>;
|
|
21
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { HttpRequest, HttpResponse } from '@ingestkorea/util-http-handler';
|
|
2
|
+
import { SensCommand, GetRequestResultInput, GetRequestResultOutput } from '../models';
|
|
3
|
+
import { SensClientResolvedConfig } from '../SensClient';
|
|
4
|
+
export interface GetRequestResultCommandInput extends GetRequestResultInput {
|
|
5
|
+
}
|
|
6
|
+
export interface GetRequestResultCommandOutput extends GetRequestResultOutput {
|
|
7
|
+
}
|
|
8
|
+
export declare class GetRequestResultCommand extends SensCommand<GetRequestResultCommandInput, GetRequestResultCommandOutput, SensClientResolvedConfig> {
|
|
9
|
+
input: GetRequestResultCommandInput;
|
|
10
|
+
constructor(input: GetRequestResultCommandInput);
|
|
11
|
+
serialize(input: GetRequestResultCommandInput, config: SensClientResolvedConfig): Promise<HttpRequest>;
|
|
12
|
+
deserialize(response: HttpResponse): Promise<GetRequestResultCommandOutput>;
|
|
13
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { HttpRequest, HttpResponse } from '@ingestkorea/util-http-handler';
|
|
2
|
+
import { SensCommand, GetRequestStatusInput, GetRequestStatusOutput } from '../models';
|
|
3
|
+
import { SensClientResolvedConfig } from '../SensClient';
|
|
4
|
+
export interface GetRequestStatusCommandInput extends GetRequestStatusInput {
|
|
5
|
+
}
|
|
6
|
+
export interface GetRequestStatusCommandOutput extends GetRequestStatusOutput {
|
|
7
|
+
}
|
|
8
|
+
export declare class GetRequestStatusCommand extends SensCommand<GetRequestStatusCommandInput, GetRequestStatusCommandOutput, SensClientResolvedConfig> {
|
|
9
|
+
input: GetRequestStatusCommandInput;
|
|
10
|
+
constructor(input: GetRequestStatusCommandInput);
|
|
11
|
+
serialize(input: GetRequestStatusCommandInput, config: SensClientResolvedConfig): Promise<HttpRequest>;
|
|
12
|
+
deserialize(response: HttpResponse): Promise<GetRequestStatusCommandOutput>;
|
|
13
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { HttpRequest, HttpResponse } from '@ingestkorea/util-http-handler';
|
|
2
|
+
import { SensCommand, ListChannelsInput, ListChannelsOutput } from '../models';
|
|
3
|
+
import { SensClientResolvedConfig } from '../SensClient';
|
|
4
|
+
export interface ListChannelsCommandInput extends ListChannelsInput {
|
|
5
|
+
}
|
|
6
|
+
export interface ListChannelsCommandOutput extends ListChannelsOutput {
|
|
7
|
+
}
|
|
8
|
+
export declare class ListChannelsCommand extends SensCommand<ListChannelsCommandInput, ListChannelsCommandOutput, SensClientResolvedConfig> {
|
|
9
|
+
input: ListChannelsCommandInput;
|
|
10
|
+
constructor(input: ListChannelsCommandInput);
|
|
11
|
+
serialize(input: ListChannelsCommandInput, config: SensClientResolvedConfig): Promise<HttpRequest>;
|
|
12
|
+
deserialize(response: HttpResponse): Promise<ListChannelsCommandOutput>;
|
|
13
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { HttpRequest, HttpResponse } from '@ingestkorea/util-http-handler';
|
|
2
|
+
import { SensCommand, SendAlimtalkInput, SendAlimtalkOutput } from '../models';
|
|
3
|
+
import { SensClientResolvedConfig } from '../SensClient';
|
|
4
|
+
export interface SendAlimtalkCommandInput extends SendAlimtalkInput {
|
|
5
|
+
}
|
|
6
|
+
export interface SendAlimtalkCommandOutput extends SendAlimtalkOutput {
|
|
7
|
+
}
|
|
8
|
+
export declare class SendAlimtalkCommand extends SensCommand<SendAlimtalkCommandInput, SendAlimtalkCommandOutput, SensClientResolvedConfig> {
|
|
9
|
+
input: SendAlimtalkCommandInput;
|
|
10
|
+
constructor(input: SendAlimtalkCommandInput);
|
|
11
|
+
serialize(input: SendAlimtalkCommandInput, config: SensClientResolvedConfig): Promise<HttpRequest>;
|
|
12
|
+
deserialize(response: HttpResponse): Promise<SendAlimtalkCommandOutput>;
|
|
13
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './signer';
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { StatusMessage } from './GetRequestStatus';
|
|
2
|
+
export interface GetRequestResultInput {
|
|
3
|
+
messageId: string;
|
|
4
|
+
}
|
|
5
|
+
export interface GetRequestResultOutput extends StatusMessage {
|
|
6
|
+
requestId?: string;
|
|
7
|
+
failover?: Failover;
|
|
8
|
+
}
|
|
9
|
+
export interface Failover {
|
|
10
|
+
smsServiceId?: string;
|
|
11
|
+
requestId?: string;
|
|
12
|
+
requestStatusCode?: string;
|
|
13
|
+
requestStatusName?: string;
|
|
14
|
+
requestStatusDesc?: string;
|
|
15
|
+
messageId?: string;
|
|
16
|
+
messageStatus?: string;
|
|
17
|
+
messageStatusCode?: string;
|
|
18
|
+
messageStatusName?: string;
|
|
19
|
+
messageStatusDesc?: string;
|
|
20
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { ReceivedMessage } from './SendAlimtalk';
|
|
2
|
+
export interface GetRequestStatusInput {
|
|
3
|
+
requestId: string;
|
|
4
|
+
}
|
|
5
|
+
export interface GetRequestStatusOutput {
|
|
6
|
+
requestId?: string;
|
|
7
|
+
statusCode?: string;
|
|
8
|
+
statusName?: string;
|
|
9
|
+
messages?: StatusMessage[];
|
|
10
|
+
}
|
|
11
|
+
export interface StatusMessage extends ReceivedMessage {
|
|
12
|
+
requestTime?: string;
|
|
13
|
+
plusFriendId?: string;
|
|
14
|
+
templateCode?: string;
|
|
15
|
+
completeTime?: string;
|
|
16
|
+
messageStatusCode?: string;
|
|
17
|
+
messageStatusName?: string;
|
|
18
|
+
messageStatusDesc?: string;
|
|
19
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
export interface ListChannelsInput {
|
|
2
|
+
}
|
|
3
|
+
export interface ListChannelsOutput {
|
|
4
|
+
channels: Channel[];
|
|
5
|
+
}
|
|
6
|
+
export interface Channel {
|
|
7
|
+
createTime?: string;
|
|
8
|
+
updateTime?: string;
|
|
9
|
+
serviceId?: string;
|
|
10
|
+
channelId?: string;
|
|
11
|
+
channelName?: string;
|
|
12
|
+
channelStatus?: string;
|
|
13
|
+
useSmsFailover?: string;
|
|
14
|
+
}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
export interface SendAlimtalkInput {
|
|
2
|
+
plusFriendId: string;
|
|
3
|
+
templateCode: string;
|
|
4
|
+
messages: SendMessage[];
|
|
5
|
+
}
|
|
6
|
+
export interface SendAlimtalkOutput {
|
|
7
|
+
requestId?: string;
|
|
8
|
+
requestTime?: string;
|
|
9
|
+
statusCode?: string;
|
|
10
|
+
statusName?: string;
|
|
11
|
+
messages?: ReceivedMessage[];
|
|
12
|
+
}
|
|
13
|
+
export interface SendMessage {
|
|
14
|
+
to: string;
|
|
15
|
+
content: string;
|
|
16
|
+
buttons?: Buttons[];
|
|
17
|
+
}
|
|
18
|
+
export interface Buttons {
|
|
19
|
+
type: string;
|
|
20
|
+
name: string;
|
|
21
|
+
linkMobile: string;
|
|
22
|
+
linkPc: string;
|
|
23
|
+
}
|
|
24
|
+
export interface ReceivedMessage {
|
|
25
|
+
messageId?: string;
|
|
26
|
+
to?: string;
|
|
27
|
+
countryCode?: string;
|
|
28
|
+
content?: string;
|
|
29
|
+
requestStatusCode?: string;
|
|
30
|
+
requestStatusName?: string;
|
|
31
|
+
requestStatusDesc?: string;
|
|
32
|
+
useSmsFailover?: boolean;
|
|
33
|
+
}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { HttpRequest, HttpResponse } from '@ingestkorea/util-http-handler';
|
|
2
|
+
export declare abstract class SensCommand<ClientInput, ClientOutput, ClientResolvedConfig> {
|
|
3
|
+
input: ClientInput;
|
|
4
|
+
constructor(input: ClientInput);
|
|
5
|
+
abstract serialize(input: ClientInput, config: ClientResolvedConfig): Promise<HttpRequest>;
|
|
6
|
+
abstract deserialize(response: HttpResponse): Promise<ClientOutput>;
|
|
7
|
+
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { HttpRequest, HttpResponse } from '@ingestkorea/util-http-handler';
|
|
2
|
+
import { GetRequestResultOutput, Failover } from '../models/GetRequestResult';
|
|
3
|
+
import { SensClientResolvedConfig } from '../SensClient';
|
|
4
|
+
import { GetRequestResultCommandInput, GetRequestResultCommandOutput } from '../commands/GetRequestResultCommand';
|
|
5
|
+
export declare const serializeIngestkorea_restJson_GetRequestResultCommand: (input: GetRequestResultCommandInput, config: SensClientResolvedConfig) => Promise<HttpRequest>;
|
|
6
|
+
export declare const deserializeIngestkorea_restJson_GetRequestResultCommand: (output: HttpResponse) => Promise<GetRequestResultCommandOutput>;
|
|
7
|
+
export declare const deserializeIngestkorea_restJson_GetRequestResultOutput: (output: any) => Promise<GetRequestResultOutput>;
|
|
8
|
+
export declare const deserializeIngestkorea_restJson_GetRequestResultFailover: (output: any) => Failover;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { HttpRequest, HttpResponse } from '@ingestkorea/util-http-handler';
|
|
2
|
+
import { GetRequestStatusOutput, StatusMessage } from '../models/GetRequestStatus';
|
|
3
|
+
import { SensClientResolvedConfig } from '../SensClient';
|
|
4
|
+
import { GetRequestStatusCommandInput, GetRequestStatusCommandOutput } from '../commands/GetRequestStatusCommand';
|
|
5
|
+
export declare const serializeIngestkorea_restJson_GetRequestStatusCommand: (input: GetRequestStatusCommandInput, config: SensClientResolvedConfig) => Promise<HttpRequest>;
|
|
6
|
+
export declare const deserializeIngestkorea_restJson_GetRequestStatusCommand: (output: HttpResponse) => Promise<GetRequestStatusCommandOutput>;
|
|
7
|
+
export declare const deserializeIngestkorea_restJson_GetRequestStatusOutput: (output: any) => Promise<GetRequestStatusOutput>;
|
|
8
|
+
export declare const deserializeIngestkorea_restJson_GetRequestStatusMessages: (outputs: any[]) => StatusMessage[];
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { HttpRequest, HttpResponse } from '@ingestkorea/util-http-handler';
|
|
2
|
+
import { ListChannelsOutput, Channel } from '../models/ListChannels';
|
|
3
|
+
import { SensClientResolvedConfig } from '../SensClient';
|
|
4
|
+
import { ListChannelsCommandInput, ListChannelsCommandOutput } from '../commands/ListChannelsCommand';
|
|
5
|
+
export declare const serializeIngestkorea_restJson_ListChannelsCommand: (input: ListChannelsCommandInput, config: SensClientResolvedConfig) => Promise<HttpRequest>;
|
|
6
|
+
export declare const deserializeIngestkorea_restJson_ListChannelsCommand: (output: HttpResponse) => Promise<ListChannelsCommandOutput>;
|
|
7
|
+
export declare const deserializeIngestkorea_restJson_ListChannelsOutput: (outputs: any[]) => Promise<ListChannelsOutput>;
|
|
8
|
+
export declare const deserializeIngestkorea_restJson_ListChannelsChannelInfo: (outputs: any[]) => Channel[];
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { HttpRequest, HttpResponse } from '@ingestkorea/util-http-handler';
|
|
2
|
+
import { SendAlimtalkOutput, ReceivedMessage } from '../models/SendAlimtalk';
|
|
3
|
+
import { SensClientResolvedConfig } from '../SensClient';
|
|
4
|
+
import { SendAlimtalkCommandInput, SendAlimtalkCommandOutput } from '../commands/SendAlimtalkCommand';
|
|
5
|
+
export declare const serializeIngestkorea_restJson_SendAlimtalkCommand: (input: SendAlimtalkCommandInput, config: SensClientResolvedConfig) => Promise<HttpRequest>;
|
|
6
|
+
export declare const deserializeIngestkorea_restJson_SendAlimtalkCommand: (output: HttpResponse) => Promise<SendAlimtalkCommandOutput>;
|
|
7
|
+
export declare const deserializeIngestkorea_restJson_SendMessageOutput: (output: any) => Promise<SendAlimtalkOutput>;
|
|
8
|
+
export declare const deserializeIngestkorea_restJson_ReceivedMessages: (outputs: any[]) => ReceivedMessage[];
|
package/package.json
ADDED
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@ingestkorea/client-sens",
|
|
3
|
+
"version": "1.0.0",
|
|
4
|
+
"description": "INGESTKOREA SDK NCP SENS Client for Node.js.",
|
|
5
|
+
"main": "./dist-cjs/index.js",
|
|
6
|
+
"module": "./dist-es/index.js",
|
|
7
|
+
"types": "./dist-types/index.d.ts",
|
|
8
|
+
"scripts": {
|
|
9
|
+
"build": "npm run clean && npm run build:cjs && npm run build:es && npm run build:types",
|
|
10
|
+
"build:cjs": "tsc -p tsconfig.cjs.json",
|
|
11
|
+
"build:es": "tsc -p tsconfig.es.json",
|
|
12
|
+
"build:types": "tsc -p tsconfig.types.json",
|
|
13
|
+
"clean": "rm -rf ./dist-*"
|
|
14
|
+
},
|
|
15
|
+
"repository": {
|
|
16
|
+
"type": "git",
|
|
17
|
+
"url": "https://github.com/ingestkorea/client-sens.git"
|
|
18
|
+
},
|
|
19
|
+
"author": "ingestkorea",
|
|
20
|
+
"license": "MIT",
|
|
21
|
+
"bugs": {
|
|
22
|
+
"url": "https://github.com/ingestkorea/client-sens/issues"
|
|
23
|
+
},
|
|
24
|
+
"homepage": "https://github.com/ingestkorea/client-sens#readme",
|
|
25
|
+
"devDependencies": {
|
|
26
|
+
"@types/node": "^18.11.0"
|
|
27
|
+
},
|
|
28
|
+
"dependencies": {
|
|
29
|
+
"@ingestkorea/util-error-handler": "^1.0.3",
|
|
30
|
+
"@ingestkorea/util-http-handler": "^1.0.0",
|
|
31
|
+
"@ingestkorea/util-simple-logger": "^1.0.3"
|
|
32
|
+
}
|
|
33
|
+
}
|