PHPackages                             champs-libres/wopi-lib - 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. champs-libres/wopi-lib

ActiveLibrary[API Development](/categories/api)

champs-libres/wopi-lib
======================

A standard and framework agnostic PHP library to facilitate the implementation of the WOPI protocol.

v1.0.0(5mo ago)1510.0k↓40.9%1[2 PRs](https://github.com/Champs-Libres/wopi-lib/pulls)2MITPHPPHP &gt;= 7.4CI passing

Since Jun 20Pushed 2mo ago2 watchersCompare

[ Source](https://github.com/Champs-Libres/wopi-lib)[ Packagist](https://packagist.org/packages/champs-libres/wopi-lib)[ Docs](http://github.com/champs-libres/wopi-lib)[ RSS](/packages/champs-libres-wopi-lib/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (1)Dependencies (14)Versions (6)Used By (2)

[![Latest Stable Version](https://camo.githubusercontent.com/05632af31cf8307e64a8f4ccdbe76a4402786590a144255869bea36226247cf8/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6368616d70732d6c69627265732f776f70692d6c69622e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/champs-libres/wopi-lib)[![GitHub stars](https://camo.githubusercontent.com/408b1681f7fd351e2f2462f0b6a1c7b37b502b490369af2d17daba4f09700baf/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f73746172732f6368616d70732d6c69627265732f776f70692d6c69622e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/champs-libres/wopi-lib)[![Total Downloads](https://camo.githubusercontent.com/b3ce1e35e34dfbbcc4f08116bea6e931c7bafe65baaaa7ba1dcb575feb50f535/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f6368616d70732d6c69627265732f776f70692d6c69622e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/champs-libres/wopi-lib)[![GitHub Workflow Status](https://camo.githubusercontent.com/5600a5adebc70bd03d1b4b51f5bb0868a5501e44210005ecef47882abf3d2f68/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f776f726b666c6f772f7374617475732f6368616d70732d6c69627265732f776f70692d6c69622f556e697425323074657374733f7374796c653d666c61742d737175617265)](https://github.com/champs-libres/wopi-lib/actions)[![Scrutinizer code quality](https://camo.githubusercontent.com/eac9d233a172737fdf5b55649b996fb3f06d6dfe1e5e7cba38c37d98a9a8c48d/68747470733a2f2f696d672e736869656c64732e696f2f7363727574696e697a65722f7175616c6974792f672f6368616d70732d6c69627265732f776f70692d6c69622f6d61737465722e7376673f7374796c653d666c61742d737175617265)](https://scrutinizer-ci.com/g/champs-libres/wopi-lib/?branch=master)[![Type Coverage](https://camo.githubusercontent.com/f82003b8913fd678e64a3e3dbfccf90f1e62245410d9459aa53b9c811cf33dc5/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f64796e616d69632f6a736f6e3f7374796c653d666c61742d73717561726526636f6c6f723d636f6c6f72266c6162656c3d54797065253230636f7665726167652671756572793d6d6573736167652675726c3d687474707325334125324625324673686570686572642e6465762532466769746875622532466368616d70732d6c6962726573253246776f70692d6c6962253246636f766572616765)](https://shepherd.dev/github/champs-libres/wopi-lib)[![Code Coverage](https://camo.githubusercontent.com/be1eed353e53ddb5c317d875fe5967fff4d3877e104d7cf66ebccfe26b0bddb0/68747470733a2f2f696d672e736869656c64732e696f2f7363727574696e697a65722f636f7665726167652f672f6368616d70732d6c69627265732f776f70692d6c69622f6d61737465722e7376673f7374796c653d666c61742d737175617265)](https://scrutinizer-ci.com/g/champs-libres/wopi-lib/?branch=master)[![License](https://camo.githubusercontent.com/3e3b72beea9f9f613032d6839a0a7fa8f4207ce55c2201c8e4b4d4055fd188c0/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f6c2f6368616d70732d6c69627265732f776f70692d6c69622e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/champs-libres/wopi-lib)

WOPI Lib
========

[](#wopi-lib)

A standard and framework agnostic PHP library to facilitate the implementation of the WOPI protocol.

Description
-----------

[](#description)

The **W**eb Application **O**pen **P**latform **I**nterface (WOPI) protocol let you integrate Office for the web with your application. The WOPI protocol enables Office for the web to access and change files that are stored in your service.

Office for the web platforms:

- [Collabora Office](https://www.collaboraoffice.com/)
- [OnlyOffice](https://www.onlyoffice.com/)
- [Office 365](https://www.office.com/)

Installation
------------

[](#installation)

`composer require champs-libres/wopi-lib`

Usage
-----

[](#usage)

There are many different ways to store documents in an application. Therefore, this library does not provide a specific implementation of the WOPI protocol described through [the WOPI interface](https://github.com/Champs-Libres/wopi-lib/blob/master/src/Contract/Service/WopiInterface.php).

Thus, this library mostly provides abstractions and few service implementations.

It provides:

- A [Wopi interface](https://github.com/Champs-Libres/wopi-lib/blob/master/src/Contract/Service/WopiInterface.php) describing the WOPI protocol
- A [Discovery interface](https://github.com/Champs-Libres/wopi-lib/blob/master/src/Contract/Service/Discovery/DiscoveryInterface.php) and its implementation
- A [DocumentManager interface](https://github.com/Champs-Libres/wopi-lib/blob/master/src/Contract/Service/DocumentManagerInterface.php) describing a document manager
- A [DocumentLockManager interface](https://github.com/Champs-Libres/wopi-lib/blob/master/src/Contract/Service/DocumentLockManagerInterface.php) describing a document lock manager
- A [ProofValidator interface](https://github.com/Champs-Libres/wopi-lib/blob/master/src/Contract/Service/ProofValidatorInterface.php) its implementation
- A [DotNetTimeConverter interface](https://github.com/Champs-Libres/wopi-lib/blob/master/src/Contract/Service/Utils/DotNetTimeConverterInterface.php) and its implementation

In order to be foster interoperability and be used across many different frameworks, this library uses PSR7, PSR17, PSR18 and PSR12 conventions from the [PHP-FIG](https://www.php-fig.org/).

### Symfony integration

[](#symfony-integration)

There is already an implementation of the library in Symfony through the [champs-libres/wopi-bundle](https://github.com/champs-libres/wopi-lib)package.

Documentation
-------------

[](#documentation)

-

Code quality, tests, benchmarks
-------------------------------

[](#code-quality-tests-benchmarks)

Every time changes are introduced into the library, [Github](https://github.com/champs-libres/wopi-lib/actions) runs the tests.

The library has tests written with [PHPSpec](http://www.phpspec.net/). Feel free to check them out in the `spec` directory. Run `composer phpspec` to trigger the tests.

Before each commit, some inspections are executed with [GrumPHP](https://github.com/phpro/grumphp); run `composer grumphp` to check manually.

The quality of the tests is tested with [Infection](https://github.com/infection/infection) a PHP Mutation testing framework, run `composer infection` to try it.

Static analyzers are also controlling the code. [PHPStan](https://github.com/phpstan/phpstan) and [PSalm](https://github.com/vimeo/psalm) are enabled to their maximum level.

Contributing
------------

[](#contributing)

Feel free to contribute to this project by submitting pull requests on Github.

Changelog
---------

[](#changelog)

See [CHANGELOG.md](https://github.com/champs-libres/wopi-lib/blob/master/CHANGELOG.md) for a changelog based on [git commits](https://github.com/champs-libres/wopi-lib/commits/master).

For more detailed changelogs, please check [the release changelogs](https://github.com/champs-libres/wopi-lib/releases).

###  Health Score

48

—

FairBetter than 95% of packages

Maintenance81

Actively maintained with recent releases

Popularity33

Limited adoption so far

Community18

Small or concentrated contributor base

Maturity51

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 59.8% 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

Unknown

Total

1

Last Release

159d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/0a70a668b9796ac8bdfc4bc23e86d9d0e37e843d96b3cc80d4174558ef2577c8?d=identicon)[julienfastre](/maintainers/julienfastre)

---

Top Contributors

[![drupol](https://avatars.githubusercontent.com/u/252042?v=4)](https://github.com/drupol "drupol (55 commits)")[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (20 commits)")[![julienfastre](https://avatars.githubusercontent.com/u/345600?v=4)](https://github.com/julienfastre "julienfastre (14 commits)")[![chancegarcia](https://avatars.githubusercontent.com/u/348263?v=4)](https://github.com/chancegarcia "chancegarcia (2 commits)")[![LenaertsJ](https://avatars.githubusercontent.com/u/59102062?v=4)](https://github.com/LenaertsJ "LenaertsJ (1 commits)")

---

Tags

wopiwopi

### Embed Badge

![Health badge](/badges/champs-libres-wopi-lib/health.svg)

```
[![Health](https://phpackages.com/badges/champs-libres-wopi-lib/health.svg)](https://phpackages.com/packages/champs-libres-wopi-lib)
```

###  Alternatives

[openai-php/client

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

5.8k22.6M232](/packages/openai-php-client)[opensearch-project/opensearch-php

PHP Client for OpenSearch

15224.3M65](/packages/opensearch-project-opensearch-php)[getbrevo/brevo-php

Official Brevo provided RESTFul API V3 php library

963.1M35](/packages/getbrevo-brevo-php)[swisnl/json-api-client

A PHP package for mapping remote JSON:API resources to Eloquent like models and collections.

211473.2k12](/packages/swisnl-json-api-client)[phpro/http-tools

HTTP tools for developing more consistent HTTP implementations.

28137.8k](/packages/phpro-http-tools)[n1ebieski/ksef-php-client

PHP API client that allows you to interact with the API Krajowego Systemu e-Faktur

7228.4k](/packages/n1ebieski-ksef-php-client)

PHPackages © 2026

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