WhiteLabel API
Ticketing
List All Ticket Categories
this endpoint ( get get ) retrieves all your ticket categories tthe response is paginated; therefore, you should use the 'page' parameter for navigating through the results in subsequent requests on successful completion, it returns an array of ticket category object docid\ iirlfdoodrfywg6u0jwxc the number of available results and the flags used for filtering query parameters page fetch the results from a specific page it defaults to 1 per page the number of results to fetch per page the maximum is 50 and if it defaults to 10 from appendix docid\ kfbmx4q3dxjtduqf75yx1 start date used for filtering to appendix docid\ kfbmx4q3dxjtduqf75yx1 end date used for filtering filter string filters the ticket categories by title sort by an optional identifier used for sorting results the available options are title and created at require "uri" require "net/http" url = uri("https //api tamio com/v2/whitelabel/ticket categories/list?page=1\&per page=10") https = net http new(url host, url port) https use ssl = true request = net http get new(url) request\["accept"] = "application/json" request\["authorization"] = "bearer your token here" response = https request(request) puts response read body var myheaders = new headers(); myheaders append("accept", "application/json"); myheaders append("authorization", "bearer your token here"); var requestoptions = { method 'get', headers myheaders, redirect 'follow' }; fetch("https //api tamio com/v2/whitelabel/ticket categories/list?page=1\&per page=10", requestoptions) then(response => response text()) then(result => console log(result)) catch(error => console log('error', error));curl location request get 'https //api tamio com/v2/whitelabel/ticket categories/list?page=1\&per page=10' \\ \ header 'accept application/json' \\ \ header 'authorization bearer your token here'{ "ticket categories" \[ { "id" "a34120ad 0340 41a3 a8c9 30e4b4b8d218", "title" "premium support", "object" "ticket category", "created at" 1671453329, "language" "en", "subcategories" \[ "technical support", "account inquiries" ], "teammate id" null, "billing plans" null, "auto reply" "thank you for contacting our premium support an agent will reply to your ticket within 48 hours " } ], "total results" 1, "status" 200, "page" 1, "per page" 10, "filter" null, "order" "desc" }