LiveZilla Live Chat
EN  DE Please sign in or register Hi
Great tool, really amazing. We have been using this for months and it is the best in its class in its...
Ashish
Show all reviews


LiveZilla API V2




Ticket
Ticket Object Format
Ticket is represented as JSON objects having the following keys:


JSON Key Type Required Read only Comment Example
IdintNoYesThe serial ticket ID11123
GroupstringYesNoGroup Idgroupid1
ChannelintNoNo
Channel

[0] = Web
[1] = Email
[2] = Phone
[3] = Misc
[4] = Chat
[5] = Rating
Read more
SubChannelstringNoNoSub-Channel NameSub Channel Name
LanguagestringNoNoTicket's Langauge (ISO two letter)EN
LastUpdatedintNoYesLast updated time (UNIX Timestamp)1395332206
WaitBeginintNoYesWait begin time (UNIX Timestamp)1395332157
Messagesarray<TicketMessage>NoYesTicket Messages
EditorTicketEditorNoYesTicket Editor (Operator)


Ticket Functions


List Tickets
Function
As of version 5.2.5.0


POST /api/v2/api.php p_tickets_list=1


Filters


Name POST Key Type Required Comment Example  
Idp_idstringNoReturn the ticket matching this Id.11123
Groupp_groupstringNoReturn all tickets of this group.groupid1
Operatorp_operatorstringNoReturn all tickets of this operator.john_doe
Created Afterp_created_afterstringNoReturn all tickets created later than
YYYY-MM-DD HH:MM:SS
2014-01-01 23:59:59
Created Beforep_created_beforestringNoReturn all tickets created earlier than
YYYY-MM-DD HH:MM:SS
2014-01-03 00:00:00
Limitp_limitintNoMaximum number of tickets to return.100
Statusp_statusstringNoReturn all tickets with specific status. Comma-separated list of statuses

[0] = Open
[1] = In Progress
[2] = Closed
[3] = Deleted
0,2,3


CURL Example


curl {yourdomain}{livezilla_folder}/api/v2/api.php
-d {authenthication}
-d p_tickets_list=1
-d p_limit=10 -X POST

Response


200 Ok: {
    "Tickets": [
        {
            "Ticket": {
                "Messages": "",
                "Group": "groupid1",
                "Channel": "0",
                "SubChannel": "Sub Channel Name",
                "Language": "EN",
                "LastUpdated": "1395332206",
                "WaitBegin": "1395332157",
                "Editor": "",
                "Id": "11123"
            }
        }
    ]
}

Error Codes


                            403 Forbidden: Invalid or no user authentication data sent (see General API Authentication)
400 Bad Data: Invalid or missing POST parameters (see required fields/filters and data types)
                        



Create Ticket
Function
As of version 5.2.5.0


POST /api/v2/api.php p_ticket_create=1


Filters


Name POST Key Type Required Comment Example  


CURL Example


curl {yourdomain}{livezilla_folder}/api/v2/api.php
-d {authenthication}
-d p_ticket_create=1
-d p_data={ "Ticket": { "Group": "groupid1", "Channel": "0", "SubChannel": "Sub Channel Name", "Language": "EN" } } -X POST

Response


200 Ok: {
    "Ticket": {
        "Messages": "",
        "Group": "groupid1",
        "Channel": "0",
        "SubChannel": "Sub Channel Name",
        "Language": "EN",
        "LastUpdated": "1395332206",
        "WaitBegin": "1395332157",
        "Editor": "",
        "Id": "11123"
    }
}

Error Codes


                            403 Forbidden: Invalid or no user authentication data sent (see General API Authentication)
400 Bad Data: Invalid or missing POST parameters (see required fields/filters and data types)
                        





Something missing?


If you find anything missing please let us know and we will add the missing structures right away. Thanks.