How to copy a picture from codea to the app photos

So i want to make an app what can Shot photos and send it with some extras and so on. But the Problem i dont know how to copy the picuture to iMessage or photos. So when Sonnenöle have a Tipp or something like that… :-?

Thanks for all answers