Skip to content

Commit c744fb2

Browse files
committed
Merge branch 'extract-payload-parsing' of https://github.com/reservoirprotocol/relay-protocol-hub into staging
2 parents 294451e + 8c134a5 commit c744fb2

File tree

3 files changed

+234
-192
lines changed

3 files changed

+234
-192
lines changed

src/api/requests/withdrawals/v1.ts

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,33 @@ import { externalError } from "../../../common/error";
1414
import { logger } from "../../../common/logger";
1515
import { RequestHandlerService } from "../../../services/request-handler";
1616

17+
const SubmitWithdrawalRequestParamsSchema = Type.Object({
18+
chainId: Type.String({
19+
description: "The chain id of the allocator",
20+
}),
21+
depository: Type.String({
22+
description: "The depository address of the allocator",
23+
}),
24+
currency: Type.String({
25+
description: "The currency to withdraw",
26+
}),
27+
amount: Type.String({
28+
description: "The amount to withdraw",
29+
}),
30+
spender: Type.String({
31+
description: "The address of the spender",
32+
}),
33+
receiver: Type.String({
34+
description: "The address of the receiver on the depository chain",
35+
}),
36+
data: Type.String({
37+
description: "The data to include in the withdrawal request",
38+
}),
39+
nonce: Type.String({
40+
description: "The nonce to include in the withdrawal request",
41+
}),
42+
});
43+
1744
const Schema = {
1845
body: Type.Object({
1946
mode: Type.Optional(
@@ -39,6 +66,7 @@ const Schema = {
3966
description:
4067
"Signature attesting the owner authorized this particular withdrawal request",
4168
}),
69+
submitWithdrawalRequestParams: Type.Optional(SubmitWithdrawalRequestParamsSchema),
4270
additionalData: Type.Optional(
4371
Type.Object(
4472
{

0 commit comments

Comments
 (0)