Skip to content

[BUG] message_id does not persist in push notification payload #183

@mihail-varbanov

Description

@mihail-varbanov

This is a notification, as it comes from api/messages API:

{
	"org_id":"0a2eff20-e2cd-11eb-af68-60f81db5ecc0",
	"app_id":"9766",
	"id":"67c3cf68-aa0a-4c9d-9f37-e655e70b3714",
	"priority":10,
	"subject":"Group - MV Accept All",
	"sender":{
		"type":"system",
		"user":{
			"user_id":"6d925154-ff9a-48ae-998b-30e101ceda1c",
			"name":"groups_bb"
		}
	},
	"body":"Todor Bachvarov posted \"This is a test post.\"",
	"data":{
		"entity_id":"7bb505e1-7b78-4adb-ac03-dcb0753ec27e",
		"entity_name":"MV Accept All",
		"entity_type":"group",
		"message_id":"67c3cf68-aa0a-4c9d-9f37-e655e70b3714",
		"operation":"post_created",
		"post_body":"This is a test post.",
		"post_id":"151ff4d0-ce15-4bc4-bb99-129516072282",
		"post_subject":"Test",
		"type":"group"
	},
	"recipients":null,
	"recipients_criteria_list":[
		
	],
	"recipient_account_criteria":null,
	"topic":"group.posts",
	"calculated_recipients_count":2,
	"date_created":"2024-09-20T08:03:16.799Z",
	"date_updated":null,
	"time":"2024-09-20T08:03:16.753Z",
	"mute":false,
	"read":false
},

This is the push notification payload that comes for the above message:

{
  "entity_id":"7bb505e1-7b78-4adb-ac03-dcb0753ec27e",
  "entity_type":"group",
  "entity_name":"MV Accept All"
  "operation":"post_created",
  "post_body":"This is a test post.",
  "post_id":"151ff4d0-ce15-4bc4-bb99-129516072282",
  "post_subject":"Test",
  "type":"group"
}

Please note that message_id is omitted from the push notification payload. The client app relies on its persistence in order to mark the message as read.

Related ticket: rokwire/illinois-app#4256

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions