@redotech/redo-api-schema 2.2.172 → 2.2.178
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/openapi.d.ts +79 -0
- package/lib/openapi.yaml +84 -0
- package/package.json +1 -1
package/lib/openapi.d.ts
CHANGED
|
@@ -53,6 +53,20 @@ export interface paths {
|
|
|
53
53
|
};
|
|
54
54
|
};
|
|
55
55
|
};
|
|
56
|
+
"/returns/{returnId}/process": {
|
|
57
|
+
/**
|
|
58
|
+
* Process return
|
|
59
|
+
* @description **BETA**: This endpoint is in beta and subject to change.
|
|
60
|
+
*
|
|
61
|
+
* Trigger processing of a return with specified products.
|
|
62
|
+
*/
|
|
63
|
+
post: operations["Return process"];
|
|
64
|
+
parameters: {
|
|
65
|
+
path: {
|
|
66
|
+
returnId: components["parameters"]["return-id.param"];
|
|
67
|
+
};
|
|
68
|
+
};
|
|
69
|
+
};
|
|
56
70
|
"/returns/{returnId}/status": {
|
|
57
71
|
/**
|
|
58
72
|
* Get return status
|
|
@@ -661,6 +675,11 @@ export interface components {
|
|
|
661
675
|
* @description Return identifier.
|
|
662
676
|
*/
|
|
663
677
|
id: string;
|
|
678
|
+
/**
|
|
679
|
+
* Internal Created By Name
|
|
680
|
+
* @description Name of the internal team member who created this return
|
|
681
|
+
*/
|
|
682
|
+
internalCreatedByName?: string;
|
|
664
683
|
/** @description Return items */
|
|
665
684
|
items: {
|
|
666
685
|
/** @description Customer's comment about the return */
|
|
@@ -1420,6 +1439,66 @@ export interface operations {
|
|
|
1420
1439
|
};
|
|
1421
1440
|
};
|
|
1422
1441
|
};
|
|
1442
|
+
/**
|
|
1443
|
+
* Process return
|
|
1444
|
+
* @description **BETA**: This endpoint is in beta and subject to change.
|
|
1445
|
+
*
|
|
1446
|
+
* Trigger processing of a return with specified products.
|
|
1447
|
+
*/
|
|
1448
|
+
"Return process": {
|
|
1449
|
+
parameters: {
|
|
1450
|
+
path: {
|
|
1451
|
+
returnId: components["parameters"]["return-id.param"];
|
|
1452
|
+
};
|
|
1453
|
+
};
|
|
1454
|
+
requestBody: {
|
|
1455
|
+
content: {
|
|
1456
|
+
"application/json": {
|
|
1457
|
+
/** @description Notes to send to customer. These can be rejection notes or processing notes. */
|
|
1458
|
+
customerNotes?: string;
|
|
1459
|
+
/** @description Whether to mark the return as reviewed before processing */
|
|
1460
|
+
markAsReviewed?: boolean;
|
|
1461
|
+
/** @description Array of products to process with their processing or rejection details */
|
|
1462
|
+
products: ({
|
|
1463
|
+
/**
|
|
1464
|
+
* @description Product ID
|
|
1465
|
+
* @example 64e4d5e837572a4813b73e41
|
|
1466
|
+
*/
|
|
1467
|
+
_id: string;
|
|
1468
|
+
processInput?: ({
|
|
1469
|
+
/** @description Adjustment amount. This will be the amount that is credited to the customer. */
|
|
1470
|
+
newMerchantAdjustment?: number | null;
|
|
1471
|
+
/** @description Whether to restock the item */
|
|
1472
|
+
restock?: boolean;
|
|
1473
|
+
}) | null;
|
|
1474
|
+
})[];
|
|
1475
|
+
};
|
|
1476
|
+
};
|
|
1477
|
+
};
|
|
1478
|
+
responses: {
|
|
1479
|
+
/** @description Processing request completed */
|
|
1480
|
+
200: {
|
|
1481
|
+
content: {
|
|
1482
|
+
"application/json": {
|
|
1483
|
+
/** @description Status message */
|
|
1484
|
+
message?: string;
|
|
1485
|
+
};
|
|
1486
|
+
};
|
|
1487
|
+
};
|
|
1488
|
+
/** @description Bad request (e.g., missing products array) */
|
|
1489
|
+
400: {
|
|
1490
|
+
content: {
|
|
1491
|
+
"application/problem+json": components["schemas"]["error.schema"];
|
|
1492
|
+
};
|
|
1493
|
+
};
|
|
1494
|
+
/** @description Error */
|
|
1495
|
+
default: {
|
|
1496
|
+
content: {
|
|
1497
|
+
"application/problem+json": components["schemas"]["error.schema"];
|
|
1498
|
+
};
|
|
1499
|
+
};
|
|
1500
|
+
};
|
|
1501
|
+
};
|
|
1423
1502
|
/**
|
|
1424
1503
|
* Get return status
|
|
1425
1504
|
* @description Get return status.
|
package/lib/openapi.yaml
CHANGED
|
@@ -657,6 +657,10 @@ components:
|
|
|
657
657
|
- 64df65d4c5a4ca3eff4b4e43
|
|
658
658
|
title: Identifier
|
|
659
659
|
type: string
|
|
660
|
+
internalCreatedByName:
|
|
661
|
+
description: Name of the internal team member who created this return
|
|
662
|
+
title: Internal Created By Name
|
|
663
|
+
type: string
|
|
660
664
|
items:
|
|
661
665
|
description: Return items
|
|
662
666
|
items:
|
|
@@ -1599,6 +1603,86 @@ paths:
|
|
|
1599
1603
|
tags:
|
|
1600
1604
|
- Returns
|
|
1601
1605
|
summary: Return comment
|
|
1606
|
+
/returns/{returnId}/process:
|
|
1607
|
+
description: Process return.
|
|
1608
|
+
parameters:
|
|
1609
|
+
- $ref: '#/components/parameters/return-id.param'
|
|
1610
|
+
post:
|
|
1611
|
+
description: |
|
|
1612
|
+
**BETA**: This endpoint is in beta and subject to change.
|
|
1613
|
+
|
|
1614
|
+
Trigger processing of a return with specified products.
|
|
1615
|
+
operationId: Return process
|
|
1616
|
+
requestBody:
|
|
1617
|
+
content:
|
|
1618
|
+
application/json:
|
|
1619
|
+
schema:
|
|
1620
|
+
properties:
|
|
1621
|
+
customerNotes:
|
|
1622
|
+
description: Notes to send to customer. These can be rejection notes or processing notes.
|
|
1623
|
+
type: string
|
|
1624
|
+
markAsReviewed:
|
|
1625
|
+
description: Whether to mark the return as reviewed before processing
|
|
1626
|
+
type: boolean
|
|
1627
|
+
products:
|
|
1628
|
+
description: Array of products to process with their processing or rejection details
|
|
1629
|
+
items:
|
|
1630
|
+
properties:
|
|
1631
|
+
_id:
|
|
1632
|
+
description: Product ID
|
|
1633
|
+
example: 64e4d5e837572a4813b73e41
|
|
1634
|
+
type: string
|
|
1635
|
+
processInput:
|
|
1636
|
+
nullable: true
|
|
1637
|
+
properties:
|
|
1638
|
+
newMerchantAdjustment:
|
|
1639
|
+
description: Adjustment amount. This will be the amount that is credited to the customer.
|
|
1640
|
+
nullable: true
|
|
1641
|
+
type: number
|
|
1642
|
+
restock:
|
|
1643
|
+
description: Whether to restock the item
|
|
1644
|
+
type: boolean
|
|
1645
|
+
type: object
|
|
1646
|
+
required:
|
|
1647
|
+
- _id
|
|
1648
|
+
type: object
|
|
1649
|
+
type: array
|
|
1650
|
+
required:
|
|
1651
|
+
- products
|
|
1652
|
+
type: object
|
|
1653
|
+
required: true
|
|
1654
|
+
responses:
|
|
1655
|
+
'200':
|
|
1656
|
+
content:
|
|
1657
|
+
application/json:
|
|
1658
|
+
schema:
|
|
1659
|
+
properties:
|
|
1660
|
+
message:
|
|
1661
|
+
description: Status message
|
|
1662
|
+
examples:
|
|
1663
|
+
- Processing triggered successfully
|
|
1664
|
+
- Successfully prepared some products to be processed
|
|
1665
|
+
type: string
|
|
1666
|
+
type: object
|
|
1667
|
+
description: Processing request completed
|
|
1668
|
+
'400':
|
|
1669
|
+
content:
|
|
1670
|
+
application/problem+json:
|
|
1671
|
+
schema:
|
|
1672
|
+
$ref: '#/components/schemas/error.schema'
|
|
1673
|
+
description: Bad request (e.g., missing products array)
|
|
1674
|
+
default:
|
|
1675
|
+
content:
|
|
1676
|
+
application/problem+json:
|
|
1677
|
+
schema:
|
|
1678
|
+
$ref: '#/components/schemas/error.schema'
|
|
1679
|
+
description: Error
|
|
1680
|
+
security:
|
|
1681
|
+
- Bearer: []
|
|
1682
|
+
summary: Process return
|
|
1683
|
+
tags:
|
|
1684
|
+
- Returns
|
|
1685
|
+
summary: Process return
|
|
1602
1686
|
/returns/{returnId}/status:
|
|
1603
1687
|
description: Return status.
|
|
1604
1688
|
get:
|
package/package.json
CHANGED