¿Como subir una imagen desde un BEAN?

Hola! ¿Cómo están?

Estoy generando un script de importación, el mismo crea Beans de un módulo custom, y a su vez debe cargar imagenes en “Documents” y relacionarlas con el mismo.

No sé como hacer para desde un bean cargar un documento (El archivo .jpg).

Intenté desde:
$bean->filename_file = ruta/del/archivo.jpg ;

Pero no funcionó.

¿Alguno que tenga experiencia en esto y pueda ayudarme?

See the file system articles here

Specifically, the ones that explain how things are stored.

Don’t use Documents module unless you need to keep track of several revisions (versions). It’s simpler to use Notes with image attachments.

thank u pgr!
I will use Notes.