Skip to content

Query LMS usage

Description: Query LMS Usage

POST  https://lms-api.swiftfederation.com/lms/v7.4.1/usage/transcoding

Request

  • Header

  • Body

Field Required Type Description
customerIds M List Array of customer Ids.
startTime M String Start time. Format yyyy-MM-ddTHH🇲🇲ssZ UTC time.
endTime M Array End time. Format yyyy-MM-ddTHH🇲🇲ssZ UTC time. Interval between start time and end time cannot be longer than 1 Day.

Response

  • Header

  • Body

Field Type Description
customerId Long each customer ID.
usages Object list of usage data with 5 minutes interval.
Usage Definition
timestamp String Format yyyy-MM-ddTHH🇲🇲ssZ UTC time. E.g. 2024-03-29T17:35:00Z will return data from 2018-03-29T17:35:00Z to 2018-03-29T17:39:59Z.
totalUsageCPU Long total usage of transcoding on CPU. Unit: Second
cpuTranscodingH264SD Long the usage of transcoding on CPU for H.264&SD. Unit: Second
cpuTranscodingH264HD Long the usage of transcoding on CPU for H.264&HD. Unit: Second
cpuTranscodingH264UHD Long the usage of transcoding on CPU for H.264&UHD. Unit: Second
cpuTranscodingH265SD Long the usage of transcoding on CPU for H.265&SD. Unit: Second
cpuTranscodingH265HD Long the usage of transcoding on CPU for H.265&HD. Unit: Second
cpuTranscodingH265UHD Long the usage of transcoding on CPU for H.265&UHD. Unit: Second
totalUsageGPU Long total usage of transcoding on GPU. Unit: Second
gpuTranscodingH264SD Long the usage of transcoding on GPU for H.264&SD. Unit: Second
gpuTranscodingH264HD Long the usage of transcoding on GPU for H.264&HD. Unit: Second
gpuTranscodingH264UHD Long the usage of transcoding on GPU for H.264&UHD. Unit: Second
gpuTranscodingH265SD Long the usage of transcoding on GPU for H.265&SD. Unit: Second
gpuTranscodingH265HD Long the usage of transcoding on GPU for H.265&HD. Unit: Second
gpuTranscodingH265UHD Long the usage of transcoding on GPU for H.265&UHD. Unit: Second
transmuxing Long the usage of transmuxing on GPU. Unit: Second
audioOnly Long the usage of transcoding on GPU for audio only. Unit: Second

Examples

  • Request
POST https://lms-api.swiftfederation.com/lms/v7.4.1/usage/transcoding
Content-Type: application/json; charset=UTF-8
Authorization: ...

{
    "customerIds": [120,36130],
    "startTime": "2024-09-30T06:50:00Z",
    "endTime": "2024-09-30T06:55:00Z"
}
  • Response

    [ { "customerId":3146, "usages": [{ "totalUsageCPU": 12332, "timestamp": "2024-03-29T17:35:00Z" "cpuTranscodingH264SD": 331, "cpuTranscodingH264HD": 3123, "cpuTranscodingH264UHD": 4222, "cpuTranscodingH265SD": 331, "cpuTranscodingH265HD": 31, "cpuTranscodingH265UHD": 41, "totalUsageGPU": 22332, "gpuTranscodingH264SD": 6443, "gpuTranscodingH264HD": 7574, "gpuTranscodingH264UHD": 1232, "gpuTranscodingH265SD": 412, "gpuTranscodingH265HD": 5223, "gpuTranscodingH265UHD": 5232, "transmuxing": 1232, "audioOnly": 232 }, { "totalUsageCPU": 12332, "timestamp": "2024-03-29T17:35:00Z" "CPUTranscodingH264SD": 331, "CPUTranscodingH264HD": 3123, "CPUTranscodingH264UHD": 4222, "CPUTranscodingH265SD": 331, "CPUTranscodingH265HD": 31, "CPUTranscodingH265UHD": 41, "totalUsageGPU": 22332, "GPUTranscodingH264SD": 6443, "GPUTranscodingH264HD": 7574, "GPUTranscodingH264UHD": 1232, "GPUTranscodingH265SD": 412, "GPUTranscodingH265HD": 5223, "GPUTranscodingH265UHD": 5232, "transmuxing": 1232, "audioOnly": 232 }, ] }, { "customerId":3145, [ { "timestamp": "2024-03-29T17:35:00Z" "totalUsageCPU": 15233, "CPUTranscodingH264SD": 331, "CPUTranscodingH264HD": 3123, "CPUTranscodingH264UHD": 4222, "CPUTranscodingH265SD": 331, "CPUTranscodingH265HD": 31, "CPUTranscodingH265UHD": 41, "totalUsageGPU": 22332, "GPUTranscodingH264SD": 6443, "GPUTranscodingH264HD": 7574, "GPUTranscodingH264UHD": 1232, "GPUTranscodingH265SD": 412, "GPUTranscodingH265HD": 5223, "GPUTranscodingH265UHD": 5232, "transmuxing": 1232, "audioOnly": 232 } ] } ]