UNPKG

@emergentmethods/asknews-typescript-sdk

Version:
57 lines (56 loc) 1.84 kB
/* tslint:disable */ /* eslint-disable */ /** * AskNews API * AskNews API [![status](https://status.asknews.app/api/badge/2/status?style=for-the-badge)](https://status.asknews.app/status/prod) * * The version of the OpenAPI document: 0.24.66 * 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. */ import { ContentBlock1FromJSON, ContentBlock1ToJSON, } from './ContentBlock1'; /** * @export */ export const ContentBlockStartEventTypeEnum = { ContentBlockStart: 'content_block_start' }; /** * Check if a given object implements the ContentBlockStartEvent interface. */ export function instanceOfContentBlockStartEvent(value) { if (!('index' in value) || value['index'] === undefined) return false; if (!('contentBlock' in value) || value['contentBlock'] === undefined) return false; return true; } export function ContentBlockStartEventFromJSON(json) { return ContentBlockStartEventFromJSONTyped(json, false); } export function ContentBlockStartEventFromJSONTyped(json, ignoreDiscriminator) { if (json == null) { return json; } return { 'type': json['type'] == null ? undefined : json['type'], 'index': json['index'], 'contentBlock': ContentBlock1FromJSON(json['content_block']), }; } export function ContentBlockStartEventToJSON(json) { return ContentBlockStartEventToJSONTyped(json, false); } export function ContentBlockStartEventToJSONTyped(value, ignoreDiscriminator = false) { if (value == null) { return value; } return { 'type': value['type'], 'index': value['index'], 'content_block': ContentBlock1ToJSON(value['contentBlock']), }; }