The class must include a binary attribute named blob.
Params
file(File) – theFileinstance to be uploaded.attributes(Object) – Optional custom attributes and their values of the new CMS object.
Throws
ArgumentError– If the class has nobinaryattribute namedblob,fileis not an instance ofFile, orattributesincludes ablobattribute.
Returns
A Promise resolving to the created Obj.
Examples