# Stickers for iMessage like a part an app

**URL:** <https://forum.defold.com/t/stickers-for-imessage-like-a-part-an-app/9646>\
**Category:** Questions\
**Created:** [July 5, 2017, 4:55pm UTC](https://forum.defold.com/t/stickers-for-imessage-like-a-part-an-app/9646 "2017-07-05T16:55:17Z")\
**Posts on this page:** 20\
**Page:** 2

<div class="post-metadata">

**Author:** ![AGulev](https://forum-defold.b-cdn.net/user_avatar/forum.defold.com/agulev/32/4541_2.png) [@AGulev](https://forum.defold.com/u/AGulev)\
**Post date:** [July 10, 2017, 4:09pm UTC](https://forum.defold.com/t/stickers-for-imessage-like-a-part-an-app/9646/21 "2017-07-10T16:09:57Z")

</div>

Yes, stickers.xcassets it’s like independend application but packaging into main IPA.  
I cant build it manualy in Defold. Because I have I/O error with icons.

Now I try to add stickers.xcassets to the iap by handa, and then re-sign IPA.  
But I recieve an error mail.

Now I found that I should use exportOptionsPlist (I don’t know what is it,just start to investigate what is it and how to use it)

For app signing I am use codesign -f -s …

---

<div class="post-metadata">

**Author:** ![AGulev](https://forum-defold.b-cdn.net/user_avatar/forum.defold.com/agulev/32/4541_2.png) [@AGulev](https://forum.defold.com/u/AGulev)\
**Post date:** [July 11, 2017, 7:30am UTC](https://forum.defold.com/t/stickers-for-imessage-like-a-part-an-app/9646/22 "2017-07-11T07:30:16Z")

</div>

I wasted whole day for trying and nothing (  
Application loader upload ipa but then after post processing I receive email from apple with error.

Do you know what is the right way to sign the ipa by hands, pls?  
(I am not sure that it is a problem, but i want to try all variants)

---

<div class="post-metadata">

**Author:** ![AGulev](https://forum-defold.b-cdn.net/user_avatar/forum.defold.com/agulev/32/4541_2.png) [@AGulev](https://forum.defold.com/u/AGulev)\
**Post date:** [July 11, 2017, 9:30am UTC](https://forum.defold.com/t/stickers-for-imessage-like-a-part-an-app/9646/23 "2017-07-11T09:30:37Z")

</div>

exportOptionsPlist - wrong way, it’s just an option for export archive of xcode project using command line.

---

<div class="post-metadata">

**Author:** ![AGulev](https://forum-defold.b-cdn.net/user_avatar/forum.defold.com/agulev/32/4541_2.png) [@AGulev](https://forum.defold.com/u/AGulev)\
**Post date:** [July 11, 2017, 11:32am UTC](https://forum.defold.com/t/stickers-for-imessage-like-a-part-an-app/9646/24 "2017-07-11T11:32:50Z")

</div>

after 34 builds and attempts to upload those to app store - i give up.  
All attempts was fail.  
I don’t know how to sign and upload Defold build with stickers to app store.

My algorihm was:

1. Build game.ipa
2. Terminal: `unzip game.ipa`
3. Terminal: `codesign -d --entitlements :- Payload/game.app/`
4. save Entitlements.plist with result of 3
5. Make xcode project with stickers
6. Make an archive of the project
7. export archive for the appstore
8. extract PlugIns folder with stickers from the ipa (p7)
9. copy PlugIns forlder to our game.app (p2)
10. Terminal: `codesign -f -s "my cert" --entitlements Entitlements.plist Payload/game.app/`
11. Terminal: `zip -qr "game.ipa" Payload`

after all that game.ipa was loaded to the store using Application Loader without errors, but after few minutes (postprocessing on the apple server) I recieve an email:

> Dear developer,

> We have discovered one or more issues with your recent delivery for “Your game name”. To process your delivery, the following issues must be corrected:

> Invalid iMessage App - Your iMessage app contains an invalid sticker pack. The app may have been built or signed with non-compliant or prerelease tools. For more information, go to [developer.apple.com](http://developer.apple.com).

> Once these issues have been corrected, you can then redeliver the corrected binary.

> Regards,

> The App Store team

If somebody know where is my mistake or can help me with it, would be great.

---

<div class="post-metadata">

**Author:** ![AGulev](https://forum-defold.b-cdn.net/user_avatar/forum.defold.com/agulev/32/4541_2.png) [@AGulev](https://forum.defold.com/u/AGulev)\
**Post date:** [July 17, 2017, 11:55am UTC](https://forum.defold.com/t/stickers-for-imessage-like-a-part-an-app/9646/25 "2017-07-17T11:55:18Z")

</div>

@sven maybe you can help me with my issue?

---

<div class="post-metadata">

**Author:** ![britzl](https://forum-defold.b-cdn.net/user_avatar/forum.defold.com/britzl/32/23_2.png) [@britzl](https://forum.defold.com/u/britzl)\
**Post date:** [July 17, 2017, 4:20pm UTC](https://forum.defold.com/t/stickers-for-imessage-like-a-part-an-app/9646/26 "2017-07-17T16:20:55Z")

</div>

We’re unfortunately down to a skeleton crew in the Defold team with most people away on vacation. Sven is away on vacation. Mathias is here but he’s probably swamped with work already. Please summarize all the info you have on this and send it to me ([Bjorn.ritzl@king.com](mailto:Bjorn.ritzl@king.com)). Detailed steps of the work involved. What you’ve tried so far. Links to official docs. Any assets I might need. And so on.

I’m on vacation visiting some relatives, but I’ve brought my laptop and I might have some time to spare.

---

<div class="post-metadata">

**Author:** ![AGulev](https://forum-defold.b-cdn.net/user_avatar/forum.defold.com/agulev/32/4541_2.png) [@AGulev](https://forum.defold.com/u/AGulev)\
**Post date:** [July 18, 2017, 2:56pm UTC](https://forum.defold.com/t/stickers-for-imessage-like-a-part-an-app/9646/27 "2017-07-18T14:56:32Z")

</div>

Today was 20 more attempts to upload build that contains stickers. Without positive results.  
I hope Apple do not banned me for a frequent uploads =)

@britzl thank you, I sent all what i know and what i have.

---

<div class="post-metadata">

**Author:** ![AGulev](https://forum-defold.b-cdn.net/user_avatar/forum.defold.com/agulev/32/4541_2.png) [@AGulev](https://forum.defold.com/u/AGulev)\
**Post date:** [July 19, 2017, 10:45am UTC](https://forum.defold.com/t/stickers-for-imessage-like-a-part-an-app/9646/28 "2017-07-19T10:45:27Z")

</div>

I tried to create question in StackOverflow [https://stackoverflow.com/questions/45188401/trying-to-add-stickers-to-existing-ipa](https://stackoverflow.com/questions/45188401/trying-to-add-stickers-to-existing-ipa)  
Pls vote, I hope someone can help me… =(

---

<div class="post-metadata">

**Author:** ![Ragnar\_Svensson](https://forum-defold.b-cdn.net/letter_avatar_proxy/v4/letter/r/b5ac83/32.png) [@Ragnar\_Svensson](https://forum.defold.com/u/Ragnar_Svensson)\
**Post date:** [July 21, 2017, 9:30am UTC](https://forum.defold.com/t/stickers-for-imessage-like-a-part-an-app/9646/29 "2017-07-21T09:30:20Z")

</div>

Hey! I know nothing about stickers and very little about xcode and bundling, but I read through your steps and was curious about copying the plugins folder. Are you sure there wasn’t anything in the stickers archive that said something about the plugins? Like in a plist/manifest file. I would expect entries describing the contents of the IPA, e.g. stickers. Maybe there is meta-info you need to bring over to the plist/manifests of the game?

Reasons I can think of for the error message:

- There was a sticker pack that wasn’t described in manifests
- The sticker pack is not “complete”, i.e. the plugins folder is not enough

Things I would try to debug the problem:

- Eliminate signing issues: do the steps except 5 - 9, to make sure that the signing works when stickers are not involved
- Eliminate Defold issues: Make a new empty ipa in xcode, and try to move the stickers over to that app

---

<div class="post-metadata">

**Author:** ![AGulev](https://forum-defold.b-cdn.net/user_avatar/forum.defold.com/agulev/32/4541_2.png) [@AGulev](https://forum.defold.com/u/AGulev)\
**Post date:** [July 21, 2017, 9:33am UTC](https://forum.defold.com/t/stickers-for-imessage-like-a-part-an-app/9646/30 "2017-07-21T09:33:56Z")

</div>

Good ideas. I’ll try it. Thank you.

---

<div class="post-metadata">

**Author:** ![AGulev](https://forum-defold.b-cdn.net/user_avatar/forum.defold.com/agulev/32/4541_2.png) [@AGulev](https://forum.defold.com/u/AGulev)\
**Post date:** [July 21, 2017, 1:05pm UTC](https://forum.defold.com/t/stickers-for-imessage-like-a-part-an-app/9646/31 "2017-07-21T13:05:34Z")

</div>

Just tried to do the following:

1. Create new game app in xcode. And upload to app store (processing done without errors)
2. Pack it like game.ipa  
Made all next steps (but add MessagesApplicationExtensionSupport folder too):

> 2 Terminal: unzip game.ipa  
> 3. Terminal: codesign -d --entitlements :- Payload/game.app/  
> 4. save Entitlements.plist with result of 3  
> 5. Make xcode project with stickers  
> 6. Make an archive of the project  
> 7. export archive for the appstore  
> 8. extract PlugIns folder with stickers from the ipa (p7)  
> 9. copy PlugIns forlder to our game.app (p2)  
> 10. Terminal: codesign -f -s “my cert” --entitlements Entitlements.plist Payload/game.app/  
> 11. Terminal: zip -qr “game.ipa” Payload

Upload to app store, and it’s works. Processing done without errors.

looks like problem in info.plist of defold build. I am using plist from bob.jar 1.2.108 but with changed ios minimum version to ios 10

Plist contains many different parameters (BuildMachineOSBuild, DTPlatformBuild, DTPlatformName, DTPlatformVersion, DTSDKBuild etc)  
I am not sure that I can change them without any problem for build.

---

<div class="post-metadata">

**Author:** ![Ragnar\_Svensson](https://forum-defold.b-cdn.net/letter_avatar_proxy/v4/letter/r/b5ac83/32.png) [@Ragnar\_Svensson](https://forum.defold.com/u/Ragnar_Svensson)\
**Post date:** [July 21, 2017, 1:08pm UTC](https://forum.defold.com/t/stickers-for-imessage-like-a-part-an-app/9646/32 "2017-07-21T13:08:53Z")

</div>

> [@Ragnar\_Svensson](#):
>
> Eliminate signing issues: do the steps except 5 - 9, to make sure that the signing works when stickers are not involved

I think it’s worth doing the signing step too, just to make sure that works with the defold ipa at all.

---

<div class="post-metadata">

**Author:** ![AGulev](https://forum-defold.b-cdn.net/user_avatar/forum.defold.com/agulev/32/4541_2.png) [@AGulev](https://forum.defold.com/u/AGulev)\
**Post date:** [July 21, 2017, 1:20pm UTC](https://forum.defold.com/t/stickers-for-imessage-like-a-part-an-app/9646/33 "2017-07-21T13:20:43Z")

</div>

> [@Ragnar\_Svensson](#):
>
> Eliminate signing issues: do the steps except 5 - 9, to make sure that the signing works when stickers are not involved

Done. And it works.

I think the reason is in difference between in plist stickers and ipa (sdk version, for example or something like this)

---

<div class="post-metadata">

**Author:** ![Ragnar\_Svensson](https://forum-defold.b-cdn.net/letter_avatar_proxy/v4/letter/r/b5ac83/32.png) [@Ragnar\_Svensson](https://forum.defold.com/u/Ragnar_Svensson)\
**Post date:** [July 21, 2017, 1:23pm UTC](https://forum.defold.com/t/stickers-for-imessage-like-a-part-an-app/9646/34 "2017-07-21T13:23:21Z")

</div>

Good news! The bad news is that as you said in the other post, the key is probably a difference in the new plist you received from xcode and the one you used from bob, and that is a fucking boring problem to investigate. 😢 You can send them to me and I will take a look… 😩

---

<div class="post-metadata">

**Author:** ![AGulev](https://forum-defold.b-cdn.net/user_avatar/forum.defold.com/agulev/32/4541_2.png) [@AGulev](https://forum.defold.com/u/AGulev)\
**Post date:** [July 21, 2017, 1:37pm UTC](https://forum.defold.com/t/stickers-for-imessage-like-a-part-an-app/9646/35 "2017-07-21T13:37:07Z")

</div>

@Mathias_Westerdahl told that he made an update of [used SDK](https://forum.defold.com/t/native-extensions/4946/92)

If Defold using latest sdk, maybe you have to update plist in accordance of SDK?

@Ragnar_Svensson What exactly plists i should to send you? 3 plists, right?

1. plist that i using in defold project now
2. plist that used in stickers
3. plist from experemental app (where I added stickers sucessfully)

---

<div class="post-metadata">

**Author:** ![Ragnar\_Svensson](https://forum-defold.b-cdn.net/letter_avatar_proxy/v4/letter/r/b5ac83/32.png) [@Ragnar\_Svensson](https://forum.defold.com/u/Ragnar_Svensson)\
**Post date:** [July 21, 2017, 1:37pm UTC](https://forum.defold.com/t/stickers-for-imessage-like-a-part-an-app/9646/36 "2017-07-21T13:37:45Z")

</div>

> [@AGulev](#):
>
> 3 plists, right?

Yes, thanks!

---

<div class="post-metadata">

**Author:** ![AGulev](https://forum-defold.b-cdn.net/user_avatar/forum.defold.com/agulev/32/4541_2.png) [@AGulev](https://forum.defold.com/u/AGulev)\
**Post date:** [July 22, 2017, 7:43am UTC](https://forum.defold.com/t/stickers-for-imessage-like-a-part-an-app/9646/37 "2017-07-22T07:43:28Z")

</div>

Apple store processing done successfully.

I change next parameters in plist to parameters like in stickers app:

```lua
 <key>BuildMachineOSBuild</key>
        <string>16F73</string>

<key>DTPlatformBuild</key>
        <string>14E8301</string>

 <key>DTPlatformVersion</key>
        <string>10.3</string>

 <key>DTSDKBuild</key>
        <string>14E8301</string>

 <key>DTSDKName</key>
        <string>iphoneos10.3</string>

 <key>DTXcode</key>
        <string>0833</string>

 <key>DTXcodeBuild</key>
        <string>8E3004b</string>

```

Minimum ios version should be :

```lua
 <key>MinimumOSVersion</key>
        <string>10.0</string>

```

And I added next key to solve issue with UI components for ipad pro with multitasking:

```lua
        <key>UIRequiresFullScreen</key>
        <true/>

```

I am not sure that I have to change all this parameters (maybe I need to change just one or two) but after more than one hundred builds I have no patience to check one by one.  
I hope my hack by hands of this parameters did not affect on the build.

Thank you @Ragnar_Svensson for your help.

 ![](https://forum-defold-uploads.b-cdn.net/original/2X/e/eb91eb8f68b55457678bd83d2d69f2f794fd4326.png)

**UPD:**  
would be great to fix png ios error:

> [@Stickers for iMessage like a part an app](https://forum.defold.com/t/stickers-for-imessage-like-a-part-an-app/9646/16):
>
> Make an stickers.xcassets using xcode with icons Add to the defold project using bundle\_resources Try to build IPA : I/O error reading PNG header! iMessage App Icon27x20@2x.png /RedHood/content/external\_res/ios/PlugIns/StickerPackExtension.appex line 0 Problem now i’ll trying to repack and re-sign stickers.xcassets using my original icons png

**UPD2:**  
I wrote an article to my blog, maybe it will be useful for somebody (sorry, only in russian, try to use google translate) [Добавление стикеров в готовый ipa | Alexey Gulev](http://agulev.com/dobavlenie-stikerov-v-gotovyj-ipa/)

---

<div class="post-metadata">

**Author:** ![britzl](https://forum-defold.b-cdn.net/user_avatar/forum.defold.com/britzl/32/23_2.png) [@britzl](https://forum.defold.com/u/britzl)\
**Post date:** [July 22, 2017, 3:23pm UTC](https://forum.defold.com/t/stickers-for-imessage-like-a-part-an-app/9646/38 "2017-07-22T15:23:32Z")

</div>

Fantastic! It would be awesome to find a way to streamline this process. Perhaps into a python script or something.

---

<div class="post-metadata">

**Author:** ![AGulev](https://forum-defold.b-cdn.net/user_avatar/forum.defold.com/agulev/32/4541_2.png) [@AGulev](https://forum.defold.com/u/AGulev)\
**Post date:** [July 22, 2017, 3:27pm UTC](https://forum.defold.com/t/stickers-for-imessage-like-a-part-an-app/9646/39 "2017-07-22T15:27:25Z")

</div>

I am use this shell script - it’s enough for me:

```lua
unzip *.ipa
codesign -d --entitlements :- Payload/*.app/ > Entitlements.plist
rm *.ipa
rm .DS_Store
rm -r Payload/*.app/_CodeSignature
unzip -o ../stickers/*.ipa -d ../stickers
cp -R ../stickers/MessagesApplicationExtensionSupport/ MessagesApplicationExtensionSupport
cp -R ../stickers/Payload/*.app/PlugIns Payload/*.app/
codesign -f -s "YOUR_CERTIFICATE" --entitlements Entitlements.plist Payload/*.app/
rm -r Entitlements.plist
zip -qr "Game_with_stickers.ipa" *

```

I like to make automatisation and sometimes it’s more interesting than make games. But It is necessary to be able to stop in time.

---

<div class="post-metadata">

**Author:** ![AGulev](https://forum-defold.b-cdn.net/user_avatar/forum.defold.com/agulev/32/4541_2.png) [@AGulev](https://forum.defold.com/u/AGulev)\
**Post date:** [August 11, 2017, 10:18am UTC](https://forum.defold.com/t/stickers-for-imessage-like-a-part-an-app/9646/40 "2017-08-11T10:18:16Z")

</div>

Small update:  
Application version can be less than sticker version (less than 10.0). That mean you can set up minimum ios version in your application 6.0 or 7.0 and still use stickers from 10.0

[Previous page](https://forum.defold.com/t/stickers-for-imessage-like-a-part-an-app/9646.md?page=1)
