UNPKG

fastcomments-sdk

Version:

FastComments API Client - A SDK for interacting with the FastComments API

69 lines 2.62 kB
"use strict"; /* tslint:disable */ /* eslint-disable */ /** * fastcomments * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 0.0.0 * * * 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.instanceOfAPIUserSubscription = instanceOfAPIUserSubscription; exports.APIUserSubscriptionFromJSON = APIUserSubscriptionFromJSON; exports.APIUserSubscriptionFromJSONTyped = APIUserSubscriptionFromJSONTyped; exports.APIUserSubscriptionToJSON = APIUserSubscriptionToJSON; exports.APIUserSubscriptionToJSONTyped = APIUserSubscriptionToJSONTyped; /** * Check if a given object implements the APIUserSubscription interface. */ function instanceOfAPIUserSubscription(value) { if (!('createdAt' in value) || value['createdAt'] === undefined) return false; if (!('urlId' in value) || value['urlId'] === undefined) return false; if (!('id' in value) || value['id'] === undefined) return false; return true; } function APIUserSubscriptionFromJSON(json) { return APIUserSubscriptionFromJSONTyped(json, false); } function APIUserSubscriptionFromJSONTyped(json, ignoreDiscriminator) { if (json == null) { return json; } return { 'notificationFrequency': json['notificationFrequency'] == null ? undefined : json['notificationFrequency'], 'createdAt': (new Date(json['createdAt'])), 'pageTitle': json['pageTitle'] == null ? undefined : json['pageTitle'], 'url': json['url'] == null ? undefined : json['url'], 'urlId': json['urlId'], 'anonUserId': json['anonUserId'] == null ? undefined : json['anonUserId'], 'userId': json['userId'] == null ? undefined : json['userId'], 'id': json['id'], }; } function APIUserSubscriptionToJSON(json) { return APIUserSubscriptionToJSONTyped(json, false); } function APIUserSubscriptionToJSONTyped(value, ignoreDiscriminator = false) { if (value == null) { return value; } return { 'notificationFrequency': value['notificationFrequency'], 'createdAt': ((value['createdAt']).toISOString()), 'pageTitle': value['pageTitle'], 'url': value['url'], 'urlId': value['urlId'], 'anonUserId': value['anonUserId'], 'userId': value['userId'], 'id': value['id'], }; } //# sourceMappingURL=APIUserSubscription.js.map