-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathordersDefine.http
39 lines (34 loc) · 1.51 KB
/
ordersDefine.http
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
POST http://{{ASSET_MANTLE_CLIENT_HOST}}:{{ASSET_MANTLE_CLIENT_PORT}}/orders/define
Content-Type: application/json
{
"type": "/xprt/orders/github.com/persistenceOne/persistenceSDK/modules/orders/internal/transactions/define/transactionRequest",
"value": {
"baseReq": {
"from": "{{ACCOUNT_1_ADDRESS}}",
"chain_id": "{{CHAIN_ID}}"
},
"fromID":"test.MgVN53MovlOXmVrFOb6Rk8efEho=|Hi4ALDaDs923R0w64cr02MffbNA=",
"immutableMetaTraits":"ImmutableMetaPropertyName1:S|ImmutableMetaPropertyValue1,ImmutableMetaPropertyName2:I|",
"immutableTraits":"ImmutablePropertyName3:H|,ImmutablePropertyName4:D|",
"mutableMetaTraits":"MutableMetaPropertyName5:S|,MutableMetaPropertyName6:S|,expiry:H|,exchangeRate:D|,makerOwnableSplit:D|,takerID:I|",
"mutableTraits":"MutablePropertyName7:S|,MutablePropertyName8:S|"
}
}
> {%
client.test("Request executed successfully", function() {
client.assert(response.status === 200, "Response status is not 200");
});
client.global.set("ordersDefineTxHash", JSON.parse(JSON.stringify(response.body)).txhash)
%}
###
GET http://{{ASSET_MANTLE_CLIENT_HOST}}:{{ASSET_MANTLE_CLIENT_PORT}}/txs/{{ordersDefineTxHash}}
Accept: application/json
> {%
client.test("Request executed successfully", function() {
client.assert(response.status === 200, "Response status is not 200");
});
client.test("Response Code Check", function() {
client.assert(!JSON.parse(JSON.stringify(response.body)).hasOwnProperty("code") , "Response Code is not 0");
});
%}
###