Get notifications

Requires authentication

HTTP Request

GET connector/api/notifications

Example request:

curl -X GET \
-G "http://erp.dstadvertising.com/connector/api/notifications" \
-H "Content-Type: application/json" \
-H "Accept: application/json" \
-H "Authorization: Bearer {token}"

Example response (200):

{
"data": [
{
"msg": "Payroll for August\/2020 added by Mr. Super Admin. Reference No. 2020\/0002",
"icon_class": "fas fa-money-bill-alt bg-green",
"link": "http:\/\/local.pos.com\/hrm\/payroll",
"read_at": null,
"created_at": "3 hours ago"
}
]
}

javascript

const url = new URL(
"http://erp.dstadvertising.com/connector/api/notifications"
);
let headers = {
"Content-Type": "application/json",
"Accept": "application/json",
"Authorization": "Bearer {token}",
};
fetch(url, {
method: "GET",
headers: headers,
})
.then(response => response.json())
.then(json => console.log(json));