Public API

Laravel REST API

The following routes are public available for everyone with a valid access token or basic auth credentials.

The modesk module API provides programmatic access to get a list of all contacts, to create, update or delete existing items by ID.

To use this API, you need an Username and Password. Please contact us at [email protected] to get your own API key or credentials.

Show Contact

get
Authorizations
HTTPRequired
Path parameters
contactIdinteger · int64 · min: 1Required
Responses
get
/contact/{contactId}
GET /api/api/contact/{contactId} HTTP/1.1
Host: testapi.cuco.lu
Authorization: Basic username:password
Accept: */*
{
  "gender": "text",
  "firstname": "text",
  "id": 1,
  "lastname": "text",
  "language": "text",
  "phone": "text",
  "mobile": "text",
  "businessPhone": "text",
  "businessMobile": "text",
  "businessEmail": "text",
  "email": "text",
  "title": "text",
  "birthday": "text"
}

Delete Contact

delete
Authorizations
HTTPRequired
Path parameters
contactIdinteger · int64 · min: 1Required
Responses
delete
/contact/{contactId}
DELETE /api/api/contact/{contactId} HTTP/1.1
Host: testapi.cuco.lu
Authorization: Basic username:password
Accept: */*

No content

Update Contact

patch
Authorizations
HTTPRequired
Path parameters
contactIdinteger · int64 · min: 1Required
Body
genderstringOptional
firstnamestringOptional
lastnamestringOptional
languagestringOptional
phonestringOptional
mobilestringOptional
businessPhonestringOptional
businessMobilestringOptional
businessEmailstringOptional
emailstringOptional
titlestringOptional
birthdaystringOptional
Responses
patch
/contact/{contactId}
PATCH /api/api/contact/{contactId} HTTP/1.1
Host: testapi.cuco.lu
Authorization: Basic username:password
Content-Type: multipart/form-data
Accept: */*
Content-Length: 221

{
  "gender": "text",
  "firstname": "text",
  "lastname": "text",
  "language": "text",
  "phone": "text",
  "mobile": "text",
  "businessPhone": "text",
  "businessMobile": "text",
  "businessEmail": "text",
  "email": "text",
  "title": "text",
  "birthday": "text"
}
{
  "gender": "text",
  "firstname": "text",
  "id": 1,
  "lastname": "text",
  "language": "text",
  "phone": "text",
  "mobile": "text",
  "businessPhone": "text",
  "businessMobile": "text",
  "businessEmail": "text",
  "email": "text",
  "title": "text",
  "birthday": "text"
}

Index Contacts

get
Authorizations
HTTPRequired
Responses
get
/contact
GET /api/api/contact HTTP/1.1
Host: testapi.cuco.lu
Authorization: Basic username:password
Accept: */*
[
  {
    "gender": "text",
    "firstname": "text",
    "id": 1,
    "lastname": "text",
    "language": "text",
    "phone": "text",
    "mobile": "text",
    "businessPhone": "text",
    "businessMobile": "text",
    "businessEmail": "text",
    "email": "text",
    "title": "text",
    "birthday": "text"
  }
]

Create Contacts

post
Authorizations
HTTPRequired
Bodyobject[]

Data transfer object for creating a new Contact.

genderstringOptional
firstnamestringRequired
lastnamestringRequired
languagestringOptional
phonestringOptional
mobilestringOptional
businessPhonestringOptional
businessMobilestringOptional
businessEmailstringOptional
emailstringOptional
titlestringOptional
birthdaystringOptional
Responses
201

The request was successful, and a new resource was created. The URI of the newly created resource can be found in the response's Location header.

application/json
post
/contact
POST /api/api/contact HTTP/1.1
Host: testapi.cuco.lu
Authorization: Basic username:password
Content-Type: multipart/form-data
Accept: */*
Content-Length: 223

[
  {
    "gender": "text",
    "firstname": "text",
    "lastname": "text",
    "language": "text",
    "phone": "text",
    "mobile": "text",
    "businessPhone": "text",
    "businessMobile": "text",
    "businessEmail": "text",
    "email": "text",
    "title": "text",
    "birthday": "text"
  }
]
{
  "gender": "text",
  "firstname": "text",
  "id": 1,
  "lastname": "text",
  "language": "text",
  "phone": "text",
  "mobile": "text",
  "businessPhone": "text",
  "businessMobile": "text",
  "businessEmail": "text",
  "email": "text",
  "title": "text",
  "birthday": "text"
}

Last updated