Go module handling Microsoft OAuth scopes and token management.
// Source: https://github.com/obra/msgvault | License: MIT | Copyright 2025-2026 Wes McKinney // Provided via justclaw.it.com; keep this notice with the code. package microsoft import ( "context" "crypto/rand" "crypto/sha256" "encoding/base64" "encoding/json" "errors" "fmt" "log/slog" "net" "net/http" "net/url" "os" "os/exec" "path/filepath" "runtime" "strings" "sync" "time" "github.com/coreos/go-oidc/v3/oidc" "go.kenn.io/msgvault/internal/fileutil" "golang.org/x/oauth2" ) const ( DefaultTenant = "common" // ScopeIMAPOrg is the IMAP scope for organizational (O365) accounts. ScopeIMAPOrg = "https://outlook.office365.com/IMAP.AccessAsUser.All" // ScopeIMAPPersonal is the IMAP scope for personal Microsoft accounts // (hotmail.com, outlook.com, live.com, etc.). S ... (truncated -- full source via MCP)
See the full source, get the GitHub permalink, and search for more like it.
Get a free API key