{"id":17125258,"url":"https://github.com/baltpeter/parse-play","last_synced_at":"2025-04-13T05:34:43.434Z","repository":{"id":37243798,"uuid":"503139275","full_name":"baltpeter/parse-play","owner":"baltpeter","description":"Library for fetching and parsing select data on Android apps from the Google Play Store via undocumented internal APIs.","archived":false,"fork":false,"pushed_at":"2024-06-25T07:21:10.000Z","size":144,"stargazers_count":29,"open_issues_count":4,"forks_count":5,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-11T18:14:35.161Z","etag":null,"topics":["android","batchexecute","google-play-store","mobile-privacy"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/baltpeter.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2022-06-13T22:58:26.000Z","updated_at":"2025-02-20T21:16:06.000Z","dependencies_parsed_at":"2024-06-13T10:29:49.608Z","dependency_job_id":"921cf7f2-fa8f-4db0-81a9-21f4ab3ec54a","html_url":"https://github.com/baltpeter/parse-play","commit_stats":null,"previous_names":[],"tags_count":6,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/baltpeter%2Fparse-play","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/baltpeter%2Fparse-play/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/baltpeter%2Fparse-play/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/baltpeter%2Fparse-play/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/baltpeter","download_url":"https://codeload.github.com/baltpeter/parse-play/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248670518,"owners_count":21142896,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["android","batchexecute","google-play-store","mobile-privacy"],"created_at":"2024-10-14T18:44:32.563Z","updated_at":"2025-04-13T05:34:43.068Z","avatar_url":"https://github.com/baltpeter.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# parse-play\n\n\u003e Library for fetching and parsing select data on Android apps from the Google Play Store via undocumented internal APIs.\n\nThis library is able to fetch and parse data from undocumented internal API endpoints of the Google Play Store. Currently, it has the following features:\n\n* Fetch the **charts of the most popular apps**, including filtering by category and chart.\n* Fetch an app's **metadata** including **data safety labels**.\n* **Search** for apps.\n\nI'll extend the supported API endpoints over time, as per what I need for my projects. The focus will likely be on functions useful for research into mobile privacy and data protection.\n\nAs all the used endpoints are undocumented, I had to resort to reverse-engineering the Play Store website, which involved some amount of guessing as to which values mean what. It is possible that I have misinterpreted some of them. It is also entirely possible that some or all of the endpoints will stop working out of the blue at some point, or change their request and/or response formats.\n\n## Installation\n\nYou can install parse-play using yarn or npm:\n\n```sh\nyarn add parse-play\n# or `npm i parse-play`\n```\n\n## API reference\n\nA full API reference can be found in the [`docs` folder](/docs/README.md).\n\n## Usage examples\n\n### Fetch app top charts\n\nThe following example fetches the current top 100 free apps across all categories for Germany:\n\n```ts\nimport { fetchTopCharts } from 'parse-play';\n\n(async () =\u003e {\n    const topChart = await fetchTopCharts(\n        { category: 'APPLICATION', chart: 'topselling_free', count: 100 },\n        { country: 'DE', language: 'EN' }\n    );\n\n    console.log(topChart?.length); // 100\n    console.log(topChart?.[0]?.app_id, topChart?.[0]?.name); // com.amazon.mShop.android.shopping Amazon Shopping\n})();\n```\n\nYou can also request multiple top charts at once. These will all be fetched in a single API request. Note that country and language apply to _all_ requests in a batch.\n\nThis example fetches the top 5 free education apps, as well as the top 1000 paid adventure game apps, both for the UK:\n\n```ts\nconst topCharts = await fetchTopCharts(\n    [\n        { category: 'EDUCATION', chart: 'topselling_free', count: 5 },\n        { category: 'GAME_ADVENTURE', chart: 'topselling_paid', count: 1000 },\n    ],\n    { country: 'GB', language: 'EN' }\n);\n\nconsole.log(topCharts[0]?.length); // 5\nconsole.log(topCharts[0]?.[0]?.app_id, topCharts?.[0]?.[0]?.name); // cn.danatech.xingseus PictureThis - Plant Identifier\nconsole.log(topCharts[1]?.length); // 660\nconsole.log(topCharts[1]?.[0]?.app_id, topCharts?.[1]?.[0]?.name); // com.MOBGames.PoppyMobileChap1 Poppy Playtime Chapter 1\n```\n\nNote that despite us trying to fetch 1000 apps for the second chart, only 660 apps were returned. This is a server-side limit.\n\n### Fetch app details\n\nThe following example fetches the metadata of the Facebook app:\n\n```ts\nimport { fetchAppDetails } from 'parse-play';\n\n(async () =\u003e {\n    const appDetails = await fetchAppDetails({ appId: 'com.facebook.katana' }, { language: 'EN', country: 'DE' });\n    console.log(appDetails.name, 'costs', appDetails.price, 'and was last updated on', appDetails.updated_on);\n    // Facebook costs €0.00 and was last updated on 2024-06-13T04:58:13.000Z\n})();\n```\n\nThrough this endpoint, you can also fetch an app's data safety labels:\n\n```ts\nconst appDetails = await fetchAppDetails({ appId: 'com.facebook.katana' }, { language: 'EN', country: 'DE' });\n\nconsole.log('Data shared:', appDetails.data_shared);\nconsole.log('Data collected:', appDetails.data_collected);\nconsole.log('Security practices:', appDetails.security_practices);\nconsole.log('Privacy policy URL:', appDetails.privacy_policy_url);\n```\n\n\u003cdetails\u003e\n\u003csummary\u003eData safety label response\u003c/summary\u003e\nThe result looks like this:\n\n```\nData shared: [\n  {\n    category: 'Personal info',\n    type: 'Name',\n    purposes: [ 'Fraud prevention, security, and compliance' ],\n    optional: false\n  },\n  // …\n]\nData collected: [\n  {\n    category: 'Personal info',\n    type: 'Name',\n    purposes: [\n      'App functionality',\n      'Analytics',\n      'Developer communications',\n      'Advertising or marketing',\n      'Fraud prevention, security, and compliance',\n      'Personalization',\n      'Account management'\n    ],\n    optional: false\n  },\n  // …\n]\nSecurity practices: {\n  data_encrypted_in_transit: true,\n  can_request_data_deletion: true,\n  committed_to_play_families_policy: undefined,\n  independent_security_review: undefined\n}\nPrivacy policy URL: https://www.facebook.com/about/privacy/\n```\n\u003c/details\u003e\n\n### Search for apps\n\nThe following example searches for the term \"education\":\n\n```ts\nimport { searchApps } from 'parse-play';\n\n(async () =\u003e {\n    const searchResult = await searchApps({ searchTerm: 'education' }, { language: 'EN', country: 'DE' });\n    console.dir(searchResult, { depth: null });\n})();\n```\n\n\u003cdetails\u003e\n\u003csummary\u003eSearch apps response\u003c/summary\u003e\nThe response looks like this:\n\n```ts\n[\n  {\n    position: 1,\n    app_id: 'de.easysoft.app.education',\n    icon_url: 'https://play-lh.googleusercontent.com/KZ19KJw8vrNy6gpRtyzLAGichfxShCU9L2kZdJbnKs6mrKblKqcWBvM5v9QdgEW-SGFR',\n    screenshot_urls: [\n      'https://play-lh.googleusercontent.com/Bh0sDOl-oOcOtmjKTIXL4eE_vIcDqntnrwqvoi9qylQjptmPnMtZyMkUxUh4JnC0hQ',\n      'https://play-lh.googleusercontent.com/vlOZjzYHjRZEwBTWYVWxkWvXMEjtJGJ2tbJQJuNuB89wgXA-MVLM5MwaJOhRMdY7vA',\n      'https://play-lh.googleusercontent.com/zEiBcIIuY6LP_BbNZQ5PxxilZMmkf6dOn2XsYCNET5GumPOktuhZPo438QiasoVv5g4l',\n      'https://play-lh.googleusercontent.com/XP02HcK1hsyCUdrt9abKiy-KdF0ATB3W5jVVW5StHkxsmrlz22DFXfPbovZhyYjLiqI',\n      'https://play-lh.googleusercontent.com/c3pmHB-DkHZ6j3g3LfmgWgdHlIK18jOt-2oFGkh9GTtQwY2aay7C9VO70XnZPX3qJas',\n      'https://play-lh.googleusercontent.com/8Pj29QXYfhFlmPrMhNvgXdWeCj4X2n3vubIxoHGgd_w4h4MsE04TftKskB53BHp01XU',\n      'https://play-lh.googleusercontent.com/mnyR06BYAQQ66ONQrYMluqALsdpKIV1_M2pKEIYurLlpEdRsE0Yu-AMsOmuPNYk-a8jP'\n    ],\n    name: 'easySoft App Education',\n    rating: 2.739726,\n    category: 'Business',\n    price: '€0.00',\n    buy_url: 'https://play.google.com/store/apps/details?id=de.easysoft.app.education\u0026rdid=de.easysoft.app.education\u0026feature=md\u0026offerId',\n    store_path: '/store/apps/details?id=de.easysoft.app.education',\n    trailer_url: undefined,\n    description: 'With the easySoft App Education, […]',\n    developer: 'easySoft. GmbH',\n    downloads: '10,000+',\n    cover_image_url: 'https://play-lh.googleusercontent.com/mnyR06BYAQQ66ONQrYMluqALsdpKIV1_M2pKEIYurLlpEdRsE0Yu-AMsOmuPNYk-a8jP'\n  },\n  // …\n]\n```\n\u003c/details\u003e\n\n### Fetch an app's data safety labels\n\n\u003e [!WARNING]\n\u003e The separate function for fetching data safety labels is deprecated and will be removed in a future release. Instead, you can use [fetch an app's metadata](#fetch-app-details), which includes the data safety label.\n\nThe following example fetches the data safety labels for TikTok in English:\n\n```ts\nimport { fetchDataSafetyLabels } from 'parse-play';\n\n(async () =\u003e {\n    const labels = await fetchDataSafetyLabels([{ app_id: 'com.zhiliaoapp.musically' }], { language: 'EN', });\n    console.dir(labels, { depth: null });\n})();\n```\n\n\u003cdetails\u003e\n\u003csummary\u003eData safety label response\u003c/summary\u003e\nThe response looks like this:\n\n```ts\n{\n  name: 'TikTok',\n  app_id: 'com.zhiliaoapp.musically',\n  developer: {\n    name: 'TikTok Pte. Ltd.',\n    path: '/store/apps/developer?id=TikTok+Pte.+Ltd.',\n    website_url: 'https://www.tiktok.com/',\n    email: 'feedback@tiktok.com',\n    address: '201 Henderson Road,\\n#06-22 Apex@Henderson,\\nSingapore 159545 Singapore'\n  },\n  icon_url: 'https://play-lh.googleusercontent.com/iBYjvYuNq8BB7EEEHktPG1fpX9NiY7Jcyg1iRtQxO442r9CZ8H-X9cLkTjpbORwWDG9d',\n  privacy_policy_url: 'https://www.tiktok.com/legal/privacy-policy',\n  data_shared: [],\n  data_collected: [\n    {\n      category: 'Location',\n      type: 'Approximate location',\n      purposes: [\n        'App functionality',\n        'Analytics',\n        'Advertising or marketing',\n        'Personalization'\n      ]\n    },\n    // …\n  ],\n  security_practices: {\n    data_encrypted_in_transit: true,\n    can_request_data_deletion: true,\n    committed_to_play_families_policy: undefined,\n    independent_security_review: undefined\n  }\n}\n```\n\u003c/details\u003e\n\nYou can also request the labels for multiple apps at once by adding corresponding objects to the first parameter, they will all be fetched in a single API request.\n\n\n## License\n\nparse-play is licensed under the MIT license, see the [`LICENSE`](/LICENSE) file for details.\n\nIssues and pull requests are welcome!\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbaltpeter%2Fparse-play","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbaltpeter%2Fparse-play","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbaltpeter%2Fparse-play/lists"}