---
title: "Demo generating iOS Passbook Pass with passkit4j and Play! Framework"
date: 2013-01-24T23:40:37+00:00
author: "poornerd"
tags: ["iOS", "passkit", "passkit4j", "PlayFramework"]
canonical: https://www.poornerd.com/2013/01/24/demo-generating-ios-passbook-pass-with-passkit4j-and-play-framework/
source: Raw Markdown twin of the HTML article; content is the original source.
---
[<img class="alignleft size-medium wp-image-171" alt="screenshot" src="https://www.poornerd.com/wp-content/uploads/2013/01/screenshot-195x300.png" width="195" height="300" srcset="https://www.poornerd.com/wp-content/uploads/2013/01/screenshot-195x300.png 195w, https://www.poornerd.com/wp-content/uploads/2013/01/screenshot-666x1024.png 666w, https://www.poornerd.com/wp-content/uploads/2013/01/screenshot.png 682w" sizes="(max-width: 195px) 100vw, 195px" />](https://www.poornerd.com/wp-content/uploads/2013/01/screenshot.png)I recently stumbled across <a href="https://github.com/ryantenney/passkit4j" onclick="javascript:pageTracker._trackPageview('/outbound/article/github.com');" target="_blank">passkit4j</a> with which it is not that hard to create a Passbook pass &#8211; assuming you have an Apple Developer Account, and can figure how to do the whole provisioning and adding the Key to your keystore (<a href="https://github.com/ryantenney/passkit4j" onclick="javascript:pageTracker._trackPageview('/outbound/article/github.com');" target="_blank">more on that here</a>).

I followed the example from passkit4j (<a href="https://github.com/ryantenney/passkit4j/issues/8#issuecomment-12056804" onclick="javascript:pageTracker._trackPageview('/outbound/article/github.com');" target="_blank">and discovered a bug in it while trying to get the pass onto my iphone</a>).  **TIP**: use the iPhone Simulator and look at the logs for errors when trying to load the pass!

I created a simple Play! Framework 2.0.4 project to generate the pass from a webapp.

If you want to try it out, this is all you need to do:

  1. checkout <a href="https://github.com/poornerd/passbook-test" onclick="javascript:pageTracker._trackPageview('/outbound/article/github.com');" target="_blank">passbook-test </a>from github
  2. get your Provisioning File and Certifictes from your Apple Developer Account and add them to your keystore:<a href="https://github.com/ryantenney/passkit4j" onclick="javascript:pageTracker._trackPageview('/outbound/article/github.com');">https://github.com/ryantenney/passkit4j</a>
  3. add then information about the provisioning and certificate files to the application.conf
  4. play run
