-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.openapi.php
More file actions
64 lines (55 loc) · 1.55 KB
/
.openapi.php
File metadata and controls
64 lines (55 loc) · 1.55 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
<?php
use Astral\Serialize\OpenApi\Storage\OpenAPI\ServersStorage;
return [
'doc_url' => 'http://127.0.0.1:8089',
// API Document Title
'title' => 'API Docs',
// Description of the API document
'description' => 'API Docs description.',
/**
* Global headers to be added to every request.
* Each header should include name, example, and description.
*
* Example:
* [
* 'name' => 'Authorization',
* 'example' => 'Bearer token',
* 'description' => 'Authentication token'
* ]
*/
'headers' => [],
/**
* Service base URLs (servers).
* You can define multiple environments like production, staging, etc.
*
* @type ServersStorage[] $service
*/
'service' => [
new ServersStorage('http://127.0.0.1', 'Default'),
],
/**
* Directories to exclude from scanning.
* These paths are relative to the project root directory.
*
* Default excluded directories:
* - /vendor
* - /tests
* - /migrations
* Example:
* ['/sdk', '/app']
*
* You can override or extend this list in your config file.
*/
'exclude_dirs' => [],
/**
* Response Data Structure Definition
*
* Defines the basic structure of API responses, including status code, return message, and data body
*
*/
'response' => [
'code' => ['description' =>'code', 'example'=> 200],
'message' => ['description' =>'message', 'example'=> 'success'],
'data' => 'T',
]
];