[FIXED] This API does not exist (migration to helix)

Hello,

I’m working on the development of twitch extension.

Our backend uses the following endpoint which seems to have changed as the previous version was once approved by twitch review team:
https://api.twitch.tv/extensions/{TWITCH_EXTENSION_CLIENT_ID}/configurations/segments/broadcaster?channel_id={channel_id}

and when I’m sending GET request all I receive is

{'error': 'Not Found', 'status': 404, 'message': 'This API does not exist'}

I went through the documentation but couldn’t find this endpoint or any other that would substitute it’s functionality.

I might be missing something here but unfortunately I’m unable to contact the previous developer.

Can I get any directions on this one?

Thanks

P.S. I’m pretty sure we are using JWT Authorization right because we are sending PUT request and that functionality works at:
https://api.twitch.tv/extensions/{TWITCH_EXTENSION_CLIENT_ID}/configurations

The old Extension API’s have been migrated to helix equivalents

See

This migration doesn’t effect get/set calls made via the JS helper only EBS/Server calls.

From your OP not sure if GETTING or SETTING Config segments

Which have a different URL structure and payload layout to previous but the same authentication requirements/JWT construction.

Hey,

Thanks for your response. I’m trying to GET the config segment.

I found that reference Reference | Twitch Developers, but unfortunately I was not able to render the equivalent URL for this:
https://api.twitch.tv/extensions/{TWITCH_EXTENSION_CLIENT_ID}/configurations/segments/broadcaster?channel_id={channel_id}

as there doesn’t seem to be broadcaster segment with channel_id property in documentation. Am I missing something here?

is broadcaster_id the same as channel_id ?

Thanks

Yes

The equivalent is

For Getting
GET https://api.twitch.tv/helix/extensions/configurations?broadcaster_id=foo&extension_id=bar&segment=broadcaster

For Setting
PUT https://api.twitch.tv/helix/extensions/configurations
With JSON body:

{
    "extension_id": "bar",
    "segment": "broadcaster",
    "broadcaster_id": "foo",
    "content": "whatever"
}

The segment is moved from a route param to a query string param or body param instead.

Code Example/test tool: Twitch Example | Extension Config Tool

1 Like

@BarryCarlyon thank you so much for quick response and your help.

Will give it a try right now.

@BarryCarlyon This is the response I’ve received:

{'data': []}

I was expecting something more like this:

{
  "data": [
    {
      "segment": "global",
      "content": "hello config!",
      "version": "0.0.1"
    }
  ]
}

We have only discussed loading a broadcasters segment. Not a global config.

Global segment is loaded with:

GET https://api.twitch.tv/helix/extensions/configurations?extension_id=bar&segment=global

Still the same response :
{'data': []}

Then this would indicate that no config is set in the global segment (or the broadcaster segment for the requested channel) for the specified Extension

That’s little strange to me as the PUT request at https://api.twitch.tv/helix/extensions/configurations returns with <Response [204]> status code.

Excuse me if I miss something really simple here.

The API will return 204 when doing a PUT even if the config service is disabled on the extension settings in the dashboard.

In the Dev Console it should be set to:

NVM it worked.

I was using the segment=global the last time.

Thank you so so much.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.