UNPKG

@ingestkorea/client-sens

Version:

INGESTKOREA SDK Naver Cloud Platform SENS Client for Node.js.

28 lines (27 loc) 1.11 kB
import { SensCommand } from "../models"; import { serializeIngestkorea_restJson_GetAlimtalkTemplateCommand, deserializeIngestkorea_restJson_GetAlimtalkTemplateCommand, } from "../protocols/GetAlimtalkTemplate"; import { IngestkoreaError } from "@ingestkorea/util-error-handler"; export class GetAlimtalkTemplateCommand extends SensCommand { constructor(input) { super(input); this.input = { channelId: input.channelId, templateCode: input.templateCode, }; } async serialize(input, config) { if (!config.serviceId.kakao) throw new IngestkoreaError({ code: 400, type: "Bad Request", message: "Invalid Params", description: "Please Check Kakao ServiceId", }); let request = await serializeIngestkorea_restJson_GetAlimtalkTemplateCommand(input, config); return request; } async deserialize(response) { let output = await deserializeIngestkorea_restJson_GetAlimtalkTemplateCommand(response); return output; } }