Skip to content

Instantly share code, notes, and snippets.

@justlev
Last active October 20, 2020 14:12
Show Gist options
  • Save justlev/fae8f3fe5a8fc926902a405abf9e912d to your computer and use it in GitHub Desktop.
Save justlev/fae8f3fe5a8fc926902a405abf9e912d to your computer and use it in GitHub Desktop.
GetCurrentUsage.json
{
"data": {
"id": "447890025715",
"type": "get_usage_currents",
"attributes": {
"plan": {
"code": "SM_SMALL",
"description": "2GB",
"autoRenew": true,
"start": "2020-10-06T01:00:02+01:00",
"end": "2020-11-04T23:59:59+00:00",
"length": "P1M",
"packageStart": "2020-10-06T01:00:02.783+0100",
"packageEnd": "2020-11-04T23:59:59.000+0000",
"packageLength": "P1M",
"bundles": [
{
"name": "Unlimited Voice",
"used": {
"value": "0",
"unit": "second"
},
"start": "2020-10-05T00:00:00.000+0100",
"end": "2020-11-05T00:00:00.000+0000"
},
{
"name": "Unlimited Text",
"used": {
"value": "0",
"unit": null
},
"start": "2020-10-05T00:00:00.000+0100",
"end": "2020-11-05T00:00:00.000+0000"
},
{
"name": "2GB Data",
"limit": {
"value": "2097152",
"unit": "KiB"
},
"used": {
"value": "0",
"unit": "KiB"
},
"reserved": {
"value": "0",
"unit": "KiB"
},
"start": "2020-10-05T00:00:00.000+0100",
"end": "2020-11-05T00:00:00.000+0000"
}
],
"addons": [
],
"totals": {
"data": {
"used": {
"value": 0,
"unit": "KiB",
"amount_in_mb": 0.0,
"value_converted": 0,
"unit_converted": "KB"
},
"limit": {
"value": 2097152,
"unit": "KiB",
"amount_in_mb": 2048.0,
"value_converted": 2.0,
"unit_converted": "GB"
},
"remaining": {
"value": 2097152,
"unit": "KiB",
"amount_in_mb": 2048.0,
"value_converted": 2.0,
"unit_converted": "GB"
}
},
"cash": {
"used": {
"unit": "GBP",
"value": 0.0
},
"limit": {
"unit": "GBP",
"value": 0.0
},
"remaining": {
"unit": "GBP",
"value": 0.0
}
}
}
},
"boltons": [
{
"code": "5_CASHGW",
"start": "2020-10-20T13:11:57.000+0100",
"expires": null,
"length": null,
"bundles": [
{
"name": "£5.00 Out of plan goodwill",
"limit": {
"value": "5.00",
"unit": "GBP"
},
"used": {
"value": "0.00",
"unit": "GBP"
},
"reserved": {
"value": "0.00",
"unit": "GBP"
},
"start": "2020-10-20T13:11:57.000+0100"
}
],
"boltonInstanceId": 54286,
"exchangeable": false
},
{
"code": "4GB_DATA",
"start": "2020-10-20T09:55:33.000+0100",
"expires": null,
"length": null,
"bundles": [
{
"name": "4GB Data add-on",
"limit": {
"value": "4194304",
"unit": "KiB"
},
"used": {
"value": "0",
"unit": "KiB"
},
"reserved": {
"value": "0",
"unit": "KiB"
},
"start": "2020-10-20T09:55:33.000+0100"
}
],
"boltonInstanceId": 54284,
"exchangeable": false
},
{
"code": "10_CASH",
"start": "2020-10-20T12:30:11.000+0100",
"expires": null,
"length": null,
"bundles": [
{
"name": "£10.00 Out of plan add-on",
"limit": {
"value": "10.00",
"unit": "GBP"
},
"used": {
"value": "0.00",
"unit": "GBP"
},
"reserved": {
"value": "0.00",
"unit": "GBP"
},
"start": "2020-10-20T12:30:11.000+0100"
}
],
"boltonInstanceId": 54285,
"exchangeable": true
}
],
"bolton_totals": {
"data": {
"used": {
"value": 0,
"unit": "KiB",
"amount_in_mb": 0.0,
"value_converted": 0,
"unit_converted": "KB"
},
"limit": {
"value": 4194304,
"unit": "KiB",
"amount_in_mb": 4096.0,
"value_converted": 4.0,
"unit_converted": "GB"
},
"remaining": {
"value": 4194304,
"unit": "KiB",
"amount_in_mb": 4096.0,
"value_converted": 4.0,
"unit_converted": "GB"
}
},
"cash": {
"used": {
"unit": "GBP",
"value": 0.0
},
"limit": {
"unit": "GBP",
"value": 15.0
},
"remaining": {
"unit": "GBP",
"value": 15.0
}
}
}
},
"links": {
"self": "/usage"
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment