PHPackages                             kechujian/aliyun-oss-sdk-laravel - 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. kechujian/aliyun-oss-sdk-laravel

ActiveLibrary[API Development](/categories/api)

kechujian/aliyun-oss-sdk-laravel
================================

A simple Laravel 5 and lumen service provider for including the Oss PHP SDK for PHP.

v1.1(7y ago)132MITPHPPHP &gt;=5.5.9

Since Sep 4Pushed 7y ago1 watchersCompare

[ Source](https://github.com/kechujian/aliyun-oss-sdk-laravel)[ Packagist](https://packagist.org/packages/kechujian/aliyun-oss-sdk-laravel)[ Docs](https://github.com/kechujian)[ RSS](/packages/kechujian-aliyun-oss-sdk-laravel/feed)WikiDiscussions master Synced yesterday

READMEChangelogDependencies (5)Versions (3)Used By (0)

AliCloud OSS Service Provider for Laravel 5
===========================================

[](#alicloud-oss-service-provider-for-laravel-5)

[![Build Status](https://camo.githubusercontent.com/763301b46030ec3a60d8ff48b23254176404dd820cafcc5fa2f4ff157caa3ac0/68747470733a2f2f7472617669732d63692e6f72672f616c6979756e2f616c6979756e2d6f73732d7068702d73646b2d6c61726176656c2e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/aliyun/aliyun-oss-php-sdk-laravel)[![Coverage Status](https://camo.githubusercontent.com/a005535798a6fd8631af2e2c83bc99acf36d6917038d0d6d887e918a2e25c335/68747470733a2f2f636f766572616c6c732e696f2f7265706f732f6769746875622f616c6979756e2f616c6979756e2d6f73732d7068702d73646b2d6c61726176656c2f62616467652e7376673f6272616e63683d6d6173746572)](https://coveralls.io/github/aliyun/aliyun-oss-php-sdk-laravel?branch=master)

[README of Chinese](https://github.com/kechujian/aliyun-oss-sdk-laravel/blob/master/README-CN.md)
-------------------------------------------------------------------------------------------------

[](#readme-of-chinese)

Make a Reference in Your Laravel Project
----------------------------------------

[](#make-a-reference-in-your-laravel-project)

- Install the Laravel framework or the Lumen framework.
- Create a Laravel or Lumen project, depending on the framework you have installed.
- In the composer.json file of the new project, insert the following code:

    ```
    {
        "require": {
            "kechujian/aliyun-oss-sdk-laravel": "~1.0.0"
        }
    }

    ```
- Run the following command: `composer update`

For the Laravel Project
-----------------------

[](#for-the-laravel-project)

- Edit the vendor/aliyun-oss/aliyun-oss-php-sdk-laravel/config/config.php file as follows:

    ```
    return [
        'id' => 'your id',
        'key' => 'your key',
        'endpoint' => 'your endpoint',
        'bucket' => 'your bucket',
        'iscname' => true or false
    ];

    ```
- Edit the config/app.php file and register OSS Service Provider:

    ```
    'providers' => array(
        // ...
        AliyunOss\Laravel\AliyunOssServiceProvider::class,
    )

    ```
- Edit the config/app.php file to insert an aliases segment.

    ```
    'aliases' => array(
        // ...
        'OSS' => AliyunOss\Laravel\AliyunOssFacade::class,
    )

    ```
- Edit the routes/web.php file as follows:

    ```
    Route::get('/', function()
    {
        $client = App::make('aliyun-oss');
        $client->putObject("your bucket", "your object", "content you want to upload");
        $result = $client->getObject("your bucket", "your boject");
        echo $result;
    });

    ```

For the Lumen Project
---------------------

[](#for-the-lumen-project)

- Edit the vendor/aliyun-oss/aliyun-oss-php-sdk-laravel/config/config.php file as follows:

    ```
    return [
        'id' => 'your id',
        'key' => 'your key',
        'endpoint' => 'your endpoint',
        'bucket' => 'your bucket',
        'iscname' => true or false
    ];

    ```
- Edit the bootstrap/app.php file and register OSS Service Providers:

    ```
    $app->register(AliyunOss\Laravel\AliyunOssServiceProvider::class);

    ```
- Edit the routes/web.php file as follows:

    ```
    $app->get('/', function () use ($app) {
        $client = $app->make('aliyun-oss');
        $client->putObject('your bucket', 'your key',  "content you want to upload");
        $result = $client->getObject("your bucket", "your boject");
        echo $result;
    });

    ```

Run the Test Case
-----------------

[](#run-the-test-case)

- Set the following environment variables:

```
export OSS_ENDPOINT=''
export OSS_ACCESS_KEY_ID=''
export OSS_ACCESS_KEY_SECRET=''
export OSS_BUCKET=''

```

- Switch to the project directory and run the following command: `php vendor/bin/phpunit`

License
-------

[](#license)

- [MIT](https://github.com/aliyun/aliyun-oss-php-sdk-laravel/blob/master/LICENSE.md)

###  Health Score

26

—

LowBetter than 43% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity9

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity58

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 ~51 days

Total

2

Last Release

2756d ago

### Community

Maintainers

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

---

Top Contributors

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

---

Tags

sdklumenlaravel 5aliyunossalicloudiscname

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/kechujian-aliyun-oss-sdk-laravel/health.svg)

```
[![Health](https://phpackages.com/badges/kechujian-aliyun-oss-sdk-laravel/health.svg)](https://phpackages.com/packages/kechujian-aliyun-oss-sdk-laravel)
```

###  Alternatives

[aliyuncs/aliyun-oss-php-sdk-laravel

A simple Laravel 5 and lumen service provider for including the Oss PHP SDK for PHP.

7935.4k2](/packages/aliyuncs-aliyun-oss-php-sdk-laravel)[openai-php/laravel

OpenAI PHP for Laravel is a supercharged PHP API client that allows you to interact with the Open AI API

3.7k7.6M74](/packages/openai-php-laravel)[resend/resend-laravel

Resend for Laravel

1191.4M6](/packages/resend-resend-laravel)

PHPackages © 2026

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