Forum Discussion
With Azure API Management can you hide Try me function for API and limit product subscription count
With Azure APIM developer portal:
Question 1: Can you hide the "Try me" button if the user is not logged in or does not have any API/Product subscription
Question 2: Can we stop users from having multiple subscriptions to the same product
2 Replies
Yes, you can hide the “Try it”/“Try me” button in the developer portal through customization and access controls, and you can also enforce a subscription count limit at the product level to prevent multiple subscriptions.
https://learn.microsoft.com/en-us/azure/api-management/api-management-subscriptions
APIM uses different controls for these requirements. For anonymous visitors, the managed developer portal can redirect anonymous users to sign-in from Developer portal > Identities > Settings. Limit product and page visibility to selected user groups. The built-in API reference owns Try it, so no simple product switch hides only that control from a signed-in nonsubscriber. Use access-controlled page sections or a custom widget; self-hosting is the option when core portal behavior must be changed. Regardless of visibility, protect the API itself: enable Requires subscription on the product, and use OAuth or another gateway policy when stronger authorization is needed. Hiding a button is not an access control. To prevent duplicate subscriptions, edit the product and set Subscription count limit to 1. Optionally enable Requires approval. Test with an anonymous browser, a signed-in nonsubscriber, and a subscriber before republishing the portal.