 
     /// Initializes `RawSignedModel` from base64 encoded string
     ///
-    /// - Parameter base64EncodedString: base64 encoded string with `RawSignedModel`
+    /// - Parameter base64EncodedString: Base64 encoded string with `RawSignedModel`
+    /// - Returns: RawSignedModel instance
+    /// - Throws: RawSignedModelError.invalidBase64String if passed string is not base64 encoded data.
+    ///           Rethrows from JSONDecoder
     @objc public static func `import`(fromBase64Encoded base64EncodedString: String) throws -> RawSignedModel {
         guard let data = Data(base64Encoded: base64EncodedString) else {
             throw RawSignedModelError.invalidBase64String


    /// Declares error types and codes
    ///
    /// - duplicateSignature: `RawSignedModel` instance already has signature with same signer field
    @objc(VSSRawSignedModelError) public enum RawSignedModelError: Int, Error {
        case invalidBase64String = 1
        case duplicateSignature = 2


    /// Exports `RawSignedModel` as base64 encoded string
    ///
    /// - Returns: Base64 encoded string with `RawSignedModel`
    /// - Throws: Rethrows from JSONEncoder
    @objc public func exportAsBase64EncodedString() throws -> String {
       return try JSONEncoder().encode(self).base64EncodedString()
    }

    /// Exports `RawSignedModel` as json dictionary
    ///
    /// - Returns: Json-compatible dictionary with `RawSignedModel`
    /// - Throws: Rethrows from JSONEncoder and JSONSerialization
    @objc public func exportAsJson() throws -> Any {
        let data = try JSONEncoder().encode(self)

        return try JSONSerialization.jsonObject(with: data, options: [])
    }

    /// Adds new signature
    ///
    /// - Parameter signature: signature to add
    /// - Throws: RawSignedModelError.duplicateSignature if signature with same signer already exists
    @objc public func addSignature(_ signature: RawSignature) throws {
        guard self.signatures.first(where: { $0.signer == signature.signer }) == nil else {
            throw RawSignedModelError.duplicateSignature
