"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.serializeMetadataInstanceValue = serializeMetadataInstanceValue;
exports.deserializeMetadataInstanceValue = deserializeMetadataInstanceValue;
const errors_1 = require("../box/errors");
const json_1 = require("../serialization/json");
const json_2 = require("../serialization/json");
const json_3 = require("../serialization/json");
function serializeMetadataInstanceValue(val) {
    return val;
}
function deserializeMetadataInstanceValue(val) {
    if ((0, json_2.sdIsString)(val)) {
        return val;
    }
    if ((0, json_1.sdIsNumber)(val)) {
        return val;
    }
    if ((0, json_3.sdIsList)(val) && val.every(json_2.sdIsString)) {
        return val;
    }
    throw new errors_1.BoxSdkError({ message: "Can't deserialize MetadataInstanceValue" });
}
//# sourceMappingURL=metadataInstanceValue.js.map