Overview

Use the Reporting API to get reports filtered according to your preferences configured in json format. You can define time window, granularity, metric type, and apply a range of filters.

Define your filters with the dimensions object, and the dimension_filter_clauses object which will contain an array of filter objects.

Request metrics such as connections, time usage, and data usage with the metrics object.

Note

The example scripts below give a response in json format, however you can get responses in csv format with --header 'Accept: text/csv'.

Time, bandwidth or byte counts

Time usage for enterprise

curl

curl --location --request POST 'https://api.alefedge.com/connectivity/v1/report?apikey=<API_KEY>' \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--data-raw '{
"start_date_time": "2022-07-07T09:50:00+05:30",
"end_date_time": "2022-07-08T09:50:00+05:30",
"granularity": "DAY",
"dimension_filter_clauses": [
    {
    "filters": [
        {
        "dimension_name": "account_id",
        "operator": "EXACT",
        "expressions": [
            "62c40843c7a1909709112345"
        ]
        }
    ]
    }
],
"metrics": [
    {
    "name": "time_usage_seconds",
    "aggregation_type": "COUNT"
    }
]
}'

Python

import requests
import json

url = "https://api.alefedge.com/connectivity/v1/report?apikey=<API_KEY>"

payload = json.dumps({
"start_date_time": "2022-07-07T09:50:00+05:30",
"end_date_time": "2022-07-08T09:50:00+05:30",
"granularity": "DAY",
"dimension_filter_clauses": [
    {
    "filters": [
        {
        "dimension_name": "account_id",
        "operator": "EXACT",
        "expressions": [
            "62c40843c7a190970912345"
        ]
        }
    ]
    }
],
"metrics": [
    {
    "name": "time_usage_seconds",
    "aggregation_type": "COUNT"
    }
]
})
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json'
}

response = requests.request("POST", url, headers=headers, data=payload)

print(response.text)

Sample response

{
    "result": [
        [
            {
                "time_stamp": "2022-07-07T05:30:00+05:30",
                "name": "time_usage_seconds",
                "value": 23933.017647058823,
                "aggregation_type": "COUNT"
            },
            {
                "time_stamp": "2022-07-08T05:30:00+05:30",
                "name": "time_usage_seconds",
                "value": 39650,
                "aggregation_type": "COUNT"
            },
            {
                "time_stamp": "2022-07-09T05:30:00+05:30",
                "name": "time_usage_seconds",
                "value": 32366,
                "aggregation_type": "COUNT"
            }
        ]
    ],
    "account_id": "62c40843c7a190970912345"
}

Time usage for mobile subscriber (MSISDN)

curl

curl --location --request POST 'https://api.alefedge.com/connectivity/v1/report?apikey=<API_KEY>' \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--data-raw '{
"start_date_time": "2022-07-07T09:50:00+05:30",
"end_date_time": "2022-07-08T09:50:00+05:30",
"granularity": "DAY",
"dimensions": [
    "msisdn"
],
"dimension_filter_clauses": [
    {
    "filters": [
        {
        "dimension_name": "account_id",
        "operator": "EXACT",
        "expressions": [
            "62c40843c7a190970912345"
        ]
        },
        {
        "dimension_name": "msisdn",
        "operator": "EXACT",
        "expressions": [
            8020010012345
        ]
        }
    ]
    }
],
"metrics": [
    {
    "name": "time_usage_seconds",
    "aggregation_type": "COUNT"
    }
]
}'

Python

import requests
import json

url = "https://api.alefedge.com/connectivity/v1/report?apikey=<API_KEY>"

payload = json.dumps({
"start_date_time": "2022-07-07T09:50:00+05:30",
"end_date_time": "2022-07-08T09:50:00+05:30",
"granularity": "DAY",
"dimensions": [
    "msisdn"
],
"dimension_filter_clauses": [
    {
    "filters": [
        {
        "dimension_name": "account_id",
        "operator": "EXACT",
        "expressions": [
            "62c40843c7a190970912345"
        ]
        },
        {
        "dimension_name": "msisdn",
        "operator": "EXACT",
        "expressions": [
            8020010012345
        ]
        }
    ]
    }
],
"metrics": [
    {
    "name": "time_usage_seconds",
    "aggregation_type": "COUNT"
    }
]
})
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json'
}

response = requests.request("POST", url, headers=headers, data=payload)

print(response.text)

Sample response

{
    "result": [
        [
            {
                "time_stamp": "2022-07-07T05:30:00+05:30",
                "name": "time_usage_seconds",
                "value": 23933.017647058823,
                "aggregation_type": "COUNT"
            },
            {
                "time_stamp": "2022-07-08T05:30:00+05:30",
                "name": "time_usage_seconds",
                "value": 39650,
                "aggregation_type": "COUNT"
            },
            {
                "time_stamp": "2022-07-09T05:30:00+05:30",
                "name": "time_usage_seconds",
                "value": 32366,
                "aggregation_type": "COUNT"
            }
        ]
    ],
    "msisdn": 8020010012345,
    "account_id": "62c40843c7a190970912345"
}

Daily and Monthly Usage for mobile subscriber (MSISDN) in bytes

curl

curl --location --request POST 'https://api.alefedge.com/connectivity/v1/report?apikey=<API_KEY>' \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--data-raw '{
"start_date_time": "2022-07-07T09:50:00+05:30",
"end_date_time": "2022-07-08T09:50:00+05:30",
"granularity": "HOUR",
"dimensions": [
    "msisdn"
],
"dimension_filter_clauses": [
    {
    "filters": [
        {
        "dimension_name": "account_id",
        "operator": "EXACT",
        "expressions": [
            "62c40843c7a190970912345"
        ]
        },
        {
        "dimension_name": "msisdn",
        "operator": "EXACT",
        "expressions": [
            8020010012345
        ]
        }
    ]
    }
],
"metrics": [
    {
    "name": "uplink_bytes",
    "aggregation_type": "COUNT"
    },
    {
    "name": "downlink_bytes",
    "aggregation_type": "COUNT"
    }
]
}'

Python

import requests
import json

url = "https://api.alefedge.com/connectivity/v1/report?apikey=<API_KEY>"

payload = json.dumps({
"start_date_time": "2022-07-07T09:50:00+05:30",
"end_date_time": "2022-07-08T09:50:00+05:30",
"granularity": "HOUR",
"dimensions": [
    "msisdn"
],
"dimension_filter_clauses": [
    {
    "filters": [
        {
        "dimension_name": "account_id",
        "operator": "EXACT",
        "expressions": [
            "62c40843c7a190970912345"
        ]
        },
        {
        "dimension_name": "msisdn",
        "operator": "EXACT",
        "expressions": [
            8020010012345
        ]
        }
    ]
    }
],
"metrics": [
    {
    "name": "uplink_bytes",
    "aggregation_type": "COUNT"
    },
    {
    "name": "downlink_bytes",
    "aggregation_type": "COUNT"
    }
]
})
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json'
}

response = requests.request("POST", url, headers=headers, data=payload)

print(response.text)

Sample response

{
    "result": [
        [
            {
                "time_stamp": "2022-07-07T09:30:00+05:30",
                "name": "uplink_bytes",
                "value": 73130,
                "aggregation_type": "COUNT"
            },
            {
                "time_stamp": "2022-07-07T10:30:00+05:30",
                "name": "uplink_bytes",
                "value": 73954,
                "aggregation_type": "COUNT"
            },
            {
                "time_stamp": "2022-07-07T11:30:00+05:30",
                "name": "uplink_bytes",
                "value": 22196.5,
                "aggregation_type": "COUNT"
            },
            {
                "time_stamp": "2022-07-07T12:30:00+05:30",
                "name": "uplink_bytes",
                "value": 73748,
                "aggregation_type": "COUNT"
            },

… Output removed for brevity

        {
                "time_stamp": "2022-07-08T10:30:00+05:30",
                "name": "downlink_bytes",
                "value": 2991011980,
                "aggregation_type": "COUNT"
            }
        ]
    ],
    "msisdn": 8020010012345,
    "account_id": "62c40843c7a190970912345"
}

Real-time Network Bandwidth

curl

curl --location --request POST 'https://api.alefedge.com/connectivity/v1/report?apikey=<API_KEY>' \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--data-raw '{
"start_date_time": "NOW",
"end_date_time": "NOW",
"dimension_filter_clauses": [
    {
    "filters": [
        {
        "dimension_name": "account_id",
        "operator": "EXACT",
        "expressions": [
            "62c40843c7a190970912345"
        ]
        },
        {
        "dimension_name": "customer_site_id",
        "operator": "EXACT",
        "expressions": [
            "62c408aaadd8f757bf412345"
        ]
        }
    ]
    }
],
"metrics": [
    {
    "name": "uplink_bandwidth",
    "aggregation_type": "AVG"
    },
    {
    "name": "downlink_bandwidth",
    "aggregation_type": "AVG"
    }
]
}'

Python

import requests
import json

url = "https://api.alefedge.com/connectivity/v1/report?apikey=<API_KEY>"

payload = json.dumps({
"start_date_time": "NOW",
"end_date_time": "NOW",
"dimension_filter_clauses": [
    {
    "filters": [
        {
        "dimension_name": "account_id",
        "operator": "EXACT",
        "expressions": [
            "62c40843c7a190970912345"
        ]
        },
        {
        "dimension_name": "customer_site_id",
        "operator": "EXACT",
        "expressions": [
            "62c408aaadd8f757bf412345"
        ]
        }
    ]
    }
],
"metrics": [
    {
    "name": "uplink_bandwidth",
    "aggregation_type": "AVG"
    },
    {
    "name": "downlink_bandwidth",
    "aggregation_type": "AVG"
    }
]
})
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json'
}

response = requests.request("POST", url, headers=headers, data=payload)

print(response.text)

Sample response

{
    "start_time": "2022-07-12T09:08:48+00:00",
    "end_time": "2022-07-12T09:13:48+00:00",
    "downlink_bandwidth": 283.9409664,
    "uplink_bandwidth": 4.1809904,
    "customer_site_id": "62c408aaadd8f757bf412345",
    "account_id": "62c40843c7a190970912345"
}

Monthly Bandwidth Usage

curl

curl --location --request POST 'https://api.alefedge.com/connectivity/v1/report?apikey=<API_KEY>' \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--data-raw '{
"start_date_time": "2022-07-11T14:40:00+05:30",
"end_date_time": "2022-07-12T14:40:00+05:30",
"dimensions": [
    "customer_site_id"
],
"dimension_filter_clauses": [
    {
    "filters": [
        {
        "dimension_name": "account_id",
        "operator": "EXACT",
        "expressions": [
            "62c40843c7a190970912345"
        ]
        },
        {
        "dimension_name": "customer_site_id",
        "operator": "EXACT",
        "expressions": [
            "62c408aaadd8f757bf412345"
        ]
        }
    ]
    }
],
"metrics": [
    {
    "name": "uplink_bandwidth",
    "metric_filter_clauses": [
        {
        "filters": [
            {
            "operator": "PERCENTILE",
            "comparison_value": 1
            }
        ]
        }
    ]
    },
    {
    "name": "downlink_bandwidth",
    "metric_filter_clauses": [
        {
        "filters": [
            {
            "operator": "PERCENTILE",
            "comparison_value": 1
            }
        ]
        }
    ]
    }
]
}'

Python

import requests
import json

url = "https://api.alefedge.com/connectivity/v1/report?apikey=<API_KEY>"

payload = json.dumps({
"start_date_time": "2022-07-11T14:40:00+05:30",
"end_date_time": "2022-07-12T14:40:00+05:30",
"dimensions": [
    "customer_site_id"
],
"dimension_filter_clauses": [
    {
    "filters": [
        {
        "dimension_name": "account_id",
        "operator": "EXACT",
        "expressions": [
            "62c40843c7a190970912345"
        ]
        },
        {
        "dimension_name": "customer_site_id",
        "operator": "EXACT",
        "expressions": [
            "62c408aaadd8f757bf412345"
        ]
        }
    ]
    }
],
"metrics": [
    {
    "name": "uplink_bandwidth",
    "metric_filter_clauses": [
        {
        "filters": [
            {
            "operator": "PERCENTILE",
            "comparison_value": 1
            }
        ]
        }
    ]
    },
    {
    "name": "downlink_bandwidth",
    "metric_filter_clauses": [
        {
        "filters": [
            {
            "operator": "PERCENTILE",
            "comparison_value": 1
            }
        ]
        }
    ]
    }
]
})
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json'
}

response = requests.request("POST", url, headers=headers, data=payload)

print(response.text)

Sample response

{
    "result": [
        [
            {
                "time_stamp": "2022-07-12T00:25:00+05:30",
                "name": "uplink_bandwidth",
                "value": 0.0003111608391608391
            },
            {
                "time_stamp": "2022-07-11T16:00:00+05:30",
                "name": "uplink_bandwidth",
                "value": 0.00034236619718309855
            },
            {
                "time_stamp": "2022-07-12T12:25:00+05:30",
                "name": "uplink_bandwidth",
                "value": 0.00034236619718309855
            },
            {
                "time_stamp": "2022-07-11T18:45:00+05:30",
                "name": "uplink_bandwidth",
                "value": 0.00034285314685314684
            },

... Output removed for brevity

            },
            {
                "time_stamp": "2022-07-12T14:40:00+05:30",
                "name": "downlink_bandwidth",
                "value": 319.57010848351644
            }
        ]
    ],
    "customer_site_id": "62c408aaadd8f757bf412345",
    "account_id": "62c40843c7a190970912345"
}
}

Mobile device, user or SIM counts

Average and Peak Active mobile device (UE) connections

curl

curl --location --request POST 'https://api.alefedge.com/connectivity/v1/report?apikey=<API_KEY>' \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--data-raw '{
"start_date_time": "2022-07-11T11:26:00+05:30",
"end_date_time": "2022-07-11T12:26:00+05:30",
"granularity": "HOUR",
"dimension_filter_clauses": [
    {
    "filters": [
        {
        "dimension_name": "account_id",
        "operator": "EXACT",
        "expressions": [
            "62c40843c7a190970912345"
        ]
        }
    ]
    }
],
"metrics": [
    {
    "name": "ue_connections",
    "aggregation_type": "MAX"
    },
    {
    "name": "ue_connections",
    "aggregation_type": "AVG"
    }
]
}'

Python

import requests
import json

url = "https://api.alefedge.com/connectivity/v1/report?apikey=<API_KEY>"

payload = json.dumps({
"start_date_time": "2022-07-11T11:26:00+05:30",
"end_date_time": "2022-07-11T12:26:00+05:30",
"granularity": "HOUR",
"dimension_filter_clauses": [
    {
    "filters": [
        {
        "dimension_name": "account_id",
        "operator": "EXACT",
        "expressions": [
            "62c40843c7a190970912345"
        ]
        }
    ]
    }
],
"metrics": [
    {
    "name": "ue_connections",
    "aggregation_type": "MAX"
    },
    {
    "name": "ue_connections",
    "aggregation_type": "AVG"
    }
]
})
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json'
}

response = requests.request("POST", url, headers=headers, data=payload)

print(response.text)

Sample response

{
    "result": [
        [
            {
                "time_stamp": "2022-07-11T10:30:00+05:30",
                "name": "ue_connections",
                "value": 1,
                "aggregation_type": "AVG"
            },
            {
                "time_stamp": "2022-07-11T11:30:00+05:30",
                "name": "ue_connections",
                "value": 1,
                "aggregation_type": "AVG"
            },
            {
                "time_stamp": "2022-07-11T12:30:00+05:30",
                "name": "ue_connections",
                "value": 1,
                "aggregation_type": "AVG"
            }
        ],
        [
            {
                "time_stamp": "2022-07-11T10:30:00+05:30",
                "name": "ue_connections",
                "value": 1,
                "aggregation_type": "MAX"
            },
            {
                "time_stamp": "2022-07-11T11:30:00+05:30",
                "name": "ue_connections",
                "value": 2,
                "aggregation_type": "MAX"
            },
            {
                "time_stamp": "2022-07-11T12:30:00+05:30",
                "name": "ue_connections",
                "value": 1,
                "aggregation_type": "MAX"
            }
        ]
    ],
    "account_id": "62c40843c7a190970912345"
}

Active SIM count

curl:

curl --location --request POST 'https://api.alefedge.com/connectivity/v1/report?apikey=<API_KEY>' \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--data-raw '{
"start_date_time": "2022-07-07T09:50:00+05:30",
"end_date_time": "2022-07-08T09:50:00+05:30",
"dimension_filter_clauses": [
    {
    "filters": [
        {
        "dimension_name": "account_id",
        "operator": "EXACT",
        "expressions": [
            "62c40843c7a190970912345"
        ]
        }
    ]
    }
],
"metrics": [
    {
    "name": "sim",
    "aggregation_type": "COUNT"
    }
]
}'

Python

import requests
import json

url = "https://api.alefedge.com/connectivity/v1/report?apikey=<API_KEY>"

payload = json.dumps({
"start_date_time": "2022-07-07T09:50:00+05:30",
"end_date_time": "2022-07-08T09:50:00+05:30",
"dimension_filter_clauses": [
    {
    "filters": [
        {
        "dimension_name": "account_id",
        "operator": "EXACT",
        "expressions": [
            "62c40843c7a190970912345"
        ]
        }
    ]
    }
],
"metrics": [
    {
    "name": "sim",
    "aggregation_type": "COUNT"
    }
]
})
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json'
}

response = requests.request("POST", url, headers=headers, data=payload)

print(response.text)

Sample response

[
    {
        "date": "07-07-2022",
        "physical": 1,
        "esim": 1
    },
    {
        "date": "08-07-2022",
        "physical": 1,
        "esim": 1
    }
]

Successful mobile device (UE) Connection Establishment for Subscriber (IMSI)

curl

curl --location --request POST 'https://api.alefedge.com/connectivity/v1/report?apikey=<API_KEY>' \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--data-raw '{
"start_date_time": "2022-07-07T09:50:00+05:30",
"end_date_time": "2022-07-08T09:50:00+05:30",
"granularity": "DAY",
"dimensions": [
    "imsi"
],
"dimension_filter_clauses": [
    {
    "filters": [
        {
        "dimension_name": "account_id",
        "operator": "EXACT",
        "expressions": [
            "62c40843c7a190970912345"
        ]
        },
        {
        "dimension_name": "imsi",
        "operator": "EXACT",
        "expressions": [
            310550000012345
        ]
        }
    ]
    }
],
"metrics": [
    {
    "name": "ue_connections",
    "aggregation_type": "COUNT"
    }
]
}'

Python

import requests
import json

url = "https://api.alefedge.com/connectivity/v1/report?apikey=<API_KEY>"

payload = json.dumps({
"start_date_time": "2022-07-07T09:50:00+05:30",
"end_date_time": "2022-07-08T09:50:00+05:30",
"granularity": "DAY",
"dimensions": [
    "imsi"
],
"dimension_filter_clauses": [
    {
    "filters": [
        {
        "dimension_name": "account_id",
        "operator": "EXACT",
        "expressions": [
            "62c40843c7a190970912345"
        ]
        },
        {
        "dimension_name": "imsi",
        "operator": "EXACT",
        "expressions": [
            310550000012345
        ]
        }
    ]
    }
],
"metrics": [
    {
    "name": "ue_connections",
    "aggregation_type": "COUNT"
    }
]
})
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json'
}

response = requests.request("POST", url, headers=headers, data=payload)

print(response.text)

Sample response

{
    "result": [
        [
            {
                "time_stamp": "2022-07-07T05:30:00+05:30",
                "name": "ue_connections",
                "value": 11,
                "aggregation_type": "COUNT"
            },
            {
                "time_stamp": "2022-07-08T05:30:00+05:30",
                "name": "ue_connections",
                "value": 3,
                "aggregation_type": "COUNT"
            },
            {
                "time_stamp": "2022-07-09T05:30:00+05:30",
                "name": "ue_connections",
                "value": 10,
                "aggregation_type": "COUNT"
            }
        ]
    ],
    "imsi": 310550000012345,
    "account_id": "62c40843c7a190970912345"
}

Successful mobile device (UE) Connection Establishment for Enterprise

curl

curl --location --request POST 'https://api.alefedge.com/connectivity/v1/report?apikey=<API_KEY>' \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--data-raw '{
"start_date_time": "2022-07-07T09:50:00+05:30",
"end_date_time": "2022-07-08T09:50:00+05:30",
"granularity": "DAY",
"dimension_filter_clauses": [
    {
    "filters": [
        {
        "dimension_name": "account_id",
        "operator": "EXACT",
        "expressions": [
            "62c40843c7a190970912345"
        ]
        }
    ]
    }
],
"metrics": [
    {
    "name": "ue_connections",
    "aggregation_type": "COUNT"
    }
]
}'

Python

import requests
import json

url = "https://api.alefedge.com/connectivity/v1/report?apikey=<API_KEY>"

payload = json.dumps({
"start_date_time": "2022-07-07T09:50:00+05:30",
"end_date_time": "2022-07-08T09:50:00+05:30",
"granularity": "DAY",
"dimension_filter_clauses": [
    {
    "filters": [
        {
        "dimension_name": "account_id",
        "operator": "EXACT",
        "expressions": [
            "62c40843c7a190970912345"
        ]
        }
    ]
    }
],
"metrics": [
    {
    "name": "ue_connections",
    "aggregation_type": "COUNT"
    }
]
})
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json'
}

response = requests.request("POST", url, headers=headers, data=payload)

print(response.text)

Sample response

{
    "result": [
        [
            {
                "time_stamp": "2022-07-07T05:30:00+05:30",
                "name": "ue_connections",
                "value": 11,
                "aggregation_type": "COUNT"
            },
            {
                "time_stamp": "2022-07-08T05:30:00+05:30",
                "name": "ue_connections",
                "value": 3,
                "aggregation_type": "COUNT"
            },
            {
                "time_stamp": "2022-07-09T05:30:00+05:30",
                "name": "ue_connections",
                "value": 10,
                "aggregation_type": "COUNT"
            }
        ]
    ],
    "account_id": "62c40843c7a190970912345"
}

Concurrent Online mobile device (UE) Connections

curl

curl --location --request POST 'https://api.alefedge.com/connectivity/v1/report?apikey=<API_KEY>' \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--data-raw '{
"start_date_time": "NOW",
"end_date_time": "NOW",
"dimensions": [
    "customer_site_id"
],
"dimension_filter_clauses": [
    {
    "filters": [
        {
        "dimension_name": "account_id",
        "operator": "EXACT",
        "expressions": [
            "62c40843c7a190970912345"
        ]
        },
        {
        "dimension_name": "customer_site_id",
        "operator": "EXACT",
        "expressions": [
            "62c408aaadd8f757bf412345"
        ]
        }
    ]
    }
],
"metrics": [
    {
    "name": "ue_connections",
    "aggregation_type": "COUNT"
    }
]
}'

Python

import requests
import json

url = "https://api.alefedge.com/connectivity/v1/report?apikey=<API_KEY>"

payload = json.dumps({
"start_date_time": "NOW",
"end_date_time": "NOW",
"dimensions": [
    "customer_site_id"
],
"dimension_filter_clauses": [
    {
    "filters": [
        {
        "dimension_name": "account_id",
        "operator": "EXACT",
        "expressions": [
            "62c40843c7a190970912345"
        ]
        },
        {
        "dimension_name": "customer_site_id",
        "operator": "EXACT",
        "expressions": [
            "62c408aaadd8f757bf412345"
        ]
        }
    ]
    }
],
"metrics": [
    {
    "name": "ue_connections",
    "aggregation_type": "COUNT"
    }
]
})
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json'
}

response = requests.request("POST", url, headers=headers, data=payload)

print(response.text)

Sample response

{
    "start_time": "2022-07-12T08:58:31+00:00",
    "end_time": "2022-07-12T09:03:31+00:00",
    "ue_connections": 1,
    "customer_site_id": "62c408aaadd8f757bf412345",
    "account_id": "62c40843c7a190970912345"
}

Current mobile device status

Current subscriber device status (IMSI)

curl

curl --location --request POST 'https://api.alefedge.com/connectivity/v1/report?apikey=<API_KEY>' \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--data-raw '{
"start_date_time": "NOW",
"end_date_time": "NOW",
"dimensions": [
    "enodeb_ip",
    "ue_ip",
    "lr_id"
],
"dimension_filter_clauses": [
    {
    "filters": [
        {
        "dimension_name": "account_id",
        "operator": "EXACT",
        "expressions": [
            "62c40843c7a190970912345"
        ]
        },
        {
        "dimension_name": "imsi",
        "operator": "EXACT",
        "expressions": [
            "310550000012345"
        ]
        }
    ]
    }
],
"metrics": [
    {
    "name": "ue_online_status",
    "aggregation_type": "EXISTS"
    }
]
}'

Python

import requests
import json

url = "https://api.alefedge.com/connectivity/v1/report?apikey=<API_KEY>"

payload = json.dumps({
"start_date_time": "NOW",
"end_date_time": "NOW",
"dimensions": [
    "enodeb_ip",
    "ue_ip",
    "lr_id"
],
"dimension_filter_clauses": [
    {
    "filters": [
        {
        "dimension_name": "account_id",
        "operator": "EXACT",
        "expressions": [
            "62c40843c7a190970912345"
        ]
        },
        {
        "dimension_name": "imsi",
        "operator": "EXACT",
        "expressions": [
            "310550000012345"
        ]
        }
    ]
    }
],
"metrics": [
    {
    "name": "ue_online_status",
    "aggregation_type": "EXISTS"
    }
]
})
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json'
}

response = requests.request("POST", url, headers=headers, data=payload)

print(response.text)

Sample response

{
    "start_time": "2022-07-12T08:48:20+00:00",
    "end_time": "2022-07-12T08:53:20+00:00",
    "ue_online_status": "YES",
    "enodeb_ip": "172.25.20.1",
    "ue_ip": "10.50.50.2",
    "lr_id": "PP-DSS-31",
    "imsi": "3105500000112345",
    "account_id": "62c40843c7a1909709155555"
}