{"id":13537940,"url":"https://github.com/darko1002001/android-rest-client","last_synced_at":"2025-12-18T07:51:51.491Z","repository":{"id":5156715,"uuid":"6325161","full_name":"darko1002001/android-rest-client","owner":"darko1002001","description":"A simple rest API client library","archived":false,"fork":false,"pushed_at":"2015-08-12T13:06:59.000Z","size":11230,"stargazers_count":83,"open_issues_count":0,"forks_count":23,"subscribers_count":6,"default_branch":"master","last_synced_at":"2025-07-06T09:04:48.272Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":"eudicots/Cactus","license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/darko1002001.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2012-10-21T20:32:16.000Z","updated_at":"2022-11-25T16:29:14.000Z","dependencies_parsed_at":"2022-09-03T00:11:18.770Z","dependency_job_id":null,"html_url":"https://github.com/darko1002001/android-rest-client","commit_stats":null,"previous_names":[],"tags_count":14,"template":false,"template_full_name":null,"purl":"pkg:github/darko1002001/android-rest-client","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/darko1002001%2Fandroid-rest-client","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/darko1002001%2Fandroid-rest-client/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/darko1002001%2Fandroid-rest-client/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/darko1002001%2Fandroid-rest-client/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/darko1002001","download_url":"https://codeload.github.com/darko1002001/android-rest-client/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/darko1002001%2Fandroid-rest-client/sbom","scorecard":{"id":322780,"data":{"date":"2025-08-11","repo":{"name":"github.com/darko1002001/android-rest-client","commit":"3e58498ac831513de8094f72b320ef7c5861c3b0"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":2,"checks":[{"name":"Token-Permissions","score":-1,"reason":"No tokens found","details":null,"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Code-Review","score":0,"reason":"Found 0/30 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Dangerous-Workflow","score":-1,"reason":"no workflows found","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"SAST","score":0,"reason":"no SAST tool detected","details":["Warn: no pull requests merged into dev branch"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}},{"name":"Binary-Artifacts","score":9,"reason":"binaries present in source code","details":["Warn: binary detected: gradle/wrapper/gradle-wrapper.jar:1"],"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Pinned-Dependencies","score":-1,"reason":"no dependencies found","details":null,"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE.txt:0","Info: FSF or OSI recognized license: Apache License 2.0: LICENSE.txt:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"Vulnerabilities","score":3,"reason":"7 existing vulnerabilities detected","details":["Warn: Project is vulnerable to: GHSA-2x83-r56g-cv47","Warn: Project is vulnerable to: GHSA-7r82-7xv7-xcpj","Warn: Project is vulnerable to: GHSA-cfh5-3ghh-wfjx","Warn: Project is vulnerable to: GHSA-fmj5-wv96-r2ch","Warn: Project is vulnerable to: GHSA-gw85-4gmf-m7rh","Warn: Project is vulnerable to: GHSA-3vqj-43w4-2q58","Warn: Project is vulnerable to: GHSA-4jq9-2xhw-jpx7"],"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}}]},"last_synced_at":"2025-08-18T01:47:03.921Z","repository_id":5156715,"created_at":"2025-08-18T01:47:03.922Z","updated_at":"2025-08-18T01:47:03.922Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":27793450,"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","status":"online","status_checked_at":"2025-12-18T02:00:09.725Z","response_time":55,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":[],"created_at":"2024-08-01T09:01:05.091Z","updated_at":"2025-12-18T07:51:51.453Z","avatar_url":"https://github.com/darko1002001.png","language":"Java","funding_links":[],"categories":["Java","HTTP客户端"],"sub_categories":["微服务框架"],"readme":"[Follow to public page for more info](http://darko1002001.github.com/android-rest-client/)\n\nandroid-rest-client\n===================\n\nA simple rest API client library\n\nCheck for the latest version on [Maven Central](http://search.maven.org/#search%7Cgav%7C1%7Cg%3A%22com.aranea-apps.android.libs%22%20AND%20a%3A%22android-rest%22)\n\n\n\nused libraries\n================\n\nMain Rest client uses OKHTTP from square\nhttps://github.com/square/okhttp\n\nto provide HTTP layer compatibility across android OS versions and manufacturers\n\nAdditions library uses:\n\n    \u003cdependency\u003e\n\t\t\t\u003cgroupId\u003ecom.fasterxml.jackson.core\u003c/groupId\u003e\n\t\t\t\u003cartifactId\u003ejackson-core\u003c/artifactId\u003e\n\t\t\t\u003cversion\u003e2.3.0\u003c/version\u003e\n\t\t\u003c/dependency\u003e\n\t\t\u003cdependency\u003e\n\t\t\t\u003cgroupId\u003ecom.fasterxml.jackson.core\u003c/groupId\u003e\n\t\t\t\u003cartifactId\u003ejackson-annotations\u003c/artifactId\u003e\n\t\t\t\u003cversion\u003e2.3.0\u003c/version\u003e\n\t\t\u003c/dependency\u003e\n\t\t\u003cdependency\u003e\n\t\t\t\u003cgroupId\u003ecom.fasterxml.jackson.core\u003c/groupId\u003e\n\t\t\t\u003cartifactId\u003ejackson-databind\u003c/artifactId\u003e\n\t\t\t\u003cversion\u003e2.3.0\u003c/version\u003e\n\t\t\u003c/dependency\u003e\n\t\t\u003cdependency\u003e\n\t\t\t\u003cgroupId\u003ecommons-io\u003c/groupId\u003e\n\t\t\t\u003cartifactId\u003ecommons-io\u003c/artifactId\u003e\n\t\t\t\u003cversion\u003e2.0.1\u003c/version\u003e\n\t\t\u003c/dependency\u003e\n\n\n\nOverview\n================\n\nCan be used to run synchronous or asynchronous requests towards your API.\nThere is a service class that handles request execution by 2 kinds of thread pools (choice can specified in the request implementation) either a single thread executor or a fixed size executor.\nEach of the executors is backed by a priority queue which means each individual request can have an execution priority set.\n\nYou can also provide your own service class which will handle the requests, extend from the current ones etc...\n\nBy default authorization is handled by setting an OAuth token in the header, but can be replaced with a custom implementation.\n\nNote: The process of getting an oauth token from the server is not a part of this library implementation and have to be set according to the specification for your webservice.\n\n\nUsage:\n======\n\nLook at the demo project included in this repo for details.\n\nThere is another sample project with an older version of android-rest-client found here:\nhttps://github.com/darko1002001/sync-notes-android\n\n\n## Steps to setup the library\n\n1. Import the lib project into your workspace and add it as a library project\n2. Look into the demo project manifest and copy the definitions\n3. Check the App.java class inside the Demo project on how to configure the library.\n\n\n## Adding just the JAR files\n\nThe library can be added inside /libs as a JAR. The dependencies include a version of Jackson for parsing JSON requests. you can use the regular jar\nand add your own parsers if the responses aren't JSON or you want to use a different library for parsing them.\n\n## Manifest Declarations\n\n      \u003cuses-permission android:name=\"android.permission.INTERNET\" /\u003e\n    \n      \u003cuses-sdk android:minSdkVersion=\"14\" /\u003e\n    \n      \u003capplication\u003e\n      \u003cservice android:name=\"com.araneaapps.android.libs.asyncrunners.services.ExecutorService\"\u003e\u003c/service\u003e\n      \u003c/application\u003e\n\n## Configuration\n\nThe library needs to be configured in a class extending Application (look into the demo project for specifics).\n\n\n    RestClientConfiguration builder = new RestClientConfiguration.ConfigurationBuilder()\n        .setAuthenticationProvider(new AuthenticationProvider() {\n          @Override\n          public void authenticateRequest(RestClientRequest client) {\n            // YOu can add parameters or headers which will be attached to each request\n          }\n        })\n        .create();\n\n    RestClientConfiguration.init(this, builder);\n\n## Note - If including this library with gradle will automatically merge your manifest with the one with the library. The lib is published as AAR.\n\n\n## Calling requests (From the demo project)\n\n    ```\n\n    //----------------------------------\n    \n    TwitterService.getUsersTwitterRequest(\"android\").setCallback(new HttpCallbackImplementation())\n        .executeAsync();\n    \n    //----------------------------------\n\n\n    // Callback returning your defined type\n\n    private final class HttpCallbackImplementation implements HttpCallback\u003cUserModel\u003e {\n\n        @Override\n        public void onSuccess(UserModel responseData, ResponseStatus responseCode) {\n            textViewResponse.setText(responseData.toString());\n        }\n\n        @Override\n        public void onHttpError(ResponseStatus responseCode) {\n            Toast.makeText(getApplicationContext(),\n                    responseCode.getStatusCode() + \" \" + responseCode.getStatusMessage(),\n                    Toast.LENGTH_LONG).show();\n\n        }\n    }\n    ```\n\nTwo callback methods are created each executing by default in the Android UI Thread so you don't have to implement the logic for switching back to UI from another thread.\n\n\n## SDK that uses This library:\n      \nChute\nhttps://github.com/chute/Chute-SDK-V2-Android\n\n\n\n## Use of Authentication Provider\n\nLook at the demo project to see how the Authentication Provider can be set. Use this if you need to define a custom logic\n(Parameters and/or headers that will be appended on each request). You can also specify a provider for individual requests.\n\n\n# Changelog:\n\n## Release 2.2.0\n\nUpdated version of OKHTTP to 2.+\nChanged the requests to RestClientRequest.class which handles all the request types.\nAdded the option to run requests without a parser or a callback\nThe callback can be set externally when creating the request\n\n## Release 1.7.0\n\n  Added RestClientConfiguration so all the global configuration is done through it.\n\n## Release 1.6.0\n\n### Breaking changes\n\n  Added response status to success callback implementation\n\n## Release 1.4.0\n\n  Created a new project additions which now has some helper libraries and classes such as Jackson JSON parser, IOUtils from apache etc...\n  Moved the async part (Service with executors) of the library to a new more general project on github not specific to just HTTP.\n  HttpRequestStore.init(context) is now replaced with AsyncRunners.init(context) which will provide a wrapping layer around the code that should be initialized in the App class\n  HttpRequest now extends Runnable interface\n  Added the option to override a handleStatus method in BaseHttpRequestImpl to be able to do custom result handing based on the status (see demo for sample)\n\n## Release 1.3.5\n\n  Fix issue with add param with token provider\n  Added socket timeout and connection timeout setters by calling `getClient().set...` inside any of the request classes. \n\n## Release 1.3.0\n\n   Added Entity body requests which are now the base class for the String body request.\n   Opens options to add FileEntity body which enables you to upload streams from files.\n   File Requests also include a progress listener which you can set if you want to track the progress.\n   Added File Parser which save the response stream to a specified file location.\n\n## Release 1.1.0\n   Reworked the HttpRequestParser to return an InputStream instead of a String.\n   Use StringResponseParser (extend or use directly) to get the input stream into a String\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdarko1002001%2Fandroid-rest-client","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdarko1002001%2Fandroid-rest-client","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdarko1002001%2Fandroid-rest-client/lists"}