Skip to content

getNetworkStatistics

Sahri Riza Umami edited this page Jun 24, 2018 · 4 revisions

Returns network data usage statistics.
Can be called before authorization.

getNetworkStatistics(only_current)  
Field Type Description
only_current Bool If true, returns only data for the current library launch

Example

  • Get current network data usage statistics.

    getNetworkStatistics(1)  

    Response:

    {
      ["@type"] = "networkStatistics",
      entries = {
        {
          ["@type"] = "networkStatisticsEntryFile",
          file_type = {
            ["@type"] = "fileTypeNone"
          },
          network_type = {
            ["@type"] = "networkTypeOther"
          },
          received_bytes = 1832,
          sent_bytes = 848
        }
      },
      since_date = 1529822268
    }

Frequently Asked Questions
The Functions

Clone this wiki locally