Upgrade to Pro — share decks privately, control downloads, hide ads and more …

既存サブスクリプション商品にアップグレード・ダウングレード商品を追加しよう

BOB
September 11, 2022

 既存サブスクリプション商品にアップグレード・ダウングレード商品を追加しよう

BOB

September 11, 2022
Tweet

More Decks by BOB

Other Decks in Technology

Transcript

  1. App಺՝ۚ App಺՝ۚ: https://developer.apple.com/jp/in-app-purchase/ App಺՝ۚछผ छྨ ֓ཁ ओͳ༻్ ফ໣ܕ ࢖͍੾Γ ήʔϜͷճ෮ΞΠςϜͳͲ

    ඇফ໣ܕ ߪೖ͢Ε͹ৗʹݖݶ͋Γ ࣸਅΞϓϦͷ༗ঈϑΟϧλʔͳͲ ࣗಈߋ৽ αϒεΫϦϓγϣϯ Ωϟϯηϧ͢Δ·Ͱఆظతʹ՝ۚ αϒεΫϦϓγϣϯάϧʔϓʹଐ͢Δ ಈըΞϓϦͷࢹௌݖݶ χϡʔεΞϓϦͷߪಡͳͲ ඇࣗಈߋ৽ αϒεΫϦϓγϣϯ ࣗಈߋ৽͞Εͳ͍ ظؒݶఆͷαʔϏε΍ήʔϜͷγʔζϯ ύεͳͲ ࠓճͷ͓࿩ 6
  2. αϒεΫϦϓγϣϯάϧʔϓͱ͸ʢ4/8ʣ ྨࣅ͢Δෳ਺άϧʔϓͷӡ༻͸ඇਪ঑ • ӡ༻͕ෳࡶԽ͢Δ • Ϣʔβ͕ࠞཚ͢Δ άϧʔϓͷҧ͍΍άϧʔϓ಺ͷͦͷଞͱ۠ผͰ͖ΔΑ͏ͳ໋໊ • ҙਤͤ͵ೋॏߪೖͷϦεΫΛܰݮ͢Δ ࣗಈߋ৽αϒεΫϦϓγϣϯ:

    https://developer.apple.com/jp/app-store/subscriptions/ Bάϧʔϓ 1 ϲ݄ 3 ϲ݄ 6 ϲ݄ 1 ϲ݄ 3 ϲ݄ 6 ϲ݄ αʔϏεϨϕϧ্͕Ґ Aάϧʔϓ 1 ϲ݄ 3 ϲ݄ 6 ϲ݄ 1 ϲ݄ 3 ϲ݄ 6 ϲ݄ 6ϲ݄͕2ͭ? 11
  3. Ϩγʔτͷڍಈ ؀ڥ • Sandbox • αʔϏεϨϕϧ͕ҟͳΔαϒεΫϦϓγϣϯΛ૝ఆ • ൃද಺༰͸͋͘·Ͱ໛ٖ 21 responseBody.Latest_receipt_info

    : https://developer.apple.com/documentation/appstorereceipts/responsebody/latest_receipt_info αʔϏεϨϕϧ ঎඼ID 1 standard 2 simple
  4. AndroidͷڍಈΛiOSʹͳΔ΂͋͘ΘͤΔ 24 Google Play Billing Libraryʹ͓͚Δൺྫ഑෼ʹؔ͢Δਪ঑ࣄ߲ γφϦΦ ਪ঑͞ΕΔൺྫ഑෼Ϟʔυ ݁Ռ ΑΓߴֹͳ֊૚΁ͷΞοϓάϨʔυ

    IMMEDIATE_AND_CHARGE_PRORATED_PRICE Ϣʔβʔ͸ɺಉ͡੥ٻର৅ظؒΛҡ࣋͠ͳ͕ Βɺ௚ͪʹΞΫηεͰ͖ΔΑ͏ʹͳΓ·͢ɻ ҆Ձͳ֊૚΁ͷμ΢ϯάϨʔυ DEFERRED Ϣʔβʔ͸͢ͰʹΑΓߴֹͳ֊૚Ͱࢧ෷͍ࡁΈ Ͱ͋ΔͨΊɺ࣍ͷ੥ٻ೔·ͰΞΫηε͕ܧଓ͞ Ε·͢ɻ ಉ͡֊૚Ͱͷܖ໿ظؒͷมߋʢ݄୯Ґ͔Β ೥୯ҐͳͲʣ DEFERRED Ϣʔβʔ͸࣍ճͷ੥ٻ೔ʹ৽͍͠ྉۚΛࢧ෷͍ ·͢ɻ ແྉࢼ༻ظؒதͷΞοϓάϨʔυ IMMEDIATE_WITHOUT_PRORATION Ϣʔβʔ͸ແྉࢼ༻ͷར༻ݖΛอ࣋͠ɺࢼ༻ظ ؒͷ࢒Γͷظؒ͸্Ґ֊૚ʹΞοϓάϨʔυ͞ Ε·͢ɻ ແྉࢼ༻ظؒதͷΞοϓάϨʔυ - ແྉࢼ ༻΁ͷΞΫηεͷऴྃ IMMEDIATE_AND_CHARGE_PRORATED_PRICE Ϣʔβʔ͸͙͢ʹ৽͍͠֊૚ʹΞΫηεͰ͖· ͕͢ɺແྉࢼ༻ظؒ͸ऴྃ͠·͢ɻ Appleʹൺ΂ͯGoogleͷํ͕બ୒ࢶ͕๛෋ • Google͕ਪ঑͢Δ഑෼Ϟʔυ ͔ͭ Appleͷڍಈʹ͍ۙϞʔυΛબ୒͠·ͨ͠ ఆظߪೖΛൢച͢Δ : https://developer.android.com/google/play/billing/subscriptions
  5. Sandbox σόοά΍ݕূʹ͸SandboxΛ࢖༻͠·ͨ͠ • αϙʔτOSͷ౎߹্ɼStoreKit Testingͷಋೖ͕౰࣌͸೉͔ͬͨͨ͠ΊͰ͢ Tips: Sandboxʹ͓͚ΔαϒεΫϦϓγϣϯͷߋ৽ස౓Λ͋͛Δ • SandboxϢʔβʔ͝ͱʹௐ੔ՄೳͰ͢ 25

    ։ൃͷશஈ֊ʹ͓͚ΔXcodeͱSandboxʹΑΔςετ: https://developer.apple.com/jp/documentation/storekit/in-app_purchase/ testing_at_all_stages_of_development_with_xcode_and_sandbox/ App ಺՝ۚͷςετ:https://help.apple.com/app-store-connect/#/dev7e89e149d ςετ༻ʹ୹ॖ͞Εͨߋ৽ස౓ͷҰཡ 1ϲ݄ͳΒ࠷খ3෼
  6. ͕͜͜ਏ͍ΑSanbox 1. ΞοϓάϨʔυʹΑΔฦۚϑϩʔ͕Θ͔Βͳ͍ • ࣮ࡍͷϢʔβମݧ͕Θ͔Βͳ͍ 2. Grace Period΍Belling Retryͷڍಈ͕֬ೝͰ͖ͳ͍ •

    ߪೖͷதஅ͸࠶ݱͰ͖Δ͕ɼ༛༧ܥ͕࠶ݱͰ͖·ͤΜ • StoreKit ConfigurationͳΒ࠶ݱͰ͖·͢ 26 ։ൃͷશஈ֊ʹ͓͚ΔXcodeͱSandboxʹΑΔςετ: https://developer.apple.com/jp/documentation/storekit/in-app_purchase/ testing_at_all_stages_of_development_with_xcode_and_sandbox/ How to test Billing Retry subscriptions case in Sanbox or Xcode Environment?: https://developer.apple.com/forums/thread/685908 iOS16~ͰͰ͖ΔΑ͏ʹͳΔ͔΋ (WWDC2022)
  7. Ձ֨มߋʢ4/5ʣ ڠఆੈք࣌ؒΛ೔ຊ࣌ؒͰղऍ͢Δඞཁ͕͋Γ·͢ ྫ 19೔ʹՁ֨มߋΛ͍ͨ͠ • AppStore্Ͱ19೔ʹઃఆʢถࠃ͕αϚʔλΠϜதʣ • ೔ຊɿ18೔ͷ14࣌ UTCʢڠఆੈք࣌ʣ 


    -> +9࣌ؒͰ 18೔ͷ23࣌(೔ຊ࣌ؒ) • AppStore্Ͱ19೔ʹઃఆʢถࠃ͕αϚʔλΠϜͰ͸ͳ͍ʣ • ೔ຊɿ18೔ͷ15࣌ UTCʢڠఆੈք࣌ʣ 
 -> +9࣌ؒͰ 18೔ͷ24࣌(19೔ͷ0࣌)(೔ຊ࣌ؒ) ஍Ҭผ App Store ͰͷՁ͓֨Αͼ഑৴։࢝࣌ࠁ: https://help.apple.com/app-store-connect/#/dev3ed2f5eee
  8. Ձ֨มߋʢ5/5ʣ • طଘͷαϒεΫϦϓγϣϯొ࿥ऀͷՁ֨Λਾ͑ஔ͖·͢ɻࠓճͷՁ֨มߋΑΓ΋લʹొ࿥ͨ͠ϢʔβʹӨڹ͸͋Γ·ͤ ΜɻαϒεΫϦϓγϣϯͷ༗ޮظݶ͕੾Εͨ৔߹ɺ༗ޮظݶ͔Β 60 ೔Ҏ಺Ͱ͋Ε͹ҡ࣋Ձ֨Ͱ࠶ొ࿥͢Δ͜ͱ͕ Ͱ͖·͢ɻ • ݱࡏ App

    Store ʹදࣔ͞Ε͍ͯΔՁ֨Λࢧ෷͍ͬͯΔطଘͷαϒεΫϦϓγϣϯొ࿥ऀʹՁ֨มߋΛద༻͠·͢ɻApp Store Connect Ͱ͸ɺಉҙ͕ඞਢ͔Ͳ͏͔ (·ͨ͸୯ʹ௨஌͕ૹ৴͞ΕΔ͚͔ͩ) Λ֤ςϦτϦ͝ͱʹදࣔ͠·͢ɻ ࣗಈߋ৽αϒεΫϦϓγϣϯͷՁ֨ͷ؅ཧ: https://help.apple.com/app-store-connect/#/devc9870599e
  9. τϥϒϧൃੜ ະఏग़ͳͷʹɼมߋͨ͠ϩʔΧϦθʔγϣϯ͕ެ։͞Εͨ τϥϒϧ಺༰ ࣌ܥྻ 1. 0x/06 15࣌͝Ζ AppStoreʹͯϩʔΧϦθʔγϣϯΛมߋͯ͠อଘ 2. 0x/06

    15࣌͝Ζ εςʔλε͸ఏग़४උதͰ͋Δ͜ͱΛ֬ೝ 3. 0x/06 15࣌͝Ζ ৹ࠪ΁ఏग़͸࣮ߦͤͣʹϒϥ΢β͔Β཭୤ 4. 0x/06 23࣌͝Ζ վΊͯఏग़४උதͰ͋Δ͜ͱΛ֬ೝ 5. 0x/07 11࣌͝Ζ ҙਤ໊ͤͣশ͕มߋ͞Εͨ͜ͱΛ֬ೝɽτϥϒϧൃੜ 6. 0x/07 11࣌͝Ζ ໊শΛ໭ͯ͠ਃ੥ 7. 0x/07 11࣌͝Ζ Apple΁࣭໰Λఏग़ʢ2022-07-26࣌఺Ͱະճ౴ʣ 8. 0x/08 8࣌͝Ζ ໊শ͕໭ͬͨ͜ͱΛ֬ೝ App ಺՝ۚͷϩʔΧϦθʔγϣϯεςʔλε: https://help.apple.com/app-store-connect/#/dev857cc6257
  10. ฦۚʹཁ͢Δ೔਺ • AppStoreConnectͷυΩϡϝϯτʹ͸هࡌ͕ͳ͍ • هࡌɿ੾Γସ͑Δલͷ௿͍ϨϕϧͷαϒεΫϦϓγϣϯ͔Βൺྫ഑෼͞Εֹ͕ͨۚɺ 
 ݩͷ෷͍ํ๏Ͱฦۚ͞Ε·͢ɻ • Apple Supportʹ͸هࡌ͋Γ

    Apple ͔Βߪೖͨ͠ App ΍ίϯςϯπͷฦۚखଓ͖ͷਐḿΛௐ΂Δ: https://support.apple.com/ja-jp/HT210904 ࣗಈߋ৽αϒεΫϦϓγϣϯ৘ใ: https://help.apple.com/app-store-connect/#/dev7f2d6b652 ฦۚʹཁ͢Δ೔਺ छྨ ೔਺ɾ࣌ؒ ετΞΫϨδοτ ࠷௕48࣌ؒ ΩϟϦΞܾࡁ ࠷௕60೔ ͦͷଞ ࠷௕30೔
  11. ·ͱΊ γφϦΦ ݁Ռ ࣗಈߋ৽αϒεΫϦϓγϣϯͱ͸ • Ωϟϯηϧ͢Δ·Ͱఆظతʹ՝ۚ͞ΕΔ • αϒεΫϦϓγϣϯάϧʔϓʹଐ͢Δ αϒεΫϦϓγϣϯάϧʔϓͱ͸ •

    ྨࣅ͢Δෳ਺ͷαϒεΫϦϓγϣϯάϧʔϓͷӡ༻͸ඇਪ঑ • ಉҰαϒεΫϦϓγϣϯάϧʔϓ಺ͰɼΞοϓάϨʔυɾμ΢ϯάϨʔυɾΫϩεάϨʔυ͕Մೳ • ܾࡁλΠϛϯά͕ҟͳΔͷͰ஫ҙ લఏ৚݅ͱΰʔϧ • ຊ൪ӡ༻͍ͯ͠ΔαϒεΫϦϓγϣϯʹαʔϏεϨϕϧ্͕ҐͷαϒεΫϦϓγϣϯΛ௥Ճ͢Δ͜ͱ • ϦϦʔεͱಉ࣌ʹطଘαϒεΫϦϓγϣϯͷ໊শ΍Ձ֨΋มߋ͢Δ͜ͱ ٕज़ݕূ • SandboxΛϑϧ׆༻ • Androidͱͷ߹Θͤํʹ΋஫ҙ • SandboxͰݕূͰ͖ͳ͍ൣғʹ͍ͭͯ΋஫ҙ ຊ൪άϧʔϓ΁ͷ௥Ճ • αʔϏεϨϕϧͷมߋλΠϛϯά͸૊৫Ͱ଍ฒΈΛἧ͑Δ͜ͱ • ৽نαϒεΫϦϓγϣϯͷਃ੥͸഑৴ՄೳͷνΣοΫΛ֎͓ͯ͘͜͠ͱ ໊শͱՁ֨มߋ • ໊শมߋͷ৹ࠪ͸ΞϓϦͱ͸ผͰߦΘΕͯɼϦϦʔελΠϛϯά͸ௐ੔Ͱ͖ͳ͍ • ೔ຊʹ͓͚ΔՁ֨ͷมߋ͸AppStoreConnectͰઃఆͨ͠೔ͷ0͔࣌લ೔ͷ23࣌ʹ։࢝͞ΕΔ ༧Ί४උɾ֬ೝ͢ΔͱΑ͍͜ͱ • ΞοϓάϨʔυ࣌ͷฦۚϑϩʔ • ฦۚʹཁ͢Δ೔਺ • ͋ΒΏΔϢʔεέʔεΛ૝ఆͨ͠Q&Aͷ੔උ