der-spiegel/ww-elvis-client
Composer 安装命令:
composer require der-spiegel/ww-elvis-client
包简介
PHP client for the WoodWing Assets (formerly: Elvis DAM) system https://www.woodwing.com/en/products/woodwing-assets
README 文档
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.
der-spiegel/ww-elvis-client 适用场景与选型建议
der-spiegel/ww-elvis-client 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 373 次下载、GitHub Stars 达 5, 最近一次更新时间为 2020 年 04 月 27 日, 在 PHP 生态内属于活跃度较高的组件。
我们在过去多个企业项目中使用过 der-spiegel/ww-elvis-client 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。
基于 der-spiegel/ww-elvis-client 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。
线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。
承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。
统计信息
- 总下载量: 373
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 5
- 点击次数: 6
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2020-04-27