Box.com IntegrationCreated 5 years ago by abfadel
Hey guys, hope you’re well. I'm need to integrate with box.com in order to associate private files to an entry. I found this laravel/box api which looks pretty decent: https://github.com/maengkom/boxapi I'm curious about best approach to take. I'm envisioning the UI to be just like the existing file-field_type except I would be able to browse folder/files from my box.com. With that said, would you make a new filed type called box-field_type or a new storage adaptor similar to the S3 adapter? Thanks
Oh dang! Somehow I missed the flysystem for Box.
As a heads up - My research with Box was pretty rough since they have no documentation for PHP implementation.
@ryanthompson, do you have some documentation on creating file system adapters? I wouldn't mind taking a stab at it since I may need it for this project I am finishing up.
I don't yet - but it'll be here: https://pyrocms.com/documentation/files-module/latest
S3 adapter gives a good example
So - I think this is clearly a storage adapter design. One thing that might need to be added is remote sync (there's local I think.. but I'd have to double check). The sync would update your DB references to the box.com files.
There is a box api driver for Filesystem which is the basis of our system: https://github.com/zburke/flysystem-box
I would also be happy to build an adapter.
PS as soon as you said work like the existing files system - storage adapter all day 😛