Authorization: Bearer ********************{
"name": "rrr",
"enabled": true
}curl --location 'https://web-api.blockindex.com/entity/entityId/tradeAutomationRule/search?page=undefined&limit=undefined' \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"name": "rrr",
"enabled": true
}'{
"status": "success",
"data": {
"totalCount": 1,
"list": [
{
"tradeAutomationRuleId": "rGBUUpX7ovmfSqTj4Q1IuPE2FlacAnWb",
"entityId": "8UTJLfAPdHkQKac8uGVNmU9jSzEBJXxy",
"priority": 1,
"name": "1111",
"conditions": [
{
"operator": "EQ",
"value": "FUTURE_OPEN",
"type": "TRADE_TYPE"
}
],
"journalTypeId": "EfKKTidTdUs73GugeIwNkZlqKBmcRtp2",
"entryActions": [
{
"chartOfAccountId": "0",
"balanceType": "Dr",
"currency": "COUNTER_ASSET",
"amount": "COUNTER_AMOUNT",
"chartOfAccountCalculator": "TREASURY_ACCOUNT",
"amountFC": "f002",
"formulaFieldMap": [
{
"var": "f002",
"type": "COUNTER_AMOUNT_FC",
"value": ""
}
],
"auxiliaryMapping": [
{
"auxiliaryTypeId": "dPAKmy9Ks3FCMPKb6SQjOExznap5owRr",
"auxiliaryType": {
"auxiliaryTypeId": "dPAKmy9Ks3FCMPKb6SQjOExznap5owRr",
"entityId": "8UTJLfAPdHkQKac8uGVNmU9jSzEBJXxy",
"name": "Account",
"type": "ENTITY_ACCOUNT"
},
"value": {
"type": "ENTITY_ACCOUNT"
}
}
],
"chartOfAccount": null
},
{
"chartOfAccountId": "M6HOIsQKPrUuVB0e519dH8SbTa3N4jDC",
"balanceType": "Cr",
"currency": "COUNTER_ASSET",
"amount": "COUNTER_AMOUNT",
"chartOfAccountCalculator": "",
"amountFC": "f002",
"formulaFieldMap": [
{
"var": "f002",
"type": "COUNTER_AMOUNT_FC",
"value": ""
}
],
"auxiliaryMapping": [],
"chartOfAccount": {
"chartOfAccountId": "M6HOIsQKPrUuVB0e519dH8SbTa3N4jDC",
"entityId": "8UTJLfAPdHkQKac8uGVNmU9jSzEBJXxy",
"parentChartOfAccountId": "0",
"code": "400-00",
"name": "Sales",
"nameCN": "销售收入",
"type": "REVENUE",
"isLeaf": 1,
"defaultBalanceType": "Cr",
"currencyTypes": [
"FIAT",
"CRYPTO"
],
"slug": "",
"creatorType": "TEMPLATE",
"userId": "0",
"isCashAccount": false,
"description": "",
"depth": 1,
"auxiliaryTypeIds": []
}
}
],
"enabled": true,
"enableAutomationJournalApproved": true,
"journalType": {
"journalTypeId": "EfKKTidTdUs73GugeIwNkZlqKBmcRtp2",
"entityId": "8UTJLfAPdHkQKac8uGVNmU9jSzEBJXxy",
"code": "10000",
"name": "Sales revenue",
"nameCN": "销售收入",
"journalNoPrefix": "SR",
"entryLines": [
{
"chartOfAccountId": "0",
"chartOfAccountCalculator": "TREASURY_ACCOUNT",
"balanceType": "Dr",
"gstType": "NA",
"gstRatio": 0
},
{
"chartOfAccountId": "M6HOIsQKPrUuVB0e519dH8SbTa3N4jDC",
"chartOfAccountCalculator": "",
"balanceType": "Cr",
"gstType": "NA",
"gstRatio": 0
}
],
"group": "OPERATING",
"userId": "JVL9cTTvvqdcnBFDEXhLy7H4tUKGks01",
"slug": "",
"creatorType": "TEMPLATE",
"brokerInventoryType": "NONE",
"entryType": "SIMPLE",
"isBrokerInventory": false
}
}
]
},
"requestId": "eba09096-b8bd-4bbd-a9dc-86319d27009d"
}