Create Sandbox/Testing Environment for API
Twitch currently completely lacks any sort of API testing feature. This causes extreme difficulty for debugging code made with the Twitch API.
This is unacceptable when the vast, vast majority of websites/software that have a public API have some sort of testing feature that sends tests through the same API endpoints as production.
For example, a piece of software I was working on recently worked great, but it turned out that events for subscriptions was broken. We have absolutely no way to test subscription events through the Twitch Pub/Sub API besides actually buying subs. I didn't actually fix it until hours later in the user's stream when we gave up on trying to fix it, when I remembered to check if the Pub/Sub was subscribed to the correct topics. I would have caught this immediately if I was just able to test the subs in the API.
Someone had suggested to create a mock Twitch API to test against, but that's not useful at all. It would require you to keep up with Twitch API changes. So say you want to write a check on GitHub actions to run an automated test, you may not know that the API was updated until it fails in production.
Testing Affiliate/Partner events is now possible with the Twitch CLI. See comments for more details.
As some folks have mentioned here, on other suggestions, and elsewhere in the community, testing Affiliate/Partner features is a challenge especially as we begin to add more endpoints like the Channel Points API. To begin solving this challenge, we have introduced the Twitch CLI in beta which allows you to test Affiliate/Partner events (among other features like creating OAuth tokens).
At this time, you can trigger test events for subscribe, unsubscribe, gift, cheer, Bits-in-Extensions transactions, add Channel Points reward, update Channel Points reward, remove Channel Points reward, create a Channel Points redemption, and update a Channel Points redemption notice.
With the functionality now available, we will close this suggestion. To provide additional feedback about the CLI, please use the Twitch CLI UserVoice category. If you have other ideas for testing APIs in addition to simulating events, please create a new suggestion in the API category.
Twitch CLI announcement:
Twitch CLI repository for installing:
Please please please I can't believe this doesn't already exist. I mean who would want to be able to test their applications without writing a massive amount of proprietary code anyway...
Up this. Is a MUST HAVE, it's impossible to test things without it. It would be awesome a kind of "Affiliate" level with the same privileges where we can test our stuff.