ynab
Version:
Official JavaScript client for the YNAB API. API documentation available at https://api.ynab.com. Generated from server specification version 1.76.0
48 lines (47 loc) • 2.25 kB
JavaScript
;
/* tslint:disable */
/* eslint-disable */
/**
* YNAB API Endpoints
* Our API uses a REST based design, leverages the JSON data format, and relies upon HTTPS for transport. We respond with meaningful HTTP response codes and if an error occurs, we include error details in the response body. API Documentation is at https://api.ynab.com
*
* Generated by: OpenAPI Generator (https://openapi-generator.tech)
*/
Object.defineProperty(exports, "__esModule", { value: true });
exports.PatchTransactionsWrapperToJSONTyped = exports.PatchTransactionsWrapperToJSON = exports.PatchTransactionsWrapperFromJSONTyped = exports.PatchTransactionsWrapperFromJSON = exports.instanceOfPatchTransactionsWrapper = void 0;
const SaveTransactionWithIdOrImportId_1 = require("./SaveTransactionWithIdOrImportId");
/**
* Check if a given object implements the PatchTransactionsWrapper interface.
*/
function instanceOfPatchTransactionsWrapper(value) {
if (!('transactions' in value) || value['transactions'] === undefined)
return false;
return true;
}
exports.instanceOfPatchTransactionsWrapper = instanceOfPatchTransactionsWrapper;
function PatchTransactionsWrapperFromJSON(json) {
return PatchTransactionsWrapperFromJSONTyped(json, false);
}
exports.PatchTransactionsWrapperFromJSON = PatchTransactionsWrapperFromJSON;
function PatchTransactionsWrapperFromJSONTyped(json, ignoreDiscriminator) {
if (json == null) {
return json;
}
return {
'transactions': (json['transactions'].map(SaveTransactionWithIdOrImportId_1.SaveTransactionWithIdOrImportIdFromJSON)),
};
}
exports.PatchTransactionsWrapperFromJSONTyped = PatchTransactionsWrapperFromJSONTyped;
function PatchTransactionsWrapperToJSON(json) {
return PatchTransactionsWrapperToJSONTyped(json, false);
}
exports.PatchTransactionsWrapperToJSON = PatchTransactionsWrapperToJSON;
function PatchTransactionsWrapperToJSONTyped(value, ignoreDiscriminator = false) {
if (value == null) {
return value;
}
return {
'transactions': (value['transactions'].map(SaveTransactionWithIdOrImportId_1.SaveTransactionWithIdOrImportIdToJSON)),
};
}
exports.PatchTransactionsWrapperToJSONTyped = PatchTransactionsWrapperToJSONTyped;