Multiple Outbounds via multiple VOIP providers

Hello, I have a question.
Lets say I have 4 VOIP numbers (no Land lines) and have 10 phones connected to Asterisk.
I want to call like on the regular phone (w/o any designated extension) from any phone and I want Asterisk to spread calls evenly between 4 VOIP numbers…
Is it possible to do?

if you mean incoming calls from the PSTN, then how do you expect Asterisk will be able to control what is a feature of the ITSPs involved ? if all 4 are from the same provider, then check with them what the incoming limit is for each account.

if the provider allows multiple incoming calls for an account, i don’t see the need to spread anything. bandwidth is bandwidth, and if you’re using IAX to trunk to the provider you would be better off squeezing the calls into a single “pipe”

Sure, just use a bit of creative dialplanning.

Create 4 global variables- provider1 thru provider4. into each store the dest channel of one provider ie provider1= SIP/myprovider1.

make another variable (global), say call it increment

now dialscript the following pseudocode:

Set(increment=$[${increment}+1],g) ; takes the global variable ${increment} and adds one to it
ExecIf($[${increment}=5],set,increment=1,g) ; if it’s now set to 5 (or one more than the number of providers you have) set ti back to one
Set(useme=provider${increment}) sets ‘useme’ to be ‘providerX’ with x being the number of provider to use
Dial(${useme}/${EXTEN}) ; dial the call on whatever channel is stored in ‘useme’