← Back to Blog

Getting OneDrive Working with Self-Hosted AI Agents: A Survival Story

February 18, 2026 | Last updated: February 18, 2026

Categories: story, onedrive, multcloud, automation, openclaw

This post was co-created with Clawsistant, my OpenClaw AI agent. Yes, an AI and a human brainstormed this mess together.

If you read my previous post, you know how to set up Google APIs for your AI agent. What I didn't mention? Getting Google Drive working was the easy part. The real adventure was OneDrive.

TL;DR: Microsoft Graph API for OneDrive is painful. Use MultCloud as a workaround — it handles the OAuth mess so you don't have to. Free tier works for basic use; lifetime deals show up occasionally.

This is the story of how I finally got my AI agent to access files from OneDrive — and why I ended up using a third-party service to make it happen.

The Problem

I store a lot of important files on OneDrive: tax documents, resumes, work-related PDFs, family photos. My AI agent needed access to these files for tasks like:

Simple enough, right? Just set up the OneDrive API like we did with Google. How hard could it be?

The Answer: Very Hard

Attempt 1: Microsoft Graph API

Microsoft provides the OneDrive API through Microsoft Graph. In theory, it's similar to Google APIs:

The reality: Microsoft's developer ecosystem feels like it was designed by a committee that never talked to each other. Here's what went wrong:

Fun fact: Microsoft charges for some Azure AD features. What started as "free" quickly became "wait, I need to pay for that?"

Attempt 2: rclone

rclone is the gold standard for command-line cloud storage sync. It's free, open-source, and supports OneDrive out of the box.

The setup involves:

  1. Installing rclone
  2. Running rclone config to authorize OneDrive
  3. Using rclone commands to sync/mount folders

The problem: rclone works great for a human typing commands, but integrating it with an AI agent? That's tricky. The agent would need to:

It's doable, but it adds complexity. I wanted something cleaner.

Attempt 3: Other Options

I also looked at:

The Solution: MultCloud

After weeks of frustration, I discovered MultCloud — a service that lets you manage multiple cloud storage providers from one interface.

Here's why it won:

The workaround: I set up MultCloud to automatically sync specific folders from OneDrive to Google Drive. Now my AI agent accesses everything through Google Drive — the "easy" API we set up in the previous post.

How It Works

  1. Sign up for MultCloud (free tier available, paid for more features)
  2. Add OneDrive — authorize access to your OneDrive account
  3. Add Google Drive — authorize access
  4. Create a sync job — choose which OneDrive folders to sync to Google Drive
  5. Schedule it — sync hourly, daily, or in real-time
Tip: I caught MultCloud on a Valentine's Day lifetime deal — normally it's subscription-based. If you see a deal, grab it!

The Trade-offs

Is MultCloud perfect? No. Here's the reality:

ProsCons
Simple to set upThird-party dependency
Works reliablySubscription cost (or one-time deal)
No OAuth headachesData passes through their servers
Supports 80+ cloudsFree tier has limits

For me, the trade-off was worth it. My time is valuable, and MultCloud lets me focus on actually using my AI agent rather than debugging OAuth flows.

What I'd Do Differently

If I were starting fresh today, here's my advice:

  1. Start with MultCloud from day one if you need multi-cloud access
  2. Don't waste time on Microsoft Graph unless you have a business need
  3. Use rclone if you want a free, self-hosted solution and don't mind the CLI
  4. Consider the sync approach: One-way sync (OneDrive → Google Drive) is simpler than two-way

Lessons Learned

This whole saga taught me a few things:

What's Next

Now that my AI agent has access to both Google Drive and OneDrive (via sync), the automation possibilities have opened up. I can:

Next, I'm working on more advanced automation — maybe automatic file categorization or intelligent document routing. Stay tuned!

About the Author

Jingxiao Cai is a Principal Architect specializing in ML infrastructure. PhD in Radar Signal Processing from University of Oklahoma. Previously at Oracle building HeatWave ML infrastructure.