The error is in the function create_resource. The test that says:

if attachment_type == "image":

should be changed to:

if attachment_type == "image/png":

Now it works. Note that if the image was resized in Synology Note Station, the size information is lost. The image transferred to Joplin is displayed at full size but you can resize it again manually.

In summary, there are 3 changes to be made to nsx2joplin.py:

  1. Change the import declaration.
  2. Remove await in 3 places.
  3. Change the attachment_type test.
1 Like