-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathTktClogr.ds
26 lines (26 loc) · 857 Bytes
/
TktClogr.ds
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
// TktClogr Zoho Deluge script (for spamming an arbitrary amount of tickets into your Zoho Desk for testing/debugging purposes).
//
void TktClogr()
{
range = #;//n-1
// Deduce 1 from your desired amount because the program starts counting from 0.
//-------------------------------------------------------------------------------
//
OrgID = #########;// Your unique Zoho tenant ID here.
//---
listTrick = leftPad(" ",range).replaceAll(" ",",");
Enum = listTrick.toList();
//---
recordValues = List();
for each index subjNum in Enum
{
recordValues.add({"subject":"Test Ticket #" + subjNum,"departmentId":"YOUR_DEPT_ID_HERE","contactId":"YOUR_CONTACT_ID_HERE"});
}
//---
for each index recordValue in recordValues
{
keyValue = recordValues.get(recordValue);
createTkt = zoho.desk.create(OrgID,"tickets",keyValue);
info createTkt;
}
}