Skip to content

Commit 80cf7a7

Browse files
committed
chore: escrow template and mappings example
1 parent 7c9c465 commit 80cf7a7

File tree

2 files changed

+80
-0
lines changed

2 files changed

+80
-0
lines changed
Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
[
2+
{
3+
"type": "graphql",
4+
"endpoint": "https://api.thegraph.com/subgraphs/name/kemuru/escrow-v2-devnet",
5+
"query": "query GetTransaction($transactionId: ID!) { escrow(id: $transactionId) { transactionUri buyer seller amount asset deadline } }",
6+
"variables": {
7+
"transactionId": "{{externalDisputeID}}"
8+
},
9+
"seek": [
10+
"escrow.transactionUri",
11+
"escrow.buyer",
12+
"escrow.seller",
13+
"escrow.amount",
14+
"escrow.asset",
15+
"escrow.deadline"
16+
],
17+
"populate": [
18+
"transactionUri",
19+
"address",
20+
"sendingRecipientAddress",
21+
"amount",
22+
"asset",
23+
"deadline"
24+
]
25+
},
26+
{
27+
"type": "fetch/ipfs/json",
28+
"ipfsUri": "{{transactionUri}}",
29+
"seek": [
30+
"title",
31+
"description",
32+
"extraDescriptionUri"
33+
],
34+
"populate": [
35+
"escrowTitle",
36+
"deliverableText",
37+
"extraDescriptionUri"
38+
]
39+
}
40+
]
Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
{
2+
"title": "{{escrowTitle}}",
3+
"description": "{{deliverableText}}",
4+
"question": "Which party abided by the terms of the contract?",
5+
"answers": [
6+
{
7+
"title": "Refund the Buyer",
8+
"description": "Select this to return the funds to the Buyer."
9+
},
10+
{
11+
"title": "Pay the Seller",
12+
"description": "Select this to release the funds to the Seller."
13+
}
14+
],
15+
"policyURI": "ipfs://TODO",
16+
"attachment": {
17+
"label": "Transaction Terms",
18+
"uri": "{{extraDescriptionUri}}"
19+
},
20+
"frontendUrl": "https://escrow-v2.kleros.builders/#/myTransactions/{{externalDisputeID}}",
21+
"arbitrableChainID": "421614",
22+
"arbitrableAddress": "{{arbitrator}}",
23+
"arbitratorChainID": "421614",
24+
"arbitratorAddress": "{{arbitrable}}",
25+
"metadata": {
26+
"buyer": "{{address}}",
27+
"seller": "{{sendingRecipientAddress}}",
28+
"amount": "{{sendingQuantity}}",
29+
"asset": "{{asset}}",
30+
"deadline": "{{deadline}}",
31+
"transactionUri": "{{transactionUri}}"
32+
},
33+
"category": "Escrow",
34+
"specification": "KIPXXX",
35+
"aliases": {
36+
"Buyer": "{{address}}",
37+
"Seller": "{{sendingRecipientAddress}}"
38+
},
39+
"version": "1.0"
40+
}

0 commit comments

Comments
 (0)