No credit card required · Free platform during early access · You bring the VPS

OneDrive as a backup destination

Overview

WayHost stores backups in OneDrive via Microsoft identity (Entra ID) OAuth. You register a Web app, add the redirect URI below, paste Application (client) ID and client secret into the backup destination, then click Connect.

Redirect URL (required)

In the Entra app registration, under Authentication → Platform configurations → Web → Redirect URIs, add exactly:

https://host.hamdek.com/api/integrations/onedrive/callback

A wrong scheme or domain causes Microsoft redirect / AADSTS errors.

Create the Microsoft Entra app

  1. Open Azure PortalMicrosoft Entra IDApp registrationsNew registration.
  2. Name the app (for example “WayHost Backups”).
  3. Supported account types: choose what fits your org (often “Accounts in any organizational directory and personal Microsoft accounts” if you use consumer OneDrive).
  4. Redirect URI: platform Web, URI = https://host.hamdek.com/api/integrations/onedrive/callback.
  5. Register.
  6. Certificates & secrets → New client secret → copy the secret Value immediately (it is shown once).
  7. Overview → copy Application (client) ID.
  8. API permissions → Microsoft Graph → Delegated:
    • Files.ReadWrite
    • offline_access
    Grant admin consent if your tenant requires it.

Add the destination in WayHost

  1. Project → Settings → Backup destinationsAdd destination.
  2. Type: OneDrive.
  3. Paste Application (client) ID and client secret Value.
  4. Test (optional) → Save.
  5. Click Connect in the table and finish the Microsoft login.

WayHost uses a folder such as wayhost-<project-slug>-backups in the OneDrive root for that project.

Optional platform defaults

MICROSOFT_CLIENT_ID=...
MICROSOFT_CLIENT_SECRET=...

Per-destination credentials in the UI override these env values when set.

Troubleshooting

  • Redirect URI mismatch — confirm the Web redirect URI is exactly https://host.hamdek.com/api/integrations/onedrive/callback.
  • Need admin approval — a tenant admin must grant consent for Graph permissions.
  • Secret expired — create a new client secret in Entra and update the destination, then Connect again.