Webhook and Spark Function Limits

Continuing the discussion from [Webhooks] Help using different event names for same hook:

Jordy, the link is broken here so I will ask... the limit on function(), variable(), and subscribe() are four each per device and the webhooks are 20 per userID, correct? I did a search to no avail...

Functions are limited to 4 per device:

Currently the application supports the creation of up to 4 different cloud functions.

Variables are limited to 10 per device:

Currently, up to 10 cloud variables may be defined and each variable name is limited to a max of 12 characters.

Subscribes are limited to 4 calls per device:

NOTE: A device can register up to 4 event handlers. This means you can call Spark.subscribe() a maximum of 4 times; after that it will return false.

Webhooks are limited per user to 20:

A user may create up to 20 webhooks in total.

Due to the 'complexity' of webhooks, several other limits are in place, which can be found here.

I've updated the link on the other topic, thanks for spotting that!

2 Likes

Are there any plans to increase the limit of subscribes and functions?

I believe I heard some chatter about that. Perhaps @dave could tell us some more. You could artificially increase your functions by using the input argument and making some if/else statements, or switch cases.

The function / var / subscribe limits on the photon are greater I believe, since we have so much more ram on the Photon. My hope is to keep upgrading the cloud limits as we add capacity :slight_smile:

Thanks,
David

@Dave, is the limit for subscribe in the Photon still 4?

If so, any idea on when that number will go up?

Thanks!

@sazp96, if it goes up (which it should), it will be in the next release due in 2 weeks or so.

2 Likes

Got it. Thanks!

1 Like

I’m seeing this error:

Failed to create, server said Too many web hooks for this device

yet, I only have 10…

So, what’s up?

@BulldogLowell, i have 13! :stuck_out_tongue:

@dave will know why :wink:

1 Like

@kennethlimcp

your an elite, you fly above the clouds!

1 Like

Hi All,

Good question! Looking back, this might be unclear, but there are two limits, total hooks per-user, and total hooks per device. A single device can have 10 hooks, and a user account can have 20 hooks total. I’m thinking that’s a bit awkward, should we just drop the per-device limit?

Thanks,
David

2 Likes

So, at present I have 2 cores and 4 photons registered and cannot create my 11th webhook.

they may or may not share hooks but certainly none use 10 on their own.

Might this be an account specific issue for me, @Dave ?

Hi @BulldogLowell,

You have 10 hooks created for no device in particular. In this case, the hook limits are somewhat loose, so if you wanted, you could create another 10 hooks for a particular device, etc. I know that’s a bit strange, I have a task in my backlog to make that more clear.

Thanks,
David