akrabat/apigility-xml
Composer 安装命令:
composer require akrabat/apigility-xml
包简介
Apigility module providing XML content-negotiation features
README 文档
README
This is an Apigility module to provide XML content-negotiation features. It allows for the rendering of payloads in XML and HAL+XML formats. It also supports ingesting HTTP bodies that are in XML format if the content-type is application/xml
The response type is based on Accept header:
application/xml(orapplication/*+xml) renders content in XMLapplication/hal+json(orapplication/*+json) renders content in HalJson.
Installation
-
Install the module using composer:
$ composer require akrabat/apigility-xml -
Add
Akrabat\ApigilityXmltomodules.config.php:return [ ..., 'Akrabat\ApigilityXml', .... ] -
In the Apigility admin, select your API and change Content Negotiation Selector to HalJsonXML
-
Add
application/xmlto Accept whitelist and Content-Type whitelist. Add other headers if needed. -
Save configuration
Credits
This module is a fork of https://github.com/diegograssato/apigility-xml-negotiation which appears to be a fork of https://github.com/zpetr/apigility-xmlnegotiation which was inspired by the https://github.com/markushausammann's ApigilityXml.
Thanks to everyone who came before me!
统计信息
- 总下载量: 106
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 3
- 点击次数: 4
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2018-02-21