Views: 2389
Last Modified: 08.02.2022
Interaction with notification buttons |
Revision
Get current information about current API revision (platform version) – im.revision.get
: 18 |
Parameters
Parameter |
Example |
Required |
Description |
Revision |
ID |
288 |
Yes |
Notification ID, supporting reply via button click |
30 |
NOTIFY_VALUE |
'Y' |
Yes |
Selected reply value (button value) |
30 |
|
For example, the notification is as follows:
- Accept button has
'Y'
value
- Deny button has
'N'
value
Called method and response
JavaScript
B24.callMethod(
'im.notify.confirm',
{
ID: 288,
NOTIFY_VALUE: 'Y'
},
res => {
if (res.error())
{
console.error(result.error().ex);
}
else
{
console.log(res.data())
}
}
)
Response example
{
"result_message": [
"Invitation accepted"
]
}
Example of response on error
{
"error":"NOTIFY_VALUE_ERROR",
"error_description":"Notification Value can\u0027t be empty"
}
Key description:
error
– error code
error_description
– error brief description
Possible error codes
Code |
Description |
ID_ERROR |
Parameter ID is not passed or isn't an integer |
NOTIFY_VALUE_ERROR |
Parameter NOTIFY_VALUE is not specified or empty |
|