UNPKG

@emergentmethods/asknews-typescript-sdk

Version:
57 lines (56 loc) 1.74 kB
"use strict"; /* tslint:disable */ /* eslint-disable */ /** * AskNews API * AskNews API * * The version of the OpenAPI document: 0.18.6 * Contact: contact@emergentmethods.ai * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech * Do not edit the class manually. */ Object.defineProperty(exports, "__esModule", { value: true }); exports.WebhookActionToJSON = exports.WebhookActionFromJSONTyped = exports.WebhookActionFromJSON = exports.instanceOfWebhookAction = exports.WebhookActionActionEnum = void 0; const WebhookParams_1 = require("./WebhookParams"); /** * @export */ exports.WebhookActionActionEnum = { Webhook: 'webhook' }; /** * Check if a given object implements the WebhookAction interface. */ function instanceOfWebhookAction(value) { if (!('params' in value)) return false; return true; } exports.instanceOfWebhookAction = instanceOfWebhookAction; function WebhookActionFromJSON(json) { return WebhookActionFromJSONTyped(json, false); } exports.WebhookActionFromJSON = WebhookActionFromJSON; function WebhookActionFromJSONTyped(json, ignoreDiscriminator) { if (json == null) { return json; } return { 'action': json['action'] == null ? undefined : json['action'], 'params': (0, WebhookParams_1.WebhookParamsFromJSON)(json['params']), }; } exports.WebhookActionFromJSONTyped = WebhookActionFromJSONTyped; function WebhookActionToJSON(value) { if (value == null) { return value; } return { 'action': value['action'], 'params': (0, WebhookParams_1.WebhookParamsToJSON)(value['params']), }; } exports.WebhookActionToJSON = WebhookActionToJSON;