                 - scalingFactor: \(scalingFactor)
                 - rotation: \(rotation)
                 - ref: \(ref)
+                - refType: \(refType)
                 """
         }
     }

            self.scalingFactor = try keyedDecoder.decodeIfPresent(Double.self, forKey: .scalingFactor)
            self.rotation = try keyedDecoder.decodeIfPresent(Double.self, forKey: .rotation) ?? 0
            if let imageRef = try keyedDecoder.decodeIfPresent(String.self, forKey: .imageRef) {
                self.ref = .image(imageRef)
            } else if let gifRef = try keyedDecoder.decodeIfPresent(String.self, forKey: .gifRef) {
                self.ref = .gif(gifRef)
            } else {
                throw DecodingError.typeMismatch(
                    Self.self,

        /// Image rotation, in degrees.
        public let rotation: Double
        
        /// A reference to an image embedded in this node.
        ///
        /// To download the image using this reference, use the GET file images endpoint
        /// to retrieve the mapping from image references to image URLs.
        public let ref: String
        public enum ReferenceType {
            case image
            case gif
        }
        public let refType: ReferenceType
        
        public enum ScaleMode: String, Codable {
            case fill = "FILL"
