link-stack/packages/signal-api/models/ApiReceipt.ts

88 lines
1.9 KiB
TypeScript
Raw Normal View History

/* tslint:disable */
/* eslint-disable */
/**
* Signal Cli REST API
* This is the Signal Cli REST API documentation.
*
* The version of the OpenAPI document: 1.0
*
*
* 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';
/**
*
* @export
* @interface ApiReceipt
*/
export interface ApiReceipt {
/**
*
* @type {string}
* @memberof ApiReceipt
*/
receiptType?: ApiReceiptReceiptTypeEnum;
/**
*
* @type {string}
* @memberof ApiReceipt
*/
recipient?: string;
/**
*
* @type {number}
* @memberof ApiReceipt
*/
timestamp?: number;
}
/**
* @export
*/
export const ApiReceiptReceiptTypeEnum = {
Read: 'read',
Viewed: 'viewed'
} as const;
export type ApiReceiptReceiptTypeEnum = typeof ApiReceiptReceiptTypeEnum[keyof typeof ApiReceiptReceiptTypeEnum];
/**
* Check if a given object implements the ApiReceipt interface.
*/
export function instanceOfApiReceipt(value: object): value is ApiReceipt {
return true;
}
export function ApiReceiptFromJSON(json: any): ApiReceipt {
return ApiReceiptFromJSONTyped(json, false);
}
export function ApiReceiptFromJSONTyped(json: any, ignoreDiscriminator: boolean): ApiReceipt {
if (json == null) {
return json;
}
return {
'receiptType': json['receipt_type'] == null ? undefined : json['receipt_type'],
'recipient': json['recipient'] == null ? undefined : json['recipient'],
'timestamp': json['timestamp'] == null ? undefined : json['timestamp'],
};
}
export function ApiReceiptToJSON(value?: ApiReceipt | null): any {
if (value == null) {
return value;
}
return {
'receipt_type': value['receiptType'],
'recipient': value['recipient'],
'timestamp': value['timestamp'],
};
}