-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #18 from AmrAhmedFekry/master
Add auto generated postman and markdown files
- Loading branch information
Showing
7 changed files
with
585 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,67 @@ | ||
# moduleName API DOCS | ||
|
||
# Base URL | ||
BaseUrl | ||
|
||
# Headers | ||
|
||
Authorization: key your token | ||
|
||
Accept : application/json | ||
|
||
# API | ||
|
||
| Route | Request Method | Parameters | Response | | ||
| ----------- | ----------- |----------- |---------- | | ||
| /api/admin/routeName | POST | [Create Parmaters](#Create)|[Response](#Response)| | ||
| /api/admin/routeName | GET |-| [Response](#Response) | | ||
|/api/admin/routeName/{id} | GET | - | [Response](#Response) | | ||
|/api/admin/routeName/{id} |PUT | [Update Parmaters](#Update)|[Response](#Response) | | ||
|/api/admin/routeName/{id} |DELETE | -|[Response](#Response)| | ||
|/api/routeName |GET |-| [Response](#Response)| | ||
|/api/routeName/{id} |GET |-|[Response](#Response)| | ||
|
||
|
||
# <a name="Create"> </a> Create new moduleName | ||
|
||
```json | ||
data | ||
``` | ||
|
||
# <a name="Update"> </a> Update moduleName | ||
|
||
```json | ||
data | ||
``` | ||
# <a name="Response"> </a> Responses | ||
|
||
## Unauthorized error | ||
|
||
__*Response code : 401*__ | ||
```json | ||
{ | ||
"message" : "Unauthenticated" | ||
} | ||
``` | ||
|
||
## Validation error | ||
__*Response code : 422*__ | ||
|
||
```json | ||
{ | ||
"errors" { | ||
"Key" : "Error message" | ||
} | ||
} | ||
``` | ||
## Success | ||
__*Response code : 200*__ | ||
```json | ||
{ | ||
"records" [ | ||
{ | ||
|
||
}, | ||
] | ||
} | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,227 @@ | ||
{ | ||
"info": { | ||
"_postman_id": "0402fe17-e481-4c12-a34e-569e61795aba", | ||
"name": "{moduleName} Postman", | ||
"schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json" | ||
}, | ||
"item": [ | ||
{ | ||
"name": "Create {moduleName} ", | ||
"request": { | ||
"method": "POST", | ||
"header": [ | ||
{ | ||
"key": "Content-Type", | ||
"name": "Content-Type", | ||
"value": "application/x-www-form-urlencoded", | ||
"type": "text" | ||
}, | ||
{ | ||
"key": "Authorization", | ||
"value": "Bearer Token", | ||
"type": "text" | ||
} | ||
], | ||
"body": { | ||
"mode": "formdata", | ||
"formdata": "{formData}" | ||
}, | ||
"url": { | ||
"raw": "{baseUrl}/api/admin/{routeUri}", | ||
"protocol":"{protocol}", | ||
"host":"{host}", | ||
"path": [ | ||
"api", | ||
"admin" | ||
] | ||
} | ||
}, | ||
"response": [] | ||
}, | ||
{ | ||
"name": "Update {moduleName}", | ||
"request": { | ||
"method": "PUT", | ||
"header": [ | ||
{ | ||
"key": "Content-Type", | ||
"name": "Content-Type", | ||
"value": "application/x-www-form-urlencoded", | ||
"type": "text" | ||
}, | ||
{ | ||
"key": "Authorization", | ||
"type": "text", | ||
"value": "Bearer Token" | ||
} | ||
], | ||
"body": { | ||
"mode": "urlencoded", | ||
"urlencoded": "{formData}" | ||
}, | ||
"url": { | ||
"raw": "{baseUrl}/api/admin/{routeUri}/{id}", | ||
"protocol":"{protocol}", | ||
"host":"{host}", | ||
"path": [ | ||
"api", | ||
"admin", | ||
"{id}" | ||
] | ||
} | ||
}, | ||
"response": [] | ||
}, | ||
{ | ||
"name": "Listing of {moduleName}", | ||
"protocolProfileBehavior": { | ||
"disableBodyPruning": true | ||
}, | ||
"request": { | ||
"method": "GET", | ||
"header": [ | ||
{ | ||
"key": "Content-Type", | ||
"name": "Content-Type", | ||
"value": "application/x-www-form-urlencoded", | ||
"type": "text" | ||
}, | ||
{ | ||
"key": "Authorization", | ||
"value": "Bearer Token", | ||
"type": "text" | ||
} | ||
], | ||
"body": { | ||
"mode": "formdata", | ||
"formdata": [] | ||
}, | ||
"url": { | ||
"raw": "{baseUrl}/api/admin/{moduleName}", | ||
"protocol":"{protocol}", | ||
"host":"{host}", | ||
"path": [ | ||
"api", | ||
"admin" | ||
] | ||
} | ||
}, | ||
"response": [] | ||
}, | ||
{ | ||
"name": "Get single of {moduleName} ", | ||
"request": { | ||
"method": "GET", | ||
"header": [ | ||
{ | ||
"key": "Authorization", | ||
"value": "Bearer Token", | ||
"type": "text" | ||
}, | ||
{ | ||
"key": "Content-Type", | ||
"value": "application/x-www-form-urlencoded", | ||
"type": "text" | ||
} | ||
], | ||
"url": { | ||
"raw": "{baseUrl}/api/admin/{routeUri}/{id}", | ||
"protocol":"{protocol}", | ||
"host":"{host}", | ||
"path": [ | ||
"api", | ||
"admin", | ||
"{id}" | ||
] | ||
} | ||
}, | ||
"response": [] | ||
}, | ||
{ | ||
"name": "Delete {moduleName} record", | ||
"request": { | ||
"method": "DELETE", | ||
"header": [ | ||
{ | ||
"key": "Authorization", | ||
"value": "Bearer Token", | ||
"type": "text" | ||
}, | ||
{ | ||
"key": "Content-Type", | ||
"value": "application/x-www-form-urlencoded", | ||
"type": "text" | ||
} | ||
], | ||
"url": { | ||
"raw": "{baseUrl}/api/admin/{routeUri}/{id}", | ||
"protocol":"{protocol}", | ||
"host":"{host}", | ||
"path": [ | ||
"api", | ||
"admin", | ||
"{id}" | ||
] | ||
} | ||
}, | ||
"response": [] | ||
}, | ||
{ | ||
"name": "Show single record of {moduleName} in front", | ||
"request": { | ||
"method": "GET", | ||
"header": [ | ||
{ | ||
"key": "Content-Type", | ||
"name": "Content-Type", | ||
"value": "application/x-www-form-urlencoded", | ||
"type": "text" | ||
}, | ||
{ | ||
"key": "Authorization", | ||
"value": "Bearer Token", | ||
"type": "text" | ||
} | ||
], | ||
"url": { | ||
"raw": "{baseUrl}/api/{routeUri}/{id}", | ||
"protocol":"{protocol}", | ||
"host":"{host}", | ||
"path": [ | ||
"api", | ||
"{id}" | ||
] | ||
} | ||
}, | ||
"response": [] | ||
}, | ||
{ | ||
"name": "Show list {moduleName} in front", | ||
"request": { | ||
"method": "GET", | ||
"header": [ | ||
{ | ||
"key": "Content-Type", | ||
"name": "Content-Type", | ||
"value": "application/x-www-form-urlencoded", | ||
"type": "text" | ||
}, | ||
{ | ||
"key": "Authorization", | ||
"value": "Bearer Token", | ||
"type": "text" | ||
} | ||
], | ||
"url": { | ||
"raw": "{baseUrl}/api/{routeUri}", | ||
"protocol":"{protocol}", | ||
"host":"{host}", | ||
"path": [ | ||
"api" | ||
] | ||
} | ||
}, | ||
"response": [] | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.