What's up ladies and gentlemen. In this exciting section, you're going to learn how to make money with in-app purchases. Well, if your app sucks, it probably won't make money, but you'll still learn how to do the in-app purchases, and don't make a crappy app, make a good app, and then people would spend money on it. So let's help you make some money and let's learn about in-app purchases. So first things first, is I've got my Xcode open on a different monitor here, so I'm gong to go to file, new project. I'm going to pull it over here for you. We're going to do a single-view application, and our apps can be very simple in terms of how it looks and feels because this lesson is all about making in-app purchases and the steps that you need to do it, and it's not as easy as you might think. So let's go ahead and give it this name here, our app here is called daily dose. So we're going to call this daily dose. Swift languages good, everything else here is good. I'm just going to start in a folder I have here. Very, very good. So a couple of things that are really important to understand is that when working with in app purchases, you actually have to have an app on the App Store. That is on iTunes connect, it doesn't have to be launched. But what I'm saying is you have to have the app there, and you can't do that unless you were a paid Apple developer. You have to at least have paid the $99 Apple developer fee in order to even test in-app purchases. You're also going to have to set up some things on your developer account as well too. So remember, there's developer.Apple.com and there's iTunesConnect.Apple.com. ITunes Connect is where you upload the apps and Apple developer is where you manage your developer account. You're going to need to work with both today. But never fear, I'm going to show you exactly what to do. So what I'm going to do is open up my browser here, and I typically use Safari when working with the Apple websites because they have features that only work on Safari and it's annoying. So I'm at developer.Apple.com as you can see right here, and we are going to go into account. But in your credentials, if you don't have credentials, you're going to need to create a developer account. It's free. This part's free. Then what you're going to do is you're going to go to certificate, identifiers, and profiles. The next thing that we're going to do is we're going to go over here to the identifier section where it says app IDs, and we're going to create a brand new app ID. We're going to call this daily dose as the name. That's just a name for you to recognize it as, and this is important here. This is the Bundle ID and this is the Bundle ID that you'll be working with in your Xcode. So we're going to have com.devslopes.daily.dose, that's what we're going to call our bundle subscription here. Of course, you would use your company name or individual account name. Then what we're going to do is scroll down and click continue, in-app purchases is already selected by default as a feature. We're going to click continue, everything here looks great, and we're going to click register, and then done. So you have to register an app ID so your iTunes Connect can find the app. Every app in the world of app development has an app ID or a bundle ID that an app needs to be associated with. The next thing we're going to do is go to iTunesConnect.Apple.com. Now, again, this portion is where you actually need to have a paid Apple developer account, at least an individual one for $99, a year and you need to make sure that all of your agreements, tax and banking agreements are signed and filled out and ready to go. Otherwise, you can't create new apps. It won't let you. So what we're going to do is we're going to go into My Apps. Again, if you don't see this My Apps section, it's because you're not a paid developer and you have to be a paid developer to work with in-app purchases, and of course, to submit apps to the App Store. So my apps, and then what we're going to do is we're going to create a brand new app clicking the plus button. We're going to do iOS only, and this one we are going to call Daily Dose. The language is going to be English US, at least for my app, you can choose whatever you want. The Bundle ID is going to be the one that you just created, daily dose, if you did not just create that over at developer.apple.com with your synced developer account, then this wouldn't be here. But ours is, so that's great. If you're not seeing it there, I have noticed that sometimes it takes a few minutes for developer account to refresh with iTunes and make that connection. Secondly, you're going to want to make sure that your developer.apple.com account is associated with your iTunes Connect account. Hopefully, those are with the same iTunes ID, and on the same account. So you may have to sync those and get them connected if you're not seeing this here. The SKU is just an internal app, name or a number that you want to give it. We're going to call this daily dose. Then the user access, we're not going to do anything with that. I'm going to click create Now, it doesn't like this name because someone obviously picked it. So we're going to call this daily dose dev slopes. You can call yours whatever you want. This is just a test app anyway. Someone else had that name on the App Store and it wouldn't let us do it. So no big deal. This is really cool. So we've signed up here. We've got our app created. One more thing I want to do before we get started is I'm going to click this ITunes connect right here, and we're gong to go over to users and roles, and what we're going to do is create a test account or a Sandbox account. You cannot test in-app purchases unless you come here and create a test account. So click sandbox users on the right-hand side, and what we're going to do is create a new one. Give it a name, anything you want. So Tester, Tester, e-mail can be Jo@bob.com, and the password, it needs to have lowercase, uppercase, a bunch of other stuff. So just put in any combination of such a password. I'm doing such a thing. So secret question, secret answer, you have to fill all of these things out. So secret answer, I'm just putting in boiler plate stuff here. Doesn't mean anything. Put your date of birth, any date in here is fine. In territory, we are going to pick United States, in my case, you can pick whatever country you want. The important thing here to remember is the e-mail. Another important thing to remember is if you make a non-consumable in-app purchase like we're going to do, if you make a purchase like that, your account that you create here will only let you purchase it once, and when you restore, it'll restore it. So anytime you want to do multiple tests, you're going to have to keep creating tests users for non-consumable purchases because it ties it to that account like it's a real iTunes account, which is what you want. So Jo@bob.com. That e-mails already associated. We'll just pick a new one. We're going to say firstname.lastname@example.org, it doesn't like that either. We're going to say email@example.com. Again, you're not going to get an e-mail or anything. This is just test accounts, firstname.lastname@example.org in my case here. So there we go, email@example.com. So what we've done is we've created a bundle ID on developer.apple.com, and then we went into iTunesConnect.Apple.com and we created a new app, and we associated that bundle ID. The last thing to do is just make sure that our app down here has the exact same bundle ID as the one in developer.Apple.com and it doesn't. So we're going to change that now from the dash to the dot. So com.devslopes.daily.dose, and what we can actually do is you can go to Xcode preferences and you can enter your account here, if you don't have it here already, or you can click download All profiles here if you do have it entered, and it will actually download the bundle IDs and match everything up for you. So one last thing to do here in Xcode is go to capabilities, now that we have our bundle ID correct, go to capabilities, go down to in-app purchases and click on. If both of these have checks, it means it's now connected the Bundle ID that's on developer.Apple.com and you are ready to go. So I know it was a lot, I'll recap one more time what we did. We registered a bundle ID on developer.Apple.com, we created an app on iTunesconnect.Apple.com, we created a test user so we can actually make a sandbox in-app purchases without spending real money, which you have to have, and then we came here in Xcode and we made sure that the Bundle ID matched what was on developer.Apple.com. Then we went into capabilities and its five capabilities, and we turned on in-app purchases. So you're now ready to actually start writing code so you can make in-app purchases. So let's call this video done. If you're not up to speed here, go ahead and get up to speed with your account, and then I'll see you back here for the next exciting episode.