### GET /tips/{channel}
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/tips.md
List tips for a specific channel.
```APIDOC
## GET /tips/{channel}
### Description
List tips for a specific channel.
### Method
GET
### Endpoint
/tips/{channel}
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
#### Query Parameters
- **offset** (integer) - Required - integer - Starting element
- **limit** (integer) - Required - integer - Events per page between 1 and 100
- **sort** (string) - Required - string - Sorting method. Possible values createdAt, -create
- **tz** (integer) - Required - integer - Timezone number
- **username** (string) - Required - string - Username
- **email** (string) - Required - string - Email address
- **after** (integer) - Required - datetime - Start date
- **before** (integer) - Required - datetime - End date
- **message** (string) - Required - string - Tip message
```
--------------------------------
### GET /tips/{channel}/leaderboard
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/tips.md
Get tips leaderboard for a channel.
```APIDOC
## GET /tips/{channel}/leaderboard
### Description
Get tips leaderboard for a channel.
### Method
GET
### Endpoint
/tips/{channel}/leaderboard
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
```
--------------------------------
### GET /tips/{channel}/top
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/tips.md
Get top tippers for a channel.
```APIDOC
## GET /tips/{channel}/top
### Description
Get top tippers for a channel.
### Method
GET
### Endpoint
/tips/{channel}/top
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
```
--------------------------------
### GET | POST /bot/commands/{channel}
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/endpoints.md
List custom commands for the channel.
```APIDOC
## GET | POST /bot/commands/{channel}
### Description
List custom commands.
### Method
GET, POST
### Endpoint
/bot/commands/{channel}
### Parameters
#### Path Parameters
- **channel** (string) - Required - The channel identifier.
```
--------------------------------
### GET /tips/{channel}/{tipId}
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/tips.md
Get details for a specific tip.
```APIDOC
## GET /tips/{channel}/{tipId}
### Description
Get details for a specific tip.
### Method
GET
### Endpoint
/tips/{channel}/{tipId}
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
- **tipId** (string) - Required - guid - Tip id
#### Query Parameters
- **type** (string) - Required
#### Header Parameters
- **Accept** (string) - Required
```
--------------------------------
### GET /overlays/{channel}
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/overlays.md
List overlays for a specific channel.
```APIDOC
## GET /overlays/{channel}
### Description
List overlays for a given channel.
### Method
GET
### Endpoint
/overlays/{channel}
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
#### Query Parameters
- **search** (string) - Required - ''
- **type** (string) - Required - ''
### Response
#### Success Response (200)
```
--------------------------------
### GET /bot/commands/{channel}/default
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/bot.md
Lists default commands for a channel.
```APIDOC
## GET /bot/commands/{channel}/default
### Description
Lists default commands for the specified channel.
### Method
GET
### Endpoint
/bot/commands/{channel}/default
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
#### Query Parameters
- **language** (string) - Required - string - language iso code lowercase (eg. en)
#### Header Parameters
- **Accept** (string) - Required - ''
### Response
#### Success Response (200)
- Response code: 200
```
--------------------------------
### GET /channels/{channel}/details
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/channels.md
Get channel details.
```APIDOC
## GET /channels/{channel}/details
### Description
Get channel details.
### Method
GET
### Endpoint
/channels/{channel}/details
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
#### Header Parameters
- **Accept** (string) - Required - ''
### Response
#### Success Response (200)
```
--------------------------------
### GET /kappa/v2/songrequest/{channel}/next
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/README.md
Retrieves the next song in the queue.
```APIDOC
## GET /kappa/v2/songrequest/{channel}/next
### Description
Retrieves the next song in the queue.
### Method
GET
### Endpoint
https://api.streamelements.com/kappa/v2/songrequest/{channel}/next
### Parameters
#### Path Parameters
- **channel** (string) - Required - The channel ID.
```
--------------------------------
### GET /kappa/v2/activities/{channel}
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/README.md
Retrieves a list of activities for a specific channel.
```APIDOC
## GET /kappa/v2/activities/{channel}
### Description
Retrieves a list of activities for a specific channel.
### Method
GET
### Endpoint
https://api.streamelements.com/kappa/v2/activities/{channel}
### Parameters
#### Path Parameters
- **channel** (string) - Required - The channel ID.
#### Query Parameters
- **after** (string) - Optional - Start timestamp.
- **before** (string) - Optional - End timestamp.
- **limit** (integer) - Optional - Number of results to return.
```
--------------------------------
### PUT /contests/{channel}/{contestId}/start
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/contests.md
Starts a contest for a given channel.
```APIDOC
## PUT /contests/{channel}/{contestId}/start
### Description
Start a contest.
### Method
PUT
### Endpoint
/contests/{channel}/{contestId}/start
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
- **contestId** (string) - Required - guid - Contest id
### Response
#### Success Response (200)
```
--------------------------------
### PUT /giveaways/{channel}/{giveawayId}/start
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/giveaways.md
Starts a giveaway for a specific channel.
```APIDOC
## PUT /giveaways/{channel}/{giveawayId}/start
### Description
Starts the giveaway identified by the giveawayId for the specified channel.
### Method
PUT
### Endpoint
/giveaways/{channel}/{giveawayId}/start
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
- **giveawayId** (string) - Required - guid - Giveaway id
#### Header Parameters
- **Accept** (string) - Required
### Response
#### Success Response (200)
- Status Code: 200
#### Error Response (400)
- Status Code: 400
```
--------------------------------
### GET | POST /bot/timers/{channel}
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/bot.md
List timers for a specific channel.
```APIDOC
## GET | POST /bot/timers/{channel}
### Description
List timers.
### Method
GET, POST
### Endpoint
/bot/timers/{channel}
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
#### Header Parameters
- **Accept** (string) - Required
### Response
#### Success Response (200, 201)
#### Error Response (409)
```
--------------------------------
### GET /bot/modules/{channel}
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/bot.md
Retrieve module information for a channel.
```APIDOC
## GET /bot/modules/{channel}
### Description
TODO: Add Description
### Method
GET
### Endpoint
/bot/modules/{channel}
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
#### Query Parameters
- **id** (string) - Required - guid - banned phrase id
#### Header Parameters
- **Accept** (string) - Required
### Response
#### Success Response (200)
```
--------------------------------
### GET /kappa/v2/tips/{channel}/top
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/README.md
Retrieves the list of top tippers for a channel.
```APIDOC
## GET /kappa/v2/tips/{channel}/top
### Description
Retrieves the list of top tippers for a channel.
### Method
GET
### Endpoint
https://api.streamelements.com/kappa/v2/tips/{channel}/top
### Parameters
#### Path Parameters
- **channel** (string) - Required - The channel ID.
#### Query Parameters
- **limit** (integer) - Optional - Number of results to return.
```
--------------------------------
### GET | POST /activities/{channel}/{activityId}
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/activities.md
Get activity details by id.
```APIDOC
## GET | POST /activities/{channel}/{activityId}
### Description
Get activity details by id.
### Method
GET | POST
### Endpoint
/activities/{channel}/{activityId}
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
- **activityId** (string) - Required - guid - Activity id
### Response
#### Success Response (200)
- 200
```
--------------------------------
### Websocket connection example
Source: https://github.com/streamelements/api-docs/blob/main/docs/Websockets.md
Establish a connection to the StreamElements realtime server and handle authentication and event listeners.
```js
// AccessToken is grabbed from OAuth2 authentication of the account.
const accessToken = "";
// JWT is available here: https://streamelements.com/dashboard/account/channels
const jwt = "";
const socket = io('https://realtime.streamelements.com', {
transports: ['websocket']
});
// Socket connected
socket.on('connect', onConnect);
// Socket got disconnected
socket.on('disconnect', onDisconnect);
// Socket is authenticated
socket.on('authenticated', onAuthenticated);
socket.on('unauthorized', console.error);
socket.on('event:test', (data) => {
console.log(data);
// Structure as on https://github.com/StreamElements/widgets/blob/master/CustomCode.md#on-event
});
socket.on('event', (data) => {
console.log(data);
// Structure as on https://github.com/StreamElements/widgets/blob/master/CustomCode.md#on-event
});
socket.on('event:update', (data) => {
console.log(data);
// Structure as on https://github.com/StreamElements/widgets/blob/master/CustomCode.md#on-session-update
});
socket.on('event:reset', (data) => {
console.log(data);
// Structure as on https://github.com/StreamElements/widgets/blob/master/CustomCode.md#on-session-update
});
function onConnect() {
console.log('Successfully connected to the websocket');
socket.emit('authenticate', {method: 'oauth2', token: accessToken});
//socket.emit('authenticate', {method: 'jwt', token: jwt});
}
function onDisconnect() {
console.log('Disconnected from websocket');
// Reconnect
}
function onAuthenticated(data) {
const {
channelId
} = data;
console.log(`Successfully connected to channel ${channelId}`);
}
```
--------------------------------
### Listen for Overlay Events
Source: https://github.com/streamelements/api-docs/blob/main/docs/Widgets.md
Basic event listener setup for handling incoming overlay events.
```javascript
window.addEventListener('onEventReceived', function (obj) {
// fancy stuff here
});
```
--------------------------------
### GET /tips/{channel}/moderation
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/tips.md
List tips waiting for moderation.
```APIDOC
## GET /tips/{channel}/moderation
### Description
List tips waiting for moderation.
### Method
GET
### Endpoint
/tips/{channel}/moderation
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
```
--------------------------------
### Construct Authorization URL
Source: https://github.com/streamelements/api-docs/blob/main/docs/OAuth2.md
Example URL for initiating the authorization code grant flow with required parameters.
```text
https://api.streamelements.com/oauth2/authorize?client_id=9d5422b8ff529d420&redirect_uri=https%3A%2F%2Foauth.it-really.rocks%2Fcallback&response_type=code&scope=channel%3Aread
```
--------------------------------
### GET /overlays/{channel}/{overlayId}
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/overlays.md
Gets detailed information about a specific overlay, including all widgets contained within it.
```APIDOC
## GET /overlays/{channel}/{overlayId}
### Description
Gets overlay details with all widgets on it.
### Method
GET
### Endpoint
/overlays/{channel}/{overlayId}
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
- **overlayId** (string) - Required - guid - Overlay id
### Response
#### Success Response (200)
```
--------------------------------
### GET | POST /bot/{channel}/levels
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/bot.md
List channel permissions for users.
```APIDOC
## GET | POST /bot/{channel}/levels
### Description
List channel permissions for users.
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
#### Header Parameters
- **Accept** (string) - Required - ''
```
--------------------------------
### GET | PUT /bot/filters/{channel}
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/bot.md
List filters for a specific channel.
```APIDOC
## GET | PUT /bot/filters/{channel}
### Description
List filters for the specified channel.
### Method
GET, PUT
### Endpoint
/bot/filters/{channel}
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
#### Header Parameters
- **Accept** (string) - Required
### Response
#### Success Response (200)
```
--------------------------------
### Handle Redirect URL
Source: https://github.com/streamelements/api-docs/blob/main/docs/OAuth2.md
Example of the callback URL received by the application containing the authorization code and state.
```text
https://oauth.it-really.rocks?code=hjqkweSNDSDQ2___12&state=ejlkqwj2u31u31i1
```
--------------------------------
### GET /kappa/v2/points/{channel}
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/overview.md
Retrieve a paginated list of points for a specific channel.
```APIDOC
## GET /kappa/v2/points/{channel}
### Description
Retrieve a paginated list of points for a specific channel.
### Method
GET
### Endpoint
https://api.streamelements.com/kappa/v2/points/{channel}
### Parameters
#### Path Parameters
- **channel** (string) - Required - The channel identifier.
#### Query Parameters
- **limit** (integer) - Optional - Number of items to return.
- **offset** (integer) - Optional - Number of items to skip.
```
--------------------------------
### GET /activities/{channel}
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/endpoints.md
List channel activities including followers, tips, hosts, and raids.
```APIDOC
## GET /activities/{channel}
### Description
List channel activities.
### Method
GET
### Endpoint
/activities/{channel}
### Parameters
#### Path Parameters
- **channel** (string) - Required - The channel identifier.
```
--------------------------------
### GET /giveaways/{channel}
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/giveaways.md
List all giveaways for a specific channel.
```APIDOC
## GET /giveaways/{channel}
### Description
List giveaways for the specified channel.
### Method
GET
### Endpoint
/giveaways/{channel}
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
#### Header Parameters
- **Accept** (string) - Required
### Response
#### Success Response (200)
```
--------------------------------
### GET /bot/commands/{channel}
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/bot.md
List custom commands for a specific channel.
```APIDOC
## GET /bot/commands/{channel}
### Description
List custom commands for the specified channel.
### Method
GET
### Endpoint
/bot/commands/{channel}
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
#### Header Parameters
- **Accept** (string) - Required - ''
### Response
#### Success Response (200, 201)
- Response codes: 200, 201, 400, 409
```
--------------------------------
### GET /store/{channel}/items/{itemId}
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/store.md
Get details for a specific store item.
```APIDOC
## GET /store/{channel}/items/{itemId}
### Description
Get item details for a specific item in a channel.
### Method
GET
### Endpoint
/store/{channel}/items/{itemId}
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
- **itemId** (string) - Required - guid - Item id
### Response
#### Success Response (200)
- **Response** (N/A) - Success
```
--------------------------------
### Render input fields in the panel
Source: https://github.com/streamelements/api-docs/blob/main/docs/Widgets.md
Examples of how input fields are constructed for the left panel interface.
```html
```
```html
```
--------------------------------
### GET /songrequest/{channel}/settings
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/songrequest.md
Retrieves the settings for the song request system.
```APIDOC
## GET /songrequest/{channel}/settings
### Description
Get settings
### Method
GET
### Endpoint
/songrequest/{channel}/settings
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
### Response
#### Success Response (200)
```
--------------------------------
### GET /bot/{channel}
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/bot.md
Retrieves information about the bot for a specific channel.
```APIDOC
## GET /bot/{channel}
### Description
Get bot info for the specified channel.
### Method
GET
### Endpoint
/bot/{channel}
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
#### Header Parameters
- **Accept** (string) - Required
### Response
#### Success Response (200)
```
--------------------------------
### GET /contests/{channel}
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/contests.md
List contests for a specific channel.
```APIDOC
## GET /contests/{channel}
### Description
List contests for a specific channel.
### Method
GET
### Endpoint
/contests/{channel}
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
#### Header Parameters
- **Accept** (string) - Required - ''
```
--------------------------------
### GET | POST /songrequest/{channel}/queue
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/endpoints.md
Retrieves or manages the songrequest queue.
```APIDOC
## GET | POST /songrequest/{channel}/queue
### Description
Get songrequest queue.
### Method
GET | POST
### Endpoint
/songrequest/{channel}/queue
```
--------------------------------
### GET /store/{channel}/items
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/store.md
List store items for a specific channel.
```APIDOC
## GET /store/{channel}/items
### Description
List store items for a given channel.
### Method
GET
### Endpoint
/store/{channel}/items
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
#### Query Parameters
- **limit** (integer) - Required - integer - number of items per page
- **offset** (integer) - Required - integer - number of items to be skipped
### Response
#### Success Response (200)
- **Response** (N/A) - Success
```
--------------------------------
### GET /kappa/v2/songrequest/{channel}/playing
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/README.md
Retrieves the currently playing song.
```APIDOC
## GET /kappa/v2/songrequest/{channel}/playing
### Description
Retrieves the currently playing song.
### Method
GET
### Endpoint
https://api.streamelements.com/kappa/v2/songrequest/{channel}/playing
### Parameters
#### Path Parameters
- **channel** (string) - Required - The channel ID.
```
--------------------------------
### GET /loyalty/{channel}
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/loyalty.md
Retrieves the loyalty settings for a specified channel.
```APIDOC
## GET /loyalty/{channel}
### Description
Get loyalty settings for the specified channel.
### Method
GET
### Endpoint
/loyalty/{channel}
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
#### Header Parameters
- **Accept** (string) - Required
### Response
#### Success Response (200)
```
--------------------------------
### PUT /bot/filters/{channel}/{filter}
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/bot.md
Start a contest for a specific filter in a channel.
```APIDOC
## PUT /bot/filters/{channel}/{filter}
### Description
Start a contest.
### Method
PUT
### Endpoint
/bot/filters/{channel}/{filter}
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
- **filter** (string) - Required
#### Header Parameters
- **Accept** (string) - Required
### Response
#### Success Response (200)
```
--------------------------------
### GET /sessions/{channel}/settings
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/sessions.md
Retrieves the session settings for a specified channel.
```APIDOC
## GET /sessions/{channel}/settings
### Description
Get session settings for a specific channel.
### Method
GET
### Endpoint
/sessions/{channel}/settings
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
### Response
#### Success Response (200)
```
--------------------------------
### GET /activities/{channel}
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/activities.md
List channel activities based on specified filters.
```APIDOC
## GET /activities/{channel}
### Description
List channel activities.
### Method
GET
### Endpoint
/activities/{channel}
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
#### Query Parameters
- **after** (integer) - Required - datetime - Start date
- **before** (integer) - Required - datetime - End date
- **limit** (integer) - Required - integer - events per page between 1 and 100
- **mincheer** (integer) - Required - integer - minimum amount of bits in cheer
- **minhost** (integer) - Required - integer - minimum amount of viewers in host
- **minsub** (integer) - Required - integer - minimum amount of subscription's months
- **mintip** (integer) - Required - integer - minimum amount of tip
- **origin** (string) - Required - ''
- **types** (string) - Required - 'array - Possible values: follow, tip, host, cheer, redempti
### Response
#### Success Response (200)
- 200
```
--------------------------------
### View Rate Limit Headers
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/errors.md
Example of the standard HTTP headers returned by the API to indicate rate limit status.
```http
X-RateLimit-Limit: 100
X-RateLimit-Remaining: 87
X-RateLimit-Reset: 1691174700
```
--------------------------------
### Handle Event Data
Source: https://github.com/streamelements/api-docs/blob/main/docs/Widgets.md
Example of accessing event details and updating the DOM using jQuery or vanilla JavaScript.
```javascript
window.addEventListener('onEventReceived', function (obj) {
const listener = obj.detail.listener;
const data = obj["detail"]["event"];
// Assigned new const value, for easier handling. You can do it with .property or ["property"].
// I personally recommend using [""] as some of keys can have "-" within, so you won't be able
// to call them (JS will try to do math operation on it).
// jQuery is included by default, so you can use following
$("#usernameContainer").html(data["name"]);
$("#actionContainer").html(listener);
//You can use vanilla JS as well
document.getElementById("amount").innerHTML=data["amount"]
});
```
--------------------------------
### API Response Structure
Source: https://github.com/streamelements/api-docs/blob/main/docs/OAuth2.md
Example JSON response body returned by the API.
```json
{
"profile": {
"title": "example's profile",
"headerImage": "https://cdn.streamelements.com/uploads/cc9f302f-44e6-4527-9db5-f461678ec643.png"
},
"_id": "0123456789abcdefghijkl",
"provider": "twitch",
"broadcasterType": "affiliate",
"suspended": false,
"providerId": "28057703",
"email": "example@example.com",
"avatar": "https://static-cdn.jtvnw.net/jtv_user_pictures/01234567-0123-abcd-efgh-9876543210ab-profile_image-300x300.png",
"type": "streamer",
"apiToken": "abcdefghijklmnopqrstuvwxyz",
"username": "example",
"alias": "example",
"displayName": "Example",
"[...]"
}
```
--------------------------------
### GET /songrequest/{channel}/next
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/songrequest.md
Retrieves details of the next song in the queue.
```APIDOC
## GET /songrequest/{channel}/next
### Description
Get details of next song in queue
### Method
GET
### Endpoint
/songrequest/{channel}/next
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
### Response
#### Success Response (200)
```
--------------------------------
### GET /songrequest/{channel}/queue/public
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/endpoints.md
Retrieves the songrequest queue for public exposure.
```APIDOC
## GET /songrequest/{channel}/queue/public
### Description
Get songrequest queue for public exposure (without video details).
### Method
GET
### Endpoint
/songrequest/{channel}/queue/public
```
--------------------------------
### Execute API Request
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/MANIFEST.txt
Example of a cURL request to the channels endpoint using a JWT token.
```bash
curl -H "Authorization: Bearer YOUR_TOKEN" \
https://api.streamelements.com/kappa/v2/channels/me
```
--------------------------------
### Get Channel Activities
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/README.md
Retrieves a list of channel activities filtered by time range and limit.
```bash
curl -H "Authorization: Bearer TOKEN" \
'https://api.streamelements.com/kappa/v2/activities/{channel}?after=0&before=1691174700000&limit=25'
```
--------------------------------
### GET /songrequest/{channel}/settings/public
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/songrequest.md
Retrieves the public settings for the song request system.
```APIDOC
## GET /songrequest/{channel}/settings/public
### Description
Get public settings
### Method
GET
### Endpoint
/songrequest/{channel}/settings/public
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
### Response
#### Success Response (200)
```
--------------------------------
### Create a Resource
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/overview.md
Send a POST request with a JSON body to create a new resource.
```bash
curl -X POST \
-H "Authorization: Bearer TOKEN" \
-H "Content-Type: application/json" \
-d '{"name":"CommandName","reply":"Response text"}' \
https://api.streamelements.com/kappa/v2/bot/commands/{channel}
```
--------------------------------
### GET /activities/{channel}/top
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/activities.md
List channel's top activities by selected type.
```APIDOC
## GET /activities/{channel}/top
### Description
List channel's top activities by selected type.
### Method
GET
### Endpoint
/activities/{channel}/top
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
#### Query Parameters
- **offset** (integer) - Required - integer - starting element
- **limit** (integer) - Required - integer - number of events
- **type** (string) - Required - 'string - Possible values: cheer, tip'
- **period** (string) - Required - 'string - Possible values: alltime, months, weeks, session'
### Response
#### Success Response (200)
- 200
```
--------------------------------
### GET /themes/{themeId}
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/themes.md
Retrieves the details for a specific theme using its unique identifier.
```APIDOC
## GET /themes/{themeId}
### Description
Get theme details
### Method
GET
### Endpoint
/themes/{themeId}
### Parameters
#### Path Parameters
- **themeId** (string) - Required - guid - theme id
#### Header Parameters
- **Accept** (string) - Required
### Response
#### Success Response (200)
- Returns theme details
```
--------------------------------
### GET /bot/commands/{channel}/public
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/bot.md
Retrieves a list of all public commands available for a specified channel.
```APIDOC
## GET /bot/commands/{channel}/public
### Description
List channel's public commands.
### Method
GET
### Endpoint
/bot/commands/{channel}/public
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
#### Header Parameters
- **Accept** (string) - Required - ''
### Response
#### Success Response (200)
```
--------------------------------
### GET /bot/{channel}/counters/{counter}
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/bot.md
Retrieves a list of bot modules for a specific counter in a channel.
```APIDOC
## GET /bot/{channel}/counters/{counter}
### Description
Get list of bot modules.
### Method
GET
### Endpoint
/bot/{channel}/counters/{counter}
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
- **counter** (string) - Required - string - Counter name
#### Header Parameters
- **Accept** (string) - Required
### Response
#### Success Response (200)
```
--------------------------------
### GET /points/{channel}/top
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/points.md
Retrieves a list of top user points for a channel.
```APIDOC
## GET /points/{channel}/top
### Description
List top userpoints.
### Method
GET
### Endpoint
/points/{channel}/top
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
#### Query Parameters
- **limit** (integer) - Required - integer - Number of items per page
- **offset** (integer) - Required - integer - Number of items to be skipped
#### Header Parameters
- **Accept** (string) - Required - ''
### Response
#### Success Response (200)
```
--------------------------------
### GET /channels/{channel}/emotes
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/channels.md
Get emotes that can be used on channel (twitch, bttv, ffz).
```APIDOC
## GET /channels/{channel}/emotes
### Description
Get emotes that can be used on channel (twitch, bttv, ffz).
### Method
GET
### Endpoint
/channels/{channel}/emotes
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
#### Header Parameters
- **Accept** (string) - Required - ''
### Response
#### Success Response (200)
```
--------------------------------
### GET | PUT /store/{channel}/items/{itemId}
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/endpoints.md
Retrieves or updates store item details.
```APIDOC
## GET | PUT /store/{channel}/items/{itemId}
### Description
Get item details.
### Method
GET | PUT
### Endpoint
/store/{channel}/items/{itemId}
```
--------------------------------
### GET /channels/{channel}
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/channels.md
Get channel details for provided channel id or channel name.
```APIDOC
## GET /channels/{channel}
### Description
Get channel details for provided channel id or channel name.
### Method
GET
### Endpoint
/channels/{channel}
### Parameters
#### Path Parameters
- **channel** (string) - Required - String|guid - Channel name or channel id
#### Header Parameters
- **Accept** (string) - Required - ''
### Response
#### Success Response (200)
```
--------------------------------
### GET /store/{channel}/redemptions/me
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/store.md
Get the authenticated user's own redemptions for a specific channel.
```APIDOC
## GET /store/{channel}/redemptions/me
### Description
Get own redemptions for a specific channel.
### Method
GET
### Endpoint
/store/{channel}/redemptions/me
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
#### Query Parameters
- **limit** (integer) - Required - Number of items per page
- **offset** (integer) - Required - Number of items to be skipped
### Response
#### Success Response (200)
```
--------------------------------
### List Resources with Pagination
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/overview.md
Retrieve a paginated list of resources using limit and offset query parameters.
```bash
curl -H "Authorization: Bearer TOKEN" \
'https://api.streamelements.com/kappa/v2/points/{channel}?limit=25&offset=0'
```
--------------------------------
### POST /kappa/v2/bot/commands/{channel}
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/README.md
Creates a new bot command for the specified channel.
```APIDOC
## POST /kappa/v2/bot/commands/{channel}
### Description
Creates a new bot command for the specified channel.
### Method
POST
### Endpoint
https://api.streamelements.com/kappa/v2/bot/commands/{channel}
### Parameters
#### Path Parameters
- **channel** (string) - Required - The channel ID or name.
#### Request Body
- **name** (string) - Required - The command name (e.g., !hello).
- **reply** (string) - Required - The response message.
- **cooldown** (integer) - Optional - Cooldown in seconds.
```
--------------------------------
### GET /kappa/v2/channels/me
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/configuration.md
Retrieves the current authenticated user's channel information, including the channel ID.
```APIDOC
## GET /kappa/v2/channels/me
### Description
Retrieves the current authenticated user's channel information, including the channel ID (_id).
### Method
GET
### Endpoint
https://api.streamelements.com/kappa/v2/channels/me
### Response
#### Success Response (200)
- **_id** (guid) - The unique channel identifier
```
--------------------------------
### SE_API.store.get(keyName)
Source: https://github.com/streamelements/api-docs/blob/main/docs/Widgets.md
Retrieves an object from the database associated with the provided keyName.
```APIDOC
## SE_API.store.get(keyName)
### Description
Retrieves the object stored in the database for the given keyName.
### Parameters
- **keyName** (string) - Required - The key identifier for the data.
### Response
- **Promise** (object) - Resolves with the stored object.
```
--------------------------------
### List Top Tippers
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/README.md
Fetches the top tippers for a specific channel.
```bash
curl -H "Authorization: Bearer TOKEN" \
'https://api.streamelements.com/kappa/v2/tips/{channel}/top?limit=10'
```
--------------------------------
### Include Socket.io Client
Source: https://github.com/streamelements/api-docs/blob/main/docs/Websockets.md
Include the Socket.io library via CDN to enable websocket functionality in the browser.
```html
```
--------------------------------
### Initialize Widget Data
Source: https://github.com/streamelements/api-docs/blob/main/docs/Widgets.md
Handles the widget load event and provides access to session, recents, and channel configuration data.
```javascript
window.addEventListener('onWidgetLoad', function (obj) {
//fancy stuff here
});
```
```javascript
window.addEventListener('onWidgetLoad', function (obj) {
let data=obj["detail"]["session"]["data"];
let recents=obj["detail"]["recents"];
let currency=obj["detail"]["currency"];
let channelName=obj["detail"]["channel"]["username"];
let apiToken=obj["detail"]["channel"]["apiToken"];
let fieldData=obj["detail"]["fieldData"];
});
```
--------------------------------
### GET /sessions/{channel}
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/sessions.md
Retrieves session data for a specified channel.
```APIDOC
## GET /sessions/{channel}
### Description
Get session data for the specified channel.
### Method
GET
### Endpoint
/sessions/{channel}
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
```
--------------------------------
### Manage Song Queue
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/README.md
Retrieves information about the next song or the currently playing song in the queue.
```bash
# Get next song
curl -H "Authorization: Bearer TOKEN" \
https://api.streamelements.com/kappa/v2/songrequest/{channel}/next
# Get current playing song
curl -H "Authorization: Bearer TOKEN" \
https://api.streamelements.com/kappa/v2/songrequest/{channel}/playing
```
--------------------------------
### GET /store/{channel}/redemptions
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/store.md
List redemptions for a specific channel.
```APIDOC
## GET /store/{channel}/redemptions
### Description
List redemptions for a specific channel.
### Method
GET
### Endpoint
/store/{channel}/redemptions
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
#### Query Parameters
- **offset** (integer) - Required - items to be skipped
- **limit** (integer) - Required - limit items
- **pending** (string) - Required - boolean
### Response
#### Success Response (200)
```
--------------------------------
### GET /contests/{channel}/{contestId}
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/contests.md
Retrieve details for a specific contest.
```APIDOC
## GET /contests/{channel}/{contestId}
### Description
Retrieve details for a specific contest.
### Method
GET
### Endpoint
/contests/{channel}/{contestId}
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
- **contestId** (string) - Required - guid - Contest id
#### Header Parameters
- **Accept** (string) - Required - ''
```
--------------------------------
### Handle Resource Not Found Error
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/errors.md
Returned when the requested resource ID does not exist. Verify the channel ID and confirm the resource exists by listing available items first.
```json
{
"error": "NotFound",
"message": "Command not found",
"statusCode": 404
}
```
--------------------------------
### GET /songrequest/{channel}/playlist
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/songrequest.md
Retrieves the list of songs on the playlist.
```APIDOC
## GET /songrequest/{channel}/playlist
### Description
Get songs on playlist
### Method
GET
### Endpoint
/songrequest/{channel}/playlist
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
#### Query Parameters
- **limit** (integer) - Required - integer - number of results per page
- **page** (string) - Required - string - page identifier as in nextPage
### Response
#### Success Response (200)
#### Error Response (400)
```
--------------------------------
### GET /songrequest/{channel}/playing
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/songrequest.md
Retrieves the currently playing song.
```APIDOC
## GET /songrequest/{channel}/playing
### Description
Get currently playing song
### Method
GET
### Endpoint
/songrequest/{channel}/playing
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
### Response
#### Success Response (200)
```
--------------------------------
### GET /chatstats/{username}
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/chatstats.md
Retrieves general statistics for a specified channel.
```APIDOC
## GET /chatstats/{username}
### Description
Get stats for channel name
### Method
GET
### Endpoint
/chatstats/{username}
### Parameters
#### Path Parameters
- **username** (string) - Required - Channel name
#### Header Parameters
- **Accept** (string) - Required
### Response
#### Success Response (200)
```
--------------------------------
### PUT /overlays/{channel}/action/{action}
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/overlays.md
Control overlay or alert states such as reload, mute, unmute, pause, or play.
```APIDOC
## PUT /overlays/{channel}/action/{action}
### Description
Overlay/Alerts control.
### Method
PUT
### Endpoint
/overlays/{channel}/action/{action}
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
- **action** (string) - Required - 'string - one of reload, mute, unmute, pause, play'
### Response
#### Success Response (201)
```
--------------------------------
### GET /stats/{channel}
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/stats.md
Retrieves statistical data for a specified channel.
```APIDOC
## GET /stats/{channel}
### Description
Get channels stats for a specific channel ID.
### Method
GET
### Endpoint
/stats/{channel}
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
#### Query Parameters
- **interval** (string) - Required - 'string - year, month, week, day'
- **date** (string) - Required - datetime
- **tz** (integer) - Required - integer - timezone number
#### Headers
- **Accept** (string) - Required
### Response
#### Success Response (200)
```
--------------------------------
### POST /bot/commands/{channel}
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/bot.md
Create or manage custom commands for a specific channel.
```APIDOC
## POST /bot/commands/{channel}
### Description
List custom commands for the specified channel.
### Method
POST
### Endpoint
/bot/commands/{channel}
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
#### Header Parameters
- **Accept** (string) - Required - ''
### Response
#### Success Response (200, 201)
- Response codes: 200, 201, 400, 409
```
--------------------------------
### POST /activities/{channel}/{activityId}/replay
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/activities.md
Replay activity.
```APIDOC
## POST /activities/{channel}/{activityId}/replay
### Description
Replay activity.
### Method
POST
### Endpoint
/activities/{channel}/{activityId}/replay
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
- **activityId** (string) - Required - guid - Activity id
### Response
#### Success Response (200)
- 200
```
--------------------------------
### SE_API.store.set(keyName, obj)
Source: https://github.com/streamelements/api-docs/blob/main/docs/Widgets.md
Stores a simple object into the database under a specific keyName. Multiple widgets using the same keyName will share the same data.
```APIDOC
## SE_API.store.set(keyName, obj)
### Description
Stores a simple object into the database under a specific keyName. keyName must be an alphanumeric string.
### Parameters
- **keyName** (string) - Required - The key identifier for the data.
- **obj** (object) - Required - The simple object to store.
```
--------------------------------
### Create a Bot Command
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/README.md
Registers a new custom bot command for a channel using a POST request.
```bash
curl -X POST \
-H "Authorization: Bearer TOKEN" \
-H "Content-Type: application/json" \
-d '{
"name": "!hello",
"reply": "Hello, {username}!",
"cooldown": 5
}' \
https://api.streamelements.com/kappa/v2/bot/commands/{channel}
```
--------------------------------
### POST /store/{channel}/items
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/store.md
Create a new store item for a specific channel.
```APIDOC
## POST /store/{channel}/items
### Description
Create a new store item for a given channel.
### Method
POST
### Endpoint
/store/{channel}/items
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
#### Query Parameters
- **limit** (integer) - Required - integer - number of items per page
- **offset** (integer) - Required - integer - number of items to be skipped
### Response
#### Success Response (200)
- **Response** (N/A) - Success
```
--------------------------------
### Import Google Fonts
Source: https://github.com/streamelements/api-docs/blob/main/docs/Widgets.md
Load Google Fonts via HTML link or CSS import.
```HTML
```
```css
@import url('https://fonts.googleapis.com/css?family=Chelsea+Market');
```
--------------------------------
### GET /giveaways/{channel}/history
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/giveaways.md
Retrieve the history of giveaways for a specific channel.
```APIDOC
## GET /giveaways/{channel}/history
### Description
Retrieve the giveaway history for the specified channel.
### Method
GET
### Endpoint
/giveaways/{channel}/history
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
#### Header Parameters
- **Accept** (string) - Required
### Response
#### Success Response (200)
```
--------------------------------
### GET /contests/{channel}/history
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/contests.md
List previous contests for a specific channel.
```APIDOC
## GET /contests/{channel}/history
### Description
List previous contests for a specific channel.
### Method
GET
### Endpoint
/contests/{channel}/history
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
#### Query Parameters
- **limit** (integer) - Required - Number of items per page
- **offset** (integer) - Required - Number of items to be skipped
#### Header Parameters
- **Accept** (string) - Required - ''
```
--------------------------------
### GET /points/{channel}/watchtime
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/points.md
Retrieves a list of user watchtime for a channel.
```APIDOC
## GET /points/{channel}/watchtime
### Description
List users watchtime.
### Method
GET
### Endpoint
/points/{channel}/watchtime
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
#### Query Parameters
- **limit** (integer) - Required - integer - Number of items per page
- **offset** (integer) - Required - integer - Number of items to be skipped
#### Header Parameters
- **Accept** (string) - Required - ''
### Response
#### Success Response (200)
```
--------------------------------
### PUT /points/{channel}
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/points.md
Bulk add or set points for users in a specific channel.
```APIDOC
## PUT /points/{channel}
### Description
Bulk add/set points to users.
### Method
PUT
### Endpoint
/points/{channel}
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
#### Header Parameters
- **Accept** (string) - Required - ''
### Response
#### Success Response (200)
```
--------------------------------
### GET /songrequest/{channel}/player
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/songrequest.md
Retrieves the current status of the media player.
```APIDOC
## GET /songrequest/{channel}/player
### Description
Get current player status
### Method
GET
### Endpoint
/songrequest/{channel}/player
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
### Response
#### Success Response (200)
```
--------------------------------
### GET /songrequest/{channel}/pending
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/api-reference/songrequest.md
Retrieves songs currently in the moderation queue.
```APIDOC
## GET /songrequest/{channel}/pending
### Description
Get songs in moderation queue
### Method
GET
### Endpoint
/songrequest/{channel}/pending
### Parameters
#### Path Parameters
- **channel** (string) - Required - guid - Channel id
### Response
#### Success Response (200)
```
--------------------------------
### Add Loyalty Points to User
Source: https://github.com/streamelements/api-docs/blob/main/_autodocs/README.md
Updates a user's loyalty points balance via a PUT request.
```bash
curl -X PUT \
-H "Authorization: Bearer TOKEN" \
-H "Content-Type: application/json" \
-d '{"points": 100}' \
https://api.streamelements.com/kappa/v2/points/{channel}/{username}/100
```