Changing notification

Parameters

HTTP method

Access rights

URL

Parameters

Note

POST web_notificator https://api.admitad.com/web_notificator/v1/web_notificator/{id}/mark_as_read/  
  • Returns an updated notification, where id is the notification ID.*

  • * Returns the result in the JSON format.

Example of use

Example of a request with utility ``curl``:

curl -L -H 'Authorization: Bearer access_token' -H "Content-Type: application/json" -X POST https://api.admitad.com/web_notificator/v1/web_notificator/63/mark_as_read/'

Example of the response from the API server in the JSON format:

{
    "id": 6,
    "status": "read",
    "category": "finance",
    "when_read": "2020-12-02T17:15:28",
    "date_created": '15.02.2021 16:08:40',
    "translate": {
        "id": 5,
        "subject": "dsf",
        "text": "sdfsd"
    }
}

Description of API server response fields

Name

Type

Description

id int

Notification ID

status char

Notification status. Example:

  • not_read — Unread

  • read — Read

category char

Notification category

when_read datetime

Date the notification was read.

Format: %Y-%m-%dT%H:%M:%S

Example: 2020-12-02T17:15:28

date_created datetime

Date the notification was received.

Format: %Y-%m-%dT%H:%M:%S

Example: 2020-12-02T17:15:28

translate object

Object with notification information.