1
- ZF Apigility Documentation
1
+ Laminas API Tools Documentation
2
2
==========================
3
3
4
- [ ![ Build Status] ( https://travis-ci.org/zfcampus/zf-apigility -documentation.png )] ( https://travis-ci.org/zfcampus/zf-apigility -documentation )
4
+ [ ![ Build Status] ( https://travis-ci.org/laminas-api-tools/api-tools -documentation.png )] ( https://travis-ci.org/laminas-api-tools/api-tools -documentation )
5
5
6
6
Introduction
7
7
------------
8
8
9
- This ZF2 module can be used with conjunction with Apigility in order to:
9
+ This Laminas module can be used with conjunction with Laminas API Tools in order to:
10
10
11
11
- provide an object model of all captured documentation information, including:
12
12
- All APIs available.
@@ -20,7 +20,7 @@ This ZF2 module can be used with conjunction with Apigility in order to:
20
20
- end-users may configure alternate/additional formats via content-negotiation.
21
21
22
22
This module accomplishes all the above use cases by providing an endpoint to connect to
23
- (` /apigility /documentation[/:api[-v:version][/:service]] ` ), using content-negotiation to provide
23
+ (` /api-tools /documentation[/:api[-v:version][/:service]] ` ), using content-negotiation to provide
24
24
both HTML and JSON representations.
25
25
26
26
Installation
@@ -29,14 +29,14 @@ Installation
29
29
Run the following ` composer ` command:
30
30
31
31
``` console
32
- $ composer require " zfcampus/zf-apigility -documentation:~1.0-dev"
32
+ $ composer require " laminas-api-tools/api-tools -documentation:~1.0-dev"
33
33
```
34
34
35
35
Alternately, manually add the following to your ` composer.json ` , in the ` require ` section:
36
36
37
37
``` javascript
38
38
" require" : {
39
- " zfcampus/zf-apigility -documentation" : " ~1.0-dev"
39
+ " laminas-api-tools/api-tools -documentation" : " ~1.0-dev"
40
40
}
41
41
```
42
42
@@ -50,7 +50,7 @@ return array(
50
50
/* ... */
51
51
'modules' => array(
52
52
/* ... */
53
- 'ZF\Apigility \Documentation',
53
+ 'Laminas\ApiTools \Documentation',
54
54
),
55
55
/* ... */
56
56
);
@@ -65,23 +65,23 @@ This module does not utilize any user configuration.
65
65
66
66
### System Configuration
67
67
68
- The following configuration is defined by the module to ensure operation within a Zend Framework 2
68
+ The following configuration is defined by the module to ensure operation within a Laminas
69
69
MVC application.
70
70
71
71
``` php
72
72
'router' => array(
73
73
'routes' => array(
74
- 'zf-apigility ' => array(
74
+ 'api-tools ' => array(
75
75
'child_routes' => array(
76
76
'documentation' => array(
77
- 'type' => 'Zend \Mvc\Router\Http\Segment',
77
+ 'type' => 'Laminas \Mvc\Router\Http\Segment',
78
78
'options' => array(
79
79
'route' => '/documentation[/:api[-v:version][/:service]]',
80
80
'constraints' => array(
81
81
'api' => '[a-zA-Z][a-zA-Z0-9_]+',
82
82
),
83
83
'defaults' => array(
84
- 'controller' => 'ZF\Apigility \Documentation\Controller',
84
+ 'controller' => 'Laminas\ApiTools \Documentation\Controller',
85
85
'action' => 'show',
86
86
),
87
87
),
@@ -92,25 +92,25 @@ MVC application.
92
92
),
93
93
'controllers' => array(
94
94
'factories' => array(
95
- 'ZF\Apigility \Documentation\Controller' => 'ZF\Apigility \Documentation\ControllerFactory',
95
+ 'Laminas\ApiTools \Documentation\Controller' => 'Laminas\ApiTools \Documentation\ControllerFactory',
96
96
),
97
97
),
98
- 'zf -content-negotiation' => array(
98
+ 'api-tools -content-negotiation' => array(
99
99
'controllers' => array(
100
- 'ZF\Apigility \Documentation\Controller' => 'Documentation',
100
+ 'Laminas\ApiTools \Documentation\Controller' => 'Documentation',
101
101
),
102
102
'accept_whitelist' => array(
103
- 'ZF\Apigility \Documentation\Controller' => array(
103
+ 'Laminas\ApiTools \Documentation\Controller' => array(
104
104
0 => 'application/vnd.swagger+json',
105
105
1 => 'application/json',
106
106
),
107
107
),
108
108
'selectors' => array(
109
109
'Documentation' => array(
110
- 'ZF\Apigility \Documentation\JsonModel' => array(
110
+ 'Laminas\ApiTools \Documentation\JsonModel' => array(
111
111
'application/json',
112
112
),
113
- 'Zend \View\Model\ViewModel' => array(
113
+ 'Laminas \View\Model\ViewModel' => array(
114
114
'text/html',
115
115
'application/xhtml+xml',
116
116
),
@@ -119,10 +119,10 @@ MVC application.
119
119
),
120
120
'view_helpers' => array(
121
121
'invokables' => array(
122
- 'agacceptheaders' => 'ZF\Apigility \Documentation\View\AgAcceptHeaders',
123
- 'agcontenttypeheaders' => 'ZF\Apigility \Documentation\View\AgContentTypeHeaders',
124
- 'agservicepath' => 'ZF\Apigility \Documentation\View\AgServicePath',
125
- 'agstatuscodes' => 'ZF\Apigility \Documentation\View\AgStatusCodes',
122
+ 'agacceptheaders' => 'Laminas\ApiTools \Documentation\View\AgAcceptHeaders',
123
+ 'agcontenttypeheaders' => 'Laminas\ApiTools \Documentation\View\AgContentTypeHeaders',
124
+ 'agservicepath' => 'Laminas\ApiTools \Documentation\View\AgServicePath',
125
+ 'agstatuscodes' => 'Laminas\ApiTools \Documentation\View\AgStatusCodes',
126
126
),
127
127
),
128
128
'view_manager' => array(
@@ -132,37 +132,37 @@ MVC application.
132
132
),
133
133
```
134
134
135
- ZF2 Events
135
+ Laminas Events
136
136
==========
137
137
138
138
This module has no events or listeners.
139
139
140
- ZF2 Services
140
+ Laminas Services
141
141
============
142
142
143
143
### View Helpers
144
144
145
145
The following list of view helpers assist in making API documentation models presentable in view
146
146
scripts.
147
147
148
- - ` ZF\Apigility \Documentation\View\AgAcceptHeaders` (a.k.a ` agAcceptHeaders ` ) for making a
148
+ - ` Laminas\ApiTools \Documentation\View\AgAcceptHeaders` (a.k.a ` agAcceptHeaders ` ) for making a
149
149
list of ` Accept ` headers, escaped for HTML.
150
- - ` ZF\Apigility \Documentation\View\AgContentTypeHeaders` (a.k.a ` agContentTypeHeaders ` ) for
150
+ - ` Laminas\ApiTools \Documentation\View\AgContentTypeHeaders` (a.k.a ` agContentTypeHeaders ` ) for
151
151
making a list of ` Content-Type ` headers, escaped for HTML.
152
- - ` ZF\Apigility \Documentation\View\AgServicePath` (a.k.a ` agServicePath ` ) for making an HTML
152
+ - ` Laminas\ApiTools \Documentation\View\AgServicePath` (a.k.a ` agServicePath ` ) for making an HTML
153
153
view representation of the route configuration of a service path.
154
- - ` ZF\Apigility \Documentation\View\AgStatusCodes` (a.k.a ` agStatusCodes ` ) for making an
154
+ - ` Laminas\ApiTools \Documentation\View\AgStatusCodes` (a.k.a ` agStatusCodes ` ) for making an
155
155
escaped list of status codes and their messages.
156
156
157
157
### Factories
158
158
159
- #### ` ZF\Apigility \Documentation\ApiFactory`
159
+ #### ` Laminas\ApiTools \Documentation\ApiFactory`
160
160
161
161
The ` ApiFactory ` service is capable of producing an object-graph representation of the desired
162
162
API documentation that is requested. This object-graph will be composed of the following types:
163
163
164
- - ` ZF\Apigility \Documentation\Api` : the root node of an API.
165
- - ` ZF\Apigility \Documentation\Services` : an array of services in the API (a service can be one
164
+ - ` Laminas\ApiTools \Documentation\Api` : the root node of an API.
165
+ - ` Laminas\ApiTools \Documentation\Services` : an array of services in the API (a service can be one
166
166
of a REST or RPC style service).
167
- - ` ZF\Apigility \Documentation\Operations` : an array of operations in the service.
168
- - ` ZF\Apigility \Documentation\Fields` : an array of fields for a service.
167
+ - ` Laminas\ApiTools \Documentation\Operations` : an array of operations in the service.
168
+ - ` Laminas\ApiTools \Documentation\Fields` : an array of fields for a service.
0 commit comments