-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: contest types implemented issue #10
- Loading branch information
Showing
2 changed files
with
72 additions
and
0 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,32 @@ | ||
declare module 'aifi' { | ||
namespace Aifi { | ||
namespace Customer { | ||
interface ContestCreateParams { | ||
/** | ||
* The order id to be contested | ||
*/ | ||
orderId: string; | ||
|
||
/** | ||
* The customer's email address. | ||
*/ | ||
message: string; | ||
|
||
/** | ||
* Items array | ||
*/ | ||
items: Aifi.Model.ContestItem[]; | ||
} | ||
|
||
class ContestsResource { | ||
/** | ||
* Retrieves an auth token. | ||
*/ | ||
create( | ||
params: ContestCreateParams, | ||
options?: RequestOptions | ||
): Promise<Aifi.Response<Aifi.Model.ContestItem[]>>; | ||
} | ||
} | ||
} | ||
} |
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,40 @@ | ||
declare module 'aifi' { | ||
namespace Aifi { | ||
namespace Model { | ||
/** | ||
* The contest object. | ||
*/ | ||
interface ContestItem { | ||
/** | ||
* TODO: What is rin, clarify?? | ||
*/ | ||
rin?: string; | ||
|
||
/** | ||
* Unique identifier for the product. | ||
*/ | ||
productId: string; | ||
|
||
/** | ||
* Item Quantity. | ||
*/ | ||
quantity?: number; | ||
|
||
/** | ||
* Original quantity. | ||
*/ | ||
originalQuantity?: number; | ||
|
||
/** | ||
* Contested quantity. | ||
*/ | ||
contestedQuantity?: number; | ||
|
||
/** | ||
* Reviewed quantity. | ||
*/ | ||
reviewedQuantity?: number; | ||
} | ||
} | ||
} | ||
} |