Understanding commercial agent to cloud communication in end products

Hi folks!

I’ve been lurking around this site for the past few months and I recently recieved my first few Imp modules. I’m an electrical engineering undergraduate student and I’m working on a semi-school / semi-hobbyist related project revolving around the Electric Imp solution to “IoT”-product development.

I’m writing an evaluation on commercial implementation of Electric Imp in a small-volume (100-500 units) production set-up. Planning on contacting sales@electricimp.com to maybe be lucky enough to get some numbers, but first I wanted to ask here for some info. I think I have covered the basics, I’ve read the blessing docs and pretty much everything else. But I realized that I am missing something basic here. My main problem probably is that I don’t have any experience with “web-stuff”. This perticular product I’m conceptualizing requires App/cloud to Agent and Agent to App/cloud communication.

Let me try to phrase my question.

How does all the individual agents of a commercial Model get to know their individual “some kind of external cloud service ID”? When hundereds of end-users use BlinkUp for the first time. How does those Agents aquire the neccessary details to establish a new ID in some kind of external cloud thingy, like PubNub(?). So that PubNub can aquire information from a specific agent and relate that information to a specific end user.

Is information between agents and the web always done with httprequests? So that all that really is needed for PubNub(or equivalent) is the agent-url? So the agent sends the agent-url to PubNub, but how? On a commercial basis, how does this flow of information work?

I’m really loving the Electric Imp, it’s like magic :smiley: Looking forward to learn more the next coming months! I’m still a bigtime Squirrel-noob, only have experience with microcontrollers, so its a kind of hard transition to work with such a high-level language. I’m gratefull for all the referance designs and docs that are out there, keep em coming! :slight_smile:

Many thanks for any and all answers!

Edit: Headline.


When you BlinkUp a device, the mobile app gets sent the URL of that device’s unique agent. The app should store this URL and use it to contact the agent whenever it needs to. Since each device has its own agent, every agent has to have a unique URL. So it doesn’t matter how many users BlinkUp, they all get the URL of their respective device’s agent.

From this point on, app-to-agent comms are made using HTTPS requests. Likewise web-to-agent comms, but in this case the user will need to key in their own agent URL, which would be presented by the BlinkUp app. The Electric Imp app doesn’t do this, but a third-party app from the device manufacturer might. However, a manufacturer probably wouldn’t want to expose an agent URL because to do so weakens security.

A developer can access one of his or her own agent URLs through the IDE, but end-users (ie. customers who buy a manufactured imp-based device) don’t have access to the IDE.

An agent can access its own URL through the imp API method http.agenturl(). It can contact an external web service which has has been set up with an API that includes a registration command: the agent registers its URL with the service, which then ties it to, say, a user account set up by the end-user, probably via the manufacturer’s app.

So for commercial use you need to put more work into the back-end than, say, an individual maker does. You have to think about how you’re going to integrate your systems for user registration and so on with all the Electric Imp agents you’ll have to talk to.

I enjoy knowing the full potential of your system, thanks for your reply. I think I understand the full concept of the Electric Imp now, at least as much as I can understand without having any actual in-depth knowledge of how one actually make those kinds of applications which handles the data flowing around in between the Agent and the cloud in such a manner that it allows for registration of new users and… whatnot… :stuck_out_tongue:

Thanks again!

I’ll just keep on asking some more questions if you don’t mind.

When you hand out BlinkUp SDK, do you also recommend a solution for this kind of application that we just talked about? Is there a “favorite” cloud-solution you recommend to your commercial business partners, or a recommended Android/IOS development company that has experience working with BlinkUp SDK?