Support custom token endpoints (non-Copilot Studio)
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 55/100
- Issue type
- Feature
- Clarity
- Clearly specified
- Activity status
- Stale
- Tech stack
- javascript
- Domain
- api
Research direction
Start by locating the embed SDK handling for data-webchat-token-url and regionalchannelsettings, then trace how the Direct Line domain is selected. Add the proposed data-webchat-domain configuration and verify that it overrides regional auto-detection while the existing custom token endpoint flow continues to work.
Written by the indexing model from the issue text.
Description
Summary
Add support for custom token endpoints that are not Copilot Studio, such as a server-side proxy that holds a Direct Line secret and returns conversation tokens.
Motivation
Currently the library assumes the token endpoint is a Copilot Studio endpoint and auto-detects the regional Direct Line domain via regionalchannelsettings. Users with custom token endpoints (e.g., their own backend that holds a Direct Line secret and generates tokens) can already use data-webchat-token-url, but the regional domain auto-detection won't work since there's no regionalchannelsettings API.
Proposed Change
Add a data-webchat-domain attribute that lets users explicitly set the Direct Line endpoint URL (e.g., https://europe.directline.botframework.com/v3/directline). When set, this overrides the auto-detected regional domain.
This is the only missing piece — the token endpoint pattern already works. Users should keep their Direct Line secret on the server and expose a token endpoint, not put secrets in HTML.
Note on Direct Line secrets
This library will not support putting Direct Line secrets in HTML attributes. Secrets are long-lived server-side credentials meant for secure environments (key vaults, backend services). The correct pattern for client-side usage is always a token endpoint that returns short-lived conversation tokens.
- Dominant language
- JavaScript
- Stars
- 0
- Forks
- 2
- PR merge metrics
- No merged PRs in 30d
Contributor guide
No contributing guide indexed for this repository
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.
More from microsoft/botframework-webchat-embed
-
enhancement
Difficulty 5/5 Over a week Newbie friendliness 35/100
-
enhancement
Difficulty 5/5 Over a week Newbie friendliness 25/100
All issues in microsoft/botframework-webchat-embed
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
HarperFast/skills#96 ·
-
[Block] Latest Posts [Type] Bug
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Automattic/studio#4908 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 86/100
sugarlabs/musicblocks#8847 ·