WorkIQ CLI returns 403 Forbidden / caller not entitled despite successful tenant enablement and licensing
Nobody has claimed this yet.
- Dominant language
- PowerShell
- Stars
- 1k
- Forks
- 132
- Avg merge
- 5d 19h
- Merged PRs (30d)
- 6
Description
Summary
WorkIQ is not usable in our tenant even after full admin enablement and user re-authentication.
workiq ask consistently returns 403 (Forbidden), and workiq fetch -u /me returns The caller is not entitled to use this tool.
CLI version
workiq version → 1.0.0.28144
Repro steps
- Run tenant provisioning/verification scripts:
pwsh -NoProfile -File scripts/Enable-WorkIQToolsForTenant.ps1pwsh -NoProfile -File scripts/Verify-WorkIQTenant.ps1
- Ensure account is logged in:
workiq auth logoutworkiq auth login --account <user>workiq auth consent -s "Mail.Read Sites.Read.All People.Read.All OnlineMeetingTranscript.Read.All Chat.Read ChannelMessage.Read.All ExternalItem.Read.All" --account <user>
- Run:
workiq ask --json -q "did Kearns send me an email today?"workiq fetch -u /me
Actual behavior
workiq ask --json ...returns:{"isError":true,"error":"Response status code does not indicate success: 403 (Forbidden).",...}
workiq fetch -u /mereturns:The caller is not entitled to use this tool.
Also reproduced across multiple prompts and agent IDs (including bizchat-as-gpt-scenario and planner declarative agent).
Expected behavior
After successful tenant enablement + consent + login, ask and fetch should execute (or return a specific missing-permission diagnostic if something is still missing).
Evidence that setup appears correct
Verify-WorkIQTenant.ps1reports all checks passed:- required MCP service principals exist
- Work IQ CLI SP exists
- required Graph delegated grants present
- MCP server grants present
Enable-WorkIQToolsForTenant.ps1reports permissions already granted.- User has
Microsoft_365_CopilotSKU assigned (service plans reported as provisioned). - MFA is enabled/enforced for the user:
- Graph
/beta/users/{upn}/authentication/requirementsreturnedperUserMfaState: enforced
- Graph
- WorkIQ CLI config:
- default account set correctly
- reproduces with both
experimental=trueandexperimental=false
workiq agents listsucceeds, butask/fetchremain blocked.
Suspected issue
A backend entitlement gate mismatch: tenant/app consent and licensing appear valid, but execution endpoints still treat the caller as not entitled.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by running scripts/Enable-WorkIQToolsForTenant.ps1 and scripts/Verify-WorkIQTenant.ps1, then reproduce with workiq ask and workiq fetch -u /me using the listed account and consent commands. Compare the successful tenant checks with the 403 and entitlement responses; done means those commands execute after valid enablement or return a specific missing-permission diagnostic.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- powershell
- Domain
- authorization, cli
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Active
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100