Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9204415
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T23:42:24+00:00 2026-06-17T23:42:24+00:00

There is an android app, Passwallet, that is able to interpret pkpass files intented

  • 0

There is an android app, Passwallet, that is able to interpret pkpass files intented for the apple app Passbook (https://play.google.com/store/apps/details?id=com.attidomobile.passwallet)

I was wondering how to read pkpass files.

Pkpass files seem to be zip files with all the information inside in json files. Is there a default structure for the pkpass files? If so what is it? And what would be a good way to import that into a android app?


For the people who wonder how read the content of the pkpass file refer to the following code:

I set up this activity with the intent filter for pkpass files

        <intent-filter>
            <action android:name="android.intent.action.VIEW" />

            <category android:name="android.intent.category.DEFAULT" />

            <data
                android:mimeType="application/vnd-com.apple.pkpass"
                android:scheme="content" />
        </intent-filter>
        <intent-filter>
            <action android:name="android.intent.action.VIEW" />

            <category android:name="android.intent.category.DEFAULT" />

            <data
                android:mimeType="application/vnd.apple.pkpass"
                android:scheme="content" />
        </intent-filter>
        <intent-filter>
            <action android:name="android.intent.action.VIEW" />

            <category android:name="android.intent.category.DEFAULT" />

            <data
                android:mimeType="application/vnd-com.apple.pkpass"
                android:scheme="file" />
        </intent-filter>
        <intent-filter>
            <action android:name="android.intent.action.VIEW" />

            <category android:name="android.intent.category.DEFAULT" />

            <data
                android:mimeType="application/vnd.apple.pkpass"
                android:scheme="file" />
        </intent-filter>

@Override
protected void onCreate(Bundle savedInstanceState) {

super.onCreate(savedInstanceState);
Intent intent = getIntent();
Uri uri = intent.getData();
String scheme = uri.getScheme();

if(ContentResolver.SCHEME_CONTENT.equals(scheme)) {
    try {
        InputStream attachment = getContentResolver().openInputStream(uri);
        handleZipInput(attachment);
    } catch (FileNotFoundException e) {
        e.printStackTrace();
    }
}
else {
    String path = uri.getEncodedPath();
    try {
        FileInputStream fis = new FileInputStream(path);
        handleZipInput(fis);
    } catch (FileNotFoundException e) {
        e.printStackTrace();
    }
}
}

private void handleZipInput(InputStream in) {
    try {
        ZipInputStream zis = new ZipInputStream(in);
        ZipEntry entry;
        while((entry = zis.getNextEntry()) != null) {
            String filename = entry.getName();
            if(filename.equals("pass.json")) {
                StringBuilder s = new StringBuilder();
                int read = 0;
                byte[] buffer = new byte[1024];
                while((read = zis.read(buffer, 0, 1024)) >= 0)
                    s.append(new String(buffer, 0, read));

                JSONObject pass = new JSONObject(s.toString());
                break;
            }
        }
    } catch (Exception e) {
        e.printStackTrace();
    }
}
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-17T23:42:26+00:00Added an answer on June 17, 2026 at 11:42 pm

    You can download the full specification for the .pkpass bundle from here. The pass content is stored in a JSON file named pass.json. The .pkpass bundle is a zip file containing pass.json, the pass images, optional locale files and a manifest file.

    The manifest needs to be signed with an Apple issued Pass ID certificate. However for Android, or any other third party App, everything required to build the pass can be read from pass.json and the bundled images.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Is there any way to play video in Android App widget.
Is there a resource somewhere that says what pieces of an Android app are
I have made a simple android app,i that some calculations are there from 1
I have an android app, in that there is a particular requirement where in
We have an Android app that consists of about 20 activities. Whenever there is
When my android app starts there will be a prompt that asks user whether
I am making an android app but the problem here is that there are
In my android app I write some files to SD card. However there is
There is this one Android app called Out of Milk that has a menu
Is there some way that an Android app written in Air can send data

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.