Skip to content

Commit

Permalink
fix: create settlement and reconciliation accounts in the hub for the…
Browse files Browse the repository at this point in the history
… DFSP currency (#156)
  • Loading branch information
kalinkrustev authored Aug 2, 2024
1 parent ac20ba9 commit 873ccb2
Showing 1 changed file with 96 additions and 3 deletions.
99 changes: 96 additions & 3 deletions collections/hub/provisioning_dfsp/newdfsp.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,100 @@
"test_cases": [
{
"id": 1,
"name": "Setup Accounts and Limits",
"name": "Setup Hub accounts",
"meta": {
"info": "Hub account"
},
"requests": [
{
"id": 1,
"meta": {
"info": "Add {$inputs.HUB_NAME} Account-HUB_MULTILATERAL_SETTLEMENT Second Currency"
},
"description": "Add {$inputs.HUB_NAME} Account-HUB_MULTILATERAL_SETTLEMENT Second Currency",
"apiVersion": {
"minorVersion": 0,
"majorVersion": 1,
"type": "central_admin"
},
"operationPath": "/participants/{name}/accounts",
"path": "/participants/{$inputs.HUB_NAME}/accounts",
"method": "post",
"params": {
"name": "{$inputs.HUB_NAME}"
},
"body": {
"type": "HUB_MULTILATERAL_SETTLEMENT",
"currency": "{$inputs.currency}"
},
"headers": {
"Content-Type": "application/json",
"FSPIOP-Source": "hub_operator"
},
"url": "{$inputs.HOST_CENTRAL_LEDGER}",
"tests": {
"assertions": [
{
"id": 1,
"description": "status to be 201 if not exists or 400 if exists",
"exec": [
"if (response.body.errorInformation) {",
" expect(response.status).to.equal(400)",
"} else {",
" expect(response.status).to.equal(201)",
"}"
]
}
]
}
},
{
"id": 2,
"meta": {
"info": "Add {$inputs.HUB_NAME} Account-HUB_RECONCILIATION for the DFSP currency"
},
"description": "Add {$inputs.HUB_NAME} Account-HUB_RECONCILIATION for the DFSP currency",
"apiVersion": {
"minorVersion": 0,
"majorVersion": 1,
"type": "central_admin"
},
"operationPath": "/participants/{name}/accounts",
"path": "/participants/{$inputs.HUB_NAME}/accounts",
"method": "post",
"params": {
"name": "{$inputs.HUB_NAME}"
},
"body": {
"type": "HUB_RECONCILIATION",
"currency": "{$inputs.currency}"
},
"headers": {
"Content-Type": "application/json",
"FSPIOP-Source": "hub_operator"
},
"url": "{$inputs.HOST_CENTRAL_LEDGER}",
"tests": {
"assertions": [
{
"id": 1,
"description": "status to be 201 if not exists or 400 if exists",
"exec": [
"if (response.body.errorInformation) {",
" expect(response.status).to.equal(400)",
"} else {",
" expect(response.status).to.equal(201)",
"}"
]
}
]
}
}
]
},
{
"id": 2,
"name": "Setup DFSP accounts and limits",
"meta": {
"info": "DFSP account"
},
Expand Down Expand Up @@ -265,7 +358,7 @@
}
},
{
"id": 2,
"id": 3,
"name": "Setup Callback Endpoints",
"meta": {
"info": "DFSP callbacks"
Expand Down Expand Up @@ -1247,7 +1340,7 @@
}
},
{
"id": 3,
"id": 4,
"name": "Setup Notification Emails",
"meta": {
"info": "DFSP notification_emails"
Expand Down

0 comments on commit 873ccb2

Please sign in to comment.