Scoring rules
Create scoring rule
Authorization
bearer AuthorizationBearer <token>
In: header
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
curl -X POST "https://api.miracle.com/v1/admin/scoring-rules" \ -H "Content-Type: application/json" \ -d '{ "name": "string", "conditions": [ { "field": "amount", "operator": "eq", "value": "string" } ], "scoreImpact": 0, "priority": 0 }'{
"data": {
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"tenantId": "f97df110-f4de-492e-8849-4a6af68026b0",
"livemode": true,
"name": "string",
"description": "string",
"isActive": true,
"conditions": [
{
"field": "amount",
"operator": "eq",
"value": "string",
"aggregation": {
"metric": "sum",
"period": {
"value": 0,
"unit": "minute"
},
"scope": [
"terminal"
],
"identifier": "card_fingerprint",
"currency": "string"
},
"statisticWindow": "1d"
}
],
"signal": "allow",
"scoreImpact": 0,
"priority": 0,
"createdAt": "string",
"updatedAt": "string",
"deletedAt": null
}
}Empty