distinguish callers

I want to write a script for UCCX. When a customer calls to our Call Center, I want to classify who is the caller. Therefore, It is easier for us to support our customer according priority level. For example, VIPs don't have to listen the waiting ringing and transfer to our agents as soon as possible. And if he/she is a normal customer he/she must listen the waiting ringing.

So..Can you give me some advices? (solutions)

We can set the capacity of queue on a flexible way (assume it is N and we set N=130). How can we know how many people are there in the queue (assume it is n)? Therefore we can compare 2 parameters to process. In UCCX script editor, how to get n?

Thanks
Best Regards    

Recommended Reading: