Repository: thenewboston-developers/Website
File: src/containers/ConfirmationValidatorApi/ConfirmationValidatorApiAccounts/index.tsx (TypeScript)

Code before:

const ConfirmationValidatorApiAccounts: FC = () => {
  return (
    <DocContainer className="ConfirmationValidatorApiAccounts" title="Accounts">
      <p>
        The confirmation validators will maintain the account numbers, balances, and balance locks for all accounts on
        the network.
      </p>

      <DocEndpoint endpoint="/accounts" method="GET" />
      <RequestResponseSnippet
        code={`{
    "count": 352,
    "next": "http://54.183.17.224/accounts?limit=50&offset=50",
    "previous": null,
    "results": [
        {
            "id": "4cb1cdbe-ebbf-43c8-9f86-826aaa2af250",
            "account_number": "9bfa37627e2dba0ae48165b219e76ceaba036b3db8e84108af73a1cce01fad35",
            "balance": 6,
            "balance_lock": "749f6faa4eeeda50f51334e903a1eaae084435d53d2a85fb0993a518fef27273"
        },
        {
            "id": "9c6dd61a-438c-4a95-b1d2-33f90bd7f6ad",
            "account_number": "2e86f48216567302527b69eae6c6a188097ed3a9741f43cc3723e570cf47644c",
            "balance": 460,
            "balance_lock": "aca94f4d2f472c6b9b662f60aab247b9c6aef2079d63b870e2cc02308a7c822b"
        }
    ]
}`}
        heading="Response"
      />

      <DocEndpoint endpoint="/accounts/<account_number>/balance" method="GET" />
      <RequestResponseSnippet
        code={`{
  "balance": "6"
}`}
        heading="Response"
      />

      <DocEndpoint endpoint="/accounts/<account_number>/balance_lock" method="GET" />
      <RequestResponseSnippet
        code={`{
  "balance_lock": "749f6faa4eeeda50f51334e903a1eaae084435d53d2a85fb0993a518fef27273"
}`}
        heading="Response"
      />
    </DocContainer>
  );
};

Review comment (suggestion):
For the Listing requests, we have decided to add the table of query params kindly add that.
[here](https://github.com/thenewboston-developers/Website/pull/982/files#diff-c4eee41d3a8c9ab0d7ec0cb4717b0991755b71e565eb72fe46e6217c8b5be168) is the reference of how that should look like

Code after:

const ConfirmationValidatorApiAccounts: FC = () => {
  return (
    <DocContainer className="ConfirmationValidatorApiAccounts" title="Accounts">
      <p>
        The confirmation validators will maintain the account numbers, balances, and balance locks for all accounts on
        the network.
      </p>

      <DocEndpoint endpoint="/accounts" method="GET" />
      <TableParams
        items={[
          {
            dataType: 'URL parameter',
            description: 'If you want to start at a specific point, an offset can be specified.',
            param: 'offset',
          },
          {
            dataType: 'URL parameter',
            description: 'Maximum number of block returned by the node. (max: 100)',
            param: 'limit',
          },
        ]}
      />
      <RequestResponseSnippet
        code={`{
  "count": 352,
  "next": "http://54.183.17.224/accounts?limit=50&offset=50",
  "previous": null,
  "results": [
    {
      "id": "4cb1cdbe-ebbf-43c8-9f86-826aaa2af250",
      "account_number": "9bfa37627e2dba0ae48165b219e76ceaba036b3db8e84108af73a1cce01fad35",
      "balance": 6,
      "balance_lock": "749f6faa4eeeda50f51334e903a1eaae084435d53d2a85fb0993a518fef27273"
    },
    {
      "id": "9c6dd61a-438c-4a95-b1d2-33f90bd7f6ad",
      "account_number": "2e86f48216567302527b69eae6c6a188097ed3a9741f43cc3723e570cf47644c",
      "balance": 460,
      "balance_lock": "aca94f4d2f472c6b9b662f60aab247b9c6aef2079d63b870e2cc02308a7c822b"
    }
  ]
}`}
        heading="Response"
      />

      <DocEndpoint endpoint="/accounts/<account_number>/balance" method="GET" />
      <RequestResponseSnippet
        code={`{
  "balance": "6"