@ringer-tel/ivy
Version:
TypeScript SDK for Ringer APIs
118 lines (103 loc) • 3.69 kB
text/typescript
/* tslint:disable */
/* eslint-disable */
/**
* Ringer Business API
* This API provides comprehensive endpoints for the Ringer Business system. It includes functionality for managing customer accounts, addresses, sites, phone numbers, payments, users, and other business resources. Operations typically require authentication and appropriate permissions.
*
* The version of the OpenAPI document: 1.0.6
* Contact: support@ringer.tel
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
import { mapValues } from '../runtime';
import type { VoicemailBoxAttributes } from './VoicemailBoxAttributes';
import {
VoicemailBoxAttributesFromJSON,
VoicemailBoxAttributesFromJSONTyped,
VoicemailBoxAttributesToJSON,
VoicemailBoxAttributesToJSONTyped,
} from './VoicemailBoxAttributes';
import type { Link } from './Link';
import {
LinkFromJSON,
LinkFromJSONTyped,
LinkToJSON,
LinkToJSONTyped,
} from './Link';
/**
*
* @export
* @interface VoicemailBoxResponseData
*/
export interface VoicemailBoxResponseData {
/**
* Unique identifier for the Voicemail Box.
* @type {string}
* @memberof VoicemailBoxResponseData
*/
id: string;
/**
*
* @type {string}
* @memberof VoicemailBoxResponseData
*/
type: VoicemailBoxResponseDataTypeEnum;
/**
*
* @type {VoicemailBoxAttributes}
* @memberof VoicemailBoxResponseData
*/
attributes: VoicemailBoxAttributes;
/**
* An object containing various HATEOAS links, where each key is the link relation type.
* @type {{ [key: string]: Link; }}
* @memberof VoicemailBoxResponseData
*/
links?: { [key: string]: Link; };
}
/**
* @export
*/
export const VoicemailBoxResponseDataTypeEnum = {
VoicemailBox: 'voicemail-box'
} as const;
export type VoicemailBoxResponseDataTypeEnum = typeof VoicemailBoxResponseDataTypeEnum[keyof typeof VoicemailBoxResponseDataTypeEnum];
/**
* Check if a given object implements the VoicemailBoxResponseData interface.
*/
export function instanceOfVoicemailBoxResponseData(value: object): value is VoicemailBoxResponseData {
if (!('id' in value) || value['id'] === undefined) return false;
if (!('type' in value) || value['type'] === undefined) return false;
if (!('attributes' in value) || value['attributes'] === undefined) return false;
return true;
}
export function VoicemailBoxResponseDataFromJSON(json: any): VoicemailBoxResponseData {
return VoicemailBoxResponseDataFromJSONTyped(json, false);
}
export function VoicemailBoxResponseDataFromJSONTyped(json: any, ignoreDiscriminator: boolean): VoicemailBoxResponseData {
if (json == null) {
return json;
}
return {
'id': json['id'],
'type': json['type'],
'attributes': VoicemailBoxAttributesFromJSON(json['attributes']),
'links': json['links'] == null ? undefined : (mapValues(json['links'], LinkFromJSON)),
};
}
export function VoicemailBoxResponseDataToJSON(json: any): VoicemailBoxResponseData {
return VoicemailBoxResponseDataToJSONTyped(json, false);
}
export function VoicemailBoxResponseDataToJSONTyped(value?: VoicemailBoxResponseData | null, ignoreDiscriminator: boolean = false): any {
if (value == null) {
return value;
}
return {
'id': value['id'],
'type': value['type'],
'attributes': VoicemailBoxAttributesToJSON(value['attributes']),
'links': value['links'] == null ? undefined : (mapValues(value['links'], LinkToJSON)),
};
}