It was an event, but you can't get that event now. Maybe they will release an event with a Liberty Pass in the future. You can also cheat, though I won't recommend that.
You get Mystery Gift automatically so all you'll need to do when you start your game is get the Unova Dex and you'll be able to download the Liberty Pass download off of Nintendo Wi-Fi after saving your game. All you have to do is find the Mystery Gift option and then you would have to select "Receive Gift" and then you would have to select the Wi-Fi option which would be "Receive via Nintendo WFC" since WFC stands for Wi-Fi Connection.