{"id":19657130,"url":"https://github.com/snipem/gameprices","last_synced_at":"2025-04-28T18:32:56.403Z","repository":{"id":16531277,"uuid":"19284551","full_name":"snipem/gameprices","owner":"snipem","description":"PSN and Eshop CLI. Command line tool for searching items and alerting price drops in the Sony Entertainment Network aka Playstation Network and Nintendo Eshop","archived":false,"fork":false,"pushed_at":"2023-03-22T21:14:12.000Z","size":814,"stargazers_count":64,"open_issues_count":2,"forks_count":12,"subscribers_count":5,"default_branch":"master","last_synced_at":"2025-04-26T12:12:54.887Z","etag":null,"topics":["api","cli","eshop","nintendo","playstation","psn","sony-entertainment-network"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/snipem.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","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":"2014-04-29T17:05:24.000Z","updated_at":"2025-02-18T21:12:23.000Z","dependencies_parsed_at":"2024-11-11T15:35:26.526Z","dependency_job_id":"dd5afda5-a7d4-489c-b0ad-78030220a015","html_url":"https://github.com/snipem/gameprices","commit_stats":null,"previous_names":["snipem/psnprices"],"tags_count":8,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/snipem%2Fgameprices","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/snipem%2Fgameprices/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/snipem%2Fgameprices/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/snipem%2Fgameprices/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/snipem","download_url":"https://codeload.github.com/snipem/gameprices/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251366148,"owners_count":21578081,"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":["api","cli","eshop","nintendo","playstation","psn","sony-entertainment-network"],"created_at":"2024-11-11T15:30:06.568Z","updated_at":"2025-04-28T18:32:56.009Z","avatar_url":"https://github.com/snipem.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Gameprices\n\n[![Build](https://github.com/snipem/gameprices/actions/workflows/build.yaml/badge.svg)](https://github.com/snipem/gameprices/actions/workflows/build.yaml) [![PyPI version](https://badge.fury.io/py/gameprices.svg)](https://badge.fury.io/py/gameprices)\n\nCommand line tool for alerting price drops in the Sony PlayStation Network (PSN) and the Nintendo Eshop.\n\n## Description\n\nThe Sony Entertainment Network (SEN) uses CIDs to identify items in its catalogue. In order to alert you on the desired price of an SEN you need the CID. Use your Browser (cid GET parameter in URL) or this script (`--query`) to retrieve the CID.\n\nIn order to check the price of an item. You need a store identifier. These store identifiers are known to work:\n\n* DE/de (Germany)\n* GB/en (Great Britain)\n* US/en (United States)\n* SE/en (Sweden)\n* JP/jp (Japan)\n\nPrices are always in the local currency. Therefore, it is € for DE/de and £ for GB/en. Additionally, prices are those for PlayStation Plus users.\n\nThe Eshop implementation lacks unique identifiers, because the Eshop does not support searching for unique identifiers. Therefore, an identifier is constructed containing the game name.\n\n## Installation\n\nUse PyPI to install `gameprices`\n\n```bash\npip install gameprices\n```\n\nThis will install the Python modules and also the following command line tools\n\n```\npsncli\neshopcli\npsnmailalert\ndealsmailalert\n```\n\n### Install development build\n\n```bash\npip install .\n```\n\n## Usage\n\n### Mail alerting for single alerts you define yourself\n\nJust run `psnmailalert` for mail alerting. See example below. Alerts are set in the `alerts.csv` file. If no store is set. The German / European store is used as a default.\n\n### Command line interface\n\n```bash\nusage: psncli [-h] [--id ID] [--store STORE] [--price PRICE] [--query QUERY] [--json] [--log]\n\noptional arguments:\n-h, --help                  show this help message and exit\n--id ID, -i ID              CID of game to check\n--store STORE, -s STORE     Regional PSN store to check. Default: 'DE/de'\n--price PRICE, -p PRICE     Desired price of game\n--query QUERY, -q QUERY     Name of item to search for\n--json, -j                  Print JSON\n--log, -l                   Write to log file\n```\n\n#### Retrieving UTF-8 encoded output on terminals\n\nYou may have to tell Python that your terminal is capable of dealing with UTF-8 outputs. Some PSN items are annotated with trademark, copyright or foreign language specific symbols. To do so set `export PYTHONIOENCODING=utf-8` in your terminal window.\n\n## Example\n\nYou may run this script with the following command line variants:\n\n### Mail alerting - Get a mail when alerts have been met\n\nWith `psnmailalert` you may set alerts for price drops in the `alerts.csv` file. The first value is the CID for the item, the second is the price to be matched in order to alert you by mail, and the second value is the store to search in. You may mix stores in the `alerts.csv`. After a price has been matched, the alert is removed from `alerts.csv`. You will not get any further alerts for that item.\n\n```csv\nP0001-NPEJ00305_00-B000000000001030,19.00,DE/de\nP0001-NPEJ00305_00-B000000000001030,19.00,DE/de\nEP0102-CUSA02521_00-MEGAMANLEGACY000,7.00\nUP0102-CUSA02516_00-MEGAMANLEGACY000,7.00,US/en\nP0101-ULES01372_00-GPCMETALGE000001,10.00,DE/de\n```\n\nIf the store value is left blank, the script tries to extract the store from the beginning character of the CID.\n\n In order to receive mails you have to set your account settings in the file `mailconfig.json`. See `mailconfig.json_example` for an example config.\n\n To run `psnmailalert`, just type:\n\n    psnmailalert\n\n#### Example mail\n\n![Mail with alerts](https://raw.githubusercontent.com/snipem/gameprices/master/res/mail.png \"Mail with alerts\")\n\n### Searching for the CID of an item\n\nDefine the name of a game and the store.\n\n    psncli --query \"metal gear solid peace walker\" --store DE/de\n\nYou will get a result containing one to many search results with the CID. The first output of each search line is the CID, the second the name, the third the supported systems and the last is a description of the item type in the local store language. It is \"Vollversion\" here which means \"full version\" in German.\n\n    EP0101-ULES01372_00-GPCMETALGE000001    Metal Gear Solid: Peace Walker  PS Vita,PSP®    9.99    GAME\n\nUse the `--json` flag to get the same output as JSON.\n\n```bash\neshopcli --json -q \"Dynasty Warriors 8 Xtreme Legends\"\n[\n  {\n    \"id\": \"1490013\",\n    \"name\": \"DYNASTY WARRIORS 8: Xtreme Legends Definitive Edition\",\n    \"type\": \"GAME\",\n    \"prices\": [\n      {\n        \"price\": 39.99,\n        \"currency\": \"\",\n        \"type\": \"OFFER\"\n      }\n    ],\n    \"platforms\": [\n      \"Nintendo Switch\"\n    ]\n  },\n...\n```\n\n### Check if desired price has been met\n\nThe price is in local currency. As exit statuses render the outcome of the alert, you may send mails or desktop notifications with `\u0026\u0026` or `||`. In this example, there is a string printed to the console.\n\n```bash\npsncli --id EP0101-ULES01372_00-GPCMETALGE000001 --store DE/de --price 15.00 \u0026\u0026\necho \"Price matched, let's buy Metal Gear Solid PW\"\n```\n\n## Disclaimer\n\nThis script is not associated with Sony, Sony PlayStation, the PlayStation Network in any kind. It consumes a public interface that is publicly advertised to the browser to list store contents.\n\nThis script is not associated with Nintendo, Nintendo Switch, or the Nintendo Eshop in any kind. It consumes a public interface that is publicly advertised to the browser to list store contents.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsnipem%2Fgameprices","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsnipem%2Fgameprices","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsnipem%2Fgameprices/lists"}