PHPackages                             kumatch/keystore - 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. [File &amp; Storage](/categories/file-storage)
4. /
5. kumatch/keystore

ActiveLibrary[File &amp; Storage](/categories/file-storage)

kumatch/keystore
================

A simple key-base value storage.

0.3.0(12y ago)22122MITPHPPHP &gt;=5.3.3

Since Dec 13Pushed 10y agoCompare

[ Source](https://github.com/kumatch/php-keystore)[ Packagist](https://packagist.org/packages/kumatch/keystore)[ Docs](https://github.com/kumatch/php-keystore)[ RSS](/packages/kumatch-keystore/feed)WikiDiscussions master Synced 3d ago

READMEChangelogDependencies (3)Versions (4)Used By (2)

PHP keystore
============

[](#php-keystore)

A simple key-base value storage.

[![Build Status](https://camo.githubusercontent.com/8dd83b482998bedf4d03de7cbce67c584d01fece061c02893bf7f8082bbb218e/68747470733a2f2f7472617669732d63692e6f72672f6b756d617463682f7068702d6b657973746f72652e706e673f6272616e63683d6d6173746572)](https://travis-ci.org/kumatch/php-keystore)

Install
-------

[](#install)

Add "kumatch/keystore" as a dependency in your project's composer.json file.

```
{
  "require": {
    "kumatch/keystore": "*"
  }
}

```

And install your dependencies.

```
$ composer install

```

Drivers
-------

[](#drivers)

- [File system](https://github.com/kumatch/php-keystore-filesystem)
- [AWS S3](https://github.com/kumatch/php-keystore-s3)

Methods
-------

[](#methods)

```
use Kumatch\KeyStore\Storage;
use Kumatch\KeyStore\Filesystem\Driver;  // driver
```

### \_\_construct ($driver)

[](#__construct-driver)

Create a storage instance by storage driver.

```
$driver = new Driver("/tmp");
$storage = new Storage($driver);
```

### write ($key, $value)

[](#write-key-value)

```
$key = "foo/bar";
$value = "Hello, world.";

$storage->write($key, $value);
```

### append ($key, $value)

[](#append-key-value)

```
$key = "foo/bar";
$value = "Hello, world.";

$storage->append($key, $value);
```

### read ($key)

[](#read-key)

```
$key = "foo/bar";
$value = $storage->read($key);
// returns a value of a key
// if key is not exists, returns null
```

### exists ($key)

[](#exists-key)

```
$key = "foo/bar";
$isExists = $storage->exists($key);
// returns boolean
```

### remove ($key)

[](#remove-key)

```
$key = "foo/bar";
$storage->remove($key);
```

### import ($key, $filename)

[](#import-key-filename)

```
$key = "foo/bar";
$filename = "/path/to/input.jpg";

$storage->import($key, $filename);
```

### export ($key, $filename)

[](#export-key-filename)

```
$key = "foo/bar";
$filename = "/path/to/output.jpg";

$storage->export($key, $filename);
// outputs a value to file path.
```

### copy ($srcKey, $dstKey)

[](#copy-srckey-dstkey)

### rename ($srcKey, $dstKey)

[](#rename-srckey-dstkey)

```
$src = "foo/bar";
$dst = "path/to/destination";

$storage->copy($src, $dst);
```

License
-------

[](#license)

Licensed under the MIT License.

Copyright (c) 2013 Yosuke Kumakura

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

###  Health Score

26

—

LowBetter than 43% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity14

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity50

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

Total

3

Last Release

4501d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/47afd1b8d692632cd02d8630a36844daaf9dc77befe5278c7e8452bf52f32921?d=identicon)[kumatch](/maintainers/kumatch)

---

Top Contributors

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

---

Tags

storage

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/kumatch-keystore/health.svg)

```
[![Health](https://phpackages.com/badges/kumatch-keystore/health.svg)](https://phpackages.com/packages/kumatch-keystore)
```

###  Alternatives

[league/flysystem

File storage abstraction for PHP

13.6k639.1M2.2k](/packages/league-flysystem)[league/flysystem-aws-s3-v3

AWS S3 filesystem adapter for Flysystem.

1.6k263.6M790](/packages/league-flysystem-aws-s3-v3)[google/cloud

Google Cloud Client Library

1.2k16.2M53](/packages/google-cloud)[qiniu/php-sdk

Qiniu Resource (Cloud) Storage SDK for PHP

8483.0M240](/packages/qiniu-php-sdk)[sylius/resource-bundle

Resource component for Sylius.

23410.2M173](/packages/sylius-resource-bundle)[microsoft/azure-storage-blob

This project provides a set of PHP client libraries that make it easy to access Microsoft Azure Storage Blob APIs.

5516.0M60](/packages/microsoft-azure-storage-blob)

PHPackages © 2026

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