I use nomics crypto APIs for data.
My URL for the API call is -'http://api.nomics.com/v1/currencies/ticker?key=my-key&ids=BTC,ETH,BNB,DOGE,ADA,XRP,USDT,DOT,BCH,LTC&interval=1d'

So using this URL I want to call the coins data in the same order as they are written in the URL.
But when I call it, the JSON file is sorted automatically by highest market\_cap.

My backend code is-

```
export async function getCryptoBitcoinInfo() {
  const url = 'https://api.nomics.com/v1/currencies/ticker?key=';
  const key =  await getSecret("Nomics_api_key");

  let fullUrl = url + key + '&ids=BTC,ETH,BNB,DOGE,ADA,XRP,USDT,DOT,BCH,LTC&interval=1d'

  console.log("Url: " + fullUrl);

  return fetch(fullUrl, {method: 'get'})
      .then(response => response.json())
}

```

And my front end code is -

```
$w.onReady(function(){
    getCryptoBitcoinInfo()
            .then(currencyInfo => {
                 $w('#text502').text = currencyInfo[3].price
            })
})

```

The above code should pull data for DOGE data but pulls XRP data.

I am using the Wix javascript console i.e. Velo for coding.
To maintain the earlier order, I need to sort the JSON file. How can I do it without affecting my URL endpoint?? What’s the code required in js for this?? Any help would be really appreciated.

Below is the JSON data format

```
[
      {
        "id": "BTC",
        "currency": "BTC",
        "symbol": "BTC",
        "name": "Bitcoin",
        "logo_url": "https://s3.us-east-2.amazonaws.com/nomics-api/static/images/currencies/btc.svg",
        "status": "active",
        "price": "49893.44419788",
        "price_date": "2021-05-13T00:00:00Z",
        "price_timestamp": "2021-05-13T15:52:00Z",
        "circulating_supply": "18709093",
        "max_supply": "21000000",
        "market_cap": "933461087588",
        "market_cap_dominance": "0.3950",
        "num_exchanges": "384",
        "num_pairs": "60196",
        "num_pairs_unmapped": "5078",
        "first_candle": "2011-08-18T00:00:00Z",
        "first_trade": "2011-08-18T00:00:00Z",
        "first_order_book": "2017-01-06T00:00:00Z",
        "rank": "1",
        "rank_delta": "0",
        "high": "63511.58620446",
        "high_timestamp": "2021-04-13T00:00:00Z",
        "1d": {
          "volume": "122857986900.35",
          "price_change": "-5592.21908418",
          "price_change_pct": "-0.1008",
          "volume_change": "43071195664.36",
          "volume_change_pct": "0.5398",
          "market_cap_change": "-104568141203.38",
          "market_cap_change_pct": "-0.1007"
        }
      },
      { "id": "ETH"
        ...
      },
      { "id": "BNB"
        ...
      },
    { "id": "ADA"
        ...
      },
    { "id": "XRP"
        ...
      },
    ...
    ]

```