SupportPal API Documentation (2.0.3)
Core ¶
IP Ban ¶
Banned IPs that are not allowed to login to either the frontend, operator panel or API (or some combination). Includes manually added bans as well as automatic bans as a result of a number of incorrect logins.
Show all of the records.GET/api/core/ipban
Example URI
- ip
string(optional)Search with an exact IP address.
- start
integer(optional) Default: 0The first result to start from.
- limit
integer(optional) Default: 50The amount of results to fetch.
- order_column
string(optional) Default: idThe column to sort by.
- order_direction
string(optional) Default: ascThe ordering of the results.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"count": 1,
"data": [
{
"id": 1,
"ip": "192.168.1.2",
"reason": "Abuse",
"event_user": 1,
"event_operator": 1,
"event_api": 1,
"type": 1,
"expiry": null,
"created_at": 1446383939,
"updated_at": 1446383939
}
]
}Display the specified resource.GET/api/core/ipban/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"data": {
"id": 1,
"ip": "192.168.1.2",
"reason": "Abuse",
"event_user": 1,
"event_operator": 1,
"event_api": 1,
"type": 1,
"expiry": null,
"created_at": 1446383939,
"updated_at": 1446383939
}
}Store a newly created resource in storage.POST/api/core/ipban
Example URI
- ip
string(required)The IP address being banned.
- reason
string(optional)A reason for the IP ban.
- event_user
boolean(optional) Default: 1The ban should not let this IP log in as a user on the frontend.
- event_operator
boolean(optional) Default: 1The ban should not let this IP log in as an operator.
- event_api
boolean(optional) Default: 1The ban should not let this IP use the API.
- expiry_time
integer(optional)A unix timestamp at when the ban should expire, only needed for temporary bans, will default to 24 hours if not entered.
Headers
Content-Type: application/x-www-form-urlencodedBody
ip=192.168.1.2&reason=Abuse&type=1200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully created new ban!",
"data": {
"id": 1,
"ip": "192.168.1.2",
"reason": "Abuse",
"event_user": 1,
"event_operator": 1,
"event_api": 1,
"type": 1,
"expiry": null,
"created_at": 1446383939,
"updated_at": 1446383939
}
}422Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The ip field is required.",
"data": null
}Update the specified resource in storage.PUT/api/core/ipban/{id}
Example URI
- id
integer(required)The ID of the resource.
- ip
string(optional)The IP address being banned.
- reason
string(optional)A reason for the IP ban.
- event_user
boolean(optional)The ban should not let this IP log in as a user on the frontend.
- event_operator
boolean(optional)The ban should not let this IP log in as an operator.
- event_api
boolean(optional)The ban should not let this IP use the API.
- expiry_time
integer(optional)A unix timestamp at when the ban should expire, only needed for temporary bans, will default to 24 hours if not entered.
Headers
Content-Type: application/x-www-form-urlencodedBody
ip=192.168.1.2&reason=Abuse&type=1200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully updated the ban!",
"data": {
"id": 1,
"ip": "192.168.1.2",
"reason": "Abuse",
"event_user": 1,
"event_operator": 1,
"event_api": 1,
"type": 1,
"expiry": null,
"created_at": 1446383939,
"updated_at": 1446383939
}
}404Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The ban with given ID was not found.",
"data": null
}Remove the specified resource from storage.DELETE/api/core/ipban/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully deleted the ban!",
"data": null
}IP Whitelist ¶
Known IP addresses that will not be banned on failed logins.
Show all of the records.GET/api/core/ipwhitelist
Example URI
- ip
string(optional)Search with an exact IP address.
- start
integer(optional) Default: 0The first result to start from.
- limit
integer(optional) Default: 50The amount of results to fetch.
- order_column
string(optional) Default: idThe column to sort by.
- order_direction
string(optional) Default: ascThe ordering of the results.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"count": 1,
"data": [
{
"id": 1,
"ip": "127.0.0.1",
"description": "Localhost",
"event_user": 1,
"event_operator": 1,
"event_api": 1,
"created_at": 1446399514,
"updated_at": 1446399514
}
]
}Display the specified resource.GET/api/core/ipwhitelist/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"data": {
"id": 1,
"ip": "127.0.0.1",
"description": "Localhost",
"event_user": 1,
"event_operator": 1,
"event_api": 1,
"created_at": 1446399514,
"updated_at": 1446399514
}
}Store a newly created resource in storage.POST/api/core/ipwhitelist
Example URI
- ip
string(required)The IP address being whitelisted.
- description
string(optional)A description of the IP being whitelisted.
- event_user
boolean(optional) Default: 1The whitelisting should apply when logging in as a user on the frontend.
- event_operator
boolean(optional) Default: 1The whitelisting should apply when logging in as an operator.
- event_api
boolean(optional) Default: 1The whitelisting should apply when using the API.
Headers
Content-Type: application/x-www-form-urlencodedBody
ip=127.0.0.1&description=Localhost200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully created new whitelisted ip!",
"data": {
"id": 1,
"ip": "127.0.0.1",
"description": "Localhost",
"event_user": 1,
"event_operator": 1,
"event_api": 1,
"created_at": 1446399514,
"updated_at": 1446399514
}
}422Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The ip field is required.",
"data": null
}Update the specified resource in storage.PUT/api/core/ipwhitelist/{id}
Example URI
- id
integer(required)The ID of the resource.
- ip
string(optional)The IP address being whitelisted.
- description
string(optional)A description of the IP being whitelisted.
- event_user
boolean(optional)The whitelisting should apply when logging in as a user on the frontend.
- event_operator
boolean(optional)The whitelisting should apply when logging in as an operator.
- event_api
boolean(optional)The whitelisting should apply when using the API.
Headers
Content-Type: application/x-www-form-urlencodedBody
ip=127.0.0.1&description=Localhost200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully updated the whitelisted ip!",
"data": {
"id": 1,
"ip": "127.0.0.1",
"description": "Localhost",
"event_user": 1,
"event_operator": 1,
"event_api": 1,
"created_at": 1446399514,
"updated_at": 1446399514
}
}404Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The whitelisted ip with given ID was not found.",
"data": null
}Remove the specified resource from storage.DELETE/api/core/ipwhitelist/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully deleted the whitelisted ip!",
"data": null
}Spam Rules ¶
The rules that are used to determine when incoming tickets and other content are considered spam.
Show all of the records.GET/api/core/spamrule
Example URI
- start
integer(optional) Default: 0The first result to start from.
- limit
integer(optional) Default: 50The amount of results to fetch.
- order_column
string(optional) Default: idThe column to sort by.
- order_direction
string(optional) Default: ascThe ordering of the results.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"count": 1,
"data": [
{
"id": 1,
"text": "Pills",
"event_message": 1,
"event_comment": 1,
"type": 0,
"created_at": 1446400836,
"updated_at": 1446400836
}
]
}Display the specified resource.GET/api/core/spamrule/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"data": {
"id": 1,
"text": "Pills",
"event_message": 1,
"event_comment": 1,
"type": 0,
"created_at": 1446400836,
"updated_at": 1446400836
}
}Store a newly created resource in storage.POST/api/core/spamrule
Example URI
- text
string(required)The text to check against, can be regex, case-insensitive.
- type
integer(required)What should be checked, 0 - Content, 1 - Sender, 2 - Content & Sender.
- event_message
boolean(optional) Default: 1Check against ticket messages.
- event_comment
boolean(optional) Default: 1Check against article comments.
Headers
Content-Type: application/x-www-form-urlencodedBody
text=Pills&type=0200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully created new spam rule!",
"data": {
"id": 1,
"text": "Pills",
"event_message": 1,
"event_comment": 1,
"type": 0,
"created_at": 1446400836,
"updated_at": 1446400836
}
}422Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The text field is required.",
"data": null
}Update the specified resource in storage.PUT/api/core/spamrule/{id}
Example URI
- id
integer(required)The ID of the resource.
- text
string(optional)The text to check against, can be regex, case-insensitive.
- type
integer(optional)What should be checked, 0 - Content, 1 - Sender, 2 - Content & Sender.
- event_message
boolean(optional)Check against ticket messages.
- event_comment
boolean(optional)Check against article comments.
Headers
Content-Type: application/x-www-form-urlencodedBody
text=Pills&type=0200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully updated the spam rule!",
"data": {
"id": 1,
"text": "Pills",
"event_message": 1,
"event_comment": 1,
"type": 0,
"created_at": 1446400836,
"updated_at": 1446400836
}
}404Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The spam rule with given ID was not found.",
"data": null
}Remove the specified resource from storage.DELETE/api/core/spamrule/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully deleted the spam rule!",
"data": null
}Settings ¶
Core system settings.
General SettingsGET/api/core/settings
Example URI
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"data": {
"active_plugins": "",
"admin_folder": "admin",
"date_format": "d/m/Y",
"default_country": "GB",
"default_frontend_language": "en",
"default_operator_language": "en",
"default_email": "email@yourcompany.com",
"default_timezone": "Europe/London",
"enable_ssl": "0",
"force_operator_ssl": "0",
"frontend_language": "1",
"frontend_template": "default",
"is_installed": "1",
"language_frontend_toggle": "1",
"language_operator_toggle": "1",
"maintenance_mode": "0",
"operator_language": "1",
"operator_template": "default",
"simpleauth_key": "g3SMCtWwNoeLTYqMCruFlMXEwjyUVQKj",
"time_format": "g:i A"
}
}User ¶
User ¶
User accounts.
Show all of the records.GET/api/user/user
Example URI
- firstname
string(optional)Search for users by their first name.
- lastname
string(optional)Search for users by their last name.
string(optional)Search for users by email.
- organisation_id
integer(optional)Search for users by their organisation ID.
- organisation_name
string(optional)Search for users by their organisation name.
- country
intstringeger(optional)Search for users by their two letter country code like ‘GB’.
- language_code
string(optional)Search for users by their two letter language code like ‘en’.
- customfield
array(optional)Search for users by their custom field values, key the array by the custom field ID.
- start
integer(optional) Default: 0The first result to start from.
- limit
integer(optional) Default: 50The amount of results to fetch.
- order_column
string(optional) Default: idThe column to sort by.
- order_direction
string(optional) Default: ascThe ordering of the results.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"count": 1,
"data": [
{
"id": 1,
"firstname": "Joe",
"lastname": "Bloggs",
"email": "jbloggs@email.com",
"password": "$2y$10$ioFx/8Ng5Fx6zJdNvCjaQ.neqgU4/IonRMDLaaPvF3DTV2vutUpwO",
"session": null,
"remember_token": null,
"confirmed": 1,
"organisation_id": null,
"organisation_access_level": null,
"country": null,
"language_code": null,
"timezone": null,
"avatar": null,
"twofa_enabled": 0,
"twofa_secret": null,
"twofa_token": null,
"twitter_id": null,
"twitter_handle": null,
"facebook_id": null,
"created_at": 1445611944,
"updated_at": 1445611959,
"formatted_name": "Joe Bloggs",
"groups": [],
"customfields": []
}
]
}Display the specified resource.GET/api/user/user/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"data": {
"id": 1,
"firstname": "Joe",
"lastname": "Bloggs",
"email": "jbloggs@email.com",
"password": "$2y$10$ioFx/8Ng5Fx6zJdNvCjaQ.neqgU4/IonRMDLaaPvF3DTV2vutUpwO",
"session": null,
"remember_token": null,
"confirmed": 1,
"organisation_id": null,
"organisation_access_level": null,
"country": null,
"language_code": null,
"timezone": null,
"avatar": null,
"twofa_enabled": 0,
"twofa_secret": null,
"twofa_token": null,
"twitter_id": null,
"twitter_handle": null,
"facebook_id": null,
"created_at": 1445611944,
"updated_at": 1445611959,
"formatted_name": "Joe Bloggs",
"groups": [],
"customfields": []
}
}Store a newly created resource in storage.POST/api/user/user
Example URI
- firstname
string(required)The first name of the user.
- lastname
string(required)The last name of the user.
string(required)The user’s email address.
- password
string(required)The user’s password.
- country
string(optional)The user’s country, as a two letter string like ‘GB’.
- language_code
string(optional)The two letter language code, like ‘en’, will default to system default if not entered.
- timezone
string(optional)The timezone of the user, like ‘Europe/London’, will default to system default if not entered.
- confirmed
boolean(optional) Default: 0If the user is confirmed and can login.
- organisation
string(optional)If creating a new organisation, use this field.
- organisation_id
integer(optional)If adding to an existing organisation, enter the organisation ID.
- organisation_notifications
boolean(optional)If user is an organisation manager or owner, should they receive emails on updates for tickets opened by other organisation users.
- customfield
array(optional)An array of custom fields values, keyed by their ID.
- groups
array(optional)An array of group IDs that the user belongs to.
Headers
Content-Type: application/x-www-form-urlencodedBody
firstname=Joe&lastname=Bloggs&email=jbloggs@email.com&confirmed=1200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully created new user!",
"data": {
"id": 1,
"firstname": "Joe",
"lastname": "Bloggs",
"email": "jbloggs@email.com",
"password": "$2y$10$ioFx/8Ng5Fx6zJdNvCjaQ.neqgU4/IonRMDLaaPvF3DTV2vutUpwO",
"session": null,
"remember_token": null,
"confirmed": 1,
"organisation_id": null,
"organisation_access_level": null,
"country": null,
"language_code": null,
"timezone": null,
"created_at": 1445611944,
"updated_at": 1445611959,
"formatted_name": "Joe Bloggs",
"groups": [],
"customfields": []
}
}422Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The name field is required.",
"data": null
}Update the specified resource in storage.PUT/api/user/user/{id}
Example URI
- id
integer(required)The ID of the resource.
- firstname
string(optional)The first name of the user.
- lastname
string(optional)The last name of the user.
string(optional)The user’s email address.
- password
string(optional)The user’s password.
- country
string(optional)The user’s country, as a two letter string like ‘GB’.
- language_code
string(optional)The two letter language code, like ‘en’, will default to system default if not entered.
- timezone
string(optional)The timezone of the user, like ‘Europe/London’, will default to system default if not entered.
- confirmed
boolean(optional) Default: 0If the user is confirmed and can login.
- organisation
string(optional)If creating a new organisation or updating the existing name, use this field.
- organisation_id
integer(optional)The ID of the organisation, use instead of ‘organisation’ if the organisation already exists. If you wish to remove the user from the organisation they are currently associated with, set as 0.
- organisation_notifications
boolean(optional)If user is an organisation manager or owner, should they receive emails on updates for tickets opened by other organisation users.
- customfield
array(optional)An array of custom fields values, keyed by their ID.
- groups
array(optional)An array of group IDs that the user belongs to.
Headers
Content-Type: application/x-www-form-urlencodedBody
firstname=Joe&lastname=Bloggs&email=jbloggs@email.com&confirmed=1200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully updated the user!",
"data": {
"id": 1,
"firstname": "Joe",
"lastname": "Bloggs",
"email": "jbloggs@email.com",
"password": "$2y$10$ioFx/8Ng5Fx6zJdNvCjaQ.neqgU4/IonRMDLaaPvF3DTV2vutUpwO",
"session": null,
"remember_token": null,
"confirmed": 1,
"organisation_id": null,
"organisation_access_level": null,
"country": null,
"language_code": null,
"timezone": null,
"avatar": null,
"twofa_enabled": 0,
"twofa_secret": null,
"twofa_token": null,
"twitter_id": null,
"twitter_handle": null,
"facebook_id": null,
"created_at": 1445611944,
"updated_at": 1445611959,
"formatted_name": "Joe Bloggs"
}
}404Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The user with given ID was not found.",
"data": null
}Remove the specified resource from storage.DELETE/api/user/user/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully deleted the user!",
"data": null
}Operator ¶
Staff accounts.
Show all of the records.GET/api/user/operator
Example URI
string(optional)Search for operators by email.
- start
integer(optional) Default: 0The first result to start from.
- limit
integer(optional) Default: 50The amount of results to fetch.
- order_column
string(optional) Default: idThe column to sort by.
- order_direction
string(optional) Default: ascThe ordering of the results.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"count": 1,
"data": [
{
"id": 1,
"firstname": "Joe",
"lastname": "Bloggs",
"email": "jbloggs@email.com",
"password": "$2y$10$ioFx/8Ng5Fx6zJdNvCjaQ.neqgU4/IonRMDLaaPvF3DTV2vutUpwO",
"session": null,
"remember_token": null,
"confirmed": 1,
"organisation_id": null,
"organisation_access_level": null,
"country": null,
"language_code": null,
"timezone": null,
"avatar": null,
"twofa_enabled": 0,
"twofa_secret": null,
"twofa_token": null,
"twitter_id": null,
"twitter_handle": null,
"facebook_id": null,
"created_at": 1445611944,
"updated_at": 1445611959,
"formatted_name": "Joe Bloggs",
"groups": [],
"departments": []
}
]
}Display the specified resource.GET/api/user/operator/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"data": {
"id": 1,
"firstname": "Joe",
"lastname": "Bloggs",
"email": "jbloggs@email.com",
"password": "$2y$10$ioFx/8Ng5Fx6zJdNvCjaQ.neqgU4/IonRMDLaaPvF3DTV2vutUpwO",
"session": null,
"remember_token": null,
"confirmed": 1,
"organisation_id": null,
"organisation_access_level": null,
"country": null,
"language_code": null,
"timezone": null,
"avatar": null,
"twofa_enabled": 0,
"twofa_secret": null,
"twofa_token": null,
"twitter_id": null,
"twitter_handle": null,
"facebook_id": null,
"created_at": 1445611944,
"updated_at": 1445611959,
"formatted_name": "Joe Bloggs",
"groups": [],
"departments": []
}
}Store a newly created resource in storage.POST/api/user/operator
Example URI
- firstname
string(required)The first name of the operator.
- lastname
string(required)The last name of the operator.
string(required)The operator’s email address.
- password
string(required)The operator’s password.
- country
string(optional)The operator’s country, as a two letter string like ‘GB’.
- language_code
string(optional)The two letter language code, like ‘en’, will default to system detault if not entered.
- timezone
string(optional)The timezone of the operator, like ‘Europe/London’, will default to system detault if not entered.
- confirmed
boolean(optional) Default: 0If the operator is confirmed and can login (1).
- groups
array(required)An array of group IDs that the operator belongs to. Requires at least one operator group.
- depts
array(optional)An array of department IDs that the operator belongs to.
Headers
Content-Type: application/x-www-form-urlencodedBody
firstname=Joe&lastname=Bloggs&email=jbloggs@email.com&confirmed=1200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully created new operator!",
"data": {
"id": 1,
"firstname": "Joe",
"lastname": "Bloggs",
"email": "jbloggs@email.com",
"password": "$2y$10$ioFx/8Ng5Fx6zJdNvCjaQ.neqgU4/IonRMDLaaPvF3DTV2vutUpwO",
"session": null,
"remember_token": null,
"confirmed": 1,
"organisation_id": null,
"organisation_access_level": null,
"country": null,
"language_code": null,
"timezone": null,
"created_at": 1445611944,
"updated_at": 1445611959,
"formatted_name": "Joe Bloggs",
"groups": [],
"departments": []
}
}422Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The name field is required.",
"data": null
}Update the specified resource in storage.PUT/api/user/operator/{id}
Example URI
- id
integer(required)The ID of the resource.
- firstname
string(optional)The first name of the operator.
- lastname
string(optional)The last name of the operator.
string(optional)The operator’s email address.
- password
string(optional)The operator’s password.
- country
string(optional)The operator’s country, as a two letter string like ‘GB’.
- language_code
string(optional)The two letter language code, like ‘en’, will default to system detault if not entered.
- timezone
string(optional)The timezone of the operator, like ‘Europe/London’, will default to system detault if not entered.
- confirmed
boolean(optional) Default: 0If the operator is confirmed and can login (1).
- groups
array(optional)An array of group IDs that the operator belongs to.
- depts
array(optional)An array of department IDs that the operator belongs to.
Headers
Content-Type: application/x-www-form-urlencodedBody
firstname=Joe&lastname=Bloggs&email=jbloggs@email.com&confirmed=1200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully updated the operator!",
"data": {
"id": 1,
"firstname": "Joe",
"lastname": "Bloggs",
"email": "jbloggs@email.com",
"password": "$2y$10$ioFx/8Ng5Fx6zJdNvCjaQ.neqgU4/IonRMDLaaPvF3DTV2vutUpwO",
"session": null,
"remember_token": null,
"confirmed": 1,
"organisation_id": null,
"organisation_access_level": null,
"country": null,
"language_code": null,
"timezone": null,
"avatar": null,
"twofa_enabled": 0,
"twofa_secret": null,
"twofa_token": null,
"twitter_id": null,
"twitter_handle": null,
"facebook_id": null,
"created_at": 1445611944,
"updated_at": 1445611959,
"formatted_name": "Joe Bloggs",
"groups": [],
"departments": []
}
}404Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The operator with given ID was not found.",
"data": null
}Remove the specified resource from storage.DELETE/api/user/operator/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully deleted the operator!",
"data": null
}Organisation ¶
Users can be part of organisations, allowing other users to view and reply to their tickets.
Show all of the records.GET/api/user/organisation
Example URI
- start
integer(optional) Default: 0The first result to start from.
- limit
integer(optional) Default: 50The amount of results to fetch.
- order_column
string(optional) Default: idThe column to sort by.
- order_direction
string(optional) Default: ascThe ordering of the results.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"count": 1,
"data": [
{
"id": 1,
"owner_id": 1,
"name": "Acme",
"address": "123 Arctic Drive",
"city": "Cambridge",
"state": "Cambridgeshire",
"postcode": "CB2 1PT",
"country": "GB",
"phone": "+441223123456",
"website": "http://www.acmecompany.com",
"language_code": "en",
"timezone": "Europe/London",
"notes": "Ordered new product in February.",
"created_at": 1446314521,
"updated_at": 1446314521,
"users": [
{
"id": 1,
"firstname": "Joe",
"lastname": "Bloggs",
"email": "jbloggs@email.com",
"password": "$2y$10$dpQPojoAFxR.8cy6qCAUGOyRd6MtqavgqsJLWfvH/JfYlzCeV2GZu",
"session": null,
"remember_token": null,
"confirmed": 1,
"organisation_id": 1,
"organisation_access_level": 0,
"country": "GB",
"language_code": "en",
"timezone": "Europe/London",
"avatar": null,
"twofa_enabled": 0,
"twofa_secret": null,
"twofa_token": null,
"twitter_id": null,
"twitter_handle": null,
"facebook_id": null,
"created_at": 1445613240,
"updated_at": 1446314521,
"formatted_name": "Joe Bloggs"
}
]
}
]
}Display the specified resource.GET/api/user/organisation/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"data": {
"id": 1,
"owner_id": 1,
"name": "Acme",
"address": "123 Arctic Drive",
"city": "Cambridge",
"state": "Cambridgeshire",
"postcode": "CB2 1PT",
"country": "GB",
"phone": "+441223123456",
"website": "http://www.acmecompany.com",
"language_code": "en",
"timezone": "Europe/London",
"notes": "Ordered new product in February.",
"created_at": 1446314521,
"updated_at": 1446314521,
"users": [
{
"id": 1,
"firstname": "Joe",
"lastname": "Bloggs",
"email": "jbloggs@email.com",
"password": "$2y$10$dpQPojoAFxR.8cy6qCAUGOyRd6MtqavgqsJLWfvH/JfYlzCeV2GZu",
"session": null,
"remember_token": null,
"confirmed": 1,
"organisation_id": 1,
"organisation_access_level": 0,
"country": "GB",
"language_code": "en",
"timezone": "Europe/London",
"avatar": null,
"twofa_enabled": 0,
"twofa_secret": null,
"twofa_token": null,
"twitter_id": null,
"twitter_handle": null,
"facebook_id": null,
"created_at": 1445613240,
"updated_at": 1446314521,
"formatted_name": "Joe Bloggs"
}
]
}
}Store a newly created resource in storage.POST/api/user/organisation
Example URI
- name
string(required)The name of the organisation.
- address
string(optional)The organisation’s address.
- city
string(optional)The city the organisation is based in.
- state
string(optional)The state the organisation is based in.
- postcode
string(optional)The organisation’s postcode.
- country
string(optional)The country the organisation is based in, as a two letter string like ‘GB’.
- phone
string(optional)The organisation’s phone number.
- website
string(optional)The organisation’s website.
- language_code
string(optional)The organisation’s language, two letter code, like ‘en’, will default to system default if not entered.
- timezone
string(optional)The organisation’s timezone, like ‘Europe/London’, will default to system default if not entered.
- notes
string(optional)Any notes about the organisation, for operators only.
- access_level
array(optional)An array of user access levels in organisation, keyed by the user ID. 0 - Manager, 1 - User.
Headers
Content-Type: application/x-www-form-urlencodedBody
name=Acme200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully created new organisation!",
"data": {
"id": 1,
"owner_id": 1,
"name": "Acme",
"address": "123 Arctic Drive",
"city": "Cambridge",
"state": "Cambridgeshire",
"postcode": "CB2 1PT",
"country": "GB",
"phone": "+441223123456",
"website": "http://www.acmecompany.com",
"language_code": "en",
"timezone": "Europe/London",
"notes": "Ordered new product in February.",
"created_at": 1446314521,
"updated_at": 1446314521,
"users": [
{
"id": 1,
"firstname": "Joe",
"lastname": "Bloggs",
"email": "jbloggs@email.com",
"password": "$2y$10$dpQPojoAFxR.8cy6qCAUGOyRd6MtqavgqsJLWfvH/JfYlzCeV2GZu",
"session": null,
"remember_token": null,
"confirmed": 1,
"organisation_id": 1,
"organisation_access_level": 0,
"country": "GB",
"language_code": "en",
"timezone": "Europe/London",
"avatar": null,
"twofa_enabled": 0,
"twofa_secret": null,
"twofa_token": null,
"twitter_id": null,
"twitter_handle": null,
"facebook_id": null,
"created_at": 1445613240,
"updated_at": 1446314521,
"formatted_name": "Joe Bloggs"
}
]
}
}422Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The name field is required.",
"data": null
}Update the specified resource in storage.PUT/api/user/organisation/{id}
Example URI
- id
integer(required)The ID of the resource.
- name
string(optional)The name of the organisation.
- address
string(optional)The organisation’s address.
- city
string(optional)The city the organisation is based in.
- state
string(optional)The state the organisation is based in.
- postcode
string(optional)The organisation’s postcode.
- country
string(optional)The country the organisation is based in, as a two letter string like ‘GB’.
- phone
string(optional)The organisation’s phone number.
- website
string(optional)The organisation’s website.
- language_code
string(optional)The organisation’s language, two letter code, like ‘en’, will default to system default if not entered.
- timezone
string(optional)The organisation’s timezone, like ‘Europe/London’, will default to system default if not entered.
- notes
string(optional)Any notes about the organisation, for operators only.
- access_level
array(optional)An array of user access levels in organisation, keyed by the user ID. 0 - Manager, 1 - User.
Headers
Content-Type: application/x-www-form-urlencodedBody
name=Acme200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully updated the organisation!",
"data": {
"id": 1,
"owner_id": 1,
"name": "Acme",
"address": "123 Arctic Drive",
"city": "Cambridge",
"state": "Cambridgeshire",
"postcode": "CB2 1PT",
"country": "GB",
"phone": "+441223123456",
"website": "http://www.acmecompany.com",
"language_code": "en",
"timezone": "Europe/London",
"notes": "Ordered new product in February.",
"created_at": 1446314521,
"updated_at": 1446314521,
"users": [
{
"id": 1,
"firstname": "Joe",
"lastname": "Bloggs",
"email": "jbloggs@email.com",
"password": "$2y$10$dpQPojoAFxR.8cy6qCAUGOyRd6MtqavgqsJLWfvH/JfYlzCeV2GZu",
"session": null,
"remember_token": null,
"confirmed": 1,
"organisation_id": 1,
"organisation_access_level": 0,
"country": "GB",
"language_code": "en",
"timezone": "Europe/London",
"avatar": null,
"twofa_enabled": 0,
"twofa_secret": null,
"twofa_token": null,
"twitter_id": null,
"twitter_handle": null,
"facebook_id": null,
"created_at": 1445613240,
"updated_at": 1446314521,
"formatted_name": "Joe Bloggs"
}
]
}
}404Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The organisation with given ID was not found.",
"data": null
}Remove the specified resource from storage.DELETE/api/user/organisation/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully deleted the organisation!",
"data": null
}User Group ¶
Groups to put together similar users.
Show all of the records.GET/api/user/usergroup
Example URI
- start
integer(optional) Default: 0The first result to start from.
- limit
integer(optional) Default: 50The amount of results to fetch.
- order_column
string(optional) Default: idThe column to sort by.
- order_direction
string(optional) Default: ascThe ordering of the results.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"count": 1,
"data": [
{
"id": 1,
"name": "Local",
"description": "Users based within 5 miles.",
"colour": "#35a600",
"administrator": 0,
"created_at": 1445441559,
"updated_at": 1445441559
}
]
}Display the specified resource.GET/api/user/usergroup/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"data": {
"id": 1,
"name": "Local",
"description": "Users based within 5 miles.",
"colour": "#35a600",
"administrator": 0,
"created_at": 1445441559,
"updated_at": 1445441559
}
}Store a newly created resource in storage.POST/api/user/usergroup
Example URI
- name
string(required)The name of the group.
- description
string(optional)A description of the group.
- colour
string(optional) Default: #ffffffThe hex colour of the group.
- roles
array(optional)An array of role IDs that the group belongs to.
Headers
Content-Type: application/x-www-form-urlencodedBody
name=Local200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully created new user group!",
"data": {
"id": 1,
"name": "Local",
"description": "Users based within 5 miles.",
"colour": "#35a600",
"administrator": 0,
"created_at": 1445441559,
"updated_at": 1445441559
}
}422Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The name field is required.",
"data": null
}Update the specified resource in storage.PUT/api/user/usergroup/{id}
Example URI
- id
integer(required)The ID of the resource.
- name
string(optional)The name of the group.
- description
string(optional)A description of the group.
- colour
string(optional)The hex colour of the group.
- roles
array(optional)An array of role IDs that the group belongs to.
Headers
Content-Type: application/x-www-form-urlencodedBody
name=Local200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully updated the user group!",
"data": {
"id": 1,
"name": "Local",
"description": "Users based within 5 miles.",
"colour": "#35a600",
"administrator": 0,
"created_at": 1445441559,
"updated_at": 1445441559
}
}404Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The user group with given ID was not found.",
"data": null
}Remove the specified resource from storage.DELETE/api/user/usergroup/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully deleted the user group!",
"data": null
}Operator Group ¶
Groups used to split operators and give them different permissions.
Show all of the records.GET/api/user/operatorgroup
Example URI
- start
integer(optional) Default: 0The first result to start from.
- limit
integer(optional) Default: 50The amount of results to fetch.
- order_column
string(optional) Default: idThe column to sort by.
- order_direction
string(optional) Default: ascThe ordering of the results.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"count": 1,
"data": [
{
"id": 1,
"name": "Sales",
"description": "Answering customer pre-sale questions.",
"colour": "#FFFFFF",
"administrator": 1,
"created_at": 1445441559,
"updated_at": 1445441559
}
]
}Display the specified resource.GET/api/user/operatorgroup/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"data": {
"0": "Sales",
"id": 1,
"description": "Answering customer pre-sale questions.",
"colour": "#FFFFFF",
"administrator": 1,
"created_at": 1445441559,
"updated_at": 1445441559
}
}Store a newly created resource in storage.POST/api/user/operatorgroup
Example URI
- name
string(required)The name of the group.
- description
string(optional)A description of the group.
- colour
string(optional) Default: #ffffffThe hex colour of the group.
- roles
array(optional)An array of role IDs that the group belongs to.
Headers
Content-Type: application/x-www-form-urlencodedBody
name=Sales200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully created new operator group!",
"data": {
"id": 1,
"name": "Sales",
"description": "Answering customer pre-sale questions.",
"colour": "#FFFFFF",
"administrator": 1,
"created_at": 1445441559,
"updated_at": 1445441559
}
}422Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The name field is required.",
"data": null
}Update the specified resource in storage.PUT/api/user/operatorgroup/{id}
Example URI
- id
integer(required)The ID of the resource.
- name
string(optional)The name of the group.
- description
string(optional)A description of the group.
- colour
string(optional)The hex colour of the group.
- roles
array(optional)An array of role IDs that the group belongs to.
Headers
Content-Type: application/x-www-form-urlencodedBody
name=Sales200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully updated the operator group!",
"data": {
"0": "Sales",
"id": 1,
"description": "Answering customer pre-sale questions.",
"colour": "#FFFFFF",
"administrator": 1,
"created_at": 1445441559,
"updated_at": 1445441559
}
}404Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The operator group with given ID was not found.",
"data": null
}Remove the specified resource from storage.DELETE/api/user/operatorgroup/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully deleted the operator group!",
"data": null
}Custom Field ¶
Fields that collect and store information on each user account.
Show all of the records.GET/api/user/customfield
Example URI
- start
integer(optional) Default: 0The first result to start from.
- limit
integer(optional) Default: 50The amount of results to fetch.
- order_column
string(optional) Default: idThe column to sort by.
- order_direction
string(optional) Default: ascThe ordering of the results.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"count": 1,
"data": [
{
"id": 1,
"name": "VAT Number",
"type": 8,
"order": 1,
"required": 0,
"public": 1,
"encrypted": 0,
"locked": 0,
"created_at": 1446325459,
"updated_at": 1446325459,
"options": []
}
]
}Display the specified resource.GET/api/user/customfield/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"data": {
"id": 1,
"name": "VAT Number",
"type": 8,
"order": 1,
"required": 0,
"public": 1,
"encrypted": 0,
"locked": 0,
"created_at": 1446325459,
"updated_at": 1446325459,
"options": []
}
}Store a newly created resource in storage.POST/api/user/customfield
Example URI
- name
string(required)The name of the custom field.
- type
integer(required)The custom field type. 0 - Boolean, 1 - Checkbox, 2 - Checklist, 3 - Date, 4 - Multiple Options, 5 - Options, 6 - Password, 7 - Radio Buttons, 8 - Text, 9 - Textarea.
- required
boolean(optional) Default: 0Whether the custom field is required to submit the form.
- public
boolean(optional) Default: 1Whether the custom field should be visible to users.
- encrypted
boolean(optional) Default: 0Whether to encrypt the custom field value in the database.
- locked
boolean(optional) Default: 0Whether to prevent edits to the custom field.
- options
array(optional)An array of options, only applied to Checklist, Multiple Options, Options and Radio Buttons.
Headers
Content-Type: application/x-www-form-urlencodedBody
name=VAT+Number&type=8200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully created new custom field!",
"data": {
"id": 1,
"name": "VAT Number",
"type": 8,
"order": 1,
"required": 0,
"public": 1,
"encrypted": 0,
"locked": 0,
"created_at": 1446325459,
"updated_at": 1446325459,
"options": []
}
}422Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The name field is required.",
"data": null
}Update the specified resource in storage.PUT/api/user/customfield/{id}
Example URI
- id
integer(required)The ID of the resource.
- name
string(optional)The name of the custom field.
- type
integer(optional)The custom field type. 0 - Boolean, 1 - Checkbox, 2 - Checklist, 3 - Date, 4 - Multiple Options, 5 - Options, 6 - Password, 7 - Radio Buttons, 8 - Text, 9 - Textarea.
- required
boolean(optional)Whether the custom field is required to submit the form.
- public
boolean(optional)Whether the custom field should be visible to users.
- encrypted
boolean(optional)Whether to encrypt the custom field value in the database.
- locked
boolean(optional)Whether to prevent edits to the custom field.
- options
array(optional)An array of options, only applied to Checklist, Multiple Options, Options and Radio Buttons.
Headers
Content-Type: application/x-www-form-urlencodedBody
name=Local200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully updated the custom field!",
"data": {
"id": 1,
"name": "VAT Number",
"type": 8,
"order": 1,
"required": 0,
"public": 1,
"encrypted": 0,
"locked": 0,
"created_at": 1446325459,
"updated_at": 1446325459,
"options": []
}
}404Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The custom field with given ID was not found.",
"data": null
}Remove the specified resource from storage.DELETE/api/user/customfield/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully deleted the custom field!",
"data": null
}Role ¶
A set of permissions that apply to operator groups.
Show all of the records.GET/api/user/role
Example URI
- start
integer(optional) Default: 0The first result to start from.
- limit
integer(optional) Default: 50The amount of results to fetch.
- order_column
string(optional) Default: idThe column to sort by.
- order_direction
string(optional) Default: ascThe ordering of the results.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"count": 1,
"data": [
{
"id": 1,
"name": "Administrator",
"slug": "administrator",
"description": "Full permissions",
"created_at": 1445611886,
"updated_at": 1445611886,
"permissions": [
{
"id": 1,
"inherit_id": null,
"module_id": 1,
"name": "apitoken",
"slug": {
"view": true,
"create": true,
"update": true,
"delete": true
},
"description": "apitoken",
"created_at": 1445611886,
"updated_at": 1445611886,
"pivot": {
"role_id": 1,
"permission_id": 1
}
}
]
}
]
}Display the specified resource.GET/api/user/role/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"data": {
"id": 1,
"name": "Administrator",
"slug": "administrator",
"description": "Full permissions",
"created_at": 1445611886,
"updated_at": 1445611886,
"permissions": [
{
"id": 1,
"inherit_id": null,
"module_id": 1,
"name": "apitoken",
"slug": {
"view": true,
"create": true,
"update": true,
"delete": true
},
"description": "apitoken",
"created_at": 1445611886,
"updated_at": 1445611886,
"pivot": {
"role_id": 1,
"permission_id": 1
}
}
]
}
}Store a newly created resource in storage.POST/api/user/role
Example URI
- name
string(required)The name of the operator role.
- description
string(optional)A description of the operator role.
- group
array(optional)An array of operator group IDs that has the role.
- permission
array(optional)An array, keyed by permission IDs, with value 1 when the role has that permission.
Headers
Content-Type: application/x-www-form-urlencodedBody
name=Administrator&permission[1]=1200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully created new role!",
"data": {
"id": 1,
"name": "Administrator",
"slug": "administrator",
"description": "Full permissions",
"created_at": 1445611886,
"updated_at": 1445611886,
"permissions": [
{
"id": 1,
"inherit_id": null,
"module_id": 1,
"name": "apitoken",
"slug": {
"view": true,
"create": true,
"update": true,
"delete": true
},
"description": "apitoken",
"created_at": 1445611886,
"updated_at": 1445611886,
"pivot": {
"role_id": 1,
"permission_id": 1
}
}
]
}
}422Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The name field is required.",
"data": null
}Update the specified resource in storage.PUT/api/user/role/{id}
Example URI
- id
integer(required)The ID of the resource.
- name
string(optional)The name of the operator role.
- description
string(optional)A description of the operator role.
- group
array(optional)An array of operator group IDs that has the role.
- permission
array(optional)An array, keyed by permission IDs, with value 1 when the role has that permission.
Headers
Content-Type: application/x-www-form-urlencodedBody
name=Local200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully updated the role!",
"data": {
"id": 1,
"name": "Administrator",
"slug": "administrator",
"description": "Full permissions",
"created_at": 1445611886,
"updated_at": 1445611886,
"permissions": [
{
"id": 1,
"inherit_id": null,
"module_id": 1,
"name": "apitoken",
"slug": {
"view": true,
"create": true,
"update": true,
"delete": true
},
"description": "apitoken",
"created_at": 1445611886,
"updated_at": 1445611886,
"pivot": {
"role_id": 1,
"permission_id": 1
}
}
]
}
}404Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The role with given ID was not found.",
"data": null
}Remove the specified resource from storage.DELETE/api/user/role/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully deleted the role!",
"data": null
}Permission ¶
Permissions for operators.
Show all of the records.GET/api/user/permission
Example URI
- start
integer(optional) Default: 0The first result to start from.
- limit
integer(optional) Default: 50The amount of results to fetch.
- order_column
string(optional) Default: idThe column to sort by.
- order_direction
string(optional) Default: ascThe ordering of the results.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"count": 1,
"data": [
{
"id": 1,
"inherit_id": null,
"module_id": 1,
"name": "apitoken",
"slug": {
"view": true,
"create": true,
"update": true,
"delete": true
},
"description": "apitoken",
"created_at": 1445611886,
"updated_at": 1445611886
}
]
}Display the specified resource.GET/api/user/permission/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"data": {
"id": 1,
"inherit_id": null,
"module_id": 1,
"name": "apitoken",
"slug": {
"view": true,
"create": true,
"update": true,
"delete": true
},
"description": "apitoken",
"created_at": 1445611886,
"updated_at": 1445611886
}
}Settings ¶
User system settings.
General SettingsGET/api/user/settings
Example URI
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"data": {
"ldap_enabled": "0",
"registration_captcha": "1",
"registration_enabled": "1",
"user_name_format": "0"
}
}Ticket ¶
Ticket ¶
Tickets are individual support requests from users or internal staff.
Show all of the records.GET/api/ticket/ticket
Example URI
- number
string(optional)Search by ticket number.
- department
mixed(optional)Filter by ticket department, accepts a single ID or a comma delimited string e.g. 1,2,3. Parent departments include children department tickets.
- channel
mixed(optional)Filter by ticket channel, accepts a single ID or a comma delimited string e.g. 1,2,3.
- status
mixed(optional)Filter by ticket status, accepts a single ID or a comma delimited string e.g. 1,2,3.
- priority
mixed(optional)Filter by ticket priority, accepts a single ID or a comma delimited string e.g. 1,2,3.
- user
mixed(optional)Filter by submitting user, accepts a single ID or a comma delimited string e.g. 1,2,3.
- user_email
string(optional)Filter by submitting user, accepts a single ID or a comma delimited string e.g. 1,2,3.
- start
integer(optional) Default: 0The first result to start from.
- limit
integer(optional) Default: 50The amount of results to fetch.
- order_column
string(optional) Default: idThe column to sort by.
- order_direction
string(optional) Default: ascThe ordering of the results.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"count": 1,
"data": [
{
"id": 1,
"number": "3189840",
"department_id": 2,
"department_email_id": 1,
"company_id": 1,
"channel_id": 1,
"user_id": 2,
"status_id": 1,
"priority_id": 1,
"sla_plan_id": null,
"subject": "Test",
"due_time": null,
"resolved_time": null,
"cc": [],
"locked": 0,
"merged": 0,
"internal": 0,
"created_at": 1445962331,
"updated_at": 1445962332,
"department": {
"id": 2,
"name": "Test",
"description": "Test",
"order": 2,
"parent": 1,
"public": 0,
"ticket_number_format": null,
"default_assignedto": null,
"notify_ticket_autoclose": 1,
"notify_ticket_closed": 1,
"notify_email_ticket": 1,
"email_templates": [],
"created_at": 1445960900,
"updated_at": 1445960900
},
"channel": {
"id": 1,
"name": "Web",
"enabled": 1,
"class": "App\Modules\Ticket\Channels\Web\Controllers\Web",
"created_at": 1445611904,
"updated_at": 1445611904
},
"user": {
"id": 2,
"firstname": "Joe",
"lastname": "Bloggs",
"email": "jshah4517@gmail.com",
"password": "$2y$10$dpQPojoAFxR.8cy6qCAUGOyRd6MtqavgqsJLWfvH/JfYlzCeV2GZu",
"session": null,
"remember_token": null,
"confirmed": 1,
"organisation_id": 3,
"organisation_access_level": 0,
"country": "US",
"language_code": "en",
"timezone": "Europe/London",
"avatar": null,
"twofa_enabled": 0,
"twofa_secret": null,
"twofa_token": null,
"twitter_id": null,
"twitter_handle": null,
"facebook_id": null,
"created_at": 1445613240,
"updated_at": 1446314521,
"formatted_name": "Joe Bloggs"
},
"status": {
"id": 1,
"name": "Open",
"colour": "#35a600",
"auto_close": 1,
"order": 1,
"created_at": 1445611902,
"updated_at": 1445611902
},
"priority": {
"id": 1,
"name": "Low",
"colour": "#3498db",
"order": 1,
"created_at": 1445611902,
"updated_at": 1445611902
},
"slaplan": null
}
]
}Display the specified resource.GET/api/ticket/ticket/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"data": {
"id": 1,
"number": "3189840",
"department_id": 2,
"department_email_id": 1,
"company_id": 1,
"channel_id": 1,
"user_id": 2,
"status_id": 1,
"priority_id": 1,
"sla_plan_id": null,
"subject": "Test",
"due_time": null,
"resolved_time": null,
"cc": [],
"locked": 0,
"merged": 0,
"internal": 0,
"created_at": 1445962331,
"updated_at": 1445962332,
"department": {
"id": 2,
"name": "Test",
"description": "Test",
"order": 2,
"parent": 1,
"public": 0,
"ticket_number_format": null,
"default_assignedto": null,
"notify_ticket_autoclose": 1,
"notify_ticket_closed": 1,
"notify_email_ticket": 1,
"email_templates": [],
"created_at": 1445960900,
"updated_at": 1445960900
},
"channel": {
"id": 1,
"name": "Web",
"enabled": 1,
"class": "App\Modules\Ticket\Channels\Web\Controllers\Web",
"created_at": 1445611904,
"updated_at": 1445611904
},
"user": {
"id": 2,
"firstname": "Joe",
"lastname": "Bloggs",
"email": "jbloggs@email.com",
"password": "$2y$10$dpQPojoAFxR.8cy6qCAUGOyRd6MtqavgqsJLWfvH/JfYlzCeV2GZu",
"session": null,
"remember_token": null,
"confirmed": 1,
"organisation_id": 3,
"organisation_access_level": 0,
"country": "US",
"language_code": "en",
"timezone": "Europe/London",
"avatar": null,
"twofa_enabled": 0,
"twofa_secret": null,
"twofa_token": null,
"twitter_id": null,
"twitter_handle": null,
"facebook_id": null,
"created_at": 1445613240,
"updated_at": 1446314521,
"formatted_name": "Joe Bloggs"
},
"status": {
"id": 1,
"name": "Open",
"colour": "#35a600",
"auto_close": 1,
"order": 1,
"created_at": 1445611902,
"updated_at": 1445611902
},
"priority": {
"id": 1,
"name": "Low",
"colour": "#3498db",
"order": 1,
"created_at": 1445611902,
"updated_at": 1445611902
},
"slaplan": null
}
}Store a newly created resource in storage.POST/api/ticket/ticket
Example URI
- user
integer(optional)The user opening the ticket, an operator ID is required if opening an internal ticket.
- user_firstname
string(optional)If a new user, set the user’s first name, required if no user ID set.
- user_lastname
string(optional)If a new user, set the user’s last name, required if no user ID set.
- user_email
string(optional)If a new user, set the user’s email, required if no user ID set.
- user_organisation
string(optional)If a new user, set the user’s organisation, will create a new organisation.
- user_ip_address
string(optional)The user’s IP address.
- department
integer(required)The department the ticket is being opened in.
- status
integer(required)The status of the new ticket.
- priority
integer(required)The priority of the new ticket.
- internal
boolean(optional) Default: 0If the ticket is internal (for operators only). If true, requires the user parameter to be set to an operator ID.
- subject
string(required)The ticket subject.
- text
string(required)The initial ticket message.
- tag
array(optional)An array of tag IDs for the new ticket.
- assignedto
array(optional)An array of operator IDs that are assigned to the new ticket.
- customfield
array(optional)An array of custom fields values, keyed by their ID.
- cc
array(optional)An array of email addresses to CC on the ticket.
- send_user_email
boolean(optional) Default: 1Whether to send an email to the user(s) about the new ticket.
- send_operators_email
boolean(optional) Default: 1Whether to send an email to operators about the new ticket.
- attachment[n][filename]
string(optional)Attachment filename.
- attachment[n][contents]
string(optional)Base64-encoded file contents.
Headers
Content-Type: application/x-www-form-urlencodedBody
user=2&department=2&status=1&priority=1&subject=Test&text=Testing+this200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully created new ticket!",
"data": {
"id": 1,
"number": "3189840",
"department_id": 2,
"department_email_id": 1,
"company_id": 1,
"channel_id": 1,
"user_id": 2,
"status_id": 1,
"priority_id": 1,
"sla_plan_id": null,
"subject": "Test",
"due_time": null,
"resolved_time": null,
"cc": [],
"locked": 0,
"merged": 0,
"internal": 0,
"created_at": 1445962331,
"updated_at": 1445962332,
"department": {
"id": 2,
"name": "Test",
"description": "Test",
"order": 2,
"parent": 1,
"public": 0,
"ticket_number_format": null,
"default_assignedto": null,
"notify_ticket_autoclose": 1,
"notify_ticket_closed": 1,
"notify_email_ticket": 1,
"email_templates": [],
"created_at": 1445960900,
"updated_at": 1445960900
},
"channel": {
"id": 1,
"name": "Web",
"enabled": 1,
"class": "App\Modules\Ticket\Channels\Web\Controllers\Web",
"created_at": 1445611904,
"updated_at": 1445611904
},
"user": {
"id": 2,
"firstname": "Joe",
"lastname": "Bloggs",
"email": "jbloggs@email.com",
"password": "$2y$10$dpQPojoAFxR.8cy6qCAUGOyRd6MtqavgqsJLWfvH/JfYlzCeV2GZu",
"session": null,
"remember_token": null,
"confirmed": 1,
"organisation_id": 3,
"organisation_access_level": 0,
"country": "US",
"language_code": "en",
"timezone": "Europe/London",
"avatar": null,
"twofa_enabled": 0,
"twofa_secret": null,
"twofa_token": null,
"twitter_id": null,
"twitter_handle": null,
"facebook_id": null,
"created_at": 1445613240,
"updated_at": 1446314521,
"formatted_name": "Joe Bloggs"
},
"status": {
"id": 1,
"name": "Open",
"colour": "#35a600",
"auto_close": 1,
"order": 1,
"created_at": 1445611902,
"updated_at": 1445611902
},
"priority": {
"id": 1,
"name": "Low",
"colour": "#3498db",
"order": 1,
"created_at": 1445611902,
"updated_at": 1445611902
},
"slaplan": null
}
}422Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The department field is required.",
"data": null
}Update the specified resource in storage.PUT/api/ticket/ticket/{id}
Example URI
- id
integer(required)The ID of the resource.
- user
integer(optional)Update the user on the ticket.
- department
integer(optional)Update the department on the ticket.
- status
integer(optional)Update the status on the ticket.
- priority
integer(optional)Update the priority on the ticket.
- subject
integer(optional)Update the subject on the ticket.
- assignedto
array(optional)An array of operator IDs that are assigned to the ticket.
- due_time
integer(optional)Manually set the due time on the ticket, set as a UNIX timestamp.
- locked
boolean(optional)If the ticket is locked and the user cannot add any further replies.
Headers
Content-Type: application/x-www-form-urlencodedBody
department=2200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully updated the ticket!",
"data": {
"id": 1,
"number": "3189840",
"department_id": 2,
"department_email_id": 1,
"company_id": 1,
"channel_id": 1,
"user_id": 2,
"status_id": 1,
"priority_id": 1,
"sla_plan_id": null,
"subject": "Test",
"due_time": null,
"resolved_time": null,
"cc": [],
"locked": 0,
"merged": 0,
"internal": 0,
"created_at": 1445962331,
"updated_at": 1445962332,
"department": {
"id": 2,
"name": "Test",
"description": "Test",
"order": 2,
"parent": 1,
"public": 0,
"ticket_number_format": null,
"default_assignedto": null,
"notify_ticket_autoclose": 1,
"notify_ticket_closed": 1,
"notify_email_ticket": 1,
"email_templates": [],
"created_at": 1445960900,
"updated_at": 1445960900
},
"channel": {
"id": 1,
"name": "Web",
"enabled": 1,
"class": "App\Modules\Ticket\Channels\Web\Controllers\Web",
"created_at": 1445611904,
"updated_at": 1445611904
},
"user": {
"id": 2,
"firstname": "Joe",
"lastname": "Bloggs",
"email": "jbloggs@email.com",
"password": "$2y$10$dpQPojoAFxR.8cy6qCAUGOyRd6MtqavgqsJLWfvH/JfYlzCeV2GZu",
"session": null,
"remember_token": null,
"confirmed": 1,
"organisation_id": 3,
"organisation_access_level": 0,
"country": "US",
"language_code": "en",
"timezone": "Europe/London",
"avatar": null,
"twofa_enabled": 0,
"twofa_secret": null,
"twofa_token": null,
"twitter_id": null,
"twitter_handle": null,
"facebook_id": null,
"created_at": 1445613240,
"updated_at": 1446314521,
"formatted_name": "Joe Bloggs"
},
"status": {
"id": 1,
"name": "Open",
"colour": "#35a600",
"auto_close": 1,
"order": 1,
"created_at": 1445611902,
"updated_at": 1445611902
},
"priority": {
"id": 1,
"name": "Low",
"colour": "#3498db",
"order": 1,
"created_at": 1445611902,
"updated_at": 1445611902
},
"slaplan": null
}
}422Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "There was an error updating the ticket.",
"data": null
}Remove the specified resource from storage.DELETE/api/ticket/ticket/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully deleted the ticket!",
"data": null
}Message ¶
Class TicketMessageController
Show all of the records.GET/api/ticket/message
Example URI
- ticket_id
integer(optional)Fetch only messages belonging to a certain ticket.
- include_draft
boolean(optional) Default: 0Whether to include drafts.
- start
integer(optional) Default: 0The first result to start from.
- limit
integer(optional) Default: 50The amount of results to fetch.
- order_column
string(optional) Default: idThe column to sort by.
- order_direction
string(optional) Default: ascThe ordering of the results.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"count": 1,
"data": [
{
"id": 1,
"ticket_id": 1,
"channel_id": 1,
"user_id": 1,
"user_ip_address": null,
"by": 0,
"type": 0,
"text": "est",
"is_draft": 0,
"social_id": null,
"created_at": 1445525220,
"updated_at": 1445525220,
"user": {
"id": 2,
"firstname": "Joe",
"lastname": "Bloggs",
"email": "jbloggs@email.com",
"password": "$2y$10$dpQPojoAFxR.8cy6qCAUGOyRd6MtqavgqsJLWfvH/JfYlzCeV2GZu",
"session": null,
"remember_token": null,
"confirmed": 1,
"organisation_id": 3,
"organisation_access_level": 0,
"country": "US",
"language_code": "en",
"timezone": "Europe/London",
"avatar": null,
"twofa_enabled": 0,
"twofa_secret": null,
"twofa_token": null,
"twitter_id": null,
"twitter_handle": null,
"facebook_id": null,
"created_at": 1445613240,
"updated_at": 1446314521,
"formatted_name": "Joe Bloggs"
}
}
]
}Display the specified resource.GET/api/ticket/message/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"data": {
"id": 1,
"ticket_id": 1,
"channel_id": 1,
"user_id": 1,
"user_ip_address": null,
"by": 0,
"type": 0,
"text": "est",
"is_draft": 0,
"social_id": null,
"created_at": 1445525220,
"updated_at": 1445525220,
"user": {
"id": 2,
"firstname": "Joe",
"lastname": "Bloggs",
"email": "jbloggs@email.com",
"password": "$2y$10$dpQPojoAFxR.8cy6qCAUGOyRd6MtqavgqsJLWfvH/JfYlzCeV2GZu",
"session": null,
"remember_token": null,
"confirmed": 1,
"organisation_id": 3,
"organisation_access_level": 0,
"country": "US",
"language_code": "en",
"timezone": "Europe/London",
"avatar": null,
"twofa_enabled": 0,
"twofa_secret": null,
"twofa_token": null,
"twitter_id": null,
"twitter_handle": null,
"facebook_id": null,
"created_at": 1445613240,
"updated_at": 1446314521,
"formatted_name": "Joe Bloggs"
}
}
}Store a newly created resource in storage.POST/api/ticket/message
Example URI
- ticket_id
string(required)The ticket we’re posting to.
- user_id
string(required)The user we’re posting on behalf of.
- user_ip_address
string(optional)The user’s IP address.
- message_type
integer(optional) Default: 0Whether we’re adding a normal message or an operator note (0 or 1).
- text
string(required)The message.
- cc
array(optional)An array of email addresses to CC on the ticket
- is_draft
integer(optional) Default: 0Whether the message is a draft.
- send_email
integer(optional) Default: 1Whether to send an email to appropriate parties (depending on the person posting the message).
- send_operators_email
integer(optional) Default: 0If an operator reply, whether to also send an email to the operators containing the reply. Does not apply with a user reply.
- attachment[n][filename]
string(optional)Attachment filename.
- attachment[n][contents]
string(optional)Base64-encoded file contents.
Headers
Content-Type: application/x-www-form-urlencodedBody
ticket_id=1&user_id=1&message200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully created new message!",
"data": {
"id": 1,
"ticket_id": 1,
"channel_id": 1,
"user_id": 1,
"user_ip_address": null,
"by": 0,
"type": 0,
"text": "est",
"is_draft": 0,
"social_id": null,
"created_at": 1445525220,
"updated_at": 1445525220,
"user": {
"id": 2,
"firstname": "Joe",
"lastname": "Bloggs",
"email": "jbloggs@email.com",
"password": "$2y$10$dpQPojoAFxR.8cy6qCAUGOyRd6MtqavgqsJLWfvH/JfYlzCeV2GZu",
"session": null,
"remember_token": null,
"confirmed": 1,
"organisation_id": 3,
"organisation_access_level": 0,
"country": "US",
"language_code": "en",
"timezone": "Europe/London",
"avatar": null,
"twofa_enabled": 0,
"twofa_secret": null,
"twofa_token": null,
"twitter_id": null,
"twitter_handle": null,
"facebook_id": null,
"created_at": 1445613240,
"updated_at": 1446314521,
"formatted_name": "Joe Bloggs"
}
}
}422Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The name field is required.",
"data": null
}Update the specified resource in storage.PUT/api/ticket/message/{id}
Example URI
- id
integer(required)The ID of the resource.
- text
string(required)The replacement text for the message.
Headers
Content-Type: application/x-www-form-urlencodedBody
text=I've+edited+this+message.200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully updated the message!",
"data": {
"id": 1,
"ticket_id": 1,
"channel_id": 1,
"user_id": 1,
"user_ip_address": null,
"by": 0,
"type": 0,
"text": "est",
"is_draft": 0,
"social_id": null,
"created_at": 1445525220,
"updated_at": 1445525220,
"user": {
"id": 2,
"firstname": "Joe",
"lastname": "Bloggs",
"email": "jbloggs@email.com",
"password": "$2y$10$dpQPojoAFxR.8cy6qCAUGOyRd6MtqavgqsJLWfvH/JfYlzCeV2GZu",
"session": null,
"remember_token": null,
"confirmed": 1,
"organisation_id": 3,
"organisation_access_level": 0,
"country": "US",
"language_code": "en",
"timezone": "Europe/London",
"avatar": null,
"twofa_enabled": 0,
"twofa_secret": null,
"twofa_token": null,
"twitter_id": null,
"twitter_handle": null,
"facebook_id": null,
"created_at": 1445613240,
"updated_at": 1446314521,
"formatted_name": "Joe Bloggs"
}
}
}422Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "There was an error updating the message.",
"data": null
}Remove the specified resource from storage.DELETE/api/ticket/message/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully deleted the message!",
"data": null
}Attachment ¶
Ticket attachments, each assigned to a specific ticket message.
Show all of the records.GET/api/ticket/attachment
Example URI
- ticket_id
integer(optional)Only fetch attachments associated with the ticket ID.
- message_id
integer(optional)Only fetch attachments associated with the ticket message ID.
- start
integer(optional) Default: 0The first result to start from.
- limit
integer(optional) Default: 50The amount of results to fetch.
- order_column
string(optional) Default: idThe column to sort by.
- order_direction
string(optional) Default: ascThe ordering of the results.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"count": 1,
"data": [
{
"id": 1,
"upload_hash": "b112b4d090c04d771c6d0d31dd5f77499b0b682c",
"ticket_id": 1,
"message_id": 12,
"original_name": "wall3[1].jpg",
"created_at": 1446224250,
"updated_at": 1446224250,
"upload": {
"id": 8,
"hash": "b112b4d090c04d771c6d0d31dd5f77499b0b682c",
"filename": "wall3[1].jpg",
"folder": "tickets",
"mime": "image/jpeg",
"size": "367.4 KB",
"created_at": 1446224225,
"updated_at": 1446224225
}
}
]
}Display the specified resource.GET/api/ticket/attachment/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"data": {
"id": 1,
"upload_hash": "b112b4d090c04d771c6d0d31dd5f77499b0b682c",
"ticket_id": 1,
"message_id": 12,
"original_name": "wall3[1].jpg",
"created_at": 1446224250,
"updated_at": 1446224250,
"upload": {
"id": 8,
"hash": "b112b4d090c04d771c6d0d31dd5f77499b0b682c",
"filename": "wall3[1].jpg",
"folder": "tickets",
"mime": "image/jpeg",
"size": "367.4 KB",
"created_at": 1446224225,
"updated_at": 1446224225
}
}
}Download the specified resource. Returns file data.GET/api/ticket/attachment/{id}/download
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonStore a newly created resource in storage.POST/api/ticket/attachment
Example URI
- message_id
integer(required)The ticket message to associate the attachment with.
- filename
string(required)The name of the file.
- contents
string(required)The base64-encoded file contents being uploaded.
Headers
Content-Type: application/x-www-form-urlencodedBody
message_id=1&filename=hello.jpg&contents=MQ==200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully created new attachment!",
"data": {
"id": 1,
"upload_hash": "b112b4d090c04d771c6d0d31dd5f77499b0b682c",
"ticket_id": 1,
"message_id": 12,
"original_name": "wall3[1].jpg",
"created_at": 1446224250,
"updated_at": 1446224250,
"upload": {
"id": 8,
"hash": "b112b4d090c04d771c6d0d31dd5f77499b0b682c",
"filename": "wall3[1].jpg",
"folder": "tickets",
"mime": "image/jpeg",
"size": "367.4 KB",
"created_at": 1446224225,
"updated_at": 1446224225
}
}
}422Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The filename field is required.",
"data": null
}Remove the specified resource from storage.DELETE/api/ticket/attachment/{id}
Example URI
- id
string(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully deleted the attachment!",
"data": null
}Status ¶
Used to identify the current state of a ticket.
Show all of the records.GET/api/ticket/status
Example URI
- start
integer(optional) Default: 0The first result to start from.
- limit
integer(optional) Default: 50The amount of results to fetch.
- order_column
string(optional) Default: idThe column to sort by.
- order_direction
string(optional) Default: ascThe ordering of the results.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"count": 1,
"data": [
{
"id": 1,
"name": "Open",
"colour": "#35a600",
"auto_close": 1,
"order": 1,
"created_at": 1445441559,
"updated_at": 1445441559
}
]
}Display the specified resource.GET/api/ticket/status/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"data": {
"id": 1,
"name": "Open",
"colour": "#35a600",
"auto_close": 1,
"order": 1,
"created_at": 1445441559,
"updated_at": 1445441559
}
}Store a newly created resource in storage.POST/api/ticket/status
Example URI
- name
string(required)The name of the status.
- colour
string(optional) Default: #FFFFFFThe colour of the status.
- auto_close
integer(required)Whether tickets should be automatically closed.
Headers
Content-Type: application/x-www-form-urlencodedBody
name=Open&auto_close=0200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully created new status!",
"data": {
"id": 1,
"name": "Open",
"colour": "#35a600",
"auto_close": 1,
"order": 1,
"created_at": 1445441559,
"updated_at": 1445441559
}
}422Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The name field is required.",
"data": null
}Update the specified resource in storage.PUT/api/ticket/status/{id}
Example URI
- id
integer(required)The ID of the resource.
- name
string(required)The name of the status.
- colour
string(optional) Default: #FFFFFFThe colour of the status.
- auto_close
integer(optional)Whether tickets should be automatically closed.
Headers
Content-Type: application/x-www-form-urlencodedBody
name=Open&colour=#999999200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully updated the status!",
"data": {
"id": 1,
"name": "Open",
"colour": "#35a600",
"auto_close": 1,
"order": 1,
"created_at": 1445441559,
"updated_at": 1445441559
}
}404Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The status with given ID was not found.",
"data": null
}422Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The name field is required.",
"data": null
}Remove the specified resource from storage.DELETE/api/ticket/status/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully deleted the status!",
"data": null
}Priority ¶
The urgency levels available for tickets.
Show all of the records.GET/api/ticket/priority
Example URI
- department_id
integer(optional)Fetch only the priorities associated with a given department
- start
integer(optional) Default: 0The first result to start from.
- limit
integer(optional) Default: 50The amount of results to fetch.
- order_column
string(optional) Default: idThe column to sort by.
- order_direction
string(optional) Default: ascThe ordering of the results.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"count": 1,
"data": [
{
"id": 1,
"name": "Low",
"colour": "#3498db",
"order": 1,
"created_at": 1445441559,
"updated_at": 1445441559
}
]
}Display the specified resource.GET/api/ticket/priority/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"data": {
"id": 1,
"name": "Low",
"colour": "#3498db",
"order": 1,
"created_at": 1445441559,
"updated_at": 1445441559
}
}Store a newly created resource in storage.POST/api/ticket/priority
Example URI
- name
string(required)The name of the priority.
- colour
string(optional) Default: #FFFFFFThe colour of the priority.
- depts
array(optional)List of department IDs.
Headers
Content-Type: application/x-www-form-urlencodedBody
name=Low&colour=#666200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully created new priority!",
"data": {
"id": 1,
"name": "Low",
"colour": "#3498db",
"order": 1,
"created_at": 1445441559,
"updated_at": 1445441559
}
}422Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The name field is required.",
"data": null
}Update the specified resource in storage.PUT/api/ticket/priority/{id}
Example URI
- id
integer(required)The ID of the resource.
- name
string(required)The name of the priority.
- colour
string(optional) Default: #FFFFFFThe colour of the priority.
- depts
array(optional)List of department IDs.
Headers
Content-Type: application/x-www-form-urlencodedBody
name=Low&colour=#999999200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully updated the priority!",
"data": {
"id": 1,
"name": "Low",
"colour": "#3498db",
"order": 1,
"created_at": 1445441559,
"updated_at": 1445441559
}
}404Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The priority with given ID was not found.",
"data": null
}422Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The name field is required.",
"data": null
}Remove the specified resource from storage.DELETE/api/ticket/priority/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully deleted the priority!",
"data": null
}Tag ¶
Tags can be given to tickets, as another way to categorise tickets.
Show all of the records.GET/api/ticket/tag
Example URI
- start
integer(optional) Default: 0The first result to start from.
- limit
integer(optional) Default: 50The amount of results to fetch.
- order_column
string(optional) Default: idThe column to sort by.
- order_direction
string(optional) Default: ascThe ordering of the results.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"count": 1,
"data": [
{
"id": 10,
"name": "Reseller",
"created_at": 1418237799,
"updated_at": 1418237799
}
]
}Display the specified resource.GET/api/ticket/tag/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"data": {
"id": 10,
"name": "Reseller",
"created_at": 1418237799,
"updated_at": 1418237799
}
}Store a newly created resource in storage.POST/api/ticket/tag
Example URI
- name
string(required)The name of the tag.
Headers
Content-Type: application/jsonBody
{
"name": "Reseller"
}200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully created new tag!",
"data": {
"id": 10,
"name": "Reseller",
"created_at": 1418237799,
"updated_at": 1418237799
}
}422Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The name field is required.",
"data": null
}Update the specified resource in storage.PUT/api/ticket/tag/{id}
Example URI
- id
integer(required)The ID of the resource.
- name
string(required)The name of the tag.
Headers
Content-Type: application/jsonBody
{
"name": "Reseller"
}200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully updated the tag!",
"data": {
"id": 10,
"name": "Reseller",
"created_at": 1418237799,
"updated_at": 1418237799
}
}404Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The tag with given ID was not found.",
"data": null
}422Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The name field is required.",
"data": null
}Remove the specified resource from storage.DELETE/api/ticket/tag/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully deleted the tag!",
"data": null
}Custom Field ¶
Fields that collect and store information on each ticket.
Show all of the records.GET/api/ticket/customfield
Example URI
- department_id
integer(optional)Fetch only the custom fields associated with a given department
- start
integer(optional) Default: 0The first result to start from.
- limit
integer(optional) Default: 50The amount of results to fetch.
- order_column
string(optional) Default: idThe column to sort by.
- order_direction
string(optional) Default: ascThe ordering of the results.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"count": 1,
"message": null,
"data": [
{
"id": 1,
"name": "IP Address",
"type": 8,
"order": 1,
"required": 0,
"public": 1,
"encrypted": 0,
"purge": 0,
"locked": 0,
"created_at": 1446228389,
"updated_at": 1446228389
}
]
}Display the specified resource.GET/api/ticket/customfield/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"data": {
"id": 1,
"name": "IP Address",
"type": 8,
"order": 1,
"required": 0,
"public": 1,
"encrypted": 0,
"purge": 0,
"locked": 0,
"created_at": 1446228389,
"updated_at": 1446228389
}
}Store a newly created resource in storage.POST/api/ticket/customfield
Example URI
- name
string(required)The name of the custom field.
- type
integer(required)The custom field type. 0 - Boolean, 1 - Checkbox, 2 - Checklist, 3 - Date, 4 - Multiple Options, 5 - Options, 6 - Password, 7 - Radio Buttons, 8 - Text, 9 - Textarea.
- depts
array(optional)List of department IDs.
- required
boolean(optional) Default: 0Whether the custom field is required to submit the form.
- public
boolean(optional) Default: 1Whether the custom field should be visible to users.
- encrypted
boolean(optional) Default: 0Whether to encrypt the custom field value in the database.
- purge
boolean(optional) Default: 0Whether to purge the custom field.
- locked
boolean(optional) Default: 0Whether to prevent edits to the custom field.
- options
array(optional)An array of options, only applied to Checklist, Multiple Options, Options and Radio Buttons.
Headers
Content-Type: application/x-www-form-urlencodedBody
name=IP Address&type=1&required=1&public=1&encrypted=0&purge=0&locked=0200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully created new custom field!",
"data": {
"id": 1,
"name": "IP Address",
"type": 8,
"order": 1,
"required": 0,
"public": 1,
"encrypted": 0,
"purge": 0,
"locked": 0,
"created_at": 1446228389,
"updated_at": 1446228389
}
}422Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The name field is required.",
"data": null
}Update the specified resource in storage.PUT/api/ticket/customfield/{id}
Example URI
- id
integer(required)The ID of the resource.
- name
string(optional)The name of the custom field.
- type
integer(optional)The custom field type. 0 - Boolean, 1 - Checkbox, 2 - Checklist, 3 - Date, 4 - Multiple Options, 5 - Options, 6 - Password, 7 - Radio Buttons, 8 - Text, 9 - Textarea.
- depts
array(optional)List of department IDs.
- required
boolean(optional) Default: 0Whether the custom field is required to submit the form.
- public
boolean(optional) Default: 1Whether the custom field should be visible to users.
- encrypted
boolean(optional) Default: 0Whether to encrypt the custom field value in the database.
- purge
boolean(optional) Default: 0Whether to purge the custom field.
- locked
boolean(optional) Default: 0Whether to prevent edits to the custom field.
- options
array(optional)An array of options, only applied to Checklist, Multiple Options, Options and Radio Buttons.
Headers
Content-Type: application/x-www-form-urlencodedBody
required=1200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully updated the custom field!",
"data": {
"id": 1,
"name": "IP Address",
"type": 8,
"order": 1,
"required": 1,
"public": 1,
"encrypted": 0,
"purge": 0,
"locked": 0,
"created_at": 1446228389,
"updated_at": 1446228389
}
}404Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The custom field with given ID was not found.",
"data": null
}422Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The name field is required.",
"data": null
}Remove the specified resource from storage.DELETE/api/ticket/customfield/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully deleted the custom field!",
"data": null
}Canned Response ¶
Commonly used replies by operators.
Show all of the records.GET/api/ticket/cannedresponse
Example URI
- start
integer(optional) Default: 0The first result to start from.
- limit
integer(optional) Default: 50The amount of results to fetch.
- order_column
string(optional) Default: idThe column to sort by.
- order_direction
string(optional) Default: ascThe ordering of the results.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"count": 1,
"data": [
{
"id": 1,
"name": "test",
"text": "test",
"category_id": 1,
"user_id": null,
"all_groups": 1,
"department_id": null,
"priority_id": null,
"status_id": null,
"tags": "[]",
"created_at": 1446134483,
"updated_at": 1446134483
}
]
}Display the specified resource.GET/api/ticket/cannedresponse/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"data": {
"id": 1,
"name": "Hello",
"text": "Hi,<br/>Thank you for your message, we'll get back to you shortly",
"user_id": null,
"public": 1,
"all_groups": 1,
"created_at": 1446134483,
"updated_at": 1446134483,
"tags": [],
"groups": []
}
}Store a newly created resource in storage.POST/api/ticket/cannedresponse
Example URI
- name
string(required)The name of the canned response.
- text
string(required)The canned response.
- tag
array(optional)An array of tag names for the canned response.
- groups
array(optional)List of operator groups who can see the canned response, an empty array means available to all operators.
Headers
Content-Type: application/x-www-form-urlencodedBody
name=Hello&text=Hi,<br/>Thank you for your message, we'll get back to you shortly.&category_id=1&public=0200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully created new canned response!",
"data": {
"id": 1,
"name": "Hello",
"text": "Hi,<br/>Thank you for your message, we'll get back to you shortly",
"user_id": null,
"public": 1,
"all_groups": 1,
"created_at": 1446134483,
"updated_at": 1446134483,
"tags": [],
"groups": []
}
}422Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The name field is required.",
"data": null
}Update the specified resource in storage.PUT/api/ticket/cannedresponse/{id}
Example URI
- id
integer(required)The ID of the resource.
- name
string(optional)The name of the canned response.
- text
string(optional)The canned response.
- tag
array(optional)An array of tag names for the canned response. Will replace the existing tags on the canned response.
- groups
array(optional)List of operator groups who can see the canned response, an empty array means available to all operators.
Headers
Content-Type: application/x-www-form-urlencodedBody
name=Low&colour=#999999200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully updated the canned response!",
"data": {
"id": 1,
"name": "Hello",
"text": "Hi,<br/>Thank you for your message, we'll get back to you shortly",
"user_id": null,
"public": 1,
"all_groups": 1,
"created_at": 1446134483,
"updated_at": 1446134483,
"tags": [],
"groups": []
}
}404Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The canned response with given ID was not found.",
"data": null
}422Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The name field is required.",
"data": null
}Remove the specified resource from storage.DELETE/api/ticket/cannedresponse/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully deleted the canned response!",
"data": null
}Department ¶
Tickets are divided into different departments.
Show all of the records.GET/api/ticket/department
Example URI
- parent_id
integer(optional)Fetch subdeparments of a given parent, set to 0 to fetch all parent departments only.
- public
boolean(optional)Fetch public or hidden departments only.
- start
integer(optional) Default: 0The first result to start from.
- limit
integer(optional) Default: 50The amount of results to fetch.
- order_column
string(optional) Default: idThe column to sort by.
- order_direction
string(optional) Default: ascThe ordering of the results.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"count": 1,
"data": [
{
"id": 1,
"name": "Support",
"description": "This is an automatically generated department, please edit me.",
"order": 1,
"parent_id": null,
"public": 1,
"ticket_number_format": null,
"default_assignedto": null,
"notify_ticket_autoclose": 1,
"notify_ticket_closed": 1,
"notify_email_ticket": 1,
"email_templates": {
"ticket_opened": 3,
"ticket_reply": 2,
"ticket_locked": 8,
"ticket_autoclose": 13,
"ticket_operatorclose": 20
},
"created_at": 1445441560,
"updated_at": 1445441560,
"emails": [
{
"id": 1,
"department_id": 1,
"address": "support@my.company",
"type": 0,
"protocol": null,
"server": null,
"username": null,
"password": null,
"port": null,
"encryption": null,
"consume_all": null,
"delete_downloaded": null,
"created_at": 0,
"updated_at": 0
}
],
"operators": [
{
"id": 1,
"firstname": "Joe",
"lastname": "Blogs",
"email": "joe.blogs@mycompany.com",
"confirmed": 1,
"organisation_id": null,
"organisation_access_level": null,
"country": null,
"language_code": null,
"timezone": null,
"avatar": "R0lGODlhQABAANUAAAAAAP////7+/v39/fz8/Pv7+/r6+vn5+fj4+Pf39/b29vX19fT09PPz8/Ly8vHx8fDw8O/v7+7u7u3t7ezs7Orq6unp6ejo6Ofn5+bm5uXl5eTk5OPj4+Li4uHh4eDg4N/f393d3dzc3Nvb29ra2tnZ2djY2NfX19bW1tXV1dTU1NPT09LS0tHR0dDQ0M/Pz87Ozs3NzczMzAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACwAAAAAQABAAAAG/8CAcEgsGo/IpHLJbDqf0Kh0Sq1ar9isdss1JjKll+ylClkM3WsBFJO5324YCJ2WFlDw/LvVqDsFFHh6gzIwDH5LAyOEjDIqA4hJIY2NFpFHEZSNKZdGJZqNCJ1DBTCgjBKjQg2njBiqARKthBuwE7ODtaqZuHmvqqy9cBWwB23CbhSwAi3IbhGwAYvOCtEYzi+QsAzOJtEBAizIGd8BHMgL5QvHsykC5QInvRflQrezLnTlAyqzuvUB7oFqoa+egBWniAEcIkhTuoVCGlKqBpGAOFATIBr4dOoFBIMUms2K8UGUqgEUUjiLIeLBO0QKNoh09mYFhgJdAJlgRzMPDIoPB7RIQNiTEowOBKwM+FC0VYuMUwZwbNrqVxSmVHFBgxIs66wWSZ+Q8NpLwxMEPMkO1MbEgtpeH5uIeIvrQ5NwdGepaGIg78iCSB74neWg7eBWCpV0OHyqA5O5jDWJYCIvMqUTTIhaZrSCiZjNjFwwSQsaDgwmpRnFQJ160AvWrfN0XhJbDwkjQQAAOw==",
"created_at": 1445441612,
"updated_at": 1445954346,
"formatted_name": "Joe Blogs",
"pivot": {
"department_id": 1,
"user_id": 1
}
}
]
}
]
}Display the specified resource.GET/api/ticket/department/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"data": {
"id": 1,
"name": "Support",
"description": "This is an automatically generated department, please edit me.",
"order": 1,
"parent_id": null,
"public": 1,
"ticket_number_format": null,
"default_assignedto": null,
"notify_ticket_autoclose": 1,
"notify_ticket_closed": 1,
"notify_email_ticket": 1,
"email_templates": {
"ticket_opened": 3,
"ticket_reply": 2,
"ticket_locked": 8,
"ticket_autoclose": 13,
"ticket_operatorclose": 20
},
"created_at": 1445441560,
"updated_at": 1445441560,
"emails": [
{
"id": 1,
"department_id": 1,
"address": "support@my.company",
"type": 0,
"protocol": null,
"server": null,
"username": null,
"password": null,
"port": null,
"encryption": null,
"consume_all": null,
"delete_downloaded": null,
"created_at": 0,
"updated_at": 0
}
],
"operators": [
{
"id": 1,
"firstname": "Joe",
"lastname": "Blogs",
"email": "joe.blogs@mycompany.com",
"confirmed": 1,
"organisation_id": null,
"organisation_access_level": null,
"country": null,
"language_code": null,
"timezone": null,
"avatar": "R0lGODlhQABAANUAAAAAAP////7+/v39/fz8/Pv7+/r6+vn5+fj4+Pf39/b29vX19fT09PPz8/Ly8vHx8fDw8O/v7+7u7u3t7ezs7Orq6unp6ejo6Ofn5+bm5uXl5eTk5OPj4+Li4uHh4eDg4N/f393d3dzc3Nvb29ra2tnZ2djY2NfX19bW1tXV1dTU1NPT09LS0tHR0dDQ0M/Pz87Ozs3NzczMzAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACwAAAAAQABAAAAG/8CAcEgsGo/IpHLJbDqf0Kh0Sq1ar9isdss1JjKll+ylClkM3WsBFJO5324YCJ2WFlDw/LvVqDsFFHh6gzIwDH5LAyOEjDIqA4hJIY2NFpFHEZSNKZdGJZqNCJ1DBTCgjBKjQg2njBiqARKthBuwE7ODtaqZuHmvqqy9cBWwB23CbhSwAi3IbhGwAYvOCtEYzi+QsAzOJtEBAizIGd8BHMgL5QvHsykC5QInvRflQrezLnTlAyqzuvUB7oFqoa+egBWniAEcIkhTuoVCGlKqBpGAOFATIBr4dOoFBIMUms2K8UGUqgEUUjiLIeLBO0QKNoh09mYFhgJdAJlgRzMPDIoPB7RIQNiTEowOBKwM+FC0VYuMUwZwbNrqVxSmVHFBgxIs66wWSZ+Q8NpLwxMEPMkO1MbEgtpeH5uIeIvrQ5NwdGepaGIg78iCSB74neWg7eBWCpV0OHyqA5O5jDWJYCIvMqUTTIhaZrSCiZjNjFwwSQsaDgwmpRnFQJ160AvWrfN0XhJbDwkjQQAAOw==",
"created_at": 1445441612,
"updated_at": 1445954346,
"formatted_name": "Joe Blogs",
"pivot": {
"department_id": 1,
"user_id": 1
}
}
]
}
}Store a newly created resource in storage.POST/api/ticket/department
Example URI
- name
string(required)The name of the department.
- description
string(optional)Description of the department, shown to users.
- public
integer(optional) Default: 1Whether the department is visible to users.
- dept_operators
array(optional)List of operator IDs that are assigned to this department.
- default_assignedto
integer(optional)List of operator IDs which should be automatically assigned on new tickets.
- notify_ticket_autoclose
integer(optional)Whether to send an email on ticket auto close.
- notify_ticket_closed
integer(optional)Whether to send an email when the ticket is closed by an operator.
- notify_email_ticket
integer(optional)Whether to email the user when a ticket is opened via email.
Headers
Content-Type: application/x-www-form-urlencodedBody
name=Support&parent=0200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully created new department!",
"data": {
"id": 1,
"name": "Support",
"description": "This is an automatically generated department, please edit me.",
"order": 1,
"parent": null,
"public": 1,
"ticket_number_format": null,
"default_assignedto": null,
"notify_ticket_autoclose": 1,
"notify_ticket_closed": 1,
"notify_email_ticket": 1,
"email_templates": {
"ticket_opened": 3,
"ticket_reply": 2,
"ticket_locked": 8,
"ticket_autoclose": 13,
"ticket_operatorclose": 20
},
"created_at": 1445441560,
"updated_at": 1445441560,
"emails": [
{
"id": 1,
"department_id": 1,
"address": "support@my.company",
"type": 0,
"protocol": null,
"server": null,
"username": null,
"password": null,
"port": null,
"encryption": null,
"consume_all": null,
"delete_downloaded": null,
"created_at": 0,
"updated_at": 0
}
],
"operators": [
{
"id": 1,
"firstname": "Joe",
"lastname": "Blogs",
"email": "joe.blogs@mycompany.com",
"confirmed": 1,
"organisation_id": null,
"organisation_access_level": null,
"country": null,
"language_code": null,
"timezone": null,
"avatar": "R0lGODlhQABAANUAAAAAAP////7+/v39/fz8/Pv7+/r6+vn5+fj4+Pf39/b29vX19fT09PPz8/Ly8vHx8fDw8O/v7+7u7u3t7ezs7Orq6unp6ejo6Ofn5+bm5uXl5eTk5OPj4+Li4uHh4eDg4N/f393d3dzc3Nvb29ra2tnZ2djY2NfX19bW1tXV1dTU1NPT09LS0tHR0dDQ0M/Pz87Ozs3NzczMzAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACwAAAAAQABAAAAG/8CAcEgsGo/IpHLJbDqf0Kh0Sq1ar9isdss1JjKll+ylClkM3WsBFJO5324YCJ2WFlDw/LvVqDsFFHh6gzIwDH5LAyOEjDIqA4hJIY2NFpFHEZSNKZdGJZqNCJ1DBTCgjBKjQg2njBiqARKthBuwE7ODtaqZuHmvqqy9cBWwB23CbhSwAi3IbhGwAYvOCtEYzi+QsAzOJtEBAizIGd8BHMgL5QvHsykC5QInvRflQrezLnTlAyqzuvUB7oFqoa+egBWniAEcIkhTuoVCGlKqBpGAOFATIBr4dOoFBIMUms2K8UGUqgEUUjiLIeLBO0QKNoh09mYFhgJdAJlgRzMPDIoPB7RIQNiTEowOBKwM+FC0VYuMUwZwbNrqVxSmVHFBgxIs66wWSZ+Q8NpLwxMEPMkO1MbEgtpeH5uIeIvrQ5NwdGepaGIg78iCSB74neWg7eBWCpV0OHyqA5O5jDWJYCIvMqUTTIhaZrSCiZjNjFwwSQsaDgwmpRnFQJ160AvWrfN0XhJbDwkjQQAAOw==",
"created_at": 1445441612,
"updated_at": 1445954346,
"formatted_name": "Joe Blogs",
"pivot": {
"department_id": 1,
"user_id": 1
}
}
]
}
}422Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The name field is required.",
"data": null
}Store a newly created resource in storage.POST/api/ticket/department
Example URI
- id
integer(required)The ID of the resource.
- name
string(optional)The name of the department.
- public
integer(optional) Default: 1Whether the department is visible to users.
- dept_operators
array(optional)List of operator IDs that are assigned to this department.
- default_assignedto
integer(optional)List of operator IDs which should be automatically assigned on new tickets.
- notify_ticket_autoclose
integer(optional)Whether to send an email on ticket auto close.
- notify_ticket_closed
integer(optional)Whether to send an email when the ticket is closed by an operator.
- notify_email_ticket
integer(optional)Whether to email the user when a ticket is opened via email.
Headers
Content-Type: application/x-www-form-urlencodedBody
name=Support&parent=0200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully created new department!",
"data": {
"id": 1,
"name": "Support",
"description": "This is an automatically generated department, please edit me.",
"order": 1,
"parent_id": null,
"public": 1,
"ticket_number_format": null,
"default_assignedto": null,
"notify_ticket_autoclose": 1,
"notify_ticket_closed": 1,
"notify_email_ticket": 1,
"email_templates": {
"ticket_opened": 3,
"ticket_reply": 2,
"ticket_locked": 8,
"ticket_autoclose": 13,
"ticket_operatorclose": 20
},
"created_at": 1445441560,
"updated_at": 1445441560,
"emails": [
{
"id": 1,
"department_id": 1,
"address": "support@my.company",
"type": 0,
"protocol": null,
"server": null,
"username": null,
"password": null,
"port": null,
"encryption": null,
"consume_all": null,
"delete_downloaded": null,
"created_at": 0,
"updated_at": 0
}
],
"operators": [
{
"id": 1,
"firstname": "Joe",
"lastname": "Blogs",
"email": "joe.blogs@mycompany.com",
"confirmed": 1,
"organisation_id": null,
"organisation_access_level": null,
"country": null,
"language_code": null,
"timezone": null,
"avatar": "R0lGODlhQABAANUAAAAAAP////7+/v39/fz8/Pv7+/r6+vn5+fj4+Pf39/b29vX19fT09PPz8/Ly8vHx8fDw8O/v7+7u7u3t7ezs7Orq6unp6ejo6Ofn5+bm5uXl5eTk5OPj4+Li4uHh4eDg4N/f393d3dzc3Nvb29ra2tnZ2djY2NfX19bW1tXV1dTU1NPT09LS0tHR0dDQ0M/Pz87Ozs3NzczMzAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACwAAAAAQABAAAAG/8CAcEgsGo/IpHLJbDqf0Kh0Sq1ar9isdss1JjKll+ylClkM3WsBFJO5324YCJ2WFlDw/LvVqDsFFHh6gzIwDH5LAyOEjDIqA4hJIY2NFpFHEZSNKZdGJZqNCJ1DBTCgjBKjQg2njBiqARKthBuwE7ODtaqZuHmvqqy9cBWwB23CbhSwAi3IbhGwAYvOCtEYzi+QsAzOJtEBAizIGd8BHMgL5QvHsykC5QInvRflQrezLnTlAyqzuvUB7oFqoa+egBWniAEcIkhTuoVCGlKqBpGAOFATIBr4dOoFBIMUms2K8UGUqgEUUjiLIeLBO0QKNoh09mYFhgJdAJlgRzMPDIoPB7RIQNiTEowOBKwM+FC0VYuMUwZwbNrqVxSmVHFBgxIs66wWSZ+Q8NpLwxMEPMkO1MbEgtpeH5uIeIvrQ5NwdGepaGIg78iCSB74neWg7eBWCpV0OHyqA5O5jDWJYCIvMqUTTIhaZrSCiZjNjFwwSQsaDgwmpRnFQJ160AvWrfN0XhJbDwkjQQAAOw==",
"created_at": 1445441612,
"updated_at": 1445954346,
"formatted_name": "Joe Blogs",
"pivot": {
"department_id": 1,
"user_id": 1
}
}
]
}
}422Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The name field is required.",
"data": null
}Remove the specified resource from storage.DELETE/api/ticket/department/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully deleted the department!",
"data": null
}Settings ¶
Ticket system settings.
General SettingsGET/api/ticket/settings
Example URI
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"data": {
"allowed_files": "doc|docx|png|gif|jpg|jpeg|zip|rar|pdf|txt|tpl|log",
"default_open_status": "1",
"default_resolved_status": "2",
"inactive_close_time": "604800",
"ticket_notes_position": "0",
"ticket_number_format": "%N{7}",
"ticket_reply_order": "0"
}
}Channel Settings ¶
Fetch the settings for a given channel.
Channel SettingsGET/api/ticket/{channel}/settings
Example URI
- channel
string(required)The channel name, e.g. ‘web’.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"data": {
"unauthenticated_users": "1",
"show_captcha": "1",
"show_related_articles": "1"
}
}Self-Service ¶
Type ¶
Self-service types, individual sections in the frontend for self-service content.
Show all of the records.GET/api/selfservice/type
Example URI
- start
integer(optional) Default: 0The first result to start from.
- limit
integer(optional) Default: 50The amount of results to fetch.
- order_column
string(optional) Default: idThe column to sort by.
- order_direction
string(optional) Default: ascThe ordering of the results.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"count": 1,
"data": [
{
"id": 1,
"name": "Announcements",
"slug": "announcements",
"description": "View the latest news and announcements.",
"order": 1,
"enabled": 1,
"view": 1,
"icon": "...",
"show_on_dashboard": 1,
"created_at": 1418237799,
"updated_at": 1418237799
}
]
}Display the specified resource.GET/api/selfservice/type/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"data": {
"id": 1,
"name": "Announcements",
"slug": "announcements",
"description": "View the latest news and announcements.",
"order": 1,
"enabled": 1,
"view": 1,
"icon": "...",
"show_on_dashboard": 1,
"created_at": 1418237799,
"updated_at": 1418237799
}
}Store a newly created resource in storage.POST/api/selfservice/type
Example URI
- name
string(required)The name of the type.
- description
string(required)A description of the type, shows under the name on the frontend dashboard.
- enabled
boolean(optional) Default: 1If the type is enabled and visible in the frontend.
- view
boolean(required)The view type, 0 for hierarchical view and 1 for list view.
- order
int(optional)Position of the type.
- show_on_dashboard
boolean(optional) Default: 1Shows some articles on the frontend dashboard. If view is set to hierarchical, it will show the 5 most viewed articles, else if list, it will show the 5 latest articles.
Headers
Content-Type: application/x-www-form-urlencodedBody
name=Announcements&description=View+the+latest+news+and+announcements.&view=1200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully created new type!",
"data": {
"id": 1,
"name": "Announcements",
"slug": "announcements",
"description": "View the latest news and announcements.",
"order": 1,
"enabled": 1,
"view": 1,
"show_on_dashboard": 1,
"created_at": 1418237799,
"updated_at": 1418237799
}
}422Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The name field is required.",
"data": null
}Update the specified resource in storage.PUT/api/selfservice/type/{id}
Example URI
- id
integer(required)The ID of the resource.
- name
string(optional)The name of the type.
- description
string(optional)A description of the type, shows on the frontend dashboard.
- enabled
boolean(optional)If the type is enabled and visible in the frontend.
- view
boolean(optional)The view type, 0 for hierarchical view and 1 for list view.
- order
int(optional)Position of the type.
- show_on_dashboard
boolean(optional)Shows some articles on the frontend dashboard. If view is set to hierarchical, it will show the 5 most viewed articles, else if list, it will show the 5 latest articles.
Headers
Content-Type: application/x-www-form-urlencodedBody
name=Announcements&view=1200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully updated the type!",
"data": {
"id": 1,
"name": "Announcements",
"slug": "announcements",
"description": "View the latest news and announcements.",
"order": 1,
"enabled": 1,
"view": 1,
"icon": "...",
"show_on_dashboard": 1,
"created_at": 1418237799,
"updated_at": 1418237799
}
}404Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The type with given ID was not found.",
"data": null
}Remove the specified resource from storage.DELETE/api/selfservice/type/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully deleted the type!",
"data": null
}Tag ¶
Self-service tags, another way to categorise articles.
Show all of the records.GET/api/selfservice/tag
Example URI
- start
integer(optional) Default: 0The first result to start from.
- limit
integer(optional) Default: 50The amount of results to fetch.
- order_column
string(optional) Default: idThe column to sort by.
- order_direction
string(optional) Default: ascThe ordering of the results.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"count": 1,
"data": [
{
"id": 10,
"name": "Reseller",
"slug": "reseller",
"created_at": 1418237799,
"updated_at": 1418237799
}
]
}Display the specified resource.GET/api/selfservice/tag/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"data": {
"id": 10,
"name": "Reseller",
"slug": "reseller",
"created_at": 1418237799,
"updated_at": 1418237799
}
}Store a newly created resource in storage.POST/api/selfservice/tag
Example URI
- name
string(required)The name of the tag.
Headers
Content-Type: application/x-www-form-urlencodedBody
name=Reseller200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully created new tag!",
"data": {
"id": 10,
"name": "Reseller",
"slug": "reseller",
"created_at": 1418237799,
"updated_at": 1418237799
}
}422Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The name field is required.",
"data": null
}Update the specified resource in storage.PUT/api/selfservice/tag/{id}
Example URI
- id
integer(required)The ID of the resource.
- name
string(optional)The name of the tag.
Headers
Content-Type: application/x-www-form-urlencodedBody
name=Reseller200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully updated the tag!",
"data": {
"id": 10,
"name": "Reseller",
"slug": "reseller",
"created_at": 1418237799,
"updated_at": 1418237799
}
}404Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The tag with given ID was not found.",
"data": null
}Remove the specified resource from storage.DELETE/api/selfservice/tag/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully deleted the tag!",
"data": null
}Category ¶
Self-service categories, filterable by type.
Show all of the records.GET/api/selfservice/category
Example URI
- type_id
integer(optional)The type of the categories.
- parent_id
integer(optional)Fetch categories with the given parent, set to 0 to fetch all top level categories only.
- public
boolean(optional)If the category is public to users.
- parent_public
boolean(optional)If the top level parent category is public to users.
- start
integer(optional) Default: 0The first result to start from.
- limit
integer(optional) Default: 50The amount of results to fetch.
- order_column
string(optional) Default: idThe column to sort by.
- order_direction
string(optional) Default: ascThe ordering of the results.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"count": 1,
"data": [
{
"id": 1,
"type_id": 1,
"parent": null,
"name": "General",
"slug": "general",
"public": 1,
"parent_public": 1,
"created_at": 1446329149,
"updated_at": 1446329149,
"type": {
"id": 1,
"name": "Announcements",
"slug": "announcements",
"description": "View the latest news and announcements.",
"view": 1,
"icon": "...",
"show_on_dashboard": 1,
"created_at": 1445611905,
"updated_at": 1445611905
}
}
]
}Display the specified resource.GET/api/selfservice/category/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"data": {
"id": 1,
"type_id": 1,
"parent": null,
"name": "General",
"slug": "general",
"public": 1,
"parent_public": 1,
"created_at": 1446329149,
"updated_at": 1446329149,
"type": {
"id": 1,
"name": "Announcements",
"slug": "announcements",
"description": "View the latest news and announcements.",
"view": 1,
"icon": "...",
"show_on_dashboard": 1,
"created_at": 1445611905,
"updated_at": 1445611905
}
}
}Store a newly created resource in storage.POST/api/selfservice/category
Example URI
- type_id
integer(required)The type that the category belongs to.
- name
string(required)The name of the category.
- parent_id
integer(optional)If the category is a child, enter the parent ID. The parent must have the same type.
- public
boolean(optional) Default: 0If the category is public to users.
Headers
Content-Type: application/x-www-form-urlencodedBody
type_id=1&name=Support&public=1200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully created new category!",
"data": {
"id": 1,
"type_id": 1,
"parent": null,
"name": "General",
"slug": "general",
"public": 1,
"parent_public": 1,
"created_at": 1446329149,
"updated_at": 1446329149,
"type": {
"id": 1,
"name": "Announcements",
"slug": "announcements",
"description": "View the latest news and announcements.",
"view": 1,
"icon": "...",
"show_on_dashboard": 1,
"created_at": 1445611905,
"updated_at": 1445611905
}
}
}422Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The name field is required.",
"data": null
}Update the specified resource in storage.PUT/api/selfservice/category/{id}
Example URI
- id
integer(required)The ID of the resource.
- type_id
integer(optional)The type that the category belongs to.
- name
string(optional)The name of the category.
- parent_id
integer(optional)If the category is a child, enter the parent ID. The parent must have the same type.
- public
boolean(optional) Default: 0If the category is public to users.
Headers
Content-Type: application/x-www-form-urlencodedBody
type_id=1&name=Support&public=1200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully updated the category!",
"data": {
"id": 1,
"type_id": 1,
"parent": null,
"name": "General",
"slug": "general",
"public": 1,
"parent_public": 1,
"created_at": 1446329149,
"updated_at": 1446329149,
"type": {
"id": 1,
"name": "Announcements",
"slug": "announcements",
"description": "View the latest news and announcements.",
"view": 1,
"icon": "...",
"show_on_dashboard": 1,
"created_at": 1445611905,
"updated_at": 1445611905
}
}
}404Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The category with given ID was not found.",
"data": null
}422Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The name field is required.",
"data": null
}Remove the specified resource from storage.DELETE/api/selfservice/category/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully deleted the category!",
"data": null
}Article ¶
Self-service articles, filterable by type, category and tags.
Show all of the records.GET/api/selfservice/article
Example URI
- type_id
integer(optional)The type of the articles
- category_id
integer(optional)The category of the articles
- tag_id
integer(optional)The tag associated with articles
- include_subcategories
boolean(optional) Default: 0Include articles from subcategories of given category
- start
integer(optional) Default: 0The first result to start from.
- limit
integer(optional) Default: 50The amount of results to fetch.
- order_column
string(optional) Default: idThe column to sort by.
- order_direction
string(optional) Default: ascThe ordering of the results.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"count": 1,
"data": [
{
"id": 1,
"type_id": 1,
"author_id": 1,
"title": "Test Article",
"slug": "test-article",
"keywords": "test, article",
"excerpt": "This is an article",
"text": "An article for the masses.",
"views": 0,
"positive_rating": 0,
"total_rating": 0,
"published": 1,
"protected": 0,
"created_at": 1446329199,
"updated_at": 1446329199,
"frontend_url": "http://localhost/supportpal_v2/Announcements/article/test-article",
"type": {
"id": 1,
"name": "Announcements",
"slug": "announcements",
"description": "View the latest news and announcements.",
"view": 1,
"icon": "...",
"show_on_dashboard": 1,
"created_at": 1445611905,
"updated_at": 1445611905
},
"categories": {
"0": {
"id": 1,
"type_id": 1,
"parent_id": null,
"name": "General",
"slug": "general",
"public": 1,
"parent_public": 1,
"created_at": 1449600034,
"updated_at": 1449600034,
"pivot": {
"article_id": 1,
"category_id": 1
}
},
"tags": [
{
"id": 1,
"name": "Test",
"slug": "test",
"created_at": 1449599991,
"updated_at": 1449600099,
"pivot": {
"article_id": 1,
"tag_id": 1
}
}
],
"attachments": []
}
}
]
}Display the specified resource. Also adds a view to the view counter.GET/api/selfservice/article/{id}
Example URI
- id
integer(required)The ID of the resource.
- increment_views
boolean(optional)Increment the article view count.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"data": {
"id": 1,
"type_id": 1,
"author_id": 1,
"title": "Test Article",
"slug": "test-article",
"keywords": "test, article",
"excerpt": "This is an article",
"text": "An article for the masses.",
"views": 0,
"positive_rating": 0,
"total_rating": 0,
"published": 1,
"protected": 0,
"created_at": 1446329199,
"updated_at": 1446329199,
"frontend_url": "http://localhost/supportpal_v2/Announcements/article/test-article",
"type": {
"id": 1,
"name": "Announcements",
"slug": "announcements",
"description": "View the latest news and announcements.",
"view": 1,
"icon": "...",
"show_on_dashboard": 1,
"created_at": 1445611905,
"updated_at": 1445611905
},
"categories": {
"0": {
"id": 1,
"type_id": 1,
"parent_id": null,
"name": "General",
"slug": "general",
"public": 1,
"parent_public": 1,
"created_at": 1449600034,
"updated_at": 1449600034,
"pivot": {
"article_id": 1,
"category_id": 1
}
},
"tags": [
{
"id": 1,
"name": "Test",
"slug": "test",
"created_at": 1449599991,
"updated_at": 1449600099,
"pivot": {
"article_id": 1,
"tag_id": 1
}
}
],
"attachments": []
}
}
}Store a newly created resource in storage.POST/api/selfservice/article
Example URI
- type_id
integer(required)The type that the article belongs to.
- author_id
integer(required)The ID of the operator who has written this article.
- title
string(required)The title of the article.
- keywords
string(optional)Any keywords for the article, mainly used for SEO.
- excerpt
string(optional)An excerpt of the article, maximum 255 characters.
- text
string(required)An excerpt of the article, maximum 255 characters.
- published
boolean(optional) Default: 0If the article is published to users.
- protected
boolean(optional) Default: 0If only logged in users can view the article.
- category
array(required)An array of category IDs to which the article belongs to.
- tag
array(optional)An array of tag IDs for the article.
Headers
Content-Type: application/x-www-form-urlencodedBody
type_id=1&author_id=1&title=Test+Article&excerpt=This+is+a+test+article+for+the+help+desk&text=This+is+a+test+article,+please+make+sure+this+is+right+before+publishing+it.&published=1&protected=0&category[]=1200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully created new article!",
"data": {
"id": 1,
"type_id": 1,
"author_id": 1,
"title": "Test Article",
"slug": "test-article",
"keywords": "test, article",
"excerpt": "This is an article",
"text": "An article for the masses.",
"views": 0,
"positive_rating": 0,
"total_rating": 0,
"published": 1,
"protected": 0,
"created_at": 1446329199,
"updated_at": 1446329199,
"frontend_url": "http://localhost/supportpal_v2/Announcements/article/test-article",
"type": {
"id": 1,
"name": "Announcements",
"slug": "announcements",
"description": "View the latest news and announcements.",
"view": 1,
"icon": "...",
"show_on_dashboard": 1,
"created_at": 1445611905,
"updated_at": 1445611905
},
"categories": {
"0": {
"id": 1,
"type_id": 1,
"parent_id": null,
"name": "General",
"slug": "general",
"public": 1,
"parent_public": 1,
"created_at": 1449600034,
"updated_at": 1449600034,
"pivot": {
"article_id": 1,
"category_id": 1
}
},
"tags": [
{
"id": 1,
"name": "Test",
"slug": "test",
"created_at": 1449599991,
"updated_at": 1449600099,
"pivot": {
"article_id": 1,
"tag_id": 1
}
}
],
"attachments": []
}
}
}422Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The name field is required.",
"data": null
}Update the specified resource in storage.PUT/api/selfservice/article/{id}
Example URI
- id
integer(required)The ID of the resource.
- type_id
integer(optional)The type that the article belongs to.
- author_id
integer(optional)The ID of the operator who has written this article.
- title
string(optional)The title of the article.
- keywords
string(optional)Any keywords for the article, mainly used for SEO.
- excerpt
string(optional)An excerpt of the article, maximum 255 characters.
- text
string(optional)An excerpt of the article, maximum 255 characters.
- published
boolean(optional) Default: 0If the article is published to users.
- protected
boolean(optional) Default: 0If only logged in users can view the article.
- category
array(optional)An array of category IDs to which the article belongs to.
- tag
array(optional)An array of tag IDs for the article.
Headers
Content-Type: application/x-www-form-urlencodedBody
type_id=1&author_id=1&title=Test+Article&excerpt=This+is+a+test+article+for+the+help+desk&text=This+is+a+test+article,+please+make+sure+this+is+right+before+publishing+it.&published=1&protected=0&category[]=1200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully updated the article!",
"data": {
"id": 1,
"type_id": 1,
"author_id": 1,
"title": "Test Article",
"slug": "test-article",
"keywords": "test, article",
"excerpt": "This is an article",
"text": "An article for the masses.",
"views": 0,
"positive_rating": 0,
"total_rating": 0,
"published": 1,
"protected": 0,
"created_at": 1446329199,
"updated_at": 1446329199,
"frontend_url": "http://localhost/supportpal_v2/Announcements/article/test-article",
"type": {
"id": 1,
"name": "Announcements",
"slug": "announcements",
"description": "View the latest news and announcements.",
"view": 1,
"icon": "...",
"show_on_dashboard": 1,
"created_at": 1445611905,
"updated_at": 1445611905
},
"categories": {
"0": {
"id": 1,
"type_id": 1,
"parent_id": null,
"name": "General",
"slug": "general",
"public": 1,
"parent_public": 1,
"created_at": 1449600034,
"updated_at": 1449600034,
"pivot": {
"article_id": 1,
"category_id": 1
}
},
"tags": [
{
"id": 1,
"name": "Test",
"slug": "test",
"created_at": 1449599991,
"updated_at": 1449600099,
"pivot": {
"article_id": 1,
"tag_id": 1
}
}
],
"attachments": []
}
}
}404Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The article with given ID was not found.",
"data": null
}Remove the specified resource from storage.DELETE/api/selfservice/article/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully deleted the article!",
"data": null
}Comment ¶
Comments made on self-service articles.
Show all of the records.GET/api/selfservice/comment
Example URI
- article_id
integer(optional)The article that the comment was posted on.
- status
integer(optional)The moderation status of the comment. 0 - Awaiting Moderation, 1 - Published, 2 - Spam.
- parent_id
integer(optional)The ID of the parent comment.
- start
integer(optional) Default: 0The first result to start from.
- limit
integer(optional) Default: 50The amount of results to fetch.
- order_column
string(optional) Default: idThe column to sort by.
- order_direction
string(optional) Default: ascThe ordering of the results.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"count": 1,
"data": [
{
"id": 1,
"article_id": 1,
"author_id": 1,
"text": "This is a comment!",
"parent_id": null,
"root_parent_id": null,
"rating": 0,
"status": 0,
"notify_reply": 1,
"created_at": 1446331613,
"updated_at": 144633161
}
]
}Display the specified resource.GET/api/selfservice/comment/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"data": {
"id": 1,
"article_id": 1,
"author_id": 1,
"text": "This is a comment!",
"parent_id": null,
"root_parent_id": null,
"rating": 0,
"status": 0,
"notify_reply": 1,
"created_at": 1446331613,
"updated_at": 144633161
}
}Store a newly created resource in storage.POST/api/selfservice/comment
Example URI
- article_id
integer(required)The article the the comment is being posted to.
- parent_id
integer(optional)If this comment is a reply, set as the parent comment ID.
- author_id
integer(optional)The commenter user ID, use the name field if not currently a user.
- text
string(required)The comment text.
- status
integer(optional) Default: 0The moderation status of the comment. 0 - Awaiting Moderation, 1 - Published, 2 - Spam.
- notify_reply
boolean(optional) Default: 0If the user would like to be notified on a reply, only applicable to users with email addresses.
Headers
Content-Type: application/x-www-form-urlencodedBody
article_id=1&author_id=1&text=This+is+a+comment!200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully created new comment!",
"data": {
"id": 1,
"article_id": 1,
"author_id": 1,
"text": "This is a comment!",
"parent_id": null,
"root_parent_id": null,
"rating": 0,
"status": 0,
"notify_reply": 1,
"created_at": 1446331613,
"updated_at": 144633161
}
}422Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The article_id field is required.",
"data": null
}Update the specified resource in storage.PUT/api/selfservice/comment/{id}
Example URI
- id
integer(required)The ID of the resource.
- article_id
integer(optional)The article the the comment is being posted to.
- parent_id
integer(optional)If this comment is a reply, set as the parent comment ID.
- text
string(optional)The comment text.
- status
integer(optional)The moderation status of the comment. 0 - Awaiting Moderation, 1 - Published, 2 - Spam.
- notify_reply
boolean(optional)If the user would like to be notified on a reply, only applicable to users with email addresses.
Headers
Content-Type: application/x-www-form-urlencodedBody
text=This+is+a+comment!200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully updated the comment!",
"data": {
"id": 1,
"article_id": 1,
"author_id": 1,
"text": "This is a comment!",
"parent_id": null,
"root_parent_id": null,
"rating": 0,
"status": 0,
"notify_reply": 1,
"created_at": 1446331613,
"updated_at": 144633161
}
}404Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The comment with given ID was not found.",
"data": null
}Remove the specified resource from storage.DELETE/api/selfservice/comment/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully deleted the comment!",
"data": null
}Article Attachment ¶
Class AttachmentController
Show all of the records.GET/api/selfservice/attachment
Example URI
- article_id
integer(optional)Only fetch attachments associated with the article ID.
- start
integer(optional) Default: 0The first result to start from.
- limit
integer(optional) Default: 50The amount of results to fetch.
- order_column
string(optional) Default: idThe column to sort by.
- order_direction
string(optional) Default: ascThe ordering of the results.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"count": 1,
"data": [
{
"id": 1,
"upload_hash": "3f9f475bb59e66165a0a97d2757a23366777a061",
"article_id": 1,
"original_name": "filename.png",
"created_at": 1470400190,
"updated_at": 1470400190,
"download_url": "http://www.domain.com/support/announcements/article/unpublished-article/attachment/3f9f475bb59e66165a0a97d2757a23366777a061",
"upload": {
"id": 1,
"hash": "3f9f475bb59e66165a0a97d2757a23366777a061",
"filename": "filename.png",
"folder": "selfservice",
"mime": "image/png",
"size": "6.6 KB",
"created_at": 1470400188,
"updated_at": 1470400188
}
}
]
}Display the specified resource.GET/api/selfservice/attachment/{id}
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"data": {
"id": 1,
"upload_hash": "3f9f475bb59e66165a0a97d2757a23366777a061",
"article_id": 1,
"original_name": "filename.png",
"created_at": 1470400190,
"updated_at": 1470400190,
"download_url": "http://www.domain.com/support/announcements/article/unpublished-article/attachment/3f9f475bb59e66165a0a97d2757a23366777a061",
"upload": {
"id": 1,
"hash": "3f9f475bb59e66165a0a97d2757a23366777a061",
"filename": "filename.png",
"folder": "selfservice",
"mime": "image/png",
"size": "6.6 KB",
"created_at": 1470400188,
"updated_at": 1470400188
}
}
}Download the specified resource. Returns file data.GET/api/selfservice/attachment/{id}/download
Example URI
- id
integer(required)The ID of the resource.
200Headers
Content-Type: application/jsonStore a newly created resource in storage.POST/api/selfservice/attachment
Example URI
- article_id
integer(required)The article to associate the attachment with.
- filename
string(required)The name of the file.
- contents
string(required)The base64-encoded file contents being uploaded.
Headers
Content-Type: application/x-www-form-urlencodedBody
article_id=1&filename=hello.jpg&contents=MQ==200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully created new attachment!",
"data": {
"id": 1,
"upload_hash": "3f9f475bb59e66165a0a97d2757a23366777a061",
"article_id": 1,
"original_name": "filename.png",
"created_at": 1470400190,
"updated_at": 1470400190,
"download_url": "http://www.domain.com/support/announcements/article/unpublished-article/attachment/3f9f475bb59e66165a0a97d2757a23366777a061",
"upload": {
"id": 1,
"hash": "3f9f475bb59e66165a0a97d2757a23366777a061",
"filename": "filename.png",
"folder": "selfservice",
"mime": "image/png",
"size": "6.6 KB",
"created_at": 1470400188,
"updated_at": 1470400188
}
}
}422Headers
Content-Type: application/jsonBody
{
"status": "error",
"message": "The filename field is required.",
"data": null
}Remove the specified resource from storage.DELETE/api/selfservice/attachment/{id}
Example URI
- id
string(required)The ID of the resource.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": "Successfully deleted the attachment!",
"data": null
}Settings ¶
Self-service system settings.
General SettingsGET/api/selfservice/settings
Example URI
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"data": {
"comment_captcha": "1",
"comment_moderation": "1",
"comment_ordering": "2",
"comment_ratings": "1",
"comment_threshold": "-2",
"comment_write": "0",
"comments_enabled": "1",
"rating_post": "0",
"rating_show": "0",
"ratings_enabled": "1"
}
}Report ¶
Report ¶
List reports and view individual report data.
Show all of the records.GET/api/report
Example URI
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"data": [
{
"Operator": [
{
"name": "Total Ticket Replies",
"slug": "TotalTicketReplies"
}
]
}
]
}Display the specified resource.GET/api/report/{category}/{name}
Example URI
- category
string(required)The name of the category the report is in.
- name
string(required)The name of the report.
200Headers
Content-Type: application/jsonBody
{
"status": "success",
"message": null,
"data": [
{
"Operator": "John Smith",
"Messages": 8
},
{
"Operator": "Anne Hill",
"Messages": 10
}
]
}