I’m trying to migrate messages from an old chat solution, but any FILE messages I send are being recorded as MESG messages with no file or message data. An example of what I’m sending:
{
"type": "FILE",
"user_id": "2fe7a6c4-7732-435f-9685-c5c5bcdf4bed",
"timestamp": 1626940111933,
"url": "https://testimages.nebo.global/dbd6a88a-3d8a-44bd-bb32-588cfbca10f5.jpg",
"file_name": "dbd6a88a-3d8a-44bd-bb32-588cfbca10f5.jpg",
"file_type": "jpg",
"file_size": 171945,
"custom_type": null,
"data": null,
"dedup_id": null
}
Which then returns from a fetch
{
"message_survival_seconds": -1,
"custom_type": "",
"mentioned_users": [],
"updated_at": 0,
"is_op_msg": false,
"is_removed": false,
"user": {
"require_auth_for_profile_image": false,
"is_active": true,
"role": "",
"user_id": "2fe7a6c4-7732-435f-9685-c5c5bcdf4bed",
"nickname": "Sam Ritchie",
"profile_url": "https:\/\/testimages.nebo.global\/93fdd281-9f86-4b18-ab82-9af75331fa18.jpg",
"metadata": {}
},
"file": {},
"message": "",
"data": "",
"message_retention_hour": -1,
"silent": false,
"type": "MESG",
"created_at": 1626940111933,
"channel_type": "group",
"mention_type": "users",
"channel_url": "960b596a-04cd-4594-9f4c-52647a529c8e",
"message_id": 6782468526
}
would appreciate any feedback as to where I’m going wrong, thanks.