Azure / Azure/api-management-developer-portal

Developer Portal uses built-in gateway hostname instead of custom domain for API endpoints and “Try it” requests

Open
#2,852 7 comments 7 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
545
Forks
360
PR merge metrics
No merged PRs in 30d

Description

## Bug description

The Developer Portal displays and uses the built-in gateway hostname (e.g., `https://.azure-api.net`) for API endpoints and “Try it” requests, even when a custom Gateway domain is configured and working. Testing the API from the Azure Portal “Test” tab uses the custom domain correctly; only the Developer Portal keeps showing and calling the built-in URL.

Image

## Reproduction steps

1. Configure a custom domain for the Gateway (e.g., `api.example.com`) in APIM and verify it’s working (valid cert, DNS OK).
2. Publish an API with base path (e.g., `/v1`).
3. Open the Managed Developer Portal and navigate to the API details page.
4. Observe the endpoint shown in the header/samples and in the **Try it** console.
5. Send a request via **Try it**.
6. Compare with the same API called from Azure Portal → APIM → APIs → *Your API* → **Test** tab (which uses the custom domain).

## Actual behavior

- Developer Portal displays and calls the API using the built-in hostname `https://.azure-api.net/...`.
- The `Host` and request URL in the browser’s dev tools also reflect the built-in hostname.

## Expected behavior

- Developer Portal should display and use the configured **custom Gateway domain** (e.g., `https://api.example.com/...`) in the UI, samples, and “Try it” requests — or provide a clear setting to choose which hostname to use.

## Is self-hosted portal?

No (Managed Developer Portal).

Contributor guide

No contributing guide indexed for this repository

Research direction

Start from the Managed Developer Portal API details page and its “Try it” console, then trace how the endpoint, samples, and request URL are constructed. Compare that value with the configured custom Gateway domain; done means the UI, samples, and Try it requests use the custom domain or expose a clear hostname choice.

Written by the indexing model from the issue text.

Assessment

Tech stack
azure, typescript
Domain
api, frontend
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.