Extracting JSON API response to load into relational database table

Hi,

I’ve created a codeless API which connects to a 3rd part API and returns a JSON response (see example below). I’ve set up at the moment to return the string to page data just to test it out.

What I really want to do is save the information returned into the database. I’ve managed to do this by saving as a single JSON object into a single JSON field in the database, but I don’t want that, I’d like to be able to save selected information from the response into a table for example save the following aspects into a table:

Field in Table | value
accountName | TRANSACTION ACCOUNT 1
accounNumber | 10000000
providerName | MOCK

There are a number of ‘accounts’ returned in the response so would need to iterate over them also.

Any support resources or videos you can point me to that would help? This is a specific use case, I have a few of these where I will get different JSON responses back and want to parse in different ways so a pattern to follow would be ideal.

Ideally I’d like to use codeless blocks but if there is another way to get there that would be cool too.

Thanks in advance for any help!

Matt

{
“results”: [
{
“account_number”: {
“number”: “10000000”,
“swift_bic”: “CPBKGB00”,
“iban”: “GB08CLRB04066800003435”,
“sort_code”: “01-21-31”
},
“account_type”: “TRANSACTION”,
“account_id”: “56c7b029e0f8ec5a2334fb0ffc2fface”,
“update_timestamp”: “2022-05-12T16:52:23.6342244Z”,
“provider”: {
“logo_uri”: “https://truelayer-client-logos.s3-eu-west-1.amazonaws.com/banks/banks-icons/mock-icon.svg”,
“provider_id”: “mock”,
“display_name”: “MOCK”
},
“currency”: “GBP”,
“display_name”: “TRANSACTION ACCOUNT 1”
},
{
“account_number”: {
“number”: “20000000”,
“swift_bic”: “CPBKGB00”,
“iban”: “GB08CLRB04066800003435”,
“sort_code”: “01-21-31”
},
“account_type”: “SAVINGS”,
“account_id”: “3c6edb9484ecd581dc1cedde8bedb1f1”,
“update_timestamp”: “2022-05-12T16:52:23.6342343Z”,
“provider”: {
“logo_uri”: “https://truelayer-client-logos.s3-eu-west-1.amazonaws.com/banks/banks-icons/mock-icon.svg”,
“provider_id”: “mock”,
“display_name”: “MOCK”
},
“currency”: “GBP”,
“display_name”: “SAVINGS ACCOUNT 1”
},
{
“account_number”: {
“number”: “30000000”,
“swift_bic”: “CPBKGB00”,
“iban”: “GB08CLRB04066800003435”,
“sort_code”: “01-21-31”
},
“account_type”: “TRANSACTION”,
“account_id”: “89c3139784a055b9b47998f9dce9122e”,
“update_timestamp”: “2022-05-12T16:52:23.6342443Z”,
“provider”: {
“logo_uri”: “https://truelayer-client-logos.s3-eu-west-1.amazonaws.com/banks/banks-icons/mock-icon.svg”,
“provider_id”: “mock”,
“display_name”: “MOCK”
},
“currency”: “GBP”,
“display_name”: “TRANSACTION ACCOUNT 2”
},
{
“account_number”: {
“number”: “40000000”,
“swift_bic”: “CPBKGB00”,
“iban”: “GB08CLRB04066800003435”,
“sort_code”: “01-21-31”
},
“account_type”: “SAVINGS”,
“account_id”: “328df3a40b828340fa4c3100e17de121”,
“update_timestamp”: “2022-05-12T16:52:23.6342528Z”,
“provider”: {
“logo_uri”: “https://truelayer-client-logos.s3-eu-west-1.amazonaws.com/banks/banks-icons/mock-icon.svg”,
“provider_id”: “mock”,
“display_name”: “MOCK”
},
“currency”: “GBP”,
“display_name”: “SAVINGS ACCOUNT 2”
},
{
“account_number”: {
“number”: “50000000”,
“swift_bic”: “CPBKGB00”,
“iban”: “GB08CLRB04066800003435”,
“sort_code”: “01-21-31”
},
“account_type”: “TRANSACTION”,
“account_id”: “8de2de9eab01b935b21abcbed11adf26”,
“update_timestamp”: “2022-05-12T16:52:23.6342611Z”,
“provider”: {
“logo_uri”: “https://truelayer-client-logos.s3-eu-west-1.amazonaws.com/banks/banks-icons/mock-icon.svg”,
“provider_id”: “mock”,
“display_name”: “MOCK”
},
“currency”: “GBP”,
“display_name”: “TRANSACTION ACCOUNT 3”
}
],
“status”: “Succeeded”
}