der-spiegel / ww-elvis-client
PHP client for the WoodWing Assets (formerly: Elvis DAM) system https://www.woodwing.com/en/products/woodwing-assets
Requires
- php: >=8.4 <8.5
- ext-ctype: *
- ext-iconv: *
- ext-json: *
- guzzlehttp/guzzle: >=6.3 <8.0
- phpunit/php-timer: >=6.0 <8.0
- twig/twig: ^3.4
Requires (Dev)
- monolog/monolog: >=3.2 <4.0
- phpunit/phpunit: ^11
- dev-master
- v9.0.0
- v8.1.3
- v8.1.2
- v8.1.1
- v8.1.0
- v8.0.0
- v7.1.0
- v7.0.0
- v6.3.1
- v6.3.0
- v6.2.1
- v6.2.0
- v6.1.0
- v6.0.0
- v5.1.1
- v5.1.0
- v5.0.4
- v5.0.3
- v5.0.2
- v5.0.1
- v5.0.0
- v4.0.1
- v4.0.0
- v3.11.1
- v3.11.0
- v3.10.0
- v3.9.0
- v3.8.0
- v3.7.0
- v3.6.2
- v3.6.1
- v3.6.0
- v3.5.1
- v3.5.0
- v3.4.0
- v3.3.0
- v3.2.0
- v3.1.0
- v3.0.0
- v2.4.0
- v2.3.0
- v2.2.1
- v2.2.0
- v2.1.0
- v2.0.0
- v1.0.3
- v1.0.2
- v1.0.1
- v1.0.0
- dev-develop
This package is auto-updated.
Last update: 2025-02-19 16:10:35 UTC
README
WoodWing Assets is a DAM (Digital Asset Management) system. This PHP client library uses its REST API.
This is not an official library supplied by the WoodWing vendor. It has been developed during the WoodWing Assets implementation at the German SPIEGEL Gruppe, 2019-2020.
Functionality
- API login
- Search:
SearchRequest
- Browse:
BrowseRequest
- Create:
CreateRequest
- Update:
UpdateRequest
- Update bulk:
UpdateBulkRequest
- Copy asset:
CopyAssetRequest
- Move / rename:
MoveRequest
- Remove:
RemoveRequest
- Create relation:
CreateRelationRequest
- Create folder:
CreateFolderRequest
- Get folder metadata:
GetFolderRequest
- Update folder metadata:
UpdateFolderRequest
Installation
Use Composer to add this library your project’s composer.json file:
$ composer require der-spiegel/ww-assets-client
Quick test
Here’s how to do a quick test, starting from scratch with a new project (Docker required):
Install dependencies using Composer
$ mkdir MyExample && cd MyExample
$ docker run --rm --interactive --tty \
--volume $PWD:/app \
--volume ${COMPOSER_HOME:-$HOME/.composer}:/tmp \
composer/composer require der-spiegel/ww-assets-client monolog/monolog
Copy and edit the example script
$ cp vendor/der-spiegel/ww-assets-client/UsageExample.php MyExample.php
Edit your copy, setting the correct Assets URL, username (API user preferred) and password in this section:
$assetsConfig = AssetsConfig::create( 'https://assets.example.com/', // Assets URL (without app/ or services/ postfix) 'username', // Assets user name (API user preferred) 'password' // That user's password );
The example script performs a simple search across all assets (visible for that user) and returns the first 50 asset IDs – you can leave it as is for a first test:
$assetsClient = new AssetsClient($assetsConfig, $logger); // Create client $request = new SearchRequest($assetsClient, // Create search request q: '', // Assets query metadataToReturn: [''] // Metadata fields to return ); $response = $request(); // Perform search foreach ($response->hits as $assetResponse) { // Loop through results echo $assetResponse->id . "\n"; // Access asset metadata }
Then run your copy
$ docker run -it --rm --name assets-client-example \
--volume "$PWD":/usr/src/myapp --workdir /usr/src/myapp \
php:cli php MyExample.php
Development
See Running tests for instructions on how to run unit and integration tests.
To regenerate the documentation in docs/_build/html from the source files, run Sphinx:
$ docker run --rm --volume "$PWD":/usr/src/myapp --workdir /usr/src/myapp/docs sphinxdoc/sphinx:5.3.0 make html
Authors
License
This library is licensed under the MIT License - see the LICENSE
file for details.