gl-file-server-client
config
var FileServerClient = ;var fsc = host: 'fs.msda.ge' port: '80' path: '/api/' key : "myPrivateKey" //optional;
save file
to save file you need to have a stream
var fs = ;var fileName = "header.png";var stream = fs;//@key is optionalfsc;
get file
key
is optional
fsc;
get cropped image
before cropping you need to add permitted resolutions:
fsc;fsc;fsc; //@key is optionalfsc;
permitted crops in get image:
{ "Top Left" : "TL", "Top Center" : "TC", "Top Right" : "TR", "Middle Left" : "ML", "Middle Center" : "MC", "Middle Right" : "MR", "Bottom Left" : "BL", "Bottom Center" : "BC", "Bottom Right" : "BR"}
you can call getFile and getImage as with a file if as a first parameter if you don't need the key
fsc;