Can i get an image selected by the user in a conversation with an iMessages app extension?

I want to create an app that gets an image from a conversation, edits it and sends it back as a reply. I've done some research and read the I messages framework, and there are a few methods that i think i could use like:

didReceive(_:conversation:)

https://developer.apple.com/documentation/messages/msmessagesappviewcontroller/1649189-didreceive **-

didSelect(_:conversation:)

https://developer.apple.com/documentation/messages/msmessagesappviewcontroller/1833298-didselect

Instance Property: selectedMessage

https://developer.apple.com/documentation/messages/msconversation/1648186-selectedmessage

But i dont fully understand how they work yet or if you can access the image of a received Message by using them.

Accepted Reply

Your app can't "read" the conversation anyone is having. Abandon all plans to try to use the contents of someone's conversation. Text, images, whatever. Thats all private, otherwise some shady developer could just start siphoning off text, images, etc from what people are sending to each other.


But you CAN have your app access the photo library (with the user's permission), they can then pull an image into your iMessage app, do edits (add arrows, funny emoji, whatever) and send that onward via your app.

Replies

Your app can't "read" the conversation anyone is having. Abandon all plans to try to use the contents of someone's conversation. Text, images, whatever. Thats all private, otherwise some shady developer could just start siphoning off text, images, etc from what people are sending to each other.


But you CAN have your app access the photo library (with the user's permission), they can then pull an image into your iMessage app, do edits (add arrows, funny emoji, whatever) and send that onward via your app.