• Topic
  • Discussion
  • ODS.OdsBriefcaseSkyDrive(Last) -- DAVWikiAdmin? , 2019-07-15 08:12:45 Edit WebDAV System Administrator 2019-07-15 08:12:45

    Using ODS-Briefcase to mediate access to data stored on Microsoft OneDrive

    Introduction

    Microsoft OneDrive (formerly SkyDrive) is a service that allows users to upload and sync files to a cloud storage, and then access them from a Web browser or their local device. It is part of the Windows Live set of online services and allows users to keep the files private, share them only with chosen contacts, or make them public.

    OneDrive file storage offers users a number of features:

    • Free online storage: allows 7GB of free online cloud storage
    • Can be used for back up of photos or documents, or for making them public and/or sharing a folder with friends
    • Drag-and-drop upload: uploading files by simply dragging files from one's computer and dropping them into OneDrive
    • Create and share office (Word, Excel, and PowerPoint) documents which can then be shared through Hotmail

    ODS-Briefcase offers a new "OneDrive" folder type which provides several additional features, once the ODS system is configured with a registered Windows API key and secret pair:

    • Specify credentials for authentication against OneDrive, enabling retrieval of any or all of your folders and files, including any associated metadata
    • Specify which Sponger Extractor Cartridges and Sponger Meta Cartridges should be run against your OneDrive data
    • Save fetched data, metadata, and Sponger output, into a newly created OneDrive-specific RDF Graph in the Virtuoso RDF Quad Store
    • Specify other ODS Users or WebID ACLs who should be granted access to your OneDrive data through ODS-Briefcase

    Example

    Here is a sample scenario showing the whole process, from setting the Windows Live API key in ODS, to retrieving all OneDrive content to ODS-Briefcase.

    Prerequisites

    Steps

    1 - Get a Microsoft Graph API key for use with ODS-Briefcase

    Note that at present, each Virtuoso + ODS instance can only be configured with a single Microsoft Graph API key, which will then be used by all ODS-Briefcase users when targeting OneDrive from that instance. Microsoft may impose limitations on this key's use. Such limitations are outside the scope of OpenLink or Virtuoso control.
    1. Browse to <https://portal.azure.com/#home> and enter your Windows Live user credentials:



    2. Select Azure Active Directory > App Registrations > New Registration and then enter a name for your Live Connect client application (i.e., your ODS-Briefcase instance) to be known by, e.g., "MyODSOneDrive", set the redirect URL, and click the Register button:



    3. Select Certificates & secrets from Application Settings Columb



      and then New client secret



    4. Select Api permissions from Application Settings Columb. Use Add permission option to choose needed permissions.

      The minimal permissions set is shown below.



    2 - Configure ODS to use your Microsoft Graph API key and secret

    1. Browse to your Virtuoso + ODS instance, http://<cname>[:<port>]/ods, e.g., <http://example.com/ods/>, and click Sign In.



    2. Log in as a Virtuoso+ODS user with Administrator privileges, e.g., dba.



    3. Click on Site Settings:



    4. Click on Login Authentication Keys:



    5. Select OneDrive API in the API Name menu, provide the Client ID and Client secret from the new Live Connect application you created above, and click Add.



    6. ODS-Briefcase is now configured to use OneDrive.



    3 - Access files stored on OneDrive through ODS-Briefcase

    1. Browse to your Virtuoso + ODS instance, http://<cname>[:<port>]/ods, e.g., <http://example.com/ods/>.



    2. Log in as a Virtuoso+ODS user with normal privileges, e.g., demo.



    3. Click to the ODS-Briefcase application:



    4. Click New Folder from the main Briefcase control strip:



    5. In the New Folder form, specify a Folder Name, e.g., MyOneDriveFolder, and set the Folder type to OneDrive:



    6. Click to the newly visible OneDrive tab:



    7. All RDF data extracted from and otherwise collected about your Google Drive files will be saved to a named graph, where the default name is constructed from the host ODS instance, the ODS username, and the Briefcase folder name -- http://<host>[:<port>]/DAV/home/<user-name>/<folder-name>#this -- so, in this example, the default graph would be named <http://example.com/ods/demo/MyOneDriveFolder#this>. Expert users may wish to change this graph name, but the default is suitable for most users.



    8. You can also turn on the Virtuoso Sponger, to process your OneDrive? files more comprehensively. When the Sponger is enabled for your folder, you can specify which "Sponger Extractor Cartridges" and "Sponger Meta Cartridges" will be run over the files in your Google Drive. You can enable all cartridges, but this will introduce some processing overhead. It's generally best to enable only those cartridges which will be applicable to your files and their content. For instance, you may know that you'll only be storing Microsoft and Open Office documents here, and that you want to find all Named Entities described by DBpedia. Then, click "Authenticate", to connect your new folder to your OneDrive:



    9. You'll be prompted to enter your Windows Live user's credentials. Note that this Windows Live user need not be the application owner/"developer" who got the API key earlier.



    10. Windows Live will prompt for confirmation that you intend to let your application ("MyODSOneDrive") have access to your OneDrive content. Click Yes.



    11. Your Windows Live user's real name will now be displayed. Click Create to finish the folder creation process.



    12. Your new OneDrive-linked folder should now be displayed in your Briefcase resources list:



    13. Click the folder name to see the resources ODS-Briefcase has found in your OneDrive Dataspace:



    Related