GroveStreams
crevicedweller private msg quote post Address this user
What are the rules for streamId names?
Can a streamID name contain spaces?
Post 1 IP   flag post
MikeMills private msg quote post Address this user
Stream IDs can contain any characters including spaces.

Some of our public APIs allow the ID to be a part of the URL so keep that in mind if you use URL reserved characters as part of the ID and you want to use the public API. URL encode the reserved characters.

API:
https://www.grovestreams.com/developers/api.html
Post 2 IP   flag post
crevicedweller private msg quote post Address this user
I can't make a streamID with spaces work and need to for an existing template.

This is my post with spaces:
PUT /api/feed?compId=0&compName=Tell&api_key=085a3bec-4e78-3d1d-80f0-85eb6566b2c2&Current Grill Temp=413&probetemp1=240 HTTP/1.1


This is a similar post with no spaces that works:
PUT /api/feed?compId=0&compName=Tell&api_key=085a3bec-4e78-3d1d-80f0-85eb6566b2c2&grilltemp=413&probetemp1=240 HTTP/1.1

Both streamIDs exist in my component. I copied and pasted the ID with spaces into my code to be sure it is correct.

Hope you can point out my flaw.
Post 3 IP   flag post
MikeMills private msg quote post Address this user
GroveStreams can handle IDs with spaces, but they have to be URL encoded, if they are passed as part of the URL, to successfully get to our servers.

So take your URL and put it into a Encoder site like this:
https://www.freeformatter.com/url-encoder.html

You'll notice that spaces within a URL need to be replaced with +
Post 4 IP   flag post
crevicedweller private msg quote post Address this user
That fixed it. I just replaced the spaces with a + character and it works.
Thanks much.
Post 5 IP   flag post
2965 5 5
Log in or sign up to compose a reply.