PHPackages                             codebuglab/laravel-opensubtitles - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [API Development](/categories/api)
4. /
5. codebuglab/laravel-opensubtitles

ActiveLibrary[API Development](/categories/api)

codebuglab/laravel-opensubtitles
================================

Simple integration with OpenSubtitles API to search for and download subtitles.

1.0.1(1y ago)45151MITPHPPHP &gt;=7.0

Since Dec 5Pushed 1y ago1 watchersCompare

[ Source](https://github.com/codebuglab/laravel-opensubtitles)[ Packagist](https://packagist.org/packages/codebuglab/laravel-opensubtitles)[ RSS](/packages/codebuglab-laravel-opensubtitles/feed)WikiDiscussions main Synced 6d ago

READMEChangelog (4)Dependencies (1)Versions (5)Used By (0)

⚡⚡⚡ Laravel OpenSubtitles
=========================

[](#-laravel-opensubtitles)

Simple integration with OpenSubtitles API to search for and download subtitles.

[![Laravel OpenSubtitles](logo.png)](logo.png)

Table of contents
-----------------

[](#table-of-contents)

- [Setup](#setup)
    - [Installation](#installation)
    - [Publish](#publish)
- [Instructions](#Instructions)
    - [Subtitles](#subtitles)
        - [Search For Subtitles](#search-for-subtitles)
    - [Download](#download)
        - [Details](#details)
        - [Get Zip File By Legacy Subtitle Id](#get-zip-file-by-legacy-subtitle-id)
- [License](#license)

Setup
-----

[](#setup)

### Installation

[](#installation)

To install this package through composer run the following command in the terminal

```
composer require codebuglab/laravel-opensubtitles
```

### Publish

[](#publish)

You have to publish config file with this artisan command:

```
php artisan vendor:publish --provider="CodeBugLab\OpenSubtitles\OpenSubtitlesServiceProvider"
```

- File `opensubtitles.php` will be publish in `config` folder after that.
- Then you have to put your opensubtitles api key in your `env` file like this `OpenSubtitles_API_KEY=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx`.

Instructions
------------

[](#instructions)

- You can use opensubtitles api and get information your want, first take a quick look at [official api page](https://opensubtitles.stoplight.io/docs/opensubtitles-api/).
- For all next API requests you have to use OpenSubtitles facade

```
use CodeBugLab\OpenSubtitles\Facades\OpenSubtitles;
```

- Every request have it's own parameters and response and we gonna explain it in details

### Subtitles

[](#subtitles)

#### Search For Subtitles

[](#search-for-subtitles)

```
$parameters = [
    'imdb_id' => "315642",
    'languages' => 'en',
    'type' => 'movie'
];
$opensubtitles = OpenSubtitles::subtitles()->searchForSubtitles($parameters)->toArray();
```

- Simply this will search for subtitles depends on movie id in opensubtitles, IMDB id or even TMDB id.
- For more information about parameters and response [click here](https://opensubtitles.stoplight.io/docs/opensubtitles-api/b3A6Mjc1MTk3MjY-search-for-subtitles).

### Download

[](#download)

#### Details

[](#details)

```
$parameters = [
    'file_id' => "2712566",
    'sub_format' => 'srt'
];
$srtFile = OpenSubtitles::download()->details($parameters)->getSrt();
```

- Here you can get srt file by file\_id that you can get from [search for subtitles](#search-for-subtitles) query.
- You can download the file with other format, take a look at this [link](https://opensubtitles.stoplight.io/docs/opensubtitles-api/b3A6Mjc1MTk3MTk-subtitle-formats) to know all other formats you can download.
- Unfortunately there is a limit depends on your opensubtitle account start from 10 up to 1000 download per day.
- For more information about parameters and response [click here](https://opensubtitles.stoplight.io/docs/opensubtitles-api/b3A6Mjc1MTk3Mjc-download).

#### Get Zip File By Legacy Subtitle Id

[](#get-zip-file-by-legacy-subtitle-id)

```
$legacySubtitleId = "7090487";
$zipFile = OpenSubtitles::download()->getZipFileByLegacySubtitleId($legacySubtitleId);
```

- This is unofficial way to download the subtitles but it still supported by opensubtitles website.
- We need legacy subtitle id instead of file id and both are available in [search for subtitles](#search-for-subtitles) response.
- There is no specific limit to download by using this method.

License
-------

[](#license)

This package is a free software distributed under the terms of the MIT license.

###  Health Score

29

—

LowBetter than 59% of packages

Maintenance32

Infrequent updates — may be unmaintained

Popularity18

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity48

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~308 days

Total

4

Last Release

696d ago

Major Versions

v0.0.2-beta → 1.0.02021-12-10

### Community

Maintainers

![](https://www.gravatar.com/avatar/1b739843a13277460d1b33db36cacdd3fe8c5c5942f458ed26284aba28c16849?d=identicon)[CodeBugLab](/maintainers/CodeBugLab)

![](https://www.gravatar.com/avatar/c933185e0cb76b98ed1896622a2128f20e5dd92a305f8e5d7253b7f4e39aa84b?d=identicon)[moelkomy](/maintainers/moelkomy)

---

Top Contributors

[![moelkomy](https://avatars.githubusercontent.com/u/70802292?v=4)](https://github.com/moelkomy "moelkomy (6 commits)")

---

Tags

phpapilaravelsubtitlessubtitleopensubtitlesopensubtitles-apidownload-subtitlessubtitles-downloadersubtitles-search

### Embed Badge

![Health badge](/badges/codebuglab-laravel-opensubtitles/health.svg)

```
[![Health](https://phpackages.com/badges/codebuglab-laravel-opensubtitles/health.svg)](https://phpackages.com/packages/codebuglab-laravel-opensubtitles)
```

###  Alternatives

[resend/resend-laravel

Resend for Laravel

1191.4M6](/packages/resend-resend-laravel)[joisarjignesh/bigbluebutton

BigBlueButton Server API Library for Laravel

162145.5k1](/packages/joisarjignesh-bigbluebutton)[php-tmdb/laravel

Laravel Package for TMDB ( The Movie Database ) API. Provides easy access to the wtfzdotnet/php-tmdb-api library.

16553.3k1](/packages/php-tmdb-laravel)[dariusiii/tmdb-laravel

Laravel Package for TMDB ( The Movie Database ) API. Provides easy access to the wtfzdotnet/php-tmdb-api library.

1821.1k](/packages/dariusiii-tmdb-laravel)[wayofdev/laravel-symfony-serializer

📦 Laravel wrapper around Symfony Serializer.

2113.6k](/packages/wayofdev-laravel-symfony-serializer)[dystcz/lunar-api

Dystore API layer for Lunar e-commerce package

411.1k3](/packages/dystcz-lunar-api)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
