Repository navigation
Fix Azure DevOps work item URLs to point to human-facing UI instead of REST API - #23
Merged
Merged
Conversation
…T API URL Co-authored-by: richardthombs <1511599+richardthombs@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Fix Azure DevOps Work Item URLs to point to main website
Fix Azure DevOps work item URLs to point to human-facing UI instead of REST API
Mar 19, 2026
richardthombs
marked this pull request as ready for review
March 19, 2026 14:34
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Work item URLs in
RelatedIssue.URLwere set directly from theurlfield returned by the Azure DevOps API, which always uses the_apis/wit/workItems/{id}path rather than the browsable_workitems/edit/{id}path.Changes
buildAzureIssueList: replaced direct use ofitem.URLwith a newazureWorkItemWebURLhelperazureWorkItemWebURL: strips the/_apis/…suffix from the API URL and reconstructs as/_workitems/edit/{id}. Handles the org-scoped case (no project in path) by appendingSystem.TeamProject— e.g.https://dev.azure.com/ensekltd/_apis/wit/workItems/378982+ projectblackbird→https://dev.azure.com/ensekltd/blackbird/_workitems/edit/378982Applies to both the CLI (
az boards work-item show) and REST code paths, as both flow throughbuildAzureIssueList. Also coversvisualstudio.com-hosted organisations.Warning
Firewall rules blocked me from connecting to one or more addresses (expand for details)
I tried to connect to the following addresses, but was blocked by firewall rules:
https://api.github.com/repos/acme/repo/pulls/42/usr/bin/gh gh api repos/acme/repo/pulls/42 --jq .base.ref,.base.sha(http block)/usr/bin/gh gh api repos/acme/repo/pulls/42 --jq .base.ref,.base.sha go1.25.0 -c=4 -nolocalimports -importcfg /tmp/go-build990954897/b187/importcfg -pack /home/REDACTED/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.25.0.linux-amd64/src/vendor/golang.org/x/net/http/httpguts/guts.go 0.1-�� 0.1-go1.25.0.linux-amd64/src/run--gdwarf-5 r ux-amd64/pkg/tool/linux_amd64/vet(http block)/usr/bin/gh gh api repos/acme/repo/pulls/42 --jq .base.ref,.base.sha go1.25.0 -c=4 -nolocalimports -importcfg /tmp/go-build990954897/b130/importcfg -pack /home/REDACTED/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.25.0.linux-amd64/src/crypto/tls/alert.go(http block)https://api.github.com/repos/acme/repo/pulls/73/usr/bin/gh gh api repos/acme/repo/pulls/73 --jq .base.ref,.base.sha go1.25.0 -c=4 -nolocalimports -importcfg /tmp/go-build990954897/b195/importcfg -pack /home/REDACTED/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.25.0.linux-amd64/src/net/textproto/header.go(http block)https://api.github.com/repos/acme/repo/pulls/77/usr/bin/gh gh api repos/acme/repo/pulls/77 --jq .base.ref,.base.sha(http block)https://api.github.com/repos/checkouttestuser/checkouttestrepo/pulls/987654321/usr/bin/gh gh api repos/checkouttestuser/checkouttestrepo/pulls/987654321 --jq .base.ref,.base.sha /tmp/go-build990954897/b179/_x001.o /tmp/go-build990954897/b179/_x002.o /tmp/go-build990954897/b179/_x003.o /tmp/go-build990954897/b179/_x004.o /tmp/go-build990954897/b179/_x005.o /tmp/go-build990954897/b179/_x006.o -O2(http block)https://api.github.com/repos/checkouttestuser2/checkouttestrepo2/pulls/123456789/usr/bin/gh gh api repos/checkouttestuser2/checkouttestrepo2/pulls/123456789 --jq .base.ref,.base.sha(http block)If you need me to access, download, or install something from one of these locations, you can either:
Original prompt
💬 Send tasks to Copilot coding agent from Slack and Teams to turn conversations into code. Copilot posts an update in your thread when it's finished.