{"id":21565851,"url":"https://github.com/prevailexcel/laravel-bible","last_synced_at":"2025-03-18T05:19:11.705Z","repository":{"id":151163367,"uuid":"623864747","full_name":"PrevailExcel/laravel-bible","owner":"PrevailExcel","description":"A Laravel Package for nearly 2500 Bible versions available across over 1600 languages, powered by API.Bible.","archived":false,"fork":false,"pushed_at":"2023-04-05T08:56:12.000Z","size":7,"stargazers_count":2,"open_issues_count":0,"forks_count":2,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-01-24T12:11:19.631Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"PHP","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/PrevailExcel.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","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":"2023-04-05T08:53:23.000Z","updated_at":"2025-01-04T15:47:16.000Z","dependencies_parsed_at":null,"dependency_job_id":"ad05fdd8-d789-4252-a0ed-54664e10d07b","html_url":"https://github.com/PrevailExcel/laravel-bible","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PrevailExcel%2Flaravel-bible","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PrevailExcel%2Flaravel-bible/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PrevailExcel%2Flaravel-bible/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PrevailExcel%2Flaravel-bible/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/PrevailExcel","download_url":"https://codeload.github.com/PrevailExcel/laravel-bible/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244160064,"owners_count":20408022,"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":[],"created_at":"2024-11-24T10:22:08.600Z","updated_at":"2025-03-18T05:19:11.688Z","avatar_url":"https://github.com/PrevailExcel.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# laravel-bible\n\n[![Latest Stable Version](https://poser.pugx.org/prevailexcel/laravel-bible/v/stable.svg)](https://packagist.org/packages/prevailexcel/laravel-bible)\n[![License](https://poser.pugx.org/prevailexcel/laravel-bible/license.svg)](LICENSE.md)\n\n\u003e A Laravel Package for nearly 2500 Bible versions available across over 1600 languages, powered by API.Bible.\n\n## Installation\n\n[PHP](https://php.net) 5.4+ or [HHVM](http://hhvm.com) 3.3+, and [Composer](https://getcomposer.org) are required.\n\nTo get the latest version of Laravel Bible, simply require it\n\n```bash\ncomposer require prevailexcel/laravel-bible\n```\n\nOr add the following line to the require block of your `composer.json` file.\n\n```\n\"prevailexcel/laravel-bible\": \"1.0.*\"\n```\n\nYou'll then need to run `composer install` or `composer update` to download it and have the autoloader updated.\n\n\n\nOnce Laravel Bible is installed, you need to register the service provider. Open up `config/app.php` and add the following to the `providers` key.\n\n```php\n'providers' =\u003e [\n    ...\n    PrevailExcel\\Bible\\BibleServiceProvider::class,\n    ...\n]\n```\n\n\u003e If you use **Laravel \u003e= 5.5** you can skip this step and go to [**`configuration`**](https://github.com/PrevailExcel/laravel-bible#configuration)\n\n* `PrevailExcel\\Bible\\BibleServiceProvider::class`\n\nAlso, register the Facade like so:\n\n```php\n'aliases' =\u003e [\n    ...\n    'Bible' =\u003e PrevailExcel\\Bible\\Facades\\Bible::class,\n    ...\n]\n```\n\n## Configuration\n\nYou can publish the configuration file using this command:\n\n```bash\nphp artisan vendor:publish --provider=\"PrevailExcel\\Bible\\BibleServiceProvider\"\n```\n\nA configuration-file named `bible.php` with some sensible defaults will be placed in your `config` directory:\n\n```php\n\u003c?php\n\n\nreturn [\n\n    /**\n     * API Key From API.Bible Dashboard\n     *\n     */\n    'apiKey' =\u003e getenv('BIBLE_API_KEY'),\n\n    /**\n     * API.Bible Live URL\n     *\n     */\n    'url' =\u003e \"https://api.scripture.api.bible/v1\",\n\n    /**\n     * This is the list of available Versions\n     *\n     */\n    'versions' =\u003e [\n        [\n            'name' =\u003e 'kjv', // King James Version\n            'id' =\u003e 'de4e12af7f28f599-02',\n        ],\n        [\n            'name' =\u003e 'igbo', // Open Igbo Contemporary Bible 2020\n            'id' =\u003e 'a36fc06b086699f1-02',\n        ],\n        [\n            'name' =\u003e 'rv', //Revised Standard Version\n            'id' =\u003e '40072c4a5aba4022-01',\n        ],\n        [\n            'name' =\u003e 'yoruba', // Open Yoruba Contemporary Bible 2020\n            'id' =\u003e 'b8d1feac6e94bd74-01',\n        ],\n        [\n            'name' =\u003e 'hausa', // Open Hausa Contemporary Bible 2020\n            'id' =\u003e '0ab0c764d56a715d-01'\n        ]\n    ],\n\n    /**\n     * This is the default Version\n     *\n     */\n    'default' =\u003e getenv('BIBLE_DEFAULT_VERSION'),\n\n];\n\n```\n## Usage\n\nOpen your `.env` file and add your api key, and the default version you want to use like so:\n\n```php\nBIBLE_API_KEY=\"xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx\"\nBIBLE_DEFAULT_VERSION=\"kjv\"\n```\n\u003eYou have to register or login to your [API.Bible](https://scripture.api.bible) account and get your app api key.\n##\n*The default version must be set in your `config/bible.php` first.\n*If you are using a hosting service like heroku, ensure to add the above details to your configuration variables.*\n\n### You can now call it the `bible()` helper function or the `Bible::method()` facade.\n\n\n```php\n\u003c?php\n\nuse Illuminate\\Support\\Facades\\Route;\nuse PrevailExcel\\Bible\\Facades\\Bible;\n\nRoute::get('/bible-verse', function () {\n\n    request()-\u003ebook = 'JHN';  \n    request()-\u003echapter = 3;  \n    request()-\u003everse = 16;      // You can set requests from your form\n    return Bible::verse();  \n\n   // or simply\n\n    return Bible::verse(16, 3, 'JHN');    // You can pass to method directly\n});\n\nRoute::get('/bible-search', function () {\n    request()-\u003eterm = 'King solomon';\n    return bible()-\u003esearch();   // You can also use the bible() helper.\n});\n\n```\n\nSome other fluent methods this package provides are listed here.\n```php\n\n/**\n * This is the method to get the full list of availble bibles, you can copy the id of the version you want, alonside and name you want to call it and add it to your config/bible.php.\n * @returns array\n */\n Bible::bibles();\n/**\n * Alternatively, use the helper.\n */\nbible()-\u003ebibles();\n\n/**\n * This is the method to get a particular bible version.\n * Leave empty to use the default version\n * @param string|null $version\n * @return array\n */\n Bible::bible();\n \n/**\n * Alternatively, use the helper.\n */\nbible()-\u003ebible('igbo');\n\n\n/**\n * This is the method to get list of books in a particular bible version.\n * Leave empty to use the default version\n * @param string|null $version\n * @return array\n */\n Bible::books('kjv');\n \n/**\n * Alternatively, use the helper.\n */\nbible()-\u003ebooks();\n\n\n/**\n * This is the method to get a book from the bible.\n * @param string $book\n * @return array\n */\n Bible::book('GEN');\n \n/**\n * Alternatively, use the helper.\n */\nbible()-\u003ebook('MAT');\n\n/**\n * This is the method to get a chapter from a book from the bible.\n * @param string $chapter \n * @param string $book\n * @return array\n */\n Bible::chapter(23, 'LUK');\n \n/**\n * Alternatively, use the helper.\n */\nbible()-\u003echapter(5, 'MAT');\n\n/**\n * This is the method to get full list of verses of a chapter from a book from the bible.\n * @param string $chapter \n * @param string $book\n * @return array\n */\n Bible::verses(23, 'LUK');\n \n/**\n * Alternatively, use the helper.\n */\nbible()-\u003everses(5, 'MAT');\n\n```\n\n## Todo\n\n* Add Comprehensive Tests\n* Add support for Audio bibles\n* Add Bible Sections\n\n## Contributing\n\nPlease feel free to fork this package and contribute by submitting a pull request to enhance the functionalities.\n\n## How can I thank you?\n\nWhy not star the github repo? I'd love the attention! Why not share the link for this repository on Twitter or HackerNews? Spread the word!\n\nDon't forget to [follow me on twitter](https://twitter.com/EjimaduPrevail)!\nAlso check out my page on medium to catch articles and tutorials on Laravel [follow me on medium](https://medium.com/@prevailexcellent)!\n\nThanks!\nChimeremeze Prevail Ejimadu.\n\n## License\n\nThe MIT License (MIT). Please see [License File](LICENSE.md) for more information.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fprevailexcel%2Flaravel-bible","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fprevailexcel%2Flaravel-bible","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fprevailexcel%2Flaravel-bible/lists"}