Skip to content

Commit 02ad387

Browse files
committed
add docs for checkout cod
1 parent 0141ddd commit 02ad387

4 files changed

Lines changed: 77 additions & 3 deletions

File tree

src/Config/CheckoutCod.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,12 +17,12 @@
1717
*
1818
* The version of the package
1919
*/
20-
'version' => '1.1.3',
20+
'version' => '1.1.4',
2121
/**
2222
*
2323
* The version number of the package
2424
*/
25-
'versionNum' => '113',
25+
'versionNum' => '114',
2626

2727
/**
2828
*

src/Docs/V1/CheckoutCod/Controller/Controller.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33

44
/**
55
* @OA\Info(
6-
* version="1.1.0",
6+
* version="1.1.4",
77
* title="NexaMerchant CheckoutCod Rest API Documentation",
88
* description="NexaMerchant CheckoutCod Rest API Documentation",
99
*
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
<?php
2+
namespace NexaMerchant\CheckoutCod\Docs\V1\CheckoutCod\Controller\Orders;
3+
4+
class OrdersController {
5+
/**
6+
* @OA\Post(
7+
* path="/orders/create",
8+
* summary="Create a new order",
9+
* tags={"Orders"},
10+
* @OA\RequestBody(
11+
* required=true,
12+
* @OA\JsonContent(ref="#/components/schemas/Order")
13+
* ),
14+
* @OA\Response(
15+
* response=201,
16+
* description="Order created successfully",
17+
* @OA\JsonContent(ref="#/components/schemas/Order")
18+
* ),
19+
* @OA\Response(
20+
* response=400,
21+
* description="Invalid input",
22+
* @OA\JsonContent(ref="#/components/schemas/Error")
23+
* )
24+
* )
25+
*/
26+
public function create(){}
27+
}
Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
<?php
2+
namespace NexaMerchant\CheckoutCod\Docs\V1\CheckoutCod\Models;
3+
4+
/**
5+
* @OA\Schema(
6+
* title="Order",
7+
* description="Order model",
8+
* )
9+
*/
10+
class Order {
11+
12+
/**
13+
* @OA\Property(
14+
* title="Cart ID",
15+
* description="Cart ID",
16+
* format="int64",
17+
* example=1
18+
* )
19+
*
20+
* @var int
21+
*/
22+
private $cart_id;
23+
24+
/**
25+
* @OA\Property(
26+
* title="Customer ID",
27+
* description="Customer ID",
28+
* format="int64",
29+
* example=1
30+
* )
31+
*
32+
* @var int
33+
*/
34+
private $customer_id;
35+
36+
/**
37+
* @OA\Property(
38+
* title="Return Insurance",
39+
* description="Return Insurance",
40+
* format="int64",
41+
* example=1
42+
* )
43+
*
44+
* @var int
45+
*/
46+
private $return_insurance;
47+
}

0 commit comments

Comments
 (0)