{"id":13633000,"url":"https://github.com/stirante/lol-client-java-api","last_synced_at":"2026-01-18T12:41:17.218Z","repository":{"id":26619993,"uuid":"101484826","full_name":"stirante/lol-client-java-api","owner":"stirante","description":"Simple library which provides access to internal League of Legends Client API.","archived":false,"fork":false,"pushed_at":"2023-03-29T17:22:05.000Z","size":1252,"stargazers_count":68,"open_issues_count":4,"forks_count":14,"subscribers_count":9,"default_branch":"master","last_synced_at":"2024-11-09T02:32:52.530Z","etag":null,"topics":["internal-league","java","league","league-of-legends","legends-client"],"latest_commit_sha":null,"homepage":null,"language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/stirante.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}},"created_at":"2017-08-26T12:38:11.000Z","updated_at":"2024-10-30T17:18:07.000Z","dependencies_parsed_at":"2024-04-16T12:03:33.718Z","dependency_job_id":null,"html_url":"https://github.com/stirante/lol-client-java-api","commit_stats":null,"previous_names":[],"tags_count":20,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stirante%2Flol-client-java-api","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stirante%2Flol-client-java-api/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stirante%2Flol-client-java-api/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stirante%2Flol-client-java-api/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/stirante","download_url":"https://codeload.github.com/stirante/lol-client-java-api/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":249479042,"owners_count":21279184,"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":["internal-league","java","league","league-of-legends","legends-client"],"created_at":"2024-08-01T23:00:22.725Z","updated_at":"2026-01-18T12:41:12.177Z","avatar_url":"https://github.com/stirante.png","language":"Java","readme":"lol-client-java-api\n----------\n[![Build Status](https://travis-ci.org/stirante/lol-client-java-api.svg?branch=master)](https://travis-ci.org/stirante/lol-client-java-api) [![lol-client-java-api](https://jitpack.io/v/stirante/lol-client-java-api.svg)](https://jitpack.io/#stirante/lol-client-java-api)\n----------\n\nSimple library which provides access to internal League of Legends Client API.\n\n## Disclaimer\nThis product is not endorsed, certified or otherwise approved in any way by Riot Games, Inc. or any of its affiliates.\n\n## Requirements\n\n**lol-client-java-api** requires at least Java 8 and works only on Windows.\n\n## Setup\n\nThis project is available on [Jitpack](https://jitpack.io/#stirante/lol-client-java-api/1.1.7)\n\n### Gradle\n\nAdd Jitpack to your root build.gradle at the end of repositories:\n\n```\nallprojects {\n\trepositories {\n\t\t...\n\t\tmaven { url 'https://jitpack.io' }\n\t}\n}\n```\n\nAdd the project as a dependency:\n\n```\ndependencies {\n\tcompile 'com.github.stirante:lol-client-java-api:1.2.3'\n}\n```\n\n### Maven\n\nAdd Jitpack as a repository:\n\n```xml\n\u003crepositories\u003e\n\t\u003crepository\u003e\n\t    \u003cid\u003ejitpack.io\u003c/id\u003e\n\t    \u003curl\u003ehttps://jitpack.io\u003c/url\u003e\n\t\u003c/repository\u003e\n\u003c/repositories\u003e\n```\n\nAdd the project as a dependency:\n\n```xml\n\u003cdependency\u003e\n    \u003cgroupId\u003ecom.github.stirante\u003c/groupId\u003e\n    \u003cartifactId\u003elol-client-java-api\u003c/artifactId\u003e\n    \u003cversion\u003e1.2.3\u003c/version\u003e\n\u003c/dependency\u003e\n```\n\n#### Snapshots\n\nSnapshots of all the latest changes are available in my personal nexus repository.\n\n\n```xml\n\u003crepositories\u003e\n    \u003crepository\u003e\n        \u003cid\u003estirante-nexus-snapshots\u003c/id\u003e\n        \u003curl\u003ehttps://nexus.stirante.com/repository/maven-snapshots/\u003c/url\u003e\n    \u003c/repository\u003e\n\u003c/repositories\u003e\n```\n\n```xml\n\u003c!-- https://github.com/stirante/lol-client-java-api --\u003e\n\u003cdependency\u003e\n    \u003cgroupId\u003ecom.stirante\u003c/groupId\u003e\n    \u003cartifactId\u003elol-client-java-api\u003c/artifactId\u003e\n    \u003cversion\u003e1.2.11-SNAPSHOT\u003c/version\u003e\n\u003c/dependency\u003e\n```\n\n## Usage\n\nThis library depends on League of Legends client and requires it to be open while using this API.\n\n```java\npackage examples;\n\nimport com.stirante.lolclient.ClientApi;\nimport com.stirante.lolclient.ClientConnectionListener;\nimport generated.LolChampionsCollectionsChampion;\nimport generated.LolChampionsCollectionsChampionSkin;\nimport generated.LolSummonerSummoner;\n\nimport java.text.SimpleDateFormat;\nimport java.util.Date;\n\npublic class SkinListExample {\n\n    private static final SimpleDateFormat FORMATTER = new SimpleDateFormat(\"dd-MM-yyyy\");\n\n    /**\n     * Simple example, which show all owned champions and skins (with purchase date)\n     */\n    public static void main(String[] args) {\n        //Initialize API\n        ClientApi api = new ClientApi();\n        api.addClientConnectionListener(new ClientConnectionListener() {\n            @Override\n            public void onClientConnected() {\n                try {\n                    //Check if user is logged in\n                    if (!api.isAuthorized()) {\n                        System.out.println(\"Not logged in!\");\n                        return;\n                    }\n                    //Get current summoner\n                    LolSummonerSummoner summoner = api.executeGet(\"/lol-summoner/v1/current-summoner\", LolSummonerSummoner.class).getResponseObject();\n                    //Get champion collection of summoner\n                    LolChampionsCollectionsChampion[] champions = api.executeGet(\n                            \"/lol-champions/v1/inventories/\" + summoner.summonerId + \"/champions\",\n                            LolChampionsCollectionsChampion[].class).getResponseObject();\n                    for (LolChampionsCollectionsChampion champion : champions) {\n                        if (champion.ownership.owned) {\n                            System.out.println(champion.name + \" purchased on \" +\n                                    FORMATTER.format(new Date(champion.ownership.rental.purchaseDate)));\n                            for (LolChampionsCollectionsChampionSkin skin : champion.skins) {\n                                if (!skin.isBase \u0026\u0026 skin.ownership.owned) {\n                                    System.out.println(\"\\t\" + skin.name + \" purchased on \" +\n                                            FORMATTER.format(new Date(skin.ownership.rental.purchaseDate)));\n                                }\n                            }\n                        }\n                    }\n                    api.stop();\n                } catch (Exception e) {\n                    e.printStackTrace();\n                }\n            }\n\n            @Override\n            public void onClientDisconnected() {\n\n            }\n        });\n    }\n}\n```\n\nThis library is still under development and lacks many features. Right now to access them, use these methods.\n\n```java\npackage examples;\n\nimport com.stirante.lolclient.ClientApi;\nimport com.stirante.lolclient.ClientConnectionListener;\nimport generated.LolChatUserResource;\n\nimport java.io.IOException;\n\npublic class DirectAccessExample {\n\n    /**\n     * Simple example, which shows how to access API directly\n     */\n    public static void main(String[] args) {\n        //Initialize API\n        ClientApi api = new ClientApi();\n        //Add listener, which will notify us about client connection available\n        api.addClientConnectionListener(new ClientConnectionListener() {\n            @Override\n            public void onClientConnected() {\n                try {\n                    //Get current user chat info\n                    ApiResponse\u003cLolChatUserResource\u003e user =\n                            api.executeGet(\"/lol-chat/v1/me\", LolChatUserResource.class);\n                    //Print status message\n                    System.out.println(user.getRawResponse());\n                    api.stop();\n                } catch (Exception e) {\n                    e.printStackTrace();\n                }\n            }\n\n            @Override\n            public void onClientDisconnected() {\n\n            }\n        });\n    }\n}\n\n```\n\nAll possible paths can be found in ```api.getSwaggerJson()``` or ```api.getOpenapiJson()```. (In order to enable this, you need to add ```enable_swagger: true``` to ```Riot Games\\League of Legends\\RADS\\projects\\league_client\\releases\\\u003clatest version\u003e\\deploy\\system.yaml```)\n\nAll classes in ```generated``` package were generated from OpenAPI JSON. To regenerate all classes, run League of \nLegends client with access to swagger and run\n```\nmvn clean compile exec:java\n```\n\nAll examples are in ```examples``` package.\n\nLibrary contains very simple command line interface which can be used like this\n```\njava -jar lol-client-java-api.jar -p PATH -m METHOD\n```\nExample:\n```\njava -jar lol-client-java-api.jar -p rso-auth/v1/authorization -m GET\n```\n\nLibrary also allows for listening to events from League of Legends client\n```java\npackage examples;\n\nimport com.stirante.lolclient.ClientApi;\nimport com.stirante.lolclient.ClientConnectionListener;\nimport com.stirante.lolclient.ClientWebSocket;\n\nimport java.io.BufferedReader;\nimport java.io.InputStreamReader;\n\npublic class WebSocketExample {\n\n    private static ClientWebSocket socket;\n\n    /**\n     * Simple example showing how to receive websocket events from client\n     */\n    public static void main(String[] args) throws Exception {\n        //Initialize API\n        ClientApi api = new ClientApi();\n        api.addClientConnectionListener(new ClientConnectionListener() {\n            @Override\n            public void onClientConnected() {\n                System.out.println(\"Client connected\");\n                try {\n                    //open web socket\n                    socket = api.openWebSocket();\n                    //add event handler, which prints every received event\n                    socket.setSocketListener(new ClientWebSocket.SocketListener() {\n                        @Override\n                        public void onEvent(ClientWebSocket.Event event) {\n                            System.out.println(event);\n                        }\n\n                        @Override\n                        public void onClose(int code, String reason) {\n                            System.out.println(\"Socket closed, reason: \" + reason);\n                        }\n                    });\n                } catch (Exception e) {\n                    e.printStackTrace();\n                }\n            }\n\n            @Override\n            public void onClientDisconnected() {\n                System.out.println(\"Client disconnected\");\n                socket.close();\n            }\n        });\n        //close socket when user enters something into console\n        BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));\n        reader.readLine();\n        api.stop();\n        socket.close();\n    }\n\n}\n```\n\n## Live game API\n\nSince version 1.2.0, this api allows for requesting live game data. The example is in `src/main/java/examples/IngameApiExample.java`. \nTo check how it's working, run this example while in game. \n\nA generated documentation can be found [here](https://files.stirante.com/ingame-api.html) (not generated by me).\n\nGenerated models for live game API are in `generated.live` package (It's not very useful right now, because the schema in the documentation is lacking. I hope it will be added in the future).\n\n## Contributing\nAll contributions are appreciated.\nIf you would like to contribute to this project, please send a pull request.\n\n## Contact\nHave a suggestion, complaint, or question? Open an [issue](https://github.com/stirante/lol-client-java-api/issues).\n","funding_links":[],"categories":["Developer Tools"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstirante%2Flol-client-java-api","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fstirante%2Flol-client-java-api","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstirante%2Flol-client-java-api/lists"}