Messages

List Note Messages

Requires admin privileges

GET/api/customers/notes/{note_id}/messages
Path parameters
note_id*integer (int64)
Query parameters
Response

OK

Body
idinteger (int64)
messagenullable string
attachmentnullable string
posted_byUser (object)
created_onstring (date-time)
Request
const response = await fetch('/api/customers/notes/{note_id}/messages', {
    method: 'GET',
    headers: {},
});
const data = await response.json();
Response
[
  {
    "message": "text",
    "attachment": "text",
    "posted_by": {
      "status": "active",
      "first_name": "text",
      "last_name": "text",
      "full_name": "text",
      "email": "text",
      "username": "text",
      "profile_photo": "text",
      "employee_id": "text",
      "mobile_number": "text",
      "business_location_id": "text",
      "enable2_fa": "text",
      "modified_on": "text",
      "created_by": "text",
      "role": "text"
    },
    "created_on": "2024-10-06T22:51:38.815Z"
  }
]

Add Note Message

Requires admin privileges

POST/api/customers/notes/{note_id}/messages
Path parameters
note_id*integer (int64)
Body
messagenullable string
attachmentnullable string (byte)
Response

OK

Body
idinteger (int64)
messagenullable string
attachmentnullable string
posted_byUser (object)
created_onstring (date-time)
Request
const response = await fetch('/api/customers/notes/{note_id}/messages', {
    method: 'POST',
    headers: {
      "Content-Type": "application/json"
    },
    body: JSON.stringify({}),
});
const data = await response.json();
Response
{
  "message": "text",
  "attachment": "text",
  "posted_by": {
    "status": "active",
    "first_name": "text",
    "last_name": "text",
    "full_name": "text",
    "email": "text",
    "username": "text",
    "profile_photo": "text",
    "employee_id": "text",
    "mobile_number": "text",
    "business_location_id": "text",
    "enable2_fa": "text",
    "modified_on": "text",
    "created_by": "text",
    "role": "text"
  },
  "created_on": "2024-10-06T22:51:38.815Z"
}