#dev-chat
1 messages Β· Page 52 of 1
i tried this page https://jebaited.net/botsay/
but the bot didn't say anything, i also tried pjonp's code it also didn't work (or maybe i did it wrong)
sooo the api docs are down... can someone point me in the direction of sending a message from streamelements custom widget to chat..I can just connect to twitch direct but thought this a bit silly considering you guys have your own wrapper
twitch btw sorry
wonder if wayback machine has a cached copy
nope lol
and wont lemme add lol
@atomic pine check this widget, it should help you with your query: #widget-share message
thanks lx
how can i find something like this but for youtube
I think that this part was just console.log(JSON.stringify(obj.detail)) and sent a message on Twitch.
okay thanks
where does console.log(); show a message?
i tried this but didn't show anything
i found another way to display it
thanks for your help
Oh, but for later - console displays in chrome console CTRL+Shift+J or F12
oh thanks very helpful
CTRL+Shift+I?
Ahh I've been doing it wrong all my life
Hey how can I get the profile pictures of the users that came with a raid and smash them onto the screen?
you don't know who came with a raid, only who initiated it and even then, you probably don't want to show any arbitrary profile picture. if it is inappropriate or against TOS, you are responsible
ok π¦
I'm not sure if this is the right spot to ask this. I am trying to create a command to select a random item, then display that random item in an overlay on my stream. I got the command working, but I'm not sure how to get it to reflect in an overlay. The command I'm using is ${random.pick 'item1''item2''item3'}. I had somthing similar working with streamlabs a few months ago, where a script selected a random item from a txt list and added the result to a different list.
you can listen for chat messages in a custom widget (https://github.com/StreamElements/widgets/blob/master/CustomCode.md#message) and if one matches your command, you can return a random item from an array in JavaScript and do whatever you want with it
but you'll need some JS knowledge for that
@tribal zenith awesome, I don't have any experience with Java, but at least its a direction to start researching in. TY!
you'll need JavaScript not Java. They sound similar but work differently π
@tribal zenith rofl, True, Thanks again π
Just wanted to doublecheck something from someone who only learned yesterday that you could create custom widgets with streamelements. If I complete a widget and want to make it for someone, do I have to handle any of the hosting services, or is that all done on Streamelements' end? It seems like once I test and demo it, then it gets put on the store and that's that. If I'm making such a widget specifically for another person, should that go on the store, or is there some other way to make and distribute it specifically to them?
that person can add you as Editor in their StreamElements dashboard, after that you can either import overlays from your own account or create a completely new one on their account
Ohhhh I see. And I notice that there's a custom widget editor directly in the streamelements overlay editor. I assume this would be the best way to get it directly to them.
yes, overlays are cloud-based and don't need any external hosting
This is super nice. I can definitely spend a ton of time in here messing around with random ideas! It seems like the emulator will be good for local prototyping and whatnot, and then it'll be pretty easier to transfer that work to the streamlabs overlay. Thanks a ton for the help!
If you look in the channel description of this channel here, you'll find some useful docs for the REST and overlay APIs
Oh that is nice. I imagine this'll be useful for anything more involved than the followers/raids/etc. stuff. I'll take a look at some of the pre-existing custom widgets from the github and use those as a baseline.
#widget-share also has a lot of useful widgets
Sounds good. I'll take a look at some of those too at some point.
Applying for OAuth credentials form is down/gone. Is this temporary along with the documentation being down?
I need to use /bot/{channel}/say can someone point me where to get the keys and vals from
oh wait I think I understand gimme a second
okay getting 200 now...so if I need to say something from streamelements I can post with this endpoint?
nice one it works.
thank you
nevermind im dumb
Would there be any legal issues if I took tbe obs.live plugin and made it avaliable for linux?
how to make streamelments addpoints from widget...I am able to send messages through XMLHttp but when I send the points they dont add....is there an endpoint to put points to?
looking in the api and I dont see anything like points/add
hmmm what is guid - Command id
is that like !addpoints
As in. loyalty points?
yeah not redemption
If you check under our api docs, I think its something like loylaties/:channel1
thanks Mitch ill have a look
Non-staff, and highly unsure. The source for OBS.Live is public, but I did refer your question to someone who might be able to find an answer for you
thanks
Alright thanks!
is this body correct??? {"users": [{"username": "itssinic", "amount": 300}],"mode": "set"}
{"users":,"mode":} can someone please tell how to add the points im am getting 200 using {"users": [{"username": "itssinic", "amount": 300}],"mode": "set"} but its incorrect body as the amount is not recognized what do i need to do
this is put endpoint on /points/{channel}
anyone about
SOMEONE PLEASE HELP M SANITY!!! {"users": [{"username": "itssinic", "amount": 4000}],"mode": "add"}
where do I add the amount
please
change the word "amount" to "current" π
thanks ill give it a go π
well i never...they key for the amount is current
thank you my brain lol
@elfin arch Thank you so much...is there some docs telling the structure of the json?
for the PUT or the return?
looks like the API got updated; looks new to me. haven't had time to see what's in it.
all docs welcome as its a bit thin on the new api at the moment π
I have to add though when the docs are bulked up a bit, I like it...simple and straight forward other than the lake of body structure lol
lack!
lack*
omg its bedtime
Thanks again
ya. no problem. sometimes it's best to ask around here if you get stuck. generally someone knows the answer ... eventually
thanks again
that endpoint (the bulk add) doesn't give a json response, it's a text() i think it is just success or fail
okay thanks...this isnt required in this case as its to individuals, but nice to know for the future.
oh; for single users you can use https://api.streamelements.com/kappa/v2/points/${process.env.SE_ACCOUNTID}/${username}/${points}
no body needed; just PUT
ya. still requires Authorization 'Bearer ....'
don't think it needs content-type; if it doesn't work add it in π
that works perfect thanks
i was thinking; you can probably hack up one of the rotators like #widget-share message to get it to match what you are looking to do.
hey! why are all the API reference endpoints like this: "This endpoint's documentation is currently experiencing difficulties and will be back online shortly." Makes it really hard to start using it...
mine are up now maybe refresh cache
they are being udpated though...looks all new to me
I was looking at https://docs.streamelements.com/ (bad) I just saw up there on the description that the API is at https://dev.streamelements.com/ (good!)
ahh lol
anyone still around on here
nevermind thought of another way
i got a template for youtube thanks
Hi, everyone, is it possible to upload custom widgets without sharing them, from my own repo?
i tried this this site
and i tried to use a command but the bot never send anything
pls help how can i make it talk in youtube
The bot can work only if your stream is live and not private/hidden.
And it affects every part of bot.
it was online
it also said something like: "streamelements bot is running π€ "
and its was public
Hmmm. I wonder if SE API allows authenticate against external service with YT account
so is there a way to make the bot send a message in youtube?
so i do something like:
fetch(`https://api.streamelements.com/kappa/v2/bot/{channel}/say/{message}`)
?
fetch(`https://api.streamelements.com/kappa/v2/bot/{channel}/say/`,{
headers:{
"Authorization": `Bearer ${jwt}`,
"content-type": "application/json"
},
method:"post",
body:JSON.stringify({message:"Your message here"})
})
More like that
ok ima try
Hi, everyone, is it possible to upload custom widgets without sharing them, from my own repo?
Or, alternatively, just upload my own widget from a repo?
I think so, but it would require authorization against API.
did i do it right?
i replaced "{channel}" with my account id from SE
it didn't work
i also tried another id
but no work
Thanks π
Do you know how I could do that?
Hmmm. But one more thing - if you create a widget on somebody's account, they will get files that create it.
So using OAuth2 authenticated API calls is imo an overkill and work the very same as widget sharing.
Well, I just plan to create them for my own account.
How can I create files on someone's/my account?
Thing about widget sharing - wouldn't I have to re-send versions for CodeGurus every single time I update my widget's codebase?
And about widget-share - it usually goes via dming me with release version. I can grab it from pastebin+jsfiddle or git repo (if it is open).
Oh, if you can grab it from a git repo then it'd makes it MUCH easier for me!
Do you have any plans for creating publishing pipelines for devs?
And updating overlay via API call - huh. I am not sure right now.
And pipelines for devs - not planned at this moment as it could be a bigger task π
Also, a question about developing widgets - if I want to write code and have the website/server(s) to run it, like with regular web development, is there any way to do that? 'cause I don't know if it'd be possible to test the code and see the result.
Gotcha, thanks π
Maybe I will have something for your dev process
what should i replace in that code?
like where should i put instead of "{channel}"
and what should i put instead of "${jwt}"
Channel should be your channelId, JWT is your personal JWT
@west herald You can find your JWT token on your account channels page (Show Secrets to reveal the token): https://streamelements.com/dashboard/account/channels
READ ME: This is a private security token. Do NOT share this token here or other public places, only with a StreamElements staff member in private.
i think i know how to get the channel id
thanks i will try
Hi, I am currently editing Awesome Shoutout widget in StreamElements. I have checked through CS and Java, I don't know how to fix this R that keeps tucking behind the image, I find that the image is permanently fixed in place. I've tried to vertically adjust the text however it doesn't help. Does anyone know the string of text I need to ammend? Thank you
OMG it Worked Thank you So Much
Thanks a LOT
Hello, dear support.
I develop module for DonationAlerts for webhooks and other types of donate notify and want connect StreamElements as target of webhook.
- I need function for send message to chat
- I need function for post tips donation in system
In documentation these functions at this time with this caption "This endpoint's documentation is currently experiencing difficulties and will be back online shortly."
the social media rotator widget in the themes overlay, the animation in & out won't work.
@prime oasis Our previous docs were getting an "update" and I've been told this is the working stuff for now https://dev.streamelements.com/docs/kappa/api.yaml
"Apply for OAuth2 credentials here." link is dead.
Not dead but unavailable atm.
Sadly π¦
@prime oasis Can you send an email with the details to noam@streamelements.com and cc me styler@streamelements.com
@static wigeon I already fast develop web site with this functions at donationalerts.com, coz for approve app in StreamLabs i must show ready system.
So i can show working system to you in few days.
This might be a little farreaching, but is there a pause scene mini game out there for chat? The thing i was thinking about is like the mini games where you have to type the same thing that the the game master writes down, or something similiar to it, maybe trivia
@ocean spindle there are several games in widget-share.
oh i was blind thanks
Hey guys so I have a question, I have alert animation that i put into stream elements and I added the text that supposed to go over the animation but I want to rotate it, change its opacity and make a custom appearance and disappearance animation so I was wondering if there's a way to code that since there isn't a way to with the default options
I sent this question here and in #helpdesk-twitch since Im not sure where I should send it
I recently noticed that Widget Data stores usernames of people in all lowcaps, while Activity Feed displays their displayName.
Don't think there's any way around it to store the correct capitalization on Widget Data, or maybe just show displayName for recent events?
which rotator do you mean exactly?
okay and you set the animations under Settings -> Animations? The extra "Animation settings" tab won't work with that
yea
so it looks something like this?
Check under settings
I think you have an older version
try this version https://strms.net/socialmedia_rotator-by-benno
np, it was just an older version π
Hello, people!
there is a limit request rate on streamelements API ?
didnΒ΄t find anything on the docs about it.
If you look at the response headers, you'll find x-ratelimit-remaining and x-ratelimit-reset
oh, didnΒ΄t check those, thanks! π
is there some sort of maintenance happening right now, im having some funky things happen while testing
Define funky.
emulating an alert would either be delayed in OBS preview or editor. Sometimes one would show and the other just wont, a gifted alert with correct variations settings is just infinitely looping, where it wasnt 20 minutes ago. Some layers not showing but others do.. lots of funky things
Since I can't look at that stuff I've poked those that can.
ive just reset pc everything to make sure its 100% not on my end
First i would refresh the cache of the browser source, just to be sure
trust me man π ive done it all. I've transferred the exact same code for widgets from my account to another and it just doesnt play good. + emulated alerts are being super slow..
And in console, are they displayed right after emulation? Maybe some console.log may help
As emulated events should be played immediately as they are emitted within overlay
Maybe you have a widget with "widgetDuration" which holds queue?
ok i think I know whats happening. the custom widget is playing the follower alert in the bg which is causing the delay and this dude is a kpop star that has an infinite follower alert going on. It's my bad, it tested fine on mine, but seems seems to be performing differently on his now he has a non stop followers going on
errr can anyone jump in a screenshare with me to help out for a minute or 2. This dudes got 6.7mill followers on twitter and hes just tweeted his brand new channel and i think its breaking everything. i literally cant ping an alert through to test it
I think when his channel is that active the best is to test it on your account, and when it is ready to deploy to streamer's account.
it tested fine on mine, but i dont have 300 followers a minute going following rn π
Also - if your widget has widgetDuration property, make sure that on event's that are queueable (like tip/cheer/follow) and not handled by widget you use SE_API.resumeQueue method
i found the widget that doing it, its one of the alert/label ones thats in #widget-share if I send the code across for the JS, can you pinpoint the follower section so I can just delete it and be done with it
Line 181
just delete that line or the whole follow section?
It's 180-216
You could probably just comment it all out.
But then again I don't understand it and simply speaking with what I see.
https://strms.net/simplehub_by_tenszop - its this widget, just modified to have invisible alerts, though follow alerts are turned off..
i know its that, as i duplicated the full overlay and deleted that widget and it works fine
@crisp needle ^^^^^
If you want to remove followers, I would replace follower function with this:
function follower(data, showAnimation) {
SE_API.resumeQueue();
}
@next radish
So it looks like that:
no idea man, nothing just seems to work
left is with that widget, right is with a normal label
The one I pasted above makes sure that this widget doesn't hold on followers. Maybe there are other events, or they are queued by something else. This seems odd.
yeah I added it to hosts/raids as well but he wont be getting those rn as hes never been live
he tweeted out about his channel 2h ago and this is where its at rn π
Can I get channel name? I am so curious π
'tuanzy'
Hmmm. I've never worked on that crowdy channel and I think that this wave can be problematic. This would require deeper look into what's clogging that widget.
but its super akward, as it works perfectly fine on my channel, ive been testing it all week. and was fine till he tweeted about it 2h ago and his whole channel exploded
It is hard to me to examine the queue, what events are happening there and what is clogging. I already asked for some support in that matter.
Thanks man! I'm safe for tonight as hes not even affiliate, but hes in talks with twitch so he'll be partnered soon, just need to make sure its ready for then whenever that will be
So for now, ive just replaced it with that tip label, but ill need to find an alternate if i cant get it working.
I think it might be streamelements lagging behind, similar when you emulate a 100 gift sub there are like 3/4 seconds of just insane sub spam that takes a minute. So it might just be behind a bit?
Also this is coocla, I changed my name π
Nah π Firstly etsKi removed a follower handler then added "resumeQueue" method, so it wasn't resumed. I added one more check and then resumeQueue as well. Should be find now.
thank you ahead of time π
Does anyone know how to make arguments in bot commands optional? Right now when I don't put anything for the arguments the command just fails
try ${1:|'test'}
Thank you!
Hello... if you make a command with "$ {random.1-100}%" ... will the number 100 fall out or not?
Yes, the highest number you'll see is 99. Inclusive of the minimum, exclusive of the maximum.
Thanks for the clarification
everything is getting reached only line number 40 is not being triggered?
this is the function
line 93 is just for testing (its not being readed)
and yes its a valid id
anyone knows why its not being reached?
either ToggleSubs is not truthy or StartTimer() errors out and stops execution
ima test
i did more tests and looks like not from both of them
its from line 39 :/
ima check the docs
event.name is the username
yep it was from event.data["name"] changed to event.name
you type faster then me :b
but thanks for the help
yeah at first I thought namme would just be undefined, but accessing "nick" on undefined throws an error
the console will show you those errors tho
Hi there! I am trying to create a resetting daily sub goal, or one that only shows that days subs instead of total (even if I have to manually reset it) Does anyone know how to get a goal that has that? Im trying to use a condensed meter under a frame to give the illusion of each daily sub filling a heart. Any help would be much apprechiated! 
you could try to use the session data and then reset it after the stream ends
That would effect the total sub count as well right? Session data is the same on all widgets?
that depends on what you want to display on each widget. But yes, that would reset the session for all widgets
ah I see, I'll do some more digging and see if I can fix both, thanks for the help!
are you trying to code your own goal or use the default ones?
Are there plans to reopen applications for API keys? Some developers would like to add StreamElements support who didn't get a key π¦
why from line 60 to line 65 all not working
line 59 is not erroring it gives the right output
because you again have event.data.nick instead of event.name
its a youtube message
youtube messages give other respeses
i have a template i made with help from lx
this is how a youtube message is getting sent
hm, okay. Yeah, I never worked with YT events and don't really know how they are structured
everything on the photo works
expect 60-65 lines
you can try console.log(plsProfile); to see what the value is
i put that after line 58
then the else should trigger
?
the value is not undefined so the else (line 63) should execute
you'll have to do some debugging then. We can't really help with that
ok i will try thanks for ur help
either use the browser debugger and step through your code or put some console.logs at different locations and see what gets executed where
ok
i found it but its weird
first 2 photos looks like its working
but the result (last photo) is not working
i got 1 more test
maybe the name is at that time not in the AllUsers array yet
i use the same array
but there a system in youtube that i wanna test
found the problem
then you say someone's full name in youtube it mention (highlight) the name for the person
so i think that system is breaking it cuz then i remove the full name this happens
which means it works
this is the highlight test
thanks Reboot0 for your help π
I have slightly reprogrammed some of Harris Heller's Alpha Rotating feed and am using it with an animation I made. The timing of the animation and rotating feed line up perfectly in the online editor and in the preview, but on the OBS Live app they are out of sync and I am not sure why. Could anyone suggest a reason/a way to fix it?
Are you using Windows?
Yeah
π€ it should be the same as the preview; ... it's just a browser source. Have you tried in normal OBS studio?
Yeah it's the same problem, it's just like the feed takes a couple more seconds to appear than the animation
is this for Twitch, YouTube or FaceBook?
For twitch
Did you happen to try it before you made the tweaks?
It shouldn't be a coding or SE.Live issue; if it's working in the browser ....
No, yeah I can't really think what the problem is
can you drop the code into a js fiddle? https://jsfiddle.net/
i'm guessing it's either a computer issue or OBS setting
Did you want me to send you the link to the js fiddle?
ya. then i can make it real quick and see if i have the same issue
Test your JavaScript, CSS, HTML or CoffeeScript online with JSFiddle code editor.
give me a minute;
Alright, thank you
I just put fields in under the HTML and the Data under that
Yeah, the problematic part is that it's not rotating in time with an animation I have, and I may have been wrong about it working in the preview I just watched it go out of time. Maybe my values for the timing are wrong but I can't think why
The animation has a 0.5 second slide in, it stays the same for 3.5 seconds and then slides out for 0.5 seconds before sliding in again
ahhh ya. you will want to add your animations into this code.
The animations were made in after effects, this might sound stupid but is that possible? π
i'm trying to see if it's a true timeout or timer based.
Hi there
...like if you spam followers... it gets into a queue so they don't all pop up at the same time
Ahhh okay
So is there a way to translate Stream Labs coding in HTML and CSS to Stream Elements?
I was given coding for Stream Labs because the person I was working with did not know anything about coding in StreamElements. the coding ALMOST works, but it just seems like there's just one bit that's not working
yes; the HTML & CSS are the exact same. (if it's not using injections like {username})
it looks like its it is on a fixed time. 400ms in; 2500ms onscreen; 500ms out
so you'd have to time to that; or adjust the number to match your animation
Any way I can show you the code? It works in Stream Labs, judging by the video he sent me, but when I do it on mine, the webm graphic that's supposed to play in the background does NOT play, and instead I just get this tiny black text in the top left corner that says {img}
That potentially makes a lot of sense, I'll try it now π
sure. drop it in a js fiddle https://jsfiddle.net/
Yep that seems to have worked, I feel kinda dumb for not noticing that π Thanks so much for your help π
π€£ we went the long road to get to an easy answer π
but at least we got the answer π
Like this? https://jsfiddle.net/fweojk8b/
Test your JavaScript, CSS, HTML or CoffeeScript online with JSFiddle code editor.
It's supposed to bring up a transparent black background behind the text. A webm graphic
I added that to the video in the top left in the alert, but it doesn't seem to call it
yup. that will work. ... but you should check out the default alertbox
Also, dude, if you could get this so I can change the font of the text that would display, I would fly over to your house and kiss your feet.
The default alertbox?
Is there a way to code it so that it plays what I added into this?
^ check out the alertbox ... i think you can get it all set up π
I'm afraid I don't follow you when you say 'check out the alertbox'
I don't understand what you're telling me to look at, and I don't understand what I would be looking for once I'm in it.
I've been struggling with this for the past few days, and the knowledge I've had about CSS has long since rusted beyond use at the moment.
check out the video i posted above ^
that is the built in stuff with StreamElements and is the best easy way to go.
I looked at it, but it was just showing about "Text delay sliders" at the timecode you put it on
Like, I watched for about 2 or 3 minutes, the dude was just playing with sliders in settings the whole time. He didn't even bring up any coding.
there is no coding. that's the best part you don't need to code anything. i didn't mean to time stamp; start at the beginning and go x2 speed.
Okay I think I know where the miscommunication is coming in
So I have the coding plugged in already. The text displays just fine. I have the video plugged into the alert box just like this, but the video does not PLAY.
Instead, I just get small black text that says {img}
Like this
It's a download link to a very short video I recorded.
If you look towards the top, kind of in the center, the {img} is there.
ok. thanks; ya; ... i was thinking something different.
It SHOULD show like this:
Also ignore the very blatant typo that I've already fixed in this man's coding
'subscirbed' 
hahah; i'm not a good speller. ... ahh i see it now. ... is there JS that goes with it? i only see HTML and CSS in you jsfiddle?
He only gave me an HTML and CSS
trying to figure out what goes here
Waaaiiiiit....
You think if I upload that video elsewhere and put the link in that 'src' tag it might bring it up that way?
Wait, that src wasn't in my code I sent you. Did you add that?
ya; that's what i'm looking for.... where is the image/video coming from?
even the {img} you have .... where is that from π€
Well I tried plugging it here
That was in between Line 3 in between the div tags. I deleted that because it was doing nothing but showing black {img} text on the screen
I apologize, I shouldn't have done that.
hahah. ya. that is where the "injection" is.
Yeah, the question is 'what do I put in the div tags to make it call the video I set in the alert box'?
if that's even possible
and that's where I'm stumped.
I don't think anything I put BETWEEN the div tags is going to make it call that video because it's just going to appear as text on the screen again.
look in the FIELDS tab for the image-input
in that image i posted; i'd change {img} to {mask}
Nah, it still just showed as {mask} in the top left.
no no; in my FIELDs tab i have 'mask' as my image input.
i'm not sure what the name of your image input is .... in your FIELDS tab
Okay, my 'Fields' looks like it's not even doing anything. I just see these labels like "someText" and "someTextField" and "someColor"
It doesn't look like 'Fields' is even being used in any way.
So perhaps it's an open slate to type in whatever you might suggest I should type in? And maybe then have it applied to the HTML portion of the code?
nope. there is an image-input there somewhere
ok delete all of that add replace with: ```json
{
"img": {
"type": "image-input",
"label": "Image",
"value": "https://raw.githubusercontent.com/pjonp/pjTestBot/master/modules/.SE_Overlays/chatterWheel/assets/demo1.png"
}
}
change the {mask} back to {img}
in HTML?
Okay so that did work, kinda.
Question is what do I need to enter in 'Value'
Like this?
ya. does that work now?
what is the HTML line that you have the {img} in?
I haven't changed anything from what you said.
I haven't changed the value yet
I'm not sure what I would put in
I have it back like this now. That's how it was able to show that URL in the previous screen shot I posted.
what was your original code with the {img} in it?
Everything I have coding-wise, I've already shown you
through that JSFiddle link
And I want to reiterate it's not MY code. it's code that I had someone pay to do for me, that he made for Stream Labs
there was no {img} tho
Right. I said I originally deleted that, but the {img} was originally right there between the div tags where you see it now
ok let's try* line 3? <div id="alert-image" src="????"></div> -> <div id="alert-image" src="{img}"></div>
Okay lemme go back
Right now
With the code looking like this right now
After applying the code you gave for me in Fields
It now shows THIS when I run it.
It's calling the value that was put in Fields
ya. cause that is the source; {img} is the picture url. ....
<img id="alert-image" src="{img}">
probably need to make that an image ... we rough coding at this point π€£
Replace that in line 3?
ya line 3 = that
lol
Now the question is what do I enter in value to make it play the video I have plugged into the alertbox?
Can't really see it, because it's against a black background, but the video itself is transparent with a translucent black background for the text to appear over.
wait it's a video background now?
in the FIELDs tab change it to video-input not image input
then line 3: <div id="alert-image"><video src='{{img}}' autoplay loop /><</div>
Sigh back to square one.
When I punched in that code, this showed up
WAIT
Tsk... nope.
Lemme see something
So now the code is showing like this
And the HTML is like this
But now it's back to just showing the text.
A new field popped up where it allowed me to plug in a video, but it still didn't do anything when I plugged the webm video into it
What I have circled in red popped up when I punched that code in. Originally it had no video in it, so I tried plugged the webm into it, to see if it would work, still no dice.
I'm sorry this is becoming such a hassle.
I just wanted one simple thing, lol
I wanted to make an alert for subscriptions that played out like what you see in this vid https://youtu.be/JpIZTGx3qw4?t=58
Hello, folks! view in 720p.
But I wanted it to say in the middle line "{name} just subcribed!"
ya. this code is upside down; and it's coming from Labs.
you got 2 <div id="alert-image-wrap"> .... which is no good. only 1 id should be used
(I also wanted it to appear in a font similar to what appears in that game too.)
I'm about to ask this fiverr guy for my money back lol
Paid him $15 for coding that doesn't work.
That took him a WEEK to have made for me
Here was the problem:
I know what you're about to say with that pic
There's a nuance to it that I wanted to emulate.
that doesn't happen with the basic alert.
Watch the clip again
You see how it spells out the message like it's being typed out?
That's what I asked him to try and replicate
That's where the need for coding lies.
oh.... you want that animation
Yes.
I even found a similar font face for it too
It was just like a basic serif font I was able to find in dafont
OldStyle Font | dafont.com
i'ma play with it for a few minutes.
^ i like that
I thought it was a good idea too lol
If I had known it would cause THIS much problem though...
All right, I hate to say it, but it's near 5 AM and I work tomorrow.
Is there a chance you could maybe DM me the code if you're still working on it?
I gotta head to bed
ya. i'ma play with it a lil more. but might not get the answer.
All right
i'm sidetracked; but i love dis
What's the best way for 2 widgets to talk to each other via websockets
What would be the connection url, if I have the widgets seperately and have them shared through the 1 click link
you need a server between them
What I am essentially trying to do is recreate the SE editing system for a OBS dock
and have the css data of the widget edited on websocket message
Well technically I can have the OBS dock use the SE API save and have the widget poll the API save for changes
But can we have the API save to emit events on save?
I'm pretty sure you can't save on client
onSave will automatically reload the page
that's not a real event-listener
Ah well that will do
but you can change an elements class or inline-css via websocket data
without editing the source code
you'll need a server with WebSocket support (NodeJS & socket.io for example), let the client connect to that via JS and then, depending on what should change, let the server listen for events, sent by the client(s). It can then just echo it back to all other connections, or parse the data and send it to a specific client
hmm yes I thought about that, but the complexity is something Im trying to avoid
One more thing, is there a hacky way to have the fields editor only as an OBS dock
that's the only way for realtime. You can just post data to a "normal" PHP server with a db and then poll on another client, but that needs more resources and is delayed
you can try putting the editor itself as an dock and make it so small that only the left side is shown
The css is in such a way that the left panel collapses after a certain min-width
....or
I could have the widget and the OBS docks as a local file
and have the OBS Dock write to a .txt file, send an event to the widget and the widget can read from the .txt
you probably won't have write-access on docks
actually no file-system access at all
Have the dock as a html file, not an actual C++ OBS Plugin
yes, but JS has no file-system access, only to files on localhost
I've had a look at the submit wiget, but since my alerts weren't made with custom HTML, CSS, JS - but they have custom video's made by myself, can I submit them? I'd like to share with clients, but few would rather not have to go through the manual set up. ideally do not not these shared with the discord though :S
That unfortunately is not a possibility
You would have to have them install manually, or share it for everyone to use
Share links are only for code gurus and the dream team AFAIK
But you could have your clients add you as a mod in their StreamElements, and you can set it up for them
that is an idea - thanks
morning
its my impression or is a week that the docs are off ?
there are another way where i can see them ?
hey guys has there been a query change for host data?
my host counter has just stopped the last week and im guessing there must have been a change some place.
oh, i think i found it here:
https://dev.streamelements.com/docs/kappa/api.yaml
Custom Variable types
guid - string that matches pattern: /^[0-9a-fA-F]{24}$/ (24 character hexadecimal string)
datetime - either timestamp in miliseconds (unix timestamp*1000) or string in ISO 8061 format
Global variables
`Authorizati...
So I was working with a guy last nighy to try and get some code that I was given to work with Stream Labs, and get it working for Stream Elements. He came tot he conclusion that essentially the coding was terrible and likely needed to be redone from scratch to get ot working with StreamElements.
I unfortunately know next to nothing about what to. type tp get what I want working. I understand how coding behaves and can read what it's doing when I see it in action, but that's the extent of it
I think there is a bug in the StreamElements bot. In the picture there is a command I made and the output. Shouldn't the value of ${user} be jhard9000?
${user} is the target if specified or the sender if not. If you always want the sender, use ${sender}
Is this more of a channel where people who already have decent knowledge on HTML/CSS just share small fixes between each other that they're not able to figure out themselves, or is this a place that can help out with newbies? Just trying to make sure I'm not like, out of line in what I'm asking for here or anything.
we can answer questions, but won't code full solutions for you
if you have a specific question, ask away
Ah. Kind of got a different impression from the website I came here from.
I mean I understanding programming is a valuable skill to learn, and honestly, I wouldn't expect someone to just do it for free. I'd honestly be willing to pay for what I want to have done at this point. Matter of fact I HAVE paid for it already, but the guy was not very helpful.
I'm just at my wits end with this, lol. I've tried Fiverr, I've tried asking around, and it's like no one is able to get this single idea I have working for StreamElements. Stream Labs, yeah, but not SE.
If this ISN'T the place to ask for something like this, do you guys at least maybe have someone/someplace I could go to that I haven't tried yet?
Yeah. Alert. Singular. For a subscriber alert.
and you have the full code and assets for that?
Well, I did.
But the person I was working with, basically explained to me that the coding I received was bass ackwards.
going from SL to SE at least.
I have the sound effects and graphics
even the font face I want to use
I mean, if you pay a guy on fiverr and he can't even rewrite a single alert, then he doesn't seem very qualified π
Yeaaahhhh he seems to only have experience with StreamLabs and not StreamElements. He stopped talking to me as well, just made off with my $15
if the code isn't too long and you're okay with that, you can just post it here and we'll take a look at it
Okay
I can also send you the revised code that pjonp had me try, that, unfortunately didn't work.
so it is partly ported?
This was the original code: https://jsfiddle.net/v9aghju7/
Test your JavaScript, CSS, HTML or CoffeeScript online with JSFiddle code editor.
This is how it looks now
Those are the changes that were made
Yeah I have a video. webm.
I want it to play the video. It's a video of a black, translucent background that should appear behind the text.
did you upload the video file to SE in the editor or have you only tried the value path?
since it is a field you should see a video picker in the widget settings
you can try
<video id="video-player" autoplay loop>
<source src="{{img}}" type="video/webm">
</video>
in your alert-image div
So just replace lines 2-4 with this?
Hey folks, sorry to interrupt the flow of your support thread. I was just wondering if anyone can help with a question I have about sharing Overlays?
Basically, I create custom stream themes and would like to be able to provide a quick link for someone to be able to import an overlay I've created. At the minute I'm having to ask people to give me access to manage their account to be able to duplicate an overlay into their account, but I've seen services like NerdOrDie and VBI using an import link, wondering if anyone has any idea how to go about setting something like that up?
Apologies if this isn't API related!
no, only the video part in line 3
Like this?
you need to become Code-Guru to have access to that feature. More infos here: https://strms.net/codeshare
yep
Awesome stuff, thanks for the info @tribal zenith !
Still no video -_-
if you go to your editor and press Ctrl + Shift + J do you see any errors?
Frankly though, I'm about done messing with this. I've been struggling with this for weeks; far longer than anything else I've worked on, and at this point, it's just not worth the time, money, or energy that I'm putting into it. I also am likely pestering you guys at this point when you likely have more important things to be working on/dealing with than trying to work with some rando who just popped in on day one asking for help with this. I'm just going to say 'fuck it' to the typewriter animation and just have the graphic appear with the text just fading in instead or something. At this point I'm just symbolizing the sunk cost fallacy. But I appreciate you guys trying to help, but this just isn't worth the frustration anymore for something as miniscule as this.
I think the CSS-only animation threw a lot of people off, but if you only want a left-to-right fade with a semi-transparent black background, then that is pretty easy to implement
Hm?
most alert animations are done with timelines in JS
I can PM you an example I used for an alert once
Sure!
I'm getting an error with the following code in custom commands:
${urlfetch json https://pastebin.com/raw/XXXXXX}
ERROR:
equestError: getaddrinfo EAI_AGAIN jsonhttps jsonhttps:80
$(customapi https://api.thefyrewire.com/twitch/pastebin/XXXXXXXX)
just wondering if any of the endpoints have changed with api update?
specifically the endpoint to query number of hosts for the session
Does anyone know if there is an escape character for Twitch commands/variables? Specifically trying to use ${random.pick} to randomize a specific list of phrases, but if there is an apostrophe in them I canβt use the apostrophe since single quotes are used to designate each pick. Trying to see if there is a way around it
@hoary juniper It doesn't look like it natively though. I'm taking a look at the API they're talking about above to see what could happen with that.
Cool, thanks for the info
Ok.
That specific thing above is what you want.
That last string at the end is what would be the end of the pastebin link.
Simply create something with each line holding a phrase and it should pick it randomly from there.
Ah, okay, thatβs pretty simple, I think I get how that works, thanks!
anyone about to answer a couple quesions at the minute
what are the questions? not sure if i know the answer
I think im querying the wrong endpoint...the data im getting back is for people I have hosted...want the data back of people hosting me
you might need to hit Twitch API for your current hosts
Ya; all i see is host-latest; but i've never used host tracking before so not sure if there is a way to check for all current hosts; my gut is saying that would be a Twitch call.
yeah same. thanks for your help
Hi, I'm trying to build a custom widget which embeds a short twitch clip on the overlay for a couple of seconds. However, seems like the twitch embed requires a parent to be able to properly embed the clip. I used streamelements.com as the parent but even then the clip doesn't embed properly. Seems to be because the widget is embeded itself in an iframe but the iframe does not share the same origin as the parent window (the overlay url itself). Is there anything I can do about this?
I was also wondering if there is a way I can test my widgets in a local environment without having to use the Custom Widget interface within the overlay creator (I'd like to be able to easily use my own code editor rather than the web one)
@fallen veldt ^^
Great! this answers one of my questions already thank you!
There is no iframe on the deployed version of the overlays
The code rendered in the overlay says otherwise
my custom widget is being embeded insided that sandboxed iframe
is there an iframe-blocker there?
I don't know, but from what I've been seeind, every single custom widget I ass is embeded inside an iframe like the one I'm showing here
there is a layer above the frame called iframe-blocker, so you would have to set .iframe-blocker { display: none; } in your BrowserSources custom CSS
OBS Browser Source Custom CSS
there's nothing with the class iframe-blocker in my overlay (from a quick ctrl+f on the overlay source)
I knew they removed it, but just to be safe
plus, adding css wouldn't have any impact on the iframe's origin regardless, which is my issue right now
I think tthe main issue I'm having is that the iframe containing my widget doesn't have the allow-same-origin flag
so when trying to embed my twitch clip, it simply doesn't like it because it is thinking that streamelements.com is not the origin for the parent window, it's simply undefined because of the iframe's origin
so I was wondering if there is a way to add the flag to the iframe, or if I simply am unable to embed twitch clips in the overlay due to this restriction
Iframes aren't supported in the overlays.
This is what I'm trying to use btw https://dev.twitch.tv/docs/embed/video-and-clips
f
Good reasons too.
abuse?
Wouldn't like if you were to get the short end of a really bad rick roll.
what? people use iframes for rick rolls
Not if they wanna do
kind to you.
haha yeh it would be a securrity risk, I get it
ohh you mean the recent clips can contain bad stuff
nono
if you use an iframe you can attempt to do an atttack by injecting malicious code
π€¦ββοΈ
Both visually and code wise.
since the overlay includes sensitive data, it could be used to "rickroll" by say, showing this sensitive data on the overlay for example
so I kind of understand it
this does answer my question
it's what I suspected but wanted to be sure
You may want to check this for clips: <#widget-share message>
with that said, is there simply no way of embeding a twitch clip on my overlay? (given the official twitch api uses an iframe)
Hey guys! Is it possible to share streamelements overlays? I would love to create overalys for a friend of mine without needing his account information
I don't think this will fit my needs,, I'm doing a lot more on my widget, the clip is just a "small" part of it
@tawdry oyster ^^
That is unfortunate! Thanks a lot
Although, you can ask to be a mod in his SE, and set up overlays for him
"Follow these steps to grant managers/moderators access to your dashboard:
- Click on your channel name at the top of the dashboard
- Create a new invite at one of three access levels (Bot Supervisor, Editor, Full Control)
- 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"
And due to iframes having no origin it enforces more safety, like iframe injection. Every custom widget is sandboxed that way.
Good Idea thanks!
nah I get this. I was thinking of maybe just trying to embed the video in a url in my domain and then embed that url in the overlay but I'm guessing what wouldn't work either due to the same no-origin iframe
I'm legit just trying to figure out a way to eembed a twitch clip without using an iframe at this point
since the clips themselves are blobs and encoded I'm not sure I'll be able to do so π¦
Oh, so the widget above embeds clips from twitch by extracting mp4 URL from it and using video tag.
ahhh I see... Is the source code for that widget avbailable somewhere? or could I only see it by isntalling it and looking at it?
For the particular widget he linked click the widget layer then settings. Open in editor.
oh I see, I think I clicked in the wrong widgeet earlier that's why I thought it wouldn't be useful, I'll have a look, if it does it via an mp4 link it will defo help me!
tbh my widget is still quite simple, it's like Awesome Shoutout but with clips instead of just profile pics, and since I onl;y need it for twitch, it doesn't need to be as big as AS
I just created a horizontal chat overlay and need some help to see if this is possible. I basically recreated MrBoost Twitch's horizontal chat and got it working for YouTube. Running a stream right now and it's working great. The only thing I am not sure i we can do or not is add badges to the users. I have a feeling it's in the JS field, but not sure of the YouTube nomenclature versus Twitch's, i.e. it was written as "service: "twitch" so I changed to YouTube but nada. (also, new to streamelements, so I'm sure there are some other things I'm missing....but it works!)
so i added a sub/follower bar to my overlays, but for some reason the bar color isn't changing when I do it, how can I actually do that? is it in CSS? or another way
instead of it fading into another color i just want one solid color
so you created your own widget? Or did you use one from the widget-gallery/share?
it was one directly off stream elements
its the goal widget
okay, that should have 2 color options. One for the background and one for the foreground
mine shows 3, gradient color 1 2 and 3
oh you meant the Advanced Goal Widget
yeah, the gradient colors are only for the name above, not for the actual goals
maybe @broken coyote wants to change that, but he is probably busy with other stuff
@unkempt parcel my sideway chat worked with YT. All you would have had to do is duplicate the twitch verison over to YT
ok, so how do I make the sub and follower bars one solid color and not fade in?
They don't fade in, it's a gradient
I'm not at my pc currently, so I'll look into it
It's an image. if you have Photoshop, you could edit the image to only have one color
Guessing that's what I ended up doing. The only thing I haven't figured out yet is how to get the YouTube badges (if there are any)
The bar going from purple to red, im trying to make it solid red
I don't think SE grabs that information. Not 100%, I just started multi streaming and set mine up to show badges per the service they are watching on
@dawn kettle you can just change it in the css to be a solid
Many thanks for your contribution. I'm new to SE, but your widget is one of the reasons I wanted to crossover. It gives the stream so much more real estate.
Glad you like it! I've worked on getting but going with SL. but haven't had much luck. I also though, haven't messed with it much
I thought that might have been the case, just wanted to make sure before I went messing with stuff
which line is it?
@dawn kettle I honestly don't know off the top of my head
I got it working on StreamLabs, but their service, as a whole, isn't always reliable.
If you want my HTML/CSS/JS for that solution, let me know. It's on my website.
Sure! I'll take a gander. What's the link
https://djlefave.com/horizontal-chat-in-obs-slobs-for-facebook-page-twitch-or-youtube-live-chat/ You technically can do this without adding the JS as well. That just adds additional rows of chat.
Ah yea. Fairly simple. It's just grabbing log and dumping it in a new div because SL appends chat messages
For what it's worth, I dig your solution better π It's what started my adventure of trying to figure it out for SLOBS first, and now having it in SE. I was able to do it today during a stream and was messing around with some stuff, like using an OBS Shader Filter to make the username RGB animated. Still need to finesse that, but there's potential.
Nice! Yea SE is alot more "free" to work with. Biggest reason I mainly use ut
Hi all, hopefully easy question: when retrieving an audio-input is it possible to get the original filename it was uploaded with?
what are you trying to do
I have a list of items that i need to match to audio files. Trying to find the simplest way to add the audio files. The length of the list can vary, so it wouldn't be ideal to have a separate field for each audio-file. I was thinking I could use an input with multiple, then match the filenames. Alternatively, if there's a way to look up the uploaded file using its original name that could work too.
Hello! I have some questions towards bot capabilities and api requests. I have build a small vote system for twitch/redbulldk, where people can vote on various scenarious for their flick competition. It appears than when a vote start and viewers start using the commands, it registers about 120-140 messages and then the bot just stops responding. I have a text-return on all the commands, but nothing is returned.
Any limitations or something to be aware of?
Edit: Please mention me on reply so I notice it
Hello, looking at detail.session.data["subscriber-goal"].amount seems to be set to value, but I don't know nor can I find where that value is being set. Any idea where that would be set?
Hi. Is there a way to use IF statements on the chat bot commands? E.g. IF ${user} == 'blablabla'
Hi, when emulating an event of host in the overlay it works...however when I run a host on the channel when its live I am getting no event dispact..Any ideas
I am checking if obj.detail.evet.type === "host"
"Due to changes to Twitch API, we have filtered out hosts and will only show these ones on your activity feed:
- All hosts coming from an online channel with at least 1+ viewer
- Auto host events with at least 1 viewer - only from a channel that just went offline
Note: If you see X channel has hosted you with no viewers on the back, that is considered an offline host or a host with 0 viewers, we do not show these."
This is the requirement for hosts to trigger with us.
so the channel hosting has to have at least 1 viewer?
thanks
that sounds like a raid to me
Β―_(γ)_/Β―
it is what it is I guess.
does stream elements output a message to chat regardless of the amount?
or is it just the above
Only if it fits the above requirements if you mean the chat alerts.
damn unsupported endpoint it is then
okay thanks sudo
was this a recent change or has it been that way for sometime
A while.
okay. never had a situation where it mattered before...Thanks for your help
Why does it say I cannot apply for OAuth2
@lofty moss OAuth2 access is granted for 3rd party companies only on direct request. There is currently no possibility to obtain OAuth2 credentials for personal projects.
@kind hornet Make sure the overlay is loaded. Also maybe for possible options the best is to use "quickpoll" widget
oh ok, ty for info
my overlay is from #widget-share autopoll
and i did what it said when i edited it
Checking it rn
Oh. Autopoll is not like that. It is live all the time and it accepts votes with defined starting character, so chat can type whatever message #option and option will be counted
I think you were looking for this: <#widget-share message>
With that I think you can do !startpoll question|answer 1|answer 2
You should add the overlay to your OBS
Click "preview" in top right corner of overlay editor, there you will have URL you have to add to your OBS
Hello Styler, can I request an oauth token like this?
@kind hornet This is expected behavior as overlay doesn't store data, so you need to add it to OBS and then start a poll.
Copy the URL of that preview, and add it as browser source in OBS
Also - Your OBS seems to be bit outdated, current version is 26.1.1.
works pog
Depending on what you're trying to achieve, this might be able to help you - https://thefyrewire.com/docs/api/twitch/pastebin/#return-filtered-lines
Apologies if this question is too early in the development process for this channel, I can delete it otherwise, but I am planning out an overlay element and I'm wondering if I can achieve what I'm imagining with StreamElements or if I need to look to another toolset.
To suit a channel theme, I need to make an "event list" like element that displays the most recent events not as a line-by-line list but as randomly placed graphics within a given area, somewhat like a scrapbook or collage
I suppose I'm most worried about the StreamElements API's ability to manage the variables and dynamics of X-Y/Rot and perhaps even various images per event over multiple graphical entities since most event lists are, well, lists with a predicable appearance.
Any insight would be greatly appreciated
Anyone?
Of course, you can prepare an area and provide different spots for each event as inline top/left/rotation CSS
Hi. Is there any way of extracting segments of a variable? Like if ${title} gets the title, is there a way of grabbing the 3rd word of the title, for example?
Hello i'm not sure its the right channel for my question but i cant find any other place, i want to upload an overlay to stream elements overlay and it's only accepting mp4, yet it seems mp4 doesnt support alpha layers(or it does with a certain codec but i have no software for it), so i'm wondering how is everyone doing video overlays? I tried many other things but i'm stuck, my last solution was making a png sequence with after effect, then converting that to a .webm file, wich works fine but the only software converting this is now asking me to pay for it, and it seems u need to be coding to convert that, wich i have no idea how to do, can someone help? thanks!
What software are you using to make the video? Most modern softwares have webm exports, which natively support alpha layers (ex. After Effects)
For streamelements widgets, does data["subscriber-session"]["count"] include resubs as well or only new subs
getting a 404 error for loading something from https://kvstore.streamelements.com/v2/channel/accountID/alerts I am not trying to load anything at the moment...any pointers as to what this is?
Hello guys, I'm doing a StreamElements SongRequest extension for LioranBoard but the api docs are down for almost a month...
Anyone knows if streamlement's api are working?
I'm trying to check this doc https://docs.streamelements.com/reference/songrequests but somehow all the docs endpoints have this message This endpoint's documentation is currently experiencing difficulties and will be back online shortly.
@civic oyster New link in channel topic.
@hardy walrus oh nice! thanks, it's working! I've just joined the channel so I didn't know lol
Fair enough. It was recently "changed" anyways.
just another quick question...
It seems that the old docs had a reference for an endpoint to list the users on a channel, but I cant find any reference for this on the new docs, is this endpoint deprecated?
Also, anyone knows if there is any endpoint to get the current online viewers on a channel? I've looked on streamlabs, twitch and streamelements api but couldn't find it
It might be under the "Others" section which is 
yeah, I was looking under the Others section, buut somehow it seems that this section only includes docs for components and schemas, not paths
I'll leave that for @viral patrol since he's our resident APi middle man.
I thought of scavenging the twitch page to get it but I found that the "users" section on twitch sends a list of chatters (not of viewers) so I'm not sure how the page gets the updated viewer count
but thanks for the information!
sends a list of chatters (not of viewers)
That's because there's no way to tell who is actually viewing since you can be logged out and still watching the stream.
my current goal is basically to create a bot command to check if the next song requester is online at the moment...
if the requester is online it plays the next song, if it isnt skips the next song on media request....
exactly, but on the other hand, the chatters option shows a lot more users than the current viewers
I was personally using twitch directly: https://discuss.dev.twitch.tv/t/how-can-i-get-chat-list-in-a-channel-by-api/12225
And this is right - there's no way to get viewers, only chatters.
Because there are multiple ways to be in chat. Not all require the video to be showing.
And you can watch a video without being a chatter (like when you are on channel that is hosting)
yeah, also it seems that muted viewers doesnt count as a viewer, but they can be chatters
I'll try to check what is a chatter and see if I can use it as a condition to play or skip the next song request
thanks for the help guys!
FYI there's a slight delay when recognizing users who are in the channel. Not entirely "instant".
humm this makes things a lot more complicated LUL
but I think that it makes sense to have some type of cache on the twitch chatters, and since they use graphql for that it's easier to create a cache on this request
I've been trying to make this code work for ages now... at the point of giving up. it doesn't seem to understand what I want it to do.
$(customapi.https://script.google.com/macros/s/AKfycbxG7v5CQVthjv_rueqOB3m51agsYWurA3qUJRiRFcI42rnOh7WZ/exec?input=$(queryencode $(1:))&user=$(sender))
by the way when i paste the link in my browser it does give me the right response, but its not pasting in chat? the code thats in Google Script is:
var input = (request.parameter.input || "").trim().toLowerCase();
if (input.includes("nothing")) {
return ContentService.createTextOutput('you need to give me something to do!');
}
else{
return ContentService.createTextOutput('thanks! This will get done later (hopefully)');
}
}```
btw I do get that the person needs to type "nothing" for it to get that..
@dusky prairie I pasted that as a command as I do get responses back (though I don't know if they're the right ones). If you use the $(1:) variable in the command then it will always require a parameter to trigger. Otherwise you can use something like $(1:|'nothing') to have the input default to nothing if the command is used alone
It might have something to do with authorization within google sheets
in the browser it does work for me, so I'm really just guessing what the problem is, why streamlabs is not pasting it to my chat. I will definetely edit the command to use the parameter.
it works now!
So I have been changing the code so the user gets mentioned in chat, however it pastes $(sender) in chat instead of the actual name. so the code in streamelements is still the same:
$(customapi.https://script.google.com/macros/s/AKfycbxG7v5CQVthjv_rueqOB3m51agsYWurA3qUJRiRFcI42rnOh7WZ/exec?input=$(queryencode $(1:))&user=$(sender))
the only thing changed in the code in google is the return value:
return ContentService.createTextOutput("Hey ${sender}. Welcome to the stream! I hope you enjoy it.")
any clue why?
The ${sender} part of your string isn't being replaced by anything. Capture the sender query-string param as a variable in the script, then replace the quote marks with backticks to use it as a string literal to place it into your string
function doGet(request) {
var sender = request.parameter.sender;
return ContentService.createTextOutput(`Hey ${sender}, how are you?`);
}
Doesnβt that already happen inside the customapi using user=$(sender)
(in your URL you've assigned the sender variable to user, so you would need to capture it with request.parameter.user)
If you check your original script you'll see it's doing the same for the input
Could I paste it as output(βHeyβ+user+β, welcome to the streamβ)
You should be able to yeah. String literals just look nicer lol
But I already have a function for input setup
double check your quotes aren't doing anything weird, they look slightly slanted so not sure if the editor will get thrown off by that
I'm not saying to replace your function, I just gave you an example of getting the user 
I see, I just don't understant quite yet how to implement that in here since theres already a function
I'll try to set the return value to ContentService.createTextOutput(βHeyβ+user+β, welcome to the streamβ)
and edit the streamelement command url to user=$(user)
Maybe if you describe the functionality I can just give you a complete example?
So basically I want the bot to be able to response a lil bit into context
So the command would be called by keywords using βstreamelementβ as recognition of my chat talking about it or to it
Then it would recognise some words im setting for the include function
so for example:
var input = (request.parameter.input || "").trim().toLowerCase();
if (input.includes("hey")){ return ContentService.createTextOutput("Hey "+user+", nice to meet you!"); }
then continue the list with
else if(input.includes("keyword 2")){return ContentService.createTextOutput("response 2");}
else return ContentService.createTextOutput("I did not understand you");
nvm now it doesnt understand what user is. xD
This is because you haven't defined what user is haha. If you define it, it'll know.
function doGet(request) {
var input = (request.parameter.input || "").trim().toLowerCase();
var user = (request.parameter.user || "");
if (input.includes("hey")){ return ContentService.createTextOutput("Hey "+user+", nice to meet you!"); }
omg it works, thank you so much
Hi, how can I make a button that says live when im live on twitch like the visualsbyimpulse.com website
What is the best method of inserting data into Stream Elements overlay elements? I know I heard there was an API but I am not sure if that is a "get" only API endpoint, I was interesting in having a Python bot and pushing text/image information into Stream Elements when various events are triggered
is there a way to have an input field with a dynamic number of colorpicker input fields? usage would be for n number of colors in a gradient
or at least a way to show fields based on the value of another field?
Does anyone have a good basic guide to making a sub goal that changes animation when someone subs? (I can handle the animation part, just need help with the coding)
Hi guys. My widgets using SE_API to store data stopped working. I can not store data. Is something changed?
You would have to poll the twitch API to see if a channel is live, or if there's an event sent when a channel goes live, you could listen to that
^^ use pubSub to get the 'online' & 'offline' events from Twitch.
negative. would be awesome but the field data is read only from what i recall and can not be dynamically changed.
π€ .... getting the same issue
how do i add a custom thumbnail to my widget?
hey guys, im new here and am familiar with css & html, i want to edit the visuals of the goal bar & hypeboss but cant seem to find where i can edit its css, any resource for people just starting out? i cant seem to find any through google
Not sure about goal bar, but hypeboss doesn't have custom css options yet
oh, for goal bar ive seen people have real nice ones but i dunno where to start, if only there was a edit css function in the goalbar widget that wouldve been easy but what i heard is i gotta build it from scratch in the custom widgets and i dunno where to start
@gloomy sleet The only way is to write own boss from scratch with JS (it is possible). And about goal bar - there are several goal widgets on #widget-share and they are fully customizable
i see, do you guys have a resource on how to do a custom widget form scratch, maybe i can manage to make the widgets by experiencing doing a simple one from scratch
hi got anyone the api for custom? here i search endloss lol best way command for dashboard
thanks <3
quick question for anyone who can help me, I am looking for an almost automated way to give out loyalty points triggered by a command for ex. !checkin would be the command to give the command user 50 loyalty points... any ideas?
Hey everyone, I had a question I was hoping someone could answer. Is there any way to require a variable, such as ${args.emote} to be entered before a command is executed? I ask because I changed Kappagens default settings so users could type !showemote followed by an emote, and it would display. The issue is someone discovered if you type !showemote but instead added a negative sign followed by a number, it would display a random amount of the specified emotes. I wanted to prevent that from happening. I already tried limiting the emotes through the default settings available. Thanks.
Hey, is there something I can do to make the redeem command to be triggered in the regex function?
Looks like they updated it this morning. It should be working now; the response has changed from text to an Object.
take a look through #widget-share and you can see/edit the code for one of those. There is also gitHub with some you can use for examples: https://github.com/StreamElements/widgets
you want viewers to be able to use the command to add points to themselves?
you can create a custom command with ${redeem ITEM} and set it to trigger with regEx, that should work
Nice
How do we edit the code in widgets from widget share?
if you go to the Settings then 'open editor' it will show the code
Thanks
it shows twitch alert data for youtube channels
ex: youtube doesnt have subscribe tier
other ex: youtube doesn't let you put a message then you subscribe
that is the SE object; i haven't played with yT or fB but i'm guessing those will both return '' empty. or 1000 for the tier (since there is only 1)
correct; data["subscriber-latest"]["name"] - Name of latest subscriber https://github.com/StreamElements/widgets/blob/master/CustomCode.md
hi the points api is working ?
i want to get the leaderboard of watchtime of my channel but it seems to don't work
I have a marathon timer and I want to set up an alert that shows by how much time the timer increases. So for example if someone gifts 4 subs, it increases by 4*20 = 80. Is it possible for Streamelements to automatically calculate the time increase, or do I have to make a variation for each number of subs ? Reposting because I got the wrong discussion
here is the link : https://api.streamelements.com/kappa/v2/points/280481419/watchtime
.
on the dashboard it appear but when a get the api here is the response :
{
"_total": 0,
"users": []
}
@flint shore Your channelId in URL doesn't look valid.
I should be [a-f0-9]{24} string
@dark river If you create a sub variation custom coded you can use a value that is basically parseInt({amount})*timeToAdd, but it is not possible with default alertbox to perform calculations within default alert message
oh wait there is a special stream elements channel id ?
where can i find it
nvm i found it
tysm
So, I can't do it with the normal SE alertbox, but if I create an alert from scratch, I can ? Just so you know, I have never touched the codes, so I don't understand everything
As a one time check in command... the cool down will be set very high
I have found a work around how ever the addpoints command keeps saying cannot find user in my chat which is weird because I can give points
@elfin arch
Ok. This is my last stop. Is there already or can there be a widget that dynamically updates based on the Twitch Stream title and game? I want this title for a specific overlay im building and will not be wanting to update this manually each time.
I have found nothing that pulls the stream title anywhere, and i think it needs to be a custom widget but i have not the faintest clue on where to start. I thought that this type of label would already exist.
I think there is one
Did a quick search of #widget-share and couldn't find one, found one that pulls the game/directory though
As a quick solution to this I modified this Game title widget from #widget-share - Just switched the game API for the title and deleted the lines for getting the boxart.
Not set up to share widgets yet, but these are the changes I made in the editor for that widget:
Replace the first function loadXMLDoc() function with:
function loadXMLDoc() {
var url = `https://decapi.me/twitch/title/${channelName}`;
var xmlHttp = new XMLHttpRequest();
xmlHttp.open("GET", url, false);
xmlHttp.send(null);
var res = xmlHttp.responseText;
document.getElementById("twitchinfo").textContent = "{{titleDropdown}} "+ res;
var title = res;
}
I deleted the first two fields (image options) as well since these changes will obviously break the boxart part of this widget. Everything else seems to work fine though.
Hello all... Can you tell me how to make the command "https://api.streamelements.com/kappa/v2/chatstats/$ {user }/stats?limit=" display the number of messages of a certain user?
is there a quick way getting the acces token?
I just need it once and dont want to implement a complete auth flow
${user} ${urlfetch https://api.streamelements.com/kappa/v2/chatstats/tornado_522/stats/chatter?nick=${sender}&view=$(queryencode "{name} nickname and {amount} number of messages")}}
what I did wrong? I do not understandπ«
hey guys, on the onEventReceived event Listener is there a way to differentiate between a subscriber event and a gifted subscriber event? Both values come up as "subscriber-latest".
window.addEventListener('onEventReceived', function (obj) {
const listener = obj.detail.listener;
const data = obj.detail.event;
if (data.listener === 'cheer-latest') {
state.type.value = "cheer-latest";
}else if(data.listener === 'tip-latest'){
state.type.value = "tip-latest";
}else if(data.listener === 'subscriber-latest'){
state.type.value = "subscriber-latest";
}
$(".listener").html(listener);
});
case 'subscriber-latest':
if (event.amount === 'gift') subscriberHandler('subGiftHandler', event); //single gift
else if (event.bulkGifted) subscriberHandler('subBulkGiftSenderHandler', event); //bulk gift sender
else if (event.isCommunityGift) subscriberHandler('subBulkGiftRecieverHandler', event); //user recieved a bulk gift
else subscriberHandler('subDefaultHandler', event); //normal sub
break;
this is what i have in my boilerplate but never finished testing it
thanks! ill try something like that
I believe that covers all the options; but didn't get too far into testing it. Basically there is a 'single gift' and that will give the sender and receiver
then a bulk gift sends a bunch of data; the first object it sends is the sender, then it sends all the receivers immediately. (so you will want to queue/handle them)
where is the subscribeHandler functio coming from? do i have access to it anywhere?
no; that is part of my code to handle it.
ohh ok i see
sometimes it's tricky with the @ in a users name. and depends on the work around. I was going to suggest using a middle ware like jebaited (but you can't really edit the response with that). and if you do go the ${custom.api} ruote double check that it is not showing the command on your public command page! otherwise people can just add all the points the want π€£
im using a seperate bot to actually run a chat command that triggers the addpoints command.. so i suppose it works lol! thank you though
ahh ya. that would work too π
anyone know how to create a custom command like !hot > Response > Myname you are % $(Randomnumber) so it would look like Myname you are %50 hot today?
RandomNumber would be 1-100
${1:|${sender}} is ${random.1-100}% hot today
thank you @elfin arch
and if i wanted it to be the broadcaster's name it would just be Hostname is ${random.1-100}% hot today
that looks for an argument too; but basically the same; i.e. !hot potato -> potato is 42% hot today
yup. or use ${channel} but either way would be the same.
okay sweet
Does anyone know how you would go about creating a widget that would display a user-selected emote and could cost loyalty points? Kappagen doesn't offer it through commands, so I was hoping to try and either find a widget that offers that type of function or create one.
would go through programming it tbh :Z all docs u need are located in the description of this channel. U can also head into #art-marketplace if u want to pay someone for it @short bobcat
Am I able to send custom websocket events to my widget? For example, I have a dockable window in OBS where I can press a button and my overlay can react to that?
Since dock and overlay are both clients, you can't send messages between them without a server as relay. if you've got your own server with WebSocket support you can just listen and emit from there
I was more wondering if I can do that through this api https://dev.streamelements.com/docs/kappa/docs/Websockets.md
In the example there's an "event:test" (not sure if this is just for example sake), I don't seem to be able to apply for an OAuth token to test it
After gaining the AccessToken make sure to pass it in the const in the JS bellow.
That gets triggered when you emulate an event in the editor. With OAuth you are most likely in server-land and from there you can emit your own events, sure
the code of this widget might interest you then: #widget-share message
Okay cool, I'll take a look at that. Thank you!
but again, you'll need your own server for that π
Yeah that was my next approach if there wasn't an out of the box solution haha
Hello, @viral patrol What's up?? I would like to ask you a question about Bot Trivia ... is there any command for the follower to see the amount of points he has so far? And do I have the possibility to reset these points?
@mild cipher Is the replay widget in #widget-share newer than the one on the website in the library?
Hi hello - hope I'm posting this in the right place! I'm hoping to find someone who can help me with a semi-custom widget. (Basically I want a goal bar similar to Annedorko's, that counts subs and is vertical rather than horizontal.) The commissions channel seems to be mainly designers, and I'm looking for a coder! Thanks!
You can find my widget in #widget-share and with a little help convert into a vertical bar
Or scroll up in #art-marketplace, should be a few from code-guru's
Hi there! I was wondering if there is a tutorial for how I could start making my chat messages on Twitch appear like this? I understand that it involves coding and graphic designing, but I'm unable to find a starting point for how the code might look or how to set it up! I would appreciate any help possible!! Thank you in advance ^^
CSS HTML JS, if u want to understand the coding "mind way" u can also learn python basics just for forming some programming knowledge (pretty optional) @trim umbra
Thank you for your reply!! Hmm, I was hoping there might be a basic coding template that I could use and substitute the values I would like to change, but I'll try to make the code from scratch. Many thanks!
#widget-share message u can start from this, but not like this "substitute the values I would like to change" u will need to learn CSS HTML JS to reach that print u sent. ALSO the designing skills >i guess< (probably PS) - but tbh i think it graphic part is all made in code too
Thank you for your insight and linking me to a starting point!! I'm excited to get started now ^^
you can try https://dev.streamelements.com/docs/kappa/api.yaml/paths/~1bot~1commands~1%7Bchannel%7D~1public/get. i haven't used these bot endpoints but it should be one of those.
@still marten @elfin arch work well thanks and come good in community lol
also
got you a idea why ${random.chatter} so clean used often times buggy is?
how do you mean it is buggy? I don't use it. is responding with like 'no user' or the same one over and over?
I was wondering if there is a way to put my StreamElements bot for following . For example IndianaMatrix is now following we have now have 409 followers. Is there a command to do that with the bit chatting in the chat ?
I am not sure if it is possible to add a variable to a alerts bot module, but you may try ${channel.followers}. List of variables can be found here: https://streamelements.com/dashboard/bot-commands/variables
I done that but it didn't work.
how can I get this parameter?
I am trying to get the follow count on chat that my bot will send in chat . Also the same with the views. Will this work hear is a picture ?
looks correct, test it out in your chat
I'm new to this. Is there anywhere to test my js code without having put together my css and html already
How do I test it in my chat? I never got able to do that? How do I test I out in chat ?
did you have people talking in chat? i've seen that happen a couple times but only when there is no chat going on
that is your channel id from the dashboard
Please provide your account ID found at the top of this page: https://streamelements.com/dashboard/account/channels This ID is public info and safe to share here.
^ you can get it there. don't need to post here.
you just type the command in your chat. For Twitch it works offline; i'm not sure how to test for yT or fB
Put in console.log in the places that you are looking to test/pass along to the HTML and check with the browser console.
this works for widgets?
yup. it will log to the browser console so you can check stuff as you need
darn okay, i see my issue, im twist my brain wondering why something wasn't working just to find out that streamelements is blocking it. I am trying to use last.fm api to create a music widget but it looks like their api isnt https, any workaround?
i'm not sure; have you tried using https:// for the calls? are you using "fetch" ?
i'm not familiar with the last.fm API
It using $.get(URL, function (data) { etc
And itβs throwing an error saying the url must have https and itβs http protected and when I replace it with https nothing changes
let timeToRefresh = 60;
let channelName;
window.addEventListener('onWidgetLoad', function (obj) {
channelName = obj["detail"]["channel"]["username"];
getData();
setInterval(function () {
getData();
}, timeToRefresh * 1000);
});
function getData() {
$.get("http://ws.audioscrobbler.com/2.0/?method=user.getrecenttracks&limit=1&user=KibsKelble&extended=0&api_key=REDACTED=json", function (data) {
console.log(data);
});
}
this is the entire code
if you go to that link directly is there a JSON response of some type? and will it work with "https" ?
Yes
i'm struggling with the jQuery get request
couldn't figure out the jQuery so i went to my normal way of fetch; try this @mighty saddle ```js
function getData() {
const dataSource = https://ws.audioscrobbler.com/2.0/?method=user.getrecenttracks&limit=1&user=KibsKelble&extended=0&api_key=REDACTED&format=json;
fetch(dataSource)
.then(response => response.json())
.then(json => {
console.log(json);
})
.catch()
.finally(setTimeout(getData, 10 *1000));
};
window.addEventListener('onWidgetLoad', obj => {
getData();
});
Okay thanks
Hey guys, I checked the code for a way to add a maximum of characters to read out by tts. (my main goal is to cut of cheering messages after X characters)
I found the textToSpeech-function in the app and it's looking up the minAmount property of the tts-object: https://dev.streamelements.com/docs/kappa/api.yaml/components/schemas/Tts
If you'd add another property, like maxCharacters, you'd be able to cut off all exceeding characters in this function using substring or whatever before building the tts-url.
I assume that this function is the appropriate place since another value (minAmount) from the tts-object is already used there.
In the UI another input field must be added to the tts-config-view to be able to set the character limit.
It would be great if you could add that.
that is not a bad idea. i'm not to familiar with the TTS too much but i believe that min is the value for cheer/tip not the text length
Yep you're right and that's why I suggest another property. minAmount is checked before reading the message to check if tts should be played at all.
If yes, the message is saved to a variable which is later checked against the spamService.isSpam-function.
Before that, I'd add a check for maxCharacters and if it's > 0 I'd use the value to (potentially) shorten the message.
I'm sure if there is no message attached then it won't get sent to TSS. There is no option for a min amount; so a TSS can be just "a". The max amount can be set, kind of on the tipping page with max message length.
Yup there's a check if the message is empty. If yes, the tts function will log "TTS: skipping, no message was found" and exit the function.
I am not sure if this length also filters Twitch subs
To clarify, this proposed option would be used for the alertbox overlay in the tts-config-settings
For like a sub message?
Or a cheer message
By adding the suggested property and using it in the suggested location would open up the possiblity to add this character-limit-option to every component that is using tts.
Yea exactly
right above the highlighted line
I think it is a good idea. and yup 100% that seems like it would work to me (but i'm not sure on all of the back end and how it all connects)
I will pass along to dev's in a couple days (if i do it now on Sunday it'll get buried π€£ ) .... but if you can submit to the ideas board. If it gets enough upvotes then it will get more attention π
That function is returning a link to the actual tts-audio, I dont think it'd impact/break something else, but idk I can just scroll through obfuscated code
Check out the StreamElements ideas board: https://strms.net/ideas. You'll be able to add ideas, upvote ideas you agree with and track their progress with email notifications. Adding and upvoting ideas also helps the staff know which ideas should be prioritized so please take some time to upvote.
Where can I fand that? Thats not a channel, right?
correct. that is that link above. it's a forum for ideas
LUL I just noticed, yea thanks π
π€£ yup and when you post there it will send it to the #ποΈ±feedback-and-ideas channel π
Hey got a question for Cocahh's boxed chat. I would like to know if it's possible to get the message background to randomly choose between specified colors? I've made the field for an alternate color already, just not sure if it's possible to implement this idea or how to do it.
you can't do it in the CSS; that will load when the overlay is started and be a fixed value. You would need to control that in JS. You could have different CSS classes ( .bg1 , .bg2 ....) or just style randomly
Ah okay, I'm not too well versed in js,but I'll look to see if I can find something that will help. Thank ya ^^
Look at this example, its just simple JS @gaunt cedar
https://codepen.io/YuvarajTana/pen/RNZjjr
@sturdy oak Ah thank you, I came across that line on a different site. gave me confirmation I was looking at the right one
This site example actually makes it easier to understand how it's connected, thank ya much.
Phew took me a while to phrase it. Could you check the text for missing information if you can spare a minute? If not, no worries, you guys sure have a lot to do. 
will do; ya give me a few. and thank you for the idea!
so i'm creating a widget that uses user messages and emojis, and i noticed a bug, not sure where to report it but can reproduce it with this:
window.addEventListener('onEventReceived', function (obj) {
const { listener, event } = obj.detail
if (listener !== 'message') return
const { emotes } = event.data
console.log(emotes)
}
if you send a message with emotes, you'll notice that if it's a twitch emote (no issue with bttv/ffz), urls 1 and 2 are the same, both ending in 1.0, when 2 should end in 2.0
can you give an example twitch chat to test? :π€¦ ... i'm not great with emoji
sure just type PogChamp in chat
π€£ .... i was trying to set that up and it couldn't read chats and it broke everything "onEventRecieved" is misspelled π€£
oh woops my bad