{"id":13701207,"url":"https://github.com/stfalcon-studio/SmsVerifyCatcher","last_synced_at":"2025-05-04T20:32:40.247Z","repository":{"id":41057309,"uuid":"65816657","full_name":"stfalcon-studio/SmsVerifyCatcher","owner":"stfalcon-studio","description":"Android library for phone number verification feature in your app. Automatically copies verification code from SMS right into the app. Made by Stfalcon","archived":false,"fork":false,"pushed_at":"2021-02-15T08:17:15.000Z","size":130,"stargazers_count":850,"open_issues_count":15,"forks_count":182,"subscribers_count":35,"default_branch":"master","last_synced_at":"2025-04-13T06:29:37.032Z","etag":null,"topics":["android","catcher","confirmation","sms","verification"],"latest_commit_sha":null,"homepage":"https://stfalcon.com","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/stfalcon-studio.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2016-08-16T12:03:23.000Z","updated_at":"2025-03-28T11:18:16.000Z","dependencies_parsed_at":"2022-07-14T07:00:33.326Z","dependency_job_id":null,"html_url":"https://github.com/stfalcon-studio/SmsVerifyCatcher","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stfalcon-studio%2FSmsVerifyCatcher","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stfalcon-studio%2FSmsVerifyCatcher/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stfalcon-studio%2FSmsVerifyCatcher/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stfalcon-studio%2FSmsVerifyCatcher/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/stfalcon-studio","download_url":"https://codeload.github.com/stfalcon-studio/SmsVerifyCatcher/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":252395585,"owners_count":21741061,"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","catcher","confirmation","sms","verification"],"created_at":"2024-08-02T20:01:22.208Z","updated_at":"2025-05-04T20:32:35.238Z","avatar_url":"https://github.com/stfalcon-studio.png","language":"Java","funding_links":[],"categories":["Java"],"sub_categories":[],"readme":"# SmsVerifyCatcher\n\n[![codebeat badge](https://codebeat.co/badges/0d0a3e88-6da8-4e43-a0fc-999af604d0b4)](https://codebeat.co/projects/github-com-stfalcon-studio-smsverifycatcher-master)\n[![](https://jitpack.io/v/stfalcon-studio/SmsVerifyCatcher.svg)](https://jitpack.io/#stfalcon-studio/SmsVerifyCatcher)\n\n![alt tag](http://i.imgur.com/7Kzzk5z.gif)\n\nA library for implementing interception of SMS with a verification code using a few lines of code.\n\n### Who we are\nNeed iOS and Android apps, MVP development or prototyping? Contact us via info@stfalcon.com. We develop software since 2009, and we're known experts in this field. Check out our [portfolio](https://stfalcon.com/en/portfolio) and see more libraries from [stfalcon-studio](https://stfalcon.com/en/opensource).\n\n### Download\n1. Add jitpack to the root build.gradle file of your project at the end of repositories.\n```\nallprojects {\n  repositories {\n    ...\n    maven { url 'https://jitpack.io' }\n  }\n}\n```\n2. Add the dependency\n```\ndependencies {\n  ...\n  implementation 'com.github.stfalcon-studio:SmsVerifyCatcher:[last_version]'\n}  \n```\n\n### Usage\n\nAdd permissions to AndroidManifest.xml:\n```xml\n  \u003cuses-permission android:name=\"android.permission.RECEIVE_SMS\" /\u003e\n  \u003cuses-permission android:name=\"android.permission.READ_SMS\" /\u003e\n```\nInit SmsVerifyCatcher in method like onCreate activity:\n```java\n    smsVerifyCatcher = new SmsVerifyCatcher(this, new OnSmsCatchListener\u003cString\u003e() {\n        @Override\n        public void onSmsCatch(String message) {\n            String code = parseCode(message);//Parse verification code\n            etCode.setText(code);//set code in edit text\n            //then you can send verification code to server\n        }\n    });\n```\nOverride activity lifecicle methods:\n```java\n    @Override\n    protected void onStart() {\n        super.onStart();\n        smsVerifyCatcher.onStart();\n    }\n\n    @Override\n    protected void onStop() {\n        super.onStop();\n        smsVerifyCatcher.onStop();\n    }\n\n    /**\n     * need for Android 6 real time permissions\n     */\n    @Override\n    public void onRequestPermissionsResult(int requestCode, @NonNull String[] permissions, @NonNull int[] grantResults) {\n        super.onRequestPermissionsResult(requestCode, permissions, grantResults);\n        smsVerifyCatcher.onRequestPermissionsResult(requestCode, permissions, grantResults);\n    }\n```\n\nYou can set phone number filter:\n```java\n    smsVerifyCatcher.setPhoneNumberFilter(\"777\");\n```\nor set message filter via regexp:\n```java\n   smsVerifyCatcher.setFilter(\"\u003cregexp\u003e\");\n```\nThat's all! \nTake a look at the [sample project](sample) for more information\n\n### License \n\n```\nCopyright 2017 stfalcon.com\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n    http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n```\n\n\n[sample]: \u003chttps://github.com/stfalcon-studio/SmsVerifyCatcher/tree/master/sample\u003e\n\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstfalcon-studio%2FSmsVerifyCatcher","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fstfalcon-studio%2FSmsVerifyCatcher","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstfalcon-studio%2FSmsVerifyCatcher/lists"}