#dev-chat

1 messages Β· Page 49 of 1

elfin arch
#

you can't via the chat; but you can get editor status for SE and set them up on the website

cedar kiln
#

by asking the streamer to grant access to his SE account i suppose?

mortal knotBOT
#

Chat/Bot Levels
100 - Viewer
250 - Subscriber (Twitch subscribers automatically placed at this level)
300 - Regular
400 - VIP (Twitch VIP automatically placed at this level)
500 - Moderator (Twitch chat moderators automatically placed at this level)
1000 - Super Moderator__
1500 - Broadcaster

Dashboard Manager Levels
Bot Supervisor
Editor
Full Access
Owner
https://i.imgur.com/s61Liry.png

elfin arch
cedar kiln
#

ah, right..then i must ask the streamer to grant me that access

#

as a manager

#

ok then, thanks

elfin arch
#

yup yup. then you get that dashboard when you log in your account

sonic vessel
#

ello ello ello how do we go about editing the confirmation message that shows in the twitch chat on a store redemption coz currently it uses an emote that we dont have in the channel and also i need it to work different

or how can i add a response when a user tries to write a command in chat and doesnt have enough credits that says you dont have enough credits to buy this it costs xx amount

merry plume
#

yo, i'm trying to get the top users to develop sort of a leaderboard page

#

however the api (with success 200 as a response) provides 0 users

#

https://api.streamelements.com/kappa/v2/points/enkk/top this API

#

i'm giving the JWT as requested

elfin arch
#

it's your account id not name

merry plume
#

jeez, what an idiot

#

thanks

elfin arch
#

i know that answer because make that error often 🀣

tiny vapor
#

Has anyone ever had any luck using google Sheets API to pull data into a streamelements custom widget? I'm trying to get 2 columns of data from a spread sheet to input either into stream elements or into OBS. Anyone that can help is amazing!

elfin arch
#

um... kind of? i've not done into into an SE overlay... but should work...

merry plume
#

ok this time I think i'm onto something :p

#

https://api.streamelements.com/kappa/v2/bot/commands/chan_id/command_id returns 500

#

which is not supposed to be an answer

#

its the get commands details API

elfin arch
#
async function loadGSheetData() {
  let spreadID = gameSetup.gSheetId,
    sheetID = "1",
    targetCells = "A:H",
    APIKEY = gameSetup.gAPI,
    dataSource = "https://sheets.googleapis.com/v4/spreadsheets/" + spreadID + "/values/Sheet" + (sheetID) + "!" + targetCells + "?key=" + APIKEY,
    tempUsers = [...gameUsers];

  const userDatabase = await fetch(dataSource)
    .then(response => response.json())
    .then(json => {
      if (json.error) {
        if (firstLoad) {
          gameUsers = JSON.parse(fs.readFileSync(GameUserDatabase));
        };
        return false;
      };
      json.values.forEach(user => {
        let userName = user[0].toLowerCase().trim();
        if (!firstLoad) { //check if mid game reload and save current progress
          let userIndex = tempUsers.findIndex(i => i.userName === userName);
          if (userIndex >= 0) {
            gameUsers.push(tempUsers[userIndex]);
            return;
          };
        };
        newUser = {};
        newUser.userName = userName
        newUser.team = user[1].toLowerCase();
        newUser.lastStandard = ''
        newUser.usedSpecial = false;
        if (user[2] !== undefined) {
          newUser.secretsRemaining = parseInt(user[2]) || 1;
        }
        gameUsers.push(newUser);
      });
      fs.writeFileSync(GameUserDatabase, JSON.stringify(gameUsers, null, 4), "utf8");
      console.log(`${gameName} user database has loaded!`)
      return true;
    })
    .catch(error => {
      console.error("Error Getting Username Data from Google: ", error);
      return false;
    }); ....
#

@tiny vapor sorry that's a lot of code; but i dont want to clean it all up; but that is a copy-pasta of what i use to pull info from a google sheet

tiny vapor
#

thanks!

#

I am playing now, ill let you know how i get on

#

Is that the entire code? whats the 4 dots at the end for?

elfin arch
#

that is a full code for like a game thing i have.

tiny vapor
#

AHH i see

elfin arch
#

you don't need most of it; just an example of how i use it

tiny vapor
#

no thats great. the first few paragraphs are really useful

elfin arch
#

ya; ya. that is sheet '1' ... then it moves into sheet '2' settings 🀣 after the ....

tiny vapor
#

I think its crazy that obs / streamelements hasn't created an actual module that allows you to input data from an api without having to code it

#

vMix has it built in and its great

elfin arch
#

what is vMix? i'll have to look into it?

tiny vapor
#

vMix is another software based platform to record / livestream from

#

Its designed more for higher end studio streams / larger projects with remote callers etc

elfin arch
#

for customization; S.E. has been the greatest i've found all things considered.

tiny vapor
#

Yer I agree. S.E is the best when it comes to customisation

#

vMix is designed less for twitch streamers etc and more for live streams on Vimeo / corporate stuff / sporting events etc

elfin arch
#

OBS and S.E. are 2 different things. streamElements doesnt have anything to do with the 'software' or streaming side.

tiny vapor
#

no i know

elfin arch
#

ahh gotcha. ya here; in s.e. it's all twitch/youtube streamers with alerts and merch. i think i saw a facebook person once

#

so vMix would be an OBS competitor then?

tiny vapor
#

yes it would. but it allows you to combine OBS with certain aspects of S.E

#

but it wouldn't allow for alerts etc, that would all be through S.E

#

but it has a great graphics / lowerthird creator etc built in

elfin arch
#

it can bring in browser source though?

tiny vapor
#

yes sir

#

it can also bring in API data from sheets and other sources

#

then link individual cells to a specific line of text

#

that automatically updates

#

which is what im trying to do, but i can't use vMix as I don't have a personal license, i only use it at work

elfin arch
#

ya; that is; i don;t want to sell SE short; but it is basically a "website"

#

and for good reason. everything is cloud based.

merry plume
#

ok, after a few more tests i'm pretty sure that the get command details APIs is not working, at least for me. Can anybody test it?

viral patrol
#

vMix is basically enterprise OBS πŸ˜‰

merry plume
#

It just gives me internal server error

elfin arch
#

ahhh; so you have to pay for it?

#

can you post your get request code? @merry plume

#

not sure i can help; but maybe 🀞

merry plume
#

well to avoid issues i'm litterally using a web based request website

#

the JWT is correct since other calls are working

#

the channel id too

#

https://api.streamelements.com/kappa/v2/bot/commands/CHAN_ID/roulette

#

try this and you should be getting 500 too

merry plume
#

any news?

elfin arch
#

i have no idea how to get the commandID

merry plume
#

command id is returned

#

from the command list

#

roulette is a command id

#

by giving a random string djijfe you will get a 400 answer, which is okay

#

but by giving a correct command such as roulette, you get 500

#

which should never happen

elfin arch
#

i've never played with that endpoint; so i'm not sure.. i also gotta run so cant set up a test

merry plume
#

don't worry, thank you πŸ™‚

#

i'll wait from some dev

viral patrol
#

@merry plume Do you want to change roulette settings or roulette command?

merry plume
#

roulette command

#

I simply want to enable or disable it

#

however, to change a command you have to provide the whole command set up

#

so firstly I need to get the command details, and then reupload it via PUT with the enabled toggled

viral patrol
#

Yes. That is correct:
https://api.streamelements.com/kappa/v2/bot/modules/:channelId/roulette
method: PUT
Payload:

{
   "roulette":{
      "cooldown":{
         "user":50,
         "global":0
      },
      "messages":{
         "win":"/me {user} won {bet} undefined in roulette and now has {points} undefined! FeelsGoodMan",
         "lose":"/me {user} lost {bet} undefined in roulette and now has {points} undefined! FeelsBadMan",
         "allinWin":"/me PogChamp {user} went all in and won {bet} undefined PogChamp they now have {points} undefined FeelsGoodMan",
         "allinLose":"/me {user} went all in and lost every single one of their {bet} undefined LUL"
      },
      "enabled":false,
      "luck":45,
      "minAmount":2
   }
}

You need to adjust enabled property.

merry plume
#

wait, you are using the modules API?

viral patrol
#

Yes.

merry plume
#

arent the module and the command two different things?

viral patrol
#

But several commands are controlled by modules.

merry plume
#

so if i enable or disable this module, the commands will follow directly?

#

it just seems weird to me that the command API is not working properly

#

is not working even for my custom commands btw

#

well it still allows me to do my thing, so i guess its okay

#

thank you mate

viral patrol
#

np

mellow canyon
#

So using another bot would be the only way?

merry wharf
#

hello, how can i create an alert for each item redeemed?

mighty vector
#

i'm trying to run something like an auction and the way i decided to do it is by people buying tickets and then refunding and taking the points from the winner of the auction. To do that I need to use a 'get' call for the participants because streamelements no longer shows all of them on the list, but the calls are not working. Any clues?

#

every other category calls are fine the giveaway ones are the only ones not working

main root
#

When attempting to use https://api.streamelements.com/kappa/v2/points/{{channel_id}/{{username}}/amount I get the following: anybody know what type of token, or authz, or code it wants and from where might one get it?

  "statusCode": 403,
  "error": "Forbidden",
  "message": "No channel authorization found"
}```

Sadly https://docs.streamelements.com/reference/single-user#pointsamountbychannelanduserput is not much help 😦
lapis barn
#

JWT token

main root
#

Yep, that's what I'm sending. All the other APIs work.

#

(Well, not all, some...)

#

https://api.streamelements.com/kappa/v2/channels/me will load perfectly fine with my JWT

#

But the APIs which manipulate points seem to want some other type of credential (or are just broken)

#

I'm passing my JWT while attempting to change the value of a user on my channel. I would understand if it was a different channel, but this is my own channel.

#

Probably missing something simple, idk, advice welcome haha

hardy walrus
heavy lily
#

hey sorry any idea how to call a function at the start of and alert and then again at the end of the alert

main root
hardy walrus
#

Are you already approved?

main root
#

O.o

#

Approved?

#

My mom approves of me. Does that count?

hardy walrus
#

Getting Oauth access is closed atm so not viable unless you already have access

main root
#

But doesn't /channels/me dump an oauth token..?

#

unless "accessToken" is yet some other confusing construct

#

I'm wondering if maybe I have to have something else set up for this.

hardy walrus
#

I'll ping @viral patrol on this as he can answer better than I can as i simply tried discord-fu to see if I could ffind something and that's about where my understanding stops.

main root
#

πŸ™‚ Appreciated.

#

This isn't particularly urgent, but this is the last piece of the app integration for something I'm building for a friend.

main root
#

Sitrep...

#

I was using my JWT which is for a channel which doesn't even have the right stuff set up in SE. That was the issue.

#

I asked for the JWT of the actual account this bot will be running for and it works as intended. Apologies for developer's denseness.

viral patrol
#

@main root Hi! JWT is per channel. It doesn't allow you to work with other channels (even if you have permissions granted). As a workaround I recommend using jebaited.net which is MITM for SE API. With that in use channel owner can create a token that will allow you to work with selected scope (like points management).

mighty vector
#

any idea why givaway api calls keep giving me 400s? I checked my id's and tokens on other calls and they work fine

viral patrol
#

Which endpoint gives you errors?

mighty vector
viral patrol
mighty vector
#

oh i see! I'll check it when I'm back from work thanks!

#

Is there any other suggestion on how to run an auction with loyalty points other than what I described?

viral patrol
#

I think this is a nice idea for two types of auctions:

  1. Regular one - you refund giveaway and just subtract points from person who was on top manually
  2. Dollar action - you close giveaway without refunding
#

And by manually I think about a way where it is not "pick winner", as winner picking is random, but grabbing top contestant there and removing their points either via !addpoints -1234 command or a call to points endpoint

mighty vector
#

yes that's the way i'm already approaching it right now, thanks a lot

stuck junco
#

@viral patrol any news on that? It really does not aggregate properly, despite having set everything right. Building a new template doesn't help either.

viral patrol
#

I am forwarding that issue. I am not aware what could be a reason for that

stuck junco
#

Thanks for the answer. I am curious if this is a general or my specific problem.

wispy wraith
#

Question: Does StreamElements API have its own stylesheet of fonts?

I ask because I am having this funnily weird experience where the baked in Lobster Two font in the Text Widget of Stream Elements overlay always seems to come out slimmer and smaller than the Lobster Two on my custom widget which is sourced from Google API even they are both the same font-size and set to bold.

Its admittedly a petty issue but I am bit of an OC so its niggling at me.

sonic vessel
pulsar willow
#

hey can anyone explsin this?

tribal zenith
#

where is the code from?

pulsar willow
#

custom made

tribal zenith
#

then maybe ask the original creator or (if you're allowed to) post the whole code here via jsfiddle

pulsar willow
#

ok

#

i can post the txt file

tribal zenith
#

it's net not com FailFish

pulsar willow
#

i dont knopw how to use js fiddle

#

@tribal zenith

tribal zenith
#

are you sure this is a StreamElements widget? It looks more like Streamlabs or something

pulsar willow
#

I used it in streamlabs but can I use this in streamelements?

#

or do I have to change it?

tribal zenith
#

you have to change the eventlisteners and how you access the field values

pulsar willow
#

can you help on that one lol

tribal zenith
pulsar willow
#

Thank you

tribal zenith
#

basically goalLoad should become onWidgetLoad and goalEvent should become onEventReceived or onSessionUpdate

#

field values can be accessed like:

window.addEventListener('onWidgetLoad', function(obj)
{
    const fieldData = obj.detail.fieldData;

    myFieldValue1 = fieldData.myFieldValue1;
    myFieldValue2 = fieldData.myFieldValue2;
});
#

depending on what the names are

pulsar willow
#

ok thank you very much!

tribal zenith
#

no problem. the html and css should work, but some field types are named differently
textfield -> text
fontpicker -> googleFont

mighty vector
#

I have a follow up question about my previous issue. How can i change the limit of the v3 giveaways entries endpoint to go over 100?

#

I need to get every entry for my auction system to work

#

@viral patrol is it ok to ping people?

viral patrol
#

I think you need to use &offset=100 to have second page

sturdy oak
#

Hey its christmas season

#

Logo dope!

mighty vector
#

ok i'll check it out thanks

left rampart
worthy dagger
#

do you have this overlay?

#

how do you download or use a shared widget?

#

As I can only se videos about the widget?

tribal zenith
worthy dagger
#

thanks a mil

#

does anyone know how I could make a animated border that instead of the colors going in a circle it flows from the bottom upwards to the top if it makes sense.

worthy dagger
#

Or to create an animated frame overlay for cam that goes from like bottom left corner to top right corner but goes around both sides (so color change goes up the right as well as right then up) at the same time

left rampart
#

Any custom animations like that will require an animation program

tribal zenith
#

you just have to move the "center" of the gradient and use a webcam-border as mask

worthy dagger
#

Any recommendations for animation programs?

tribal zenith
#

if you know css you could create a kreyframe animation and just change the background-position over time

worthy dagger
#

Don't know how to do thatπŸ˜‚

tribal zenith
#

there may even be css gradient-animation generators if you google it

worthy dagger
#

Or know of someone or somewhere I can learn to use it or something?

tribal zenith
#

there also are a lot of free animated webcam-borders as video files. That's probably easier, than learning css LUL

hollow quail
#

i seem to have a problem with some functions on streamelements. I have logged in to streamelements with my twitch account. now im trying to add more payment methods (SE.pay) but it won't let me. I have all the requirements so i'm really confused as to what the problem is.

restive reef
#

Is there any way to run a contest or something through python?

mortal knotBOT
knotty thorn
#

hello all, if i connect via websocket to streamelements on my own website, and do the onWidgetLoad thing, will it console log the same data as on your CustomCode website? eg recents, session data etc

sonic meteor
#

hey, anybody knows how to use the ${args} variable? I'm trying for hours, but the reply always comes as '${args}', but I'm trying to personalize the value that I add in a $(count)

elfin arch
#

the args requires a number like ${2} would reply to this message: !argtest which word is it? with word

#

^ @sonic meteor

main imp
#

I have a problem and it is not a unique one. I have a custom css alert so I can animate it with transforms, and I can change the font easily enough in a number of ways. It's set to impact now. However, I want to use a custom font. I tried using google fonts or ones defined as '/fonts/font.ttf' from my computer and saved the overlay and refreshed obs.. all sorts of things. I tried defining a font in the html and referencing it in css and I just don't get it at all.

#

also tried redefining the body in obs's browser source

elfin arch
#

what is the font code you are using in the CSS?

main imp
#

I used everything, but as an example

#

@font-face
{
font-family:Gunstar.ttf;
src:url(/fonts/Gunstar_Large.ttf);
}

font-family:Gunstar.ttf;

elfin arch
#

try just: ```css

  • {
    font-family:Gunstar;
    }
main imp
#

while that would be simpler, there is no change in this example

#

.text-container {
font-size: 16px;
color: rgb(245, 245, 245);
position: relative;
text-align: center;
margin: auto;
text-shadow: rgba(0, 0, 0, 0.8) 2px 2px 2px;
background-color: black;
font-family: 'gunstar_heroes_megadrive';
animation: slideDown 10s;
}

#

I tried various things, this was the last iteration

elfin arch
#

hmmm; ya. that looks right. sometimes the local fonts are tricky but that looks right.

main imp
#

I also tried 'Gunstar Heroes Megadrive' 'Gunstar Heroes Megadrive Regular' 'Gunstar_Heroes_Megadrive.ttf' and other less viable things

#

if I just put impact in there it works so I was thinking maybe the other fonts were authorized or something involving windows verification

#

which sounds odd, but after grappling with this for 8 hours I had time to think

elfin arch
#

i can get google fonts working ```css
@import url('https://fonts.googleapis.com/css2?family=Bangers&display=swap');

.text-container {
font-size: 16px;
color: rgb(245, 245, 245);
position: relative;
text-align: center;
margin: auto;
text-shadow: rgba(0, 0, 0, 0.8) 2px 2px 2px;
background-color: black;
font-family: 'bangers';
animation: slideDown 10s;
}

main imp
#

I couldnt even do that let me just copy this verbatim

#

It went to fallback arial

elfin arch
#

hmmm; that code doesn't work?

main imp
#

heres my full css, which I admit is messy but ive tried so many things all the optimizations went out the window

#

its a.. fairly complicated path it moves on

elfin arch
main imp
#

it says richard in 40 px arial with a shadow

#

so something is taking precedence

#

Is this html overriding it

elfin arch
#

hmmm let me grab a different font. i have that bangers one local so it was working with the local file i had

#

move the @import part to the top of the CSS

main imp
#

oh

#

well that worked

elfin arch
#

getting a little closer. I like that animation

main imp
#

thanks it svery precise

#

but yes just a littl emore and were in the clear

elfin arch
#

so i just downloaded and installed a custom font; restarted chrome and it is working

main imp
#

Ive had it installed since I created it

elfin arch
#

can you DM me the tff file?

#

or send me a link to download it

main imp
#

yes

#

I can definitely get the url source to work

elfin arch
#

try font-family: 'gunstar_large'; πŸ™‚

main imp
#

see this is the part I dont get. I do that and neither the browser, which ok there might be a problem doing that - nor OBS, which definitely should - show the font

#

Also I refereshed the source

elfin arch
main imp
#

not there

elfin arch
#

when you downloaded the font you did click the install button, right?

main imp
#

I installe dit a few times, I actually made it

#

so like 30 times

#

I wasnt quite happy with it the first few dozen

#

to wit, it works in photoshop and whatnot

#

or if I just do text in obs

elfin arch
#

hmmm... what web browser do you use?

#

it's loading it for me in Chrome

main imp
#

edge, based on chromium

elfin arch
#

let me check edge

#

ya; it's working there as well. that is odd?

main imp
#

it really is

#

Im guessing that I can sidestep the problem using the url importer

#

..im not clear on how that works

#

I cant just host it on mega nz im guessing

elfin arch
#

ya. i don't think so; you might be able to on gitHub and pull it from there?

#

but i'd suggest trying a PC restart and make sure that font is in the windows/fonts folder. maybe even uninstall it then reinstall it?

#

then check that codepen i posted to see if it's loading

main imp
#

may as well

#

uninstalling and reinstalling the font caused it to appear

#

let me check my obs source

#

It seems as though you have resolved my problem completely. I dont understand why it would work with any fonts but some cobination of outside factors being resoved was the culprit

#

I thought I was losing my druthers but it's some whole other thing

elfin arch
#

haha. glad i could help!

#

i've never had good experiences with CSS in general and fonts are always a p.i.a. 🀣

main imp
#

yeah I always strap in for hours of fun and frolic when I start one of these projects

#

thanks for the help, good day

pulsar willow
#

Cross posting here due to recommendation: Hey all, have a question regarding updating a command using the API. (I've breifly read through the api docs before coming here, but am still somewhat confused).

I am trying to use that API to update a command (!queue) with a JSON string from my google sheet. I have that whole part of getting the string, etc figured out but am having trouble actually pushing the command update to my channel. Is there any guides or premade tools with a similar function that anyone knows of?

elfin arch
pulsar willow
#

Giving it a shot now see if I have any success

elfin arch
#

where is says channel that is the ID*; and requires JWT token in the header; for example ^ this is some code i have for pulling points.

pulsar willow
#

Okay, making progress. Was able to actually get the command ID this time and get that setup. Now I am getting error 401 'unauthorized' when trying to make the PUT request.

Do you know how the header for the bearer token should be formatted? I have a strong feeling thats my issue.

I have my JWT Token, just unsure how to format it.

elfin arch
#

should be ```js
'Authorization': Bearer ${process.env.SE_JWTTOKEN}

pulsar willow
#

Name part at the top is just for labeling so ignore it.

elfin arch
#

you don't need the ${ or end }

pulsar willow
#

Hmm, still getting Error 401. Could there be anything else Im missing there?

elfin arch
#

what program are you using? might not need the "auth..." in the value part

#

probably just Bearer .....

#

no qoutes or anything

pulsar willow
#

Im using a service called Integromat.

So just Bearer *Key* ?

elfin arch
#

yup

pulsar willow
#

Still Error 401. Tried adding quotes back in and in a few different positions.

#

As well as the base Bearer *Key*

elfin arch
#

which end point are you hitting, the get or put? do you have the content-type header?

pulsar willow
#

omg im so dumbfacepalm

#

There was a extra character in the channel ID

#

I appreciate your help so much!

#

aplPray Thank you for helping people like me KEKW

elfin arch
#

not a problem. i'm learning as well. first time i've played with that endpoint

worthy dagger
#

Is anyone able to help me, i want to create an animated border, however instead of the animation just going in a circle i want it to rotate around both sides an meet in the top

pulsar willow
#

will this work with streamelements?

sonic vessel
#

ello ello ello how do we go about editing the confirmation message that shows in the twitch chat on a store redemption coz currently it uses an emote that we dont have in the channel and also i need it to work different

or how can i add a response when a user tries to write a command in chat and doesnt have enough credits that says you dont have enough credits to buy this it costs xx amount

#

I was sent here from support at the weekend but got no reply

hardy walrus
#

@sonic vessel enable !pepes command and do !pepes disable

viral patrol
#

@pulsar willow It won't work without conversion to SE system.

pulsar willow
#

Can you help me out lol im in trouble

#

just gimme some general directions

sonic vessel
#

@hardy walrus which one will that fix?

hardy walrus
#

The emote in the response.

sonic vessel
#

I want to change the response to be a #colour

#

As that triggers stuff in the background of the camera

#

So each redeem would have #name

#

Of what ever the store item is called

#

Because then standard command with a price doesn't reply if you too poor

#

I just want a custom text response for items redeemed basically is the summary

worthy dagger
#

Is anyone able to help me, i want to create an animated border, however instead of the animation just going in a circle i want it to rotate around both sides an meet in the top

viral patrol
#

@worthy dagger Check this one: https://codepen.io/mike-schultz/pen/NgQvGO, set angle to 0deg and background position to:

@keyframes animatedgradient {
    0% {
        background-position: 0% 0%;
    }
    50% {
        background-position: 100% 100%;
    }
    100% {
        background-position: 0% 0%;
    }
}
#

I think you should be able to adjust the above to your needs or create your own with that as starting point

worthy dagger
#

not getting it right lol...it keeps like fading in and out

#

and not like flowing

viral patrol
#

I think that simplest way would be to create two divs with gradiend background and move them in parent div.

#

Or - create a looped gradient background in video editing software and use a webm file.

worthy dagger
#

@viral patrol do you mind if I pm you?

viral patrol
#

I think it is the best to keep conversation here, so other can profit from it as well

worthy dagger
#

trying to teach myself css nowTovChamp

pulsar willow
#

Hey, just wondering if someone here could possibly code a progress bar exactly like the one for donations, subs, and bits with the color customization and all but make it respond to a counter in chat going up?

wraith lynx
pulsar willow
#

@tribal zenith @wraith lynx I mean a progress bar that would respond to a bot counter. I believe the only progress bar options within stream elements at the moment are ones that respond to donos cheers and subs

slate elbow
#

Extra Life integration - I'm actually not sure which channel to put this in, but sometime last month my streamelements stopped pulling any information from Extra Life. Has this been reported somewhere?

wraith lynx
tribal zenith
#

for the bot counter, that is

pulsar willow
#

yeah that looks great, is there a way to maybe add a title and choose between a rounded style or a straight edge style? @tribal zenith

tribal zenith
pulsar willow
tribal zenith
pulsar willow
#

thanks seredaUwu

tribal zenith
#

@pulsar willow have you talked to the original creator of the widget? It's not that trivial and you would have to add some fields to get to the goal functionaility. Like title, type, goalAmount, endDate

#

if he/she doesn't support StreamElements for future updates, there is not really a point to port this

pulsar willow
#

I have talked to him and he doesnt know streamelements stuff

#

I just like the animation amd I cant bug him to do that cos I got it for free lol

tribal zenith
#

if he has any questions regarding the StreamElements API, he can just ask here

pulsar willow
#

ok

broken coyote
#

WHere is did you get the widget ? @pulsar willow

pulsar willow
#

Somebody coded it for me

#

@broken coyote

broken coyote
#

Who?

pulsar willow
#

Just a friend

broken coyote
#

I had some questions about the code it self. Any way I could contact him?

pulsar willow
#

just tell me ill tell him

#

Btw thats not thge code he sent

#

thats the code i made by modding it(im noob)

#

like super noob

broken coyote
#

I’m referring to the original code

pulsar willow
#

ok ill send you

#

can i pm you?

#

i mean dm

broken coyote
#

I’m mainly just interested in whom originally built it. It’s a really nice widget

pulsar willow
#

i think im not allowed to share his details lol

broken coyote
#

Well have him dm me

pulsar willow
#

I'll try

broken coyote
#

Thanks

muted moat
#

How can I make a link to pass it on to someone and have them create an overlay that I did?

rugged rapids
#

That feature is only available on specific accounts. You can make the other person invite you as an editor to their StreamElements Account, so you can copy the overlay over.

mortal knotBOT
#

@muted moat "Follow these steps to grant managers/moderators access to your dashboard:

  1. Click on your channel name at the top of the dashboard
  2. Create a new invite at one of three access levels (Bot Supervisor, Editor, Full Control)
  3. Send this invite to a mod/manager to give them access to your dashboard. The link is one-time-use and expires after 72 hours if not accepted

Video tutorial: https://youtu.be/zl_h-ttZDF0"

hardy walrus
broken coyote
#

Orrrrrrr....

next radish
#

anyone know how to get emulated alerts to ping "top" labels of the session? Atm, any emulated alerts do not work on changing the label calls

#

as I have a custom widget that animates in/out when a new label replaces it (currently donation) but the streamer wants it changed to top donation of the session, and emulated alerts just to show if its working or not

faint pier
#

someone works the instagram widget? @torn wave

torn wave
wary oxide
#

For the Chat Stats feature, is it only available with a range of "all time" or is there a way through the API or an easier way to get the chat stats for a set range of time?

#

This would be specifically related to BTTV emotes if possible.

tame sparrow
#

Does anyone know how to setup facebook live events like stream elements? I'm trying to make an app in c# to grab info in the same manner and I can't find A) a dev discord for help, and B) resources on the internet specifically talking about live streaming things with facebook

sturdy oak
#

They save the data of the last 24 events, so you don't have the hassle of saving them somewhere

timber lark
#

Is there any way to get the senders/user alltime points within a chat command? There is a variable ${user.points_alltime_rank} but no ${user.points_alltime}

tame sparrow
#

Use SE how?

charred urchin
#

so uh, how do i make this work?

viral patrol
#

Maybe The time is ${time ${1:|CET}}

#

Where CET is failsafe for user parameter

charred urchin
#

so "!time EST" should equal ${time.EST}

charred urchin
viral patrol
#

It is either period or space. I prefer space

charred urchin
#

oh ok

#

trouble is that doesn't display pm or 24h time

hardy walrus
#

There's a 3rd party api you can use to specify more than that. You'd have to work out the variables for how it displays though.

charred urchin
#

also the aest was incorrect, it should've been 8:41

charred urchin
#

why isn't it showing in 24h time?

viral patrol
#

Format should be g:i:s AFAIK

charred urchin
#

oh nvm, the timezone list is weird. So instead of typing !time AEDT I had to type !time Australia/Sydney

#

It was returning the default

hardy walrus
#

You don't have to do that. You can specify that from within the URL.

#

And simply have commands as the timezone name.

charred urchin
#

i don't want to type out every timezone lol

hardy walrus
#

@charred urchin Apologies for the late reply: Unfortunately due to the 500 character limit for command responses you'd either do a bunch of commands or the tedious typing with !timezone ActualTimezone to use just one command and specify any of them.

#

Not many options beyond those that I am aware of.

charred urchin
#

It's okay the command works to an extent, and I don't mind half assing things lol

#

Thanks for your help though

fluid dome
#

I am trying to link to the API and it does not work

#

The error always comes: The authorization server encountered an unexpected condition that prevented it from fulfilling the request.

pulsar willow
#

Hello, is there a way to fetch a value from a json response?
since the eval function is not working!!

elfin arch
#

how is your JS skills?

pulsar willow
#

decent

elfin arch
#

the default custom API just reads the 'text' response from the server

tribal zenith
#

are we talking about chat commands or widgets?

pulsar willow
#

chat commands

pulsar willow
elfin arch
#

so... short story; it will take some set up; but if you have JS, you can get it to work πŸ˜‰ ... maybe... i am trying to set up an "easy API"

#

You'd need to set up a repl account and create your own "server"

pulsar willow
#

ok one sec

#

ok i created an acc

#

so now i have to create a new "repl" right?

elfin arch
#

you can clone that code

pulsar willow
#

aaah ok

elfin arch
#

or Fork.. haha that is the right word

pulsar willow
#

ok done

#

so now i have to link it with streamelements ?

elfin arch
#

you have the api now; so you need to make your commands with your link

pulsar willow
#

aaaah ok

#

ill give it a try and back to you

#

thanks 😘

elfin arch
#

yup yup. let me know. 🀞 ... i'm still trying to make it "easy" and you are the first one to use it .... so good luck πŸ˜‰

pulsar willow
#

the Hello one is working

#

now to make one where i can fetch the data from json

elfin arch
#

so; it is redundant... but you'll need to make that api call inside the repl code.

#

so basically from Twtich chat -> api call to repl -> api call to external API ... then snap back

pulsar willow
elfin arch
#

correct. you'd have to do an api call inside that and get the object back

pulsar willow
#

aaah ok

#

should i use this methode
let url = 'https://complimentr.com/api'; fetch(url) .then(res => res.json()) .then((out) => { message = out; }) .catch(err => { throw err });

#

or you suggest a better one

elfin arch
#

i think you want return message? ... but i'm not sure best practice here

pulsar willow
#

`app.get("/api/com", (req, res) => {
let message = ``;
let url = 'https://complimentr.com/api';

fetch(url)
.then(res => res.json())
.then((out) => {
message = success //out.compliment;
})
.catch(err => { throw err });

res.send(message);
});`

#

like this

tribal zenith
#

the fetch is asynchronous

elfin arch
#

here is an example i use ```js
return new Promise((resolve, reject) => {
fetch(https://api.twitch.tv/helix/games?id=${gameID}, {
method: 'GET',
headers: {
'Content-Type': 'application/json',
'Authorization': Bearer ${process.env.T_BOTOAUTHTOKEN},
'Client-ID': process.env.T_APPCLIENTID
},
})
.then(response => response.json())
.then(data => {
resolve(data);
})
.catch(error => {
console.error(error, !!!Error Getting Twitch Game Data ^^...)
reject();
});
});

tribal zenith
#

so you probably want to await that

elfin arch
#

thank you for trying to set this up... i'm going to add in an example API call

tribal zenith
#

then it's re-usable

elfin arch
#

ya... that is a good a idea . getDatat() or something?

tribal zenith
#

maybe fetchData or fetchURL to be more transparent

elfin arch
#

shit @pulsar willow ... there is no "node-fetch" package in that template yet

pulsar willow
#

i already installed it πŸ˜‚

elfin arch
#

hahahah. thank you

tribal zenith
#

axios is also nice for node server fetches

#

easy to use and does some work for you

elfin arch
#

hmm; i'll have to check that? i'm trying to set up an "easy" API ...

#

you see the code in the code channel, Reboot?

#

it just a basic Express server

tribal zenith
#

the sayMessage?

elfin arch
#

the repl link

tribal zenith
#

oh, yeah it's the same link you posted here

elfin arch
#

ya. i did add in the 'fetch' or external API calls yet

pulsar willow
#

welp, keep giving me the The remote server returned status code 408 Request Timeout error πŸ˜‚

tribal zenith
#

are you awaiting the response now?

tribal zenith
#

it's still hello, or and eval

elfin arch
#

didn't*

#

🀣 ... i forgot the word "not"

tribal zenith
#

well, that changes things LUL

elfin arch
#

what is your API call @pulsar willow ?

tribal zenith
#

so the axios get would look like this:

async function getURL(url) {
  try {
    const response = await axios.get(url);
    return response;
  } catch (error) {
    console.error(error);
    return null;
  }
}
elfin arch
#

how would you send headers or auth with that?

tribal zenith
#

overload the function with a second parameter for data

#

the express function could be:

app.get("/api/test", (req, res) =>
{
  let response = getURL("https://myCoolUrl.com/test");
  let message = (response === null) ? "An error occured" : response;
  res.send(message);
});
elfin arch
#

are we "await" getURL ? ... i do like the the way that looks

tribal zenith
#

a more abstract call could be

async function callURL(method, url, headers, data)
{
  try
  {
    const response = await axios({ method, url, headers, data });
    return response;
  }
  catch(err)
  {
    console.error(err);
    return null;
  }
}
#

axios.get is just a wrapper

#

but that is very abstract

pulsar willow
#

welp i tried it

#

now its returns {}

#

πŸ˜‚

elfin arch
#

ya; i think that will end up the same when you add in the objects

#

🀣

#

what is your API call.... i'm trying to catch up and get it working.

pulsar willow
#

you mean the link ?? or what

elfin arch
#

ya. the JSON object you are grabbing

pulsar willow
#

{
"compliment": "i've heard you have deeply crazy thighs"
}

elfin arch
#

(β•―Β°β–‘Β°οΌ‰β•―οΈ΅ ┻━┻

pulsar willow
#

┬─┬ γƒŽ( γ‚œ-γ‚œγƒŽ)

#

πŸ˜‚

elfin arch
#

it seems to work... i'll need to look into that wrapper a little more with what reboot said

#

did a ninja edit and added a forced object value 😬

pulsar willow
#

ok yours working fine but when i cloned it its not working

#

πŸ˜‚

elfin arch
#

did you make a direct fork of mine?

#

the professional people say 'fork' 🀣

#

i say clone

#

<- not professional

pulsar willow
elfin arch
#

where i get confused with the Async @tribal zenith is that you have to handle that too ... like if it returns null

#

what is your link @pulsar willow

tribal zenith
#

if it returns null you know an error occurred, if not you can just respond with the result

#

but you can of course still use the promise based variant

#

you don't have to await it

pulsar willow
#

im dumb

#

forgot the "api" in the link

#

πŸ˜‚

#

its working

elfin arch
#

🀣

#

@tribal zenith if you have time or want to; feel free to edit and improve on that.

#

i'm just trying to make a 'boiler plate' for people

pulsar willow
#

damn , this took some time todo
thanks again @elfin arch 😘

tribal zenith
elfin arch
#

and thank you @pulsar willow for helping ... this was rough; and you are 1000x better than the "how do i ... redacted" people

pulsar willow
#

😳😳😳

tribal zenith
#

you just may want to change const fetchDataGET = (link) => { to async function fetchDataGet(url) {

pulsar willow
#

@elfin arch also thank you , now i can just use this mehode for now for different apis , i hope streamelements add an easier way to play with custom apis calls

elfin arch
#

There may be some additions.... but this from my testing is the best route to go (i've on;y had it running for 6 days)

#

So if you run into issues or problems let me know ..... and also; it can be expanded at this point to return an JSON

pulsar willow
#

Yes sir, ill let you know if any issues occur πŸ‘

elfin arch
#

@tribal zenith .... ya that is where i 🀷; i don't think that needs to be an asyc function, because it is a straight Promise return... and i'm ES6 so i'll never have "function" in my code.

tribal zenith
#

if you mark a function as async it can also be awaited. Sou you give the devs some options. Also function declarations and function expressions do different things, even if they are pretty similar

elfin arch
#

ya.. that is too deep for me 🀣 ... i'm just a hobbyist

tribal zenith
#

hoisting and context are the biggest differences

#
console.log(test1());
console.log(test2());

function test1()
{
  return "Test1";
}

const test2 = () =>
{
  return "Test2";
}
// test2 is only available after this block

the first log will work, the second throws an error

#

also it's easier to read what part of your code is a function and what a variable

pulsar willow
#

@elfin arch hey again πŸ˜„ , i was wondering is there a way to see how many times my custom api link was called in the repl website ??

tribal zenith
#

you could add a counter to the chat command

daring mauve
#

I searched but could not find it.. is there a goal tracker widget that tracks a total of tips + bits? I want both to go towards a common goal rather than having two discreet trackers

daring mauve
#

@sturdy oak do you know which one you're using or who made it so I can search?

cedar kiln
#

can i send a bot message via overlay? i have tested using CURL and it work, but i want to get it more streamlined (as in copy paste code to overlay)

#

from the docs, i can retrieve apiKey, but not JWT Token, or can i?

#

current way to get JWT is to set my bearer to obj.detail.fieldData

tribal zenith
cedar kiln
#

oh thanks!

#

but im looking to do it inside streamelements, is it possible doint it without using jebaited.net?

tribal zenith
#

nope, the widget token alone does not have he required permissions

cedar kiln
#

oh well, then back to my previous code where i need the user set up the JWT token on widget field

#

thanks btw

tribal zenith
#

that is very bad practice and you should never do that

cedar kiln
#

uh oh

tribal zenith
#

the jebaited.net tokens are scoped, so if they ever get leaked they only have a limited usability and can easily be invalidated

#

the JWT tokens give full access

cedar kiln
#

i get what you mean. in case someone just embed/iframe the widget, we can see the JWT token on developer console(chromium)

#

just realized that

#

thanks for the heads up

#

then, is there any documentation for jebaited api endpoints?

tribal zenith
#

@viral patrol is the living documentation. he made that site πŸ˜„

cedar kiln
#

hahaha..cool!

viral patrol
#

Basically when you click on a button with endpoint you selected, you will get basic usage example

main imp
#

I just want to follow up earlier on why my custom font that I created and installed wouldn't show up in my browser or OBS

#

It stopped working again after a reboot or just randomly. The solution is to install the font for all users, which I of course did not know was even a feature

#

you can go through %localappdata%, microsoft/windows/fonts and if a font shows up there it likely is only installed locally, so you right click on those and install for all users

#

then there's no font mysteries after that

#

@elfin arch actually

timber lark
#

Is there any way to expand the "!top online|offline|alltime" command to show the top 10 or even top 20 with help of API? I'd like to have a command with a chat output (not overlay).

viral patrol
#

You would need to have a MITM that will query your channel's leaderboard and output specified data.

next radish
#

@indigo flume will you be able to answer it here? Is it possible to test that call?

indigo flume
#

I simply redirected you to the right channel. I haven't coded a custom widget in over a year and stuff has changed since then.

next radish
#

its not really the widget I need help with, more the getting the emulated data to show so i can test to see if everything works

#

ok well Ill ask here, but was ignored last time I tried - I have a 2 custom label widgets , left side is based on recent sub/gifted, right side is going to be top donation/bit donation of the session. Atm I cant test to see if the top donation works, because emulated data is seen by the top donation of the session calls.. Any way I can get those emulations to work so I can test to see if a new top event will replace the previous?

viral patrol
#

You can change top events in widget data tab

#

Top right corner of overlay editor

spare tendon
#

How do I get my overlay working on PS4

#

Can I do it on windows

#

I'm so lost

mortal knotBOT
#

@spare tendon Consoles do not have native support for overlays. You would need a capture card, PS4 remote play or Xbox companion app and a PC with OBS in order to have overlays over your console gameplay.
We have a blog post about how to set up console streaming with our essential tools: https://blog.streamelements.com/how-to-stream-on-console-7b620b1c46c3

pliant axle
#

Is it possible to have an overlay/widget that works for both YT and FB in one for multistreaming, so I mean like the rotating feed (made by thefyrewire) but with data of both YouTube subscribers and Facebook followers at once

sturdy oak
#

Technically yes with the api.store

pliant axle
#

I will screenshot this and come back with more knowledge

muted stag
#

Hi, is this where Im supposed to ask for help if Im making a custom widget?

sturdy oak
muted stag
#

Hi, so Im trying to make a countdown bar for a subtrain, and when I tried doing it with a while loop it just shit itself so now Im trying out setInterval which Im very unfamiliar with. Does anyone know why this code is not working?

else if (listener === 'subscriber') {
    timeleft = 300;
          setInterval(while(timeleft > 0){
            progressBarWidth = timeleft * $('#progressBar').width() / timetotal;
            $('#progressBar').find('div').animate({ width: progressBarWidth }, 500);
            timeleft = timeleft - 1;
         if(timeleft === 0){ clearInterval()};
        },1000);
    }```
And does this specifically work? 
```if(timeleft === 0){ clearInterval()};```
tribal zenith
#

you have to pass a function to setInterval and don't really need a while-loop. setInterval gets called every x ms (1000 in your case) so you can check the counter on every iteration

#

to clear an Interval you need to pass the creation variable as parameter

#
timeleft = 300;
// myInterval should be a global variable
myInterval = setInterval(function()
{
  progressBarWidth = timeleft * $('#progressBar').width() / timetotal;
  $('#progressBar').find('div').animate({ width: progressBarWidth }, 500);
  timeleft -= 1;
  if(timeleft === 0){ clearInterval(myInterval)}; // you might want to call an external function to clear the interval
 }, 1000);
#

but your calculation for the widths doesn't seem right. Since timeleft is your factor the whole bar gets smaller on every iteration

#

also timeleft gets set to 300 every time the whole code should be called outside of the subscriber listener

whole mural
#

trying to convert to the SE overlays for alerts, when doing recent subscriber what is the variable for how long they have subbed for?

#

i have it in streamlabs using {months} as the variable, but it doesnt work in SE

rugged rapids
#

{{amount}}

#

There is an API documentation at the channel header in this channel.

whole mural
#

Thanks

muted stag
#

@tribal zenith nah its correct , it has a background and stuff. Or in second thought, I could just set the width to timeleft, that part was copied and redone so haven’t looked in to it to much xD. Thanks for the help though!

sturdy oak
#

StreamElements does not like while loops

willow plank
#

Quick question, is there a way to see highest amount of total subs in the custom widget?

sturdy oak
#

Is there a way to see if a sub is a resub within onEventReceived, without having to cross referencing it with data["subscriber-resub-latest"]["name"]

tribal zenith
#

obj.detail.event.amount

#

a value of 1 is a new sub, anything above a resub

tribal zenith
sturdy oak
tribal zenith
#

Twitch also counts cumulative and total months. So a resub streak of 3 means you were subbed 3 months in a row, while total can be in any timespan

muted stag
#

Anyone know if I can .find divs by id using jquery instead of this JS $('#progressBar').find('div')

tribal zenith
#

$('#progressBar #myDivId')

willow plank
#

Follow-up, is it possible to store data/variables in the widgets that can be used on next load? That way I can iterate the highest subcount on my own

willow plank
#

There it was. I can see it uses a .then, so I assume the get is async πŸ€”

tribal zenith
#

it returns a Promise, yes

#

but it should also be awaitable if that was your question

muted stag
#

Why doesnt JS $('#progressBar #bar2')
Pick up JS <div id="progressBar"> <div id="bar"></div> <div id="bar2"></div> </div>

#

But it does work for #bar

tribal zenith
#

what do you get when you put console.log($('#progressBar #bar2').length); in your JS?

muted stag
#

Do I have a console in streamelements? xD

tribal zenith
#

your browser has one

#

F12 if you use chrome

muted stag
#

outputs 1 (I think)

tribal zenith
#

then it finds the element

muted stag
#

in console but doesnt start animation

tribal zenith
#

then it's either the css or something else in the interval

sturdy oak
#

@muted stag You might wanna consider GSAP

true stirrup
#

Hello everybody, we are trying to make little bot-like app, that will track down donations done, takes its value and make some action (python script). Is there some way to listen to some trigger done by streamlabs chatbot, or periodically check streamlabs API for tips/channel/moderation ? I was thinking that I could check this endpoint every second, but is it good practice, or is there some better way to catch donations? Can you point me to some good solution?

lethal herald
#

Hello! I had paid someone to make me a custom alert/notification bar and they returned to me wit ha jS file that works on streamlabs but i use streamelements and when I put the code into the Custom widget maker nothing works, Does anyone know how to help? Also if this helps, attached is the js code

broken coyote
#

@lethal herald looks like the custom fields are missing. its calling for a volume, and alert type

elfin arch
#

no problem @lusty star ... it's sleep time for me; good luck πŸ™‚ (you can also grab something from #widget-share and see how others do it too!)

lusty star
#

I ought to sleep too, I always leave these things so late that I never get them done at an appropriate time! I've 0 experience with javascript so I'm salvaging what I need from every widget I can find and breaking everything πŸ˜‰ Thank you for your help though, hope you sleep well ❀️

heavy lily
#

hey guys just wondering how long the approval time is roughly for the widget-share once you have submitted your application?

hardy walrus
#

When dis you submit it?

viral patrol
#

Widgets are published one by one, so every single one of them gets enough hype from being "latest one", your widget is second in queue πŸ˜‰

heavy lily
#

oh ok thanks was just curious cause some people are hitting me up for the link thanks for letting me know πŸ™‚

true stirrup
#

@sturdy oak thank you, going to look into it

next radish
sturdy oak
#

Then navigate to Session data and change the values

tribal zenith
viral patrol
true stirrup
#

@tribal zenith ok, that rate limit is what I want to know πŸ˜„ where can i find that information please? πŸ™‚

next radish
#

@viral patrol Yeah the data visualisation πŸ‘Œ thats what I've been using, but it doesnt update the custom label when I change the data, I have the labels animate in/out as new alerts coming in, and as Im about to change this to top dono/bits, I want to see the change work before I send this over to the client

viral patrol
#

Oh.. On events. This triggers onSessionUpdate event

tribal zenith
next radish
#

yeah so assuming theres no way to test that without physically donating to my channel?

viral patrol
tribal zenith
#

or via a button under fields

viral patrol
#

Yup. Button under fields does the same (emulate event from within widget)

next radish
#

ahh perfect πŸ‘ thanks!

true stirrup
#

thank you too πŸ™‚ helped alot πŸ™‚

next radish
#

hmm still doesnt update using the fake tip, assuming the stream will need to be live for this to work with session based events?

viral patrol
#

It should when you use "imported" - it should calculate aggregates and latest labels.

next radish
#

yeah alert was triggered, label didnt proc - ive just modified the custom labels code from the github

#

hmm normal built in labels seem to change, so it must be something in the code - all good then, Ill figure it out πŸ‘Œ thanks for all the help though

lusty star
#

I've got an issue that might be similar to etsKi that maybe someone can help with. I've repurposed a "goals" widget that someone else made (I have zero experience with Javascript so I'm just butchering things), however I want the current total to be a sum of my tips, cheers and subs. I have it set in the JS that the variable is defined as those numbers, but it will only update on widget load. I was trying to make it update onEventReceived, but from my pathetic knowledge of JS I've read that you can't access this data then? Having massive PepeHands moments. Sorry to bother you all ❀️

tribal zenith
#

onSessionUpdate in the docs might help you

frank trout
#

Hey there! I've noted something interesting. I tried editing an overlay widget's fields, replacing a dropdown field with a checkbox instead. However, when I change the checkbox's state, expecting the widget to reload as it did when I changed the now gone dropdown, it doesn't reload anymore. I have to refresh the page. Is this intended behavior? If so, could it not? πŸ˜‰

#

Use case is simple: why have a dropdown with 2 elements when you could have a boolean checkbox?

viral patrol
#

@frank trout Unfortunately checkboxes don't trigger widget reload. This is why I personally went with dropdown yes/no (and it looks nicer)

frank trout
#

@viral patrol

checkboxes don't trigger widget reload
Which I've noticed, sadly. Wish that could be different though :
I went with dropdown yes/no
Which I had and hated because you can't just parse the values from the fields outright, you have to check if a string is a certain value.... ugh FeelsSpecialMan

tribal zenith
#

you could set the values to "true" and "false" weSmart PepeLaugh

frank trout
#

If only they weren't both truthy...

#

Unrelated question: is it possible to import a custom widget from a directory/archive or something of sorts? That would be FeelsWowMan

viral patrol
#

Then you will need to manually move your widget to overlay editor.

swift widget
#

@viral patrol im trying to use your GOFUNDME ALERTS in its not picking up the donation when its been made can u help please

#

i have what i think is the short name bit nothing

viral patrol
#

Can you send me link to fundraiser via dms?

lusty star
#

@viral patrol Just wanted to say thanks for the widget you linked to, managed to use some of the code to iron my stuff out. I'm 90% sure it's working though it's still being erratic when I use the emulate function in the editor. But just wanted to send my gratitude. Happy holidays mate ❀️

viral patrol
#

@lusty star use "Goals" tab in "Session data" to play with values

lusty star
#

I've been using that to change the actual values, but it only updates when a visual event happens (or when I hit replay through OBS). I have a 'OnSessionUpdate' event listener but I think I'm misunderstanding what that does πŸ˜…

tropic fern
#

@viral patrol i have a question about the bank heist game - do you need to login to the jebaited link in post and login with your stream elements account for it to sync up and work?

timber ore
elfin arch
#

Last I heard, OAuth credentials are currently not available @timber ore

timber ore
#

@elfin arch is there another form of auth that is being used as an alternative now?

elfin arch
#

Depends on what you are trying to work on? For like personal projects and your own server you can use JWT.

#

or if you are doing like an overlay; then jebaited.net some some basic API calls

tropic fern
#

@elfin arch do you need to login to jebaited with your stream elements account for it work properly?

elfin arch
#

yes. it asks a a middle man service

#

it basically gives you a scoped and easily discardable token to make SE API calls for saying messages and points

winter creek
#

Not sure if this is the right channel, would it be possible to animate the color on the text portion of the alert widget to change midway through, or a gradient?

hushed zinc
#

Not sure if this is the right place, but I am trying to display bitcoin price data in an overlay and can't seem to get it to show. I have code I know works, because it displays in codepen.io, but doesn't show in streamelements. Any advice? Here's the code in codepen working https://codepen.io/ngauthier/pen/xxEXaGd

whole storm
#

Hey! I'm a Software Developer and right now I'm working on my first custom widget, I'm wondering if it is possible to add text to speech (TTS) on a custom widget, and if it is, how? I already searched but I only find information related to cheers/subs/tips, which is not something that I want. I just want to be able to TTS a message that a user send in chat followed by a command.

Per example:
user: !tts Hey this message will be TTS
and after receiving this message a bot would TTS "Hey this message will be TTS"

Any kind of help or even documentation would be appreciated!

broken coyote
#

@hushed zinc your going to run into a cors issue. IMO. save it as a local html file. and drop that into OBS

#

just download that, drop into OBS

whole storm
broken coyote
#

no problem!

west night
#

I'm not really sure how to ask this, so this is the best I got:
Occasionally on the user's end, tip-session-top-donation breaks and shows the recent donation amount with the name "tip-session-top-donation". However on my end when I look at it in streamelements editor it is working properly. Is the only option to have to the user refresh cache in OBS?

frank trout
#

Few questions about fields in custom widgets: how are field names parsed when interpolating them into, say, CSS? I use some of the values in my stylesheet for coloring and some other variables. However, I've noticed dashed names (something-like-this) aren't ingested properly vs. camel cased names (somethingLikeThis). Instead, they are just kept as {{something-like-this}} in the stylesheet. Are dashes an illegal identifier character? For what reason? Could it be supported?

frank trout
#

I have a terrible workaround for this using js:

  1. Get the root html node
  2. Get its computed style
  3. Filter fields that are defined as variables in the CSS stylesheet as --variable-name
  4. For every such field, change the root node's style, provoking a DOM reflow
elfin arch
#

I just did a test @frank trout and am seeing the same thing; using _ seems to work for field names. Is there a reason that you have to use dashes in the field Json?

frank trout
#

It's a mixture of convention convenience than anything else. I was taking a look at the custom widgets over at SE's widget repo, specifically at the custom event list one. The fields there are a mix of camelCase and dashed-variables. For consistency's sake, I'd also like for the fields to all follow the same naming convention. The reason for it being dashed is I can just use the event's type as a part of the field's name, similar to what's being done in the aforementioned widget I visited.

#

I must say I prefer dashes vs. underscores, but that would definitely "solve" the issue. It's yet another workaround, but a much more acceptable one.

#

@elfin arch should've replied directly, sorry for the late ping

elfin arch
#

Ah. ya, that makes sense. I'm not sure of an easy work around for the dash thing, the underscore is best probably closest. I normally name my fields something like FDcolor to specify it is a field data JSON. (i've had issues in the past using literals and variable name confusion, the ${varName} was changed to a string $varValue during the widget load.) ... then convert those field data variables to js variables on widget load to same name without the FD. But everyone has their own style i'm sure.

frank trout
#

Indeed. I think I'll just keep it as is, it's not like it under performs terribly. Since the parsing and hacking really only happens once, I'll take it. Helps me debug some stuff locally too, as well as copying stuff over to the SE overlay.

#

I used to have to take caution when copying CSS since locally I had hardcoded values whilst remotely I was using the values retrieved from field data. Now I don't really have to care. If I have CSS variables named after fields, they will just be automatically parsed. Neat side-effect.

elfin arch
#

Ya. it's actually really nice how it does that

pliant onyx
#

so for the credit roll widget it doesn't show my new followers.

hardy walrus
#

Are there any showing for that session in the activity feed?

pliant onyx
#

yes

#

I had 1 new follower and it didn't show it's been doing that for awhile now

keen aurora
#

hay guys I'm new here just started messing around with SE api. I'm looking at Connecting via Websocket docs. https://docs.streamelements.com/docs/connecting-via-websocket
I managed to connect to websocket and get some test data.
One thing that I don't understand is websocket.schema.json snippet. What do I do with this file? I tot it was used in JS but I don't see any reference in JS snippet.
Btw there on that on Connecting via Websocket "snipper" probably should be "snippet" πŸ˜„

viral patrol
#

websocket.schema.json is a file that describes what you can expect in events coming via ws. More details: https://json-schema.org/

#

@keen aurora ‴️

keen aurora
#

@viral patrol thank you for the explanation. I'll take a look at example code.

keen aurora
# viral patrol And if you want to check "live example", you may look into: https://discord.com/...

I been playing around with live example. It was really helpful I think I can start making widget πŸ™‚ I just have few more questions.
Is it possible to make widget that pulls data from Twitch and YouTube at same time. Something like rotating labels displaying twitch follow and YouTube sub? I tried connecting to YT and Twitch with JWT tokens at same time that works. I guess I can make local hosted widget that way. But can I publish a widget to SE that uses data from YT and Twitch at same time.
One other thing do you have live example code for YouTube?

pulsar willow
#

When a video ends in the media request queue, the next doesnt starts (the autoplay option is enable), I need to click in the start every time?

gentle swan
#

Anyone know how (this is just a reskined tracker) I can track my bits and other goals not towards a total ?

elfin arch
#

so; #1; warning.... i would not recommend mixing bits with tips.

#

that is a Twitch no-no (TOS)

#

with that said; do you want to keep that same visual or open to anything?

gentle swan
elfin arch
#

you can't give a $ value to a bit.

#

so you can not say $1 = 100 bits

gentle swan
gentle swan
# elfin arch you can't give a $ value to a bit.

ahh no no, thats donations and bits each. not a combined thing. And also this is a example text in case something was a miss. The numbers tough are the total for the stream, not a goal set in time there and then.

#

that worked well with SOBS , but OBS/Elements is having problems here.

elfin arch
#

when you say I can track my bits and other goals not towards a total do you just want to remove the "of ####" part?

gentle swan
elfin arch
#

in slOBS?

gentle swan
elfin arch
#

.... i guess i should clarify this for you. OBS is OpenBroadcastService that deals with your camera and microphone.

gentle swan
#

same as streamelements have

elfin arch
#

correct. but those settings do not affect the source (overlay).

gentle swan
#

so its not important about what is where .

#

im trying to solve the problem πŸ™‚

elfin arch
#

it's not different. you can use an SE overlay in OBS Studio, slOBS, OBS.live it will work the same in all 3.

#

but; either way; is that the goal is not triggering when you hit the max?

gentle swan
#

Thats not important in this case. no matter the wordings, the problem is still its different. so something is a miss.

#

no as said. it counts all bits, or all donations earned

#

and wont start at 0 when new goals are aset.

elfin arch
#

the widget doesn't reset to 0?

gentle swan
#

correct

viral patrol
#

To reset goals:

  • from the Overlay Editor > Session data on top right (monitor symbol) > Goals tab > reset progress of desired goal
  • from the Dashboard > Activity feed on the left > Widget data on the right > Goals tab -> reset progress of desired goal

Note: Goal widgets (progress) only counts up and doesn't go down automatically, if you lose followers/subs.

elfin arch
#

ahhh. so my guess is that the widget isn't checking for the current status on load

gentle swan
#

il try restarting for cache clearing

#

but its late for me i been up so need to sleep now. thx for the hlp and il work on this later.

elfin arch
#

merry Xmas πŸ™‚ we'll be here when you get back into it

winter creek
#

Would anyone here know how to make a circular sub train like lirik has on his overlay?

hardy walrus
#

@thick trail disregard

thick trail
#

sry just got back

#

whats up

hardy walrus
#

The emote combo widget was only counting at most 3 uses instead of the correct number that would be recognized in chat. According to lx: Seems like the original code put all the emotes into single bag and it was confused with all the numbers. Now every emote has it separate

thick trail
#

widget has been in use in many channels with no errors...

#

uhm, i've done personalized customization for some people tho, is this the case?

hardy walrus
#

I'll let LX answer.

viral patrol
#

Hi @thick trail! I just rewritten that so it uses per emote buckets, so right now you have structure like:

emoteCombo={
"Kappa":{
users:[],
count=1,
timeout=somthing
},
"Jebaited":{
users:[],
count=1,
timeout=somthing
}
}
thick trail
#

any text or other emote would break the combo, also it is required for it to be unique people

#

i don't see how this was an issue... this just seems like a feature to me?

viral patrol
#

It didn't break the combo.

#

It just acted weird then.

thick trail
#

im confused

viral patrol
#

But also I see I broke it in other way rn πŸ˜‰

thick trail
#

What I understand from ur snippet u are aiming for per emote combo?

viral patrol
#

I see I wrote it bad in that use case scenario.

thick trail
#

widget was only counting at most 3 uses

#

can u elaborate on that?

hardy walrus
#

While the combo in chat was recognized as 36x

#

Granted it was 1 person but Β―_(ツ)_/Β―

thick trail
#

its not possible tho... one person cannot trigger combo

#

it has to be unique people

#

im so confused

viral patrol
#

That is so true. I didn't know that a single user did that.

hardy walrus
#

Yeah....... Sweat

thick trail
#

can you provide the code for the widget, it might be customized is my only guess

viral patrol
thick trail
#

line 81

#

if unique it continues to loop

viral patrol
#

Also there's no need for:

if (!usedEmotes.length) return
thick trail
#

line 19 was my code which checked for unique users, which u have commented out

viral patrol
#

Because actual check is afterwards

#

And line 81 is to continue the loop, not to exit it, if somebody has more than one emote in their message

hardy walrus
#

Which is a very common thing

thick trail
#

but its not unique person, why continue the loop

#

and u have to check if usedemotes is an array before looping it

viral patrol
#

It is always an array (it may be empty)

thick trail
#

that is true but I feel like it's best practice

#

might be wrong

viral patrol
#

Typeguard is not required if this object cannot store mixed values.

thick trail
#

anyways, if i understand correctly u are trying to write some feature to it that allows for multiple emote combos?

viral patrol
#

That is correct. For example people type "Kappa Jebaited" so there are 2 combos going on.

thick trail
#

because the original is not broken by any means as stated above

viral patrol
#

Then somebody writes "Kappa" and "Jebaited" is broken, but Kappa is ongoing.

thick trail
#

Kappa Jebaited in original would mean, if any of those are in the combo and is unique person it will continue the combo

#

otherwise it will store the emotes for next combo

viral patrol
#

It would display just first emote then. Your combo had an array of emotes and displayed one with 0 index (even if the emote on 0 was broken already and only one was the next one ongoing)

#

So I basically split that up to:

  1. allow multiple emotes combos ongoing (separately, on different indexes)
  2. Ability to break a combo by text (or ignoring it, so people could have just an emote counter within single widget)
  3. Ability to not ignore users (just like the bot has it)
thick trail
#

was broken
i dont think i understand what u mean by broken

viral patrol
#

UserA: Kappa Jebaited
UserB: Kappa Jebaited
UserC: Kappa Jebaited // will display Kappa emote and x3
UserD: Jebaited OMEGALUL // will keep Kappa with x4

#

Because there was a Jebaited (part of combo), but not the element that was on index 0

hardy walrus
#

This instance that I had initially poked you about was with a streamer who has a streamdeck and spamming multiple emotes within the message and making the "streak".

thick trail
#

Ohh I see what you mean

hardy walrus
#

And others within the chat as well who would do the same.

viral patrol
#

Hmmm. I see this needs additional changes however.

thick trail
#

is the code working properly now?

viral patrol
#

Because it has Kappa stored, but with lower counter.

#
        for (let emoteText in emoteCombo){
            if (usedEmotes.findIndex(p => p.text === emoteCombo) === -1){
                delete emoteCombo[emoteText];
            }
        }

Like this?

#

at the end of checkCombo

thick trail
#
  if (!usedEmotes.length) {
    emoteCombo.emotes.length = 0
    emoteCombo.triggerUsernames.length = 0
    emoteCombo.count = 0
    return
  }

this is regarding the loop of empty array we discussed earlier, I was resetting it in original

#

yea that would work, at the end of checkcombo or at reset would work right?

#

if im not overlooking something

viral patrol
#

"Reset" (but not actual reset) is done via showCombo() - if emoteCombo is empty, or top emote is below threshold - it doesn't display it

#

checkCombo prepares emote combo object which is then parsed by showCombo

thick trail
#

yea, i was referring to why i had that in original, showcombo was not resetting it or checking it

#

how are 2 simultaneous combos handled

#

oh i see

#

topIndex

#

after that clearing the top emote would work, right?

viral patrol
#

Yes.

thick trail
#

you could've just asked me to write the functionality instead of dedicating your own time πŸ™‚

#

but I appreciate it

#

if only it was easier to push updates to all widget users, that would be amazing

#

I understand that would require some supervision because of security issues

#

but yea, currently pushing an update for the widget for all the users is quite difficult

viral patrol
#

Especially - they wouldn't be happy if they adjusted the code on their own πŸ˜‰

thick trail
#

true

viral patrol
#

And about dedicating my own time - I am still so full after Christmas dinner I cannot move out of my PC, so I want to be creative ❀️

thick trail
#

same here, hope you had a nice christmas

viral patrol
#

So I apologize for stealing your opportunity to be creative (and even that last fix I pushed after your insight)

hardy walrus
#

And part of it was for a VIP user.

thick trail
#

haha, no need to apologize. you fixed something that was broken

viral patrol
#

And before you arrived I broke another thing! Without you I wouldn't be able to see that issue! TYSM

thick trail
#

teamwork makes the dream work

#

if there is any way I can be helpful feel free to shoot me a message, i'm always happy to contribute

viral patrol
#

If you have any widget ideas I will be more than happy to review and let whole community use it/them πŸ˜‰

vestal grotto
#

Hi everyone

#

Could anyone help me?

#

I'm trying to enable and disable a default command (songrequest) using the API

#

But I only get this error: {'statusCode': 400, 'error': 'Bad Request', 'message': 'child "command" fails because ["command" is required]', 'details': [{'path': ['command'], 'message': '"command" is required'}]}

viral patrol
#

You cannot disable command on it's own as it is managed by module. You need to send PUT request to https://api.streamelements.com/kappa/v2/songrequest/:channelId/settings with full payload of that module. (you can use GET call on that endpoint, change either enabled or mode properties (mode accepts strings free,tip,combined).

vestal grotto
#

I got it

#

Thank you very much πŸ™‚

burnt yoke
#

Hey everyone, is there a way in a custom overlay to have the overlay send a message to chat?

viral patrol
lofty wigeon
#

Does anyone know what (or IF it exists) the endpoint would be for this custom command?

${user} was last seen ${user.lastseen} ago

Returns: User was last seen 2 months 29 days 14 hours ago

I can get this to work as a chat command but I'd like to make a small script and pull back a list of usernames to let me know how long ago they were last seen.

uncut cliff
#

not sure if anyone has made one or not but though id ask here anyways, does anyone have a rotator for subs, stars and tips on facebook? if not how hard would it be to make one?

sturdy oak
uncut cliff
lofty wigeon
#

Anyone know what the endpoints are for ${user.lastseen} and ${user.lastactive} for user=whoever at my channel?

tame sparrow
#

@sturdy oak you have to know the facebook graph api.

mild cipher
uncut cliff
#

i have it for my twitch account and i think i added it to my facebook account. ill have to check.

ebon pulsar
#

hello, i would like to do some math on the ${user.points} variable, is it possible to display like "0.1" when the player has 100 loyality points: doing like "${user.points}/1000"

forest geyser
#

Hey guys might be a dumb question but looking for some help with text to speech and the streamelements api. This website https://www.elunduscore.com/ says its powered by streamelements but when looking through the API I couldn't find a TTS endpoint

I also found this github repo https://github.com/5E7EN/TTS-Emulator/blob/5c9a906d148093661f93321b4802d49e93110976/index.html#L87 that seems to be out of date but at one point it was hitting a TTS streamelements api endpoint. Is there still a TTS stream elements api endpoint that one could use to hear Brian perform text to speech?

To provide some context I'm trying to build a goofy discord bot that can do text to speech with Brian's voice and I was trying to explore different avenues I could use to get the bot to speak

Thanks for anyone who takes the time to help me out πŸ™‚

hardy walrus
#

@forest geyser Due to excessive use there was a "security wall" put in place for our TTS related bits.

forest geyser
#

Ah I see, so to just get further clarification is there a way to get access/permission through this security wall or is it not available to the public?

#

@hardy walrus

hardy walrus
#

Not possible atm.

forest geyser
#

No worries ty for your time πŸ‘πŸΏ

sturdy oak
#

You can use google's TTS instead @forest geyser

forest geyser
#

@sturdy oak Yeah theres a ton of TTS stuff out there. Javascript has a few libraries for TTS and same with python which is super cool but the bummer part is a lot of them don't have the voice of Brian :/

With the text to speech voice of Brian you can get him to say really silly stuff and his voice is super recognizable because many of the popular streamers use Brian for their TTS voice. So its been tough to find an API or library that includes his voice. Streamlabs I think may have a TTS endpoint but I reached out via email to confirm that

Otherwise I may use AWS polly to do TTS but the downside with that is AWS would bill me every month. The other option is to use selenium to go to that elundus core website I linked above and have selenium enter the text and submit it that way. It might be slower but could be a work around. Gotta do some more exploring with it πŸ€·πŸΏβ€β™‚οΈ

viral patrol
#

@ebon pulsar You can use ${customapi https://api.mathjs.org/v4/?expr=${user.points}/1000}

#

@forest geyser I think that amazon polly on free tier would be enough for most of cases.

timid bough
#

Hey devs.
Is there any way that you can add tts in Greenlandic? I know tts from Oqaasileriffik website one called "Martha" voice where it can read in Greenlandic.

#

It will be so cool to use it from my stream

spark obsidian
#

hi, this isn't specifically api related but im not sure what other chat to ask this in: I'm creating my own custom alert and I'm having trouble getting the Username text to constrain to a specified area. I have everything almost working properly except if the name is longer than about 9 characters it runs off to the right side. I'm not sure if I've setup the alert widget wrong or not. If theres anyone that could lend a hand that would be great! I can share gifs/screenshots in DMs if necessary

tropic fern
#

is there a way to prevent multiple heist's happening at the same time?

latent cargo
#

Hi, im trying to get the watchtime(loyalty) list of a channel I am editor for using the streamelements api but all I get back is this json file. What am I missing, or is it not possible? json {"_total":0,"users":[]}

unique zodiac
#

hey guys

#

anyone has any information about ByNoGame & Streamelements linking issue?

atomic pine
#

not done a lot of developing in streamelements custom widget editor in a while and just wanted to say that the improvements that have been made make it a lot! nicer to work on...thanks for this seriously thanks!!!

viral patrol
#

@tropic fern Use only one browser source with that game, because every instance of that widget generates a new game. So the best way is to have it only once in OBS, on dedicated browser source. Also - if you have it open in Overlay Editor, this will cause a new instance of game too.

river lance
slate elbow
fair osprey
lucid totem
#

Anyone ever had problems bringing over watchtime from obs?

#

slobs*

tropic fern
#

Does anyone know how a viewer can check the amount of currents tickets they have in a current giveaway using a chat command?

glad urchin
#

SE_API.Store questions:

  1. Are there size limitations for each object?
  2. Documentation says only simple objects, does this mean primitive types like string, integer, etc? Or does this mean no nested objects? Or does it mean something else?
  3. Does each store hold a single object or can it hold an array of objects?
  4. Counters, can you give me a good example where or how these would be used? Is a counter like a dictionary object that holds multiple values with an associated count?

Thank you for the assistance!

viral patrol
#

@tropic fern I thin that they can check that on giveaway's webpage.

#

@glad urchin I am not sure about size limits. When it comes to simple objects - it means you cannot have references nor functions nested. Basically - this is something you could represent as JSON. So it is absolutely safe to have {a:5,b:[1,2,"test"]} stored.

#

And about counters - this is for bot counters. Like when a viewer types !death and your death counter goes up by one. After bot increases that value, it will be increased on your screen (in any format, so you can have Deaths: 5, or face images like in old FPP games)

glad urchin
#

Thanks for the quick reply @viral patrol πŸ™‚

glad urchin
#

Just to double check @viral patrol but do you think it’ll be safe to store an array of simple objects in the se_api.store?

velvet jasper
#

Hello guys, does anyone have any insight on where to begin if I wanted to add (or suggest adding..?) a payment method in SE's tipping page?

ocean fractal
#

question: and this has probably been answered over and over again...
the customWidget onWidgetLoad event has the following field:

{
  detail: {
    channel: {
      apiToken: "tokenValue"
    }
  }
}

my question is is that apiToken what's used as a twitch oauth token or for streamelements?

spark obsidian
#

it does this for every label

ocean fractal
spark obsidian
#

nevermind i figured it out lol

#

closing tags will be the death of me

tribal zenith
ocean fractal
#

gotcha. thanks!

glad urchin
timber lark
#

I try to figure out how to format command variable ${user.time_online} to just show the sum of ours with one decimal place.
So instead of "7 months 3 days 14 hours" it should show "5222,0 hours".
It should be possible with the use of API, that's what I heard. But I am in despair, can't find how to do that.

split zinc
#

@viral patrol I always get an error when I enter the command (404 The requested URL was not found on this server.) What can I do? I integrated the pashse correctly and otherwise it always worked.

viral patrol
#

If requested url throws 404 it means that path is not found on server. It can be because your url is wrong or file got deleted.

nimble crown
#

hi! is there a way to trigger a sound with a command and on the same with response something with the bot in chat? for example: !hi --> hi chat ${redeem hi} (if you have access to support request check 101666)

copper portal
#

Does anyone know the list of all of the icon names for streamelements. Like if you type " heart " a heart will show up or " crown "

viral patrol
#

@copper portal Can you elaborate?

copper portal
#

no

broken coyote
#

Hahahaha

sturdy oak
#

Lmao trolls

crisp spire
viral patrol
#

Oh. This one is meant to be used by somebody with html/css/js knowledge. I am not aware of any "ready to go" solutions. Basically with that library you can select the text container and code will adjust the size of text inside, so it won't overflow the container dimensions.

silk delta
#

hi! short question. is it possible to use ${game} with the integrated Tweetfunktion from streamelements?

safe gull
#

hi

restive cloud
#

I'm not sure where to ask this question so I'm just gonna ask it here. My !watchtime is not working. I have it set up (or at least i thought I did) but it always just says 0 seconds. Is anyone else having this problem?

elfin arch
#

The watch time is in 10 minute intervals; do you have users that have more than 10 minutes already?

restive cloud
#

yes

#

If I were to do the command would it work?

elfin arch
#

ya; it should

radiant halo
#

Hoping this is the right place to post! I'm trying to code out Twitch T2 and T3 alerts, but with JS to (hopefully) show how many months they've been subscribed as well. Ideally I'd like to do this for Prime, too.

I realized what I have currently is targeting tier since the variations are for tiers. Is there a way to make the alert display months as well?

I rarely touch JS btw! I animate and all with CSS so this is practically a foreign language to me.

elfin arch
#

You are in the right place @radiant halo .... what are you looking for ... like 'user resubbed with tier for X months' ?

radiant halo
elfin arch
#

🀣 ya. 2000 months; that's dedication

radiant halo
#

Multi-generational subs, hahaha

elfin arch
#

i've tested it some @radiant halo .... not sure where you are getting that 2000 from?

#

{amount} will give you the amount of months they've subbed. and {tier} will give the Tier

radiant halo
#

Oh hmmm. That's just what pops up in the emulator when I hit the play button of the left menu

#

OH! I think I found the issue @elfin arch! It's the emulator and not the code lol. When I put in a custom event and tell it the tier and months it's ok! πŸ‘Œ

elfin arch
#

oohh. hahah ya. emulate the event with custom amount

radiant halo
#

I've mainly worked with Streamlabs so I'm getting used to how SE functions

elfin arch
#

.... looks like the {tier} includes the word Tier too

radiant halo
#

Oh ha. I'll remember that so I don't go double tier

elfin arch
#

Welcome to SE πŸ™‚ that alert you posted looks great.

radiant halo
#

Thanks! It's my brainchild of CSS animation with scaling svg backgrounds 🀣 Brought on mostly by the question "Can I actually do this?!"

tribal zenith
#

what happens when you emulate 2 events directly after each other?

elfin arch
#

i see CSS and SVG in the same sentence; and i'm nope

radiant halo
radiant halo
tribal zenith
# radiant halo Both work!

Nice πŸ‘
I saw some CSS only animations, which would override each other on stream when multiple were triggered πŸ˜„

radiant halo
pulsar willow
light topaz
#

For the developers....the helpdesk for merch cannot answer this question to no fault of their own. But is there going to be an update to the merch store? Looking to add long sleeve shirts and masks. Anyone developing an update for the merch store?

radiant halo
#

Back again with a JS question that I hope can be resolved with JS. I'm trying to set up a widget that will update with the latest follower/sub/cheer etc.

I just am INEPT at JS, lol. I found the StreamElements variable list, but I'm not sure how to make the variable display into the IDs in my HTML.

ember sigil
#

How might I have an input that accepts multiple lines of text?

viral patrol
#

@radiant halo Check "Ultimate text widget" from #widget-share - it should help you

#

@ember sigil Unfortunately there are no textareas

cobalt pike
#

Howdy folks! Weird question, but have any of you tried building react applications into the custom widget? Have you seen any performance issues?

viral patrol
#

Any app that can be held within jailed environment should be OK there. I haven't tried react/vue apps there, but I think they should be just fine there.

cobalt pike
#

Ohhh awesome.

#

I will play around with it. I can't imagine any speed issues, but this is my first day playing with this.

#

I am still trying to understand the event system and all.

viral patrol
#

I think that the best way is to check docs/widgets on github

#

Basically there is window event dispatched on actions happening.

tribal zenith
#

In most cases you won't need a complete React app though

cobalt pike
#

Yeah, I just like the idea of building a robust plug and play library for my own components that can hook into context without needing to individually listen to window events.

#

Something I can version out and prototype on quickly. I might need a couple functions to simulate the data coming in for local development. Hrm.

granite ice
#

For StreamElements paypal integration...
Can it be used soley through OBS Studio? or does it require a Twitch, FB, or YT stream platforms to work?

#

Scenario. I stream on Zoom through OBS Studio and would like if there was an option that when people donated to my paypal that a popup/alert shows on screen.

Maybe I could somehow use the streamelements tipping page link that it generates for FB?

hardy walrus
#

That's the only way an alert would work.

granite ice
#

@hardy walrus So I would have to stream on either FB, YT, twitch for it to work? 😦

hardy walrus
#

Stream no. Just have an account for any of those platforms and connected with us.

granite ice
#

Im still newish and not the sharpest tool. How would I be able to use the tipping overlay system if I am streaming on Zoom using OBS Studio or OBS Live ?

viral patrol
#

I think you would need to use virtual cam from OBS

granite ice
viral patrol
#

You can use that. Set it as for Twitch, just use overlay and tipping link wherever you want

radiant halo
viral patrol
#

That is awesome! Say my thank you to your friend please ❀️

radiant halo
#

I definitely will!

Just in case anyone wants/needs to do what we did here's the rundown for stream labels in HTML and JS. You'd style the CSS however you want

HTML

  <div class="follower">New Follower: <div id="new-follower"></div></div>
  <div class="subscriber">New Subscriber: <div id="new-subscriber"></div></div>
  <div class="cheer">Newest Cheer: <div id="new-cheer"></div></div>
  <div class="tip">Newest Tip: <div id="new-tip"></div></div>
</div>

JS

    let data=obj["detail"]["session"]["data"];
      currencyCode=obj.detail.currency.symbol;
      console.log(obj.detail);
      console.log(data);

      $("#new-follower").text(data["follower-latest"]["name"]);
    $("#new-subscriber").text(data["subscriber-latest"]["name"]);
    $("#new-cheer").text(data["cheer-latest"]["name"]+" x"+data["cheer-latest"]["amount"]);
    $("#new-tip").text(data["tip-latest"]["name"]+" "+currencyCode+data["tip-latest"]["amount"]);
});

window.addEventListener('onSessionUpdate', function (obj) {
    const data = obj.detail.session;

    $("#new-follower").text(data["follower-latest"]["name"]);
    $("#new-subscriber").text(data["subscriber-latest"]["name"]);
    $("#new-cheer").text(data["cheer-latest"]["name"]+" x"+data["cheer-latest"]["amount"]);
    $("#new-tip").text(data["tip-latest"]["name"]+" "+currencyCode+data["tip-latest"]["amount"]);
});
tribal zenith
#

you may want to replace the $(...).html(...) with $(...).text(...) to escape possible bad names

tribal zenith
radiant halo
tribal zenith
#

XSS is short for Cross-site scripting

viral patrol
#

I think this should be covered by name length πŸ˜‰

tribal zenith
#

the $().html() "executes" any html it gets, while $().text() just sets the text value without any parsing

viral patrol
#

But from the other hand, they can break your widget using name like </div>

tribal zenith
#

what is the max name length for donations?

#

Twitch allows 25 characters, but I think donation names can be longer

radiant halo
tribal zenith
#

if you don't really need to render html, you should always prefer the text alternative

#

but in the case of widgets it's not that tragic

#

but it is not good either LUL

radiant halo
#

Hahaha good to know! I'll definitely change it

violet swallow
#

Hey, I was sent here from #helpdesk-twitch I am wondering if someone can help me if you have time

#

regarding a !boss command

viral patrol
#

@violet swallow Can you give us bit more details please?

timber sierra
#

Got a question about setting up a widget on Streamelements. I currently have a premade rotating ticker that shows latest Sub/follow/ect.

One of the tickers on it is for Sub goal, is there a code I can enter into the field before the {{ amount }} command so that it can also show how many current subs I have instead of only what my goal is?

#

Same question regarding current followers since I have one for follower goals also πŸ™‚

tropic wagon
#

OMFG @radiant halo I was looking for this code for month !!!!!! Thank you so much for your help with Stream Labels SEheart SEheart SEheart