Engineering

Over the past two months, AeroFS has been excited to release developer SDKs for C#, Golang, Javascript and Python! All of these projects are open source and available on Github. They each wrap the publicly exposed AeroFS REST API for ease of use, so developers can focus on application building rather than creating a wrapper library. These development kits will allow developers on multiple platforms to tap into the AeroFS appliance and build third party applications.

Building Third Party Applications

The SDKs expose all facets of the AeroFS appliance, giving developers the ability to interact with a user’s files, devices, folders and appliance metadata. Applications can be granted different permissions, allowing them to perform administrative operations like managing appliance invitations to user-specific operations like managing a user’s files. These applications allow developers to extend the functionality of your AeroFS appliance and create custom integrations for your deployment. The support languages enable you to create both front-end and server applications.

The design and simplicity of the SDK’s make it easy to start building your own AeroFS app. Installation is straightforward via package managers like NPM, Pip, and Go-Get. A quick build process is required for C# and enables you to build for multiple target platforms.

AeroFS exposes a standard OAuth2 authentication flow for the retrieval of an authentication token used by each SDK. The following code snippets provide an example of how easy it is to use the corresponding SDKs. They also illustrate how to retrieve a list of files and folders in a user’s root directory given a link to the AeroFS appliance and a retrieved OAuth2 token.

Examples

Golang

 
import (
  api "github.com/aerofs/aerofs-sdk-golang/aerofsapi"
  sdk "github.com/aerofs/aerofs-sdk-golang/aerofssdk"
  fmt
)

...
apiClient, _ := api.NewClient(OAUTH_TOKEN, APPLIANCE_URL)
folder, _ := sdk.NewFolderClient(apiClient, "root", []string{})
folder.LoadChildren()
fmt.Print(folder.Desc.ChildList.Files, folder.Desc.ChildList.Folders)


Python


from aerofs import api, sdk

...
config = api.InstanceConfiguration(APPLIANCE_URL)
client = api.APIClient(config, OAUTH_TOKEN)
children = sdk.Folder(client, 'root').children
print children.folders, children.files

C#


using AeroFSSDK;

AeroFSAPI client = AeroFSClient.Create(OAUTH_TOKEN, new AeroFSClient.Configuration
{
  HostName = APPLIANCE_URL,
  APIVersion = "1.3"
});
   
var children = client.ListChildren(FolderID.Root);
var folders = children.Folders;
var files = children.Files;

Javascript


aero.initialize({oauthToken : OAUTH_TOKEN, hostUrl : APPLIANCE_URL});
let children = aero.api.folder.listChildren('root')
console.log(children)

These APIs are used internally in our different micro-services. A prime example of a sample application is AeroUP. AeroUP is a tool utilizing the Python SDK that enables third party file uploads to an AeroFS Appliance behind a firewall. The AeroFS customer and success team use it heavily when interfacing with a client.

Applications you can Develop

The SDKs give developers the perfect means to extend their appliance. All of us at AeroFS look forward to seeing the applications that will be created to solve the user-facing problems of your AeroFS appliance. We greatly encourage pull requests and contributions to the various SDKs at https://github.com/aerofs/.

Happy coding and Happy St. Patrick’s Day!

-Daniel and the AeroFS team