REST API knowledge exchange
Post Reply
bstout29
Novice
Posts: 3
Liked: never
Joined: Nov 05, 2020 8:46 pm
Full Name: Ben Stout
Contact:

Veeam API - any way to get realtime job statistics?

Post by bstout29 »

I am getting a list of backup task sessions fine and can see the Total Size....is there anyway to get real time data about the task sessions? Like Transferred Size, Processing Rate etc?
Natalia Lupacheva
Veteran
Posts: 1143
Liked: 302 times
Joined: Apr 27, 2020 12:46 pm
Full Name: Natalia Lupacheva
Contact:

Re: Veeam API - any way to get realtime job statistics?

Post by Natalia Lupacheva »

Hi Ben,

Just to clarify your case and to make sure I understand you correctly -
you run /backupSessions method, then get the session id and check the session info with /backupSessions/{ID}.

Correct?
bstout29
Novice
Posts: 3
Liked: never
Joined: Nov 05, 2020 8:46 pm
Full Name: Ben Stout
Contact:

Re: Veeam API - any way to get realtime job statistics?

Post by bstout29 »

Hi Natalia,

Yes, I am using /backupSessions/{ID} to get the session info and /backupTaskSessions/{ID} to get the task sessions info. I see the Total Size exposed, but what I am wondering is if the API exposes real time information about sessions and task sessions that have not completed...how much has transferred, what the processing rate is etc.? Are there any API calls I might be missing to see that or does the API not expose that information anywhere?

Thanks,
Ben
Natalia Lupacheva
Veteran
Posts: 1143
Liked: 302 times
Joined: Apr 27, 2020 12:46 pm
Full Name: Natalia Lupacheva
Contact:

Re: Veeam API - any way to get realtime job statistics?

Post by Natalia Lupacheva »

Ben,

you're right, currently we don't have a possibility to get such a detailed information as we see in UI.
Using this method, you can get how much data was transferred (TotalSize) and count processing rate using start/end time.

Thanks!
oleg.feoktistov
Veeam Software
Posts: 2010
Liked: 670 times
Joined: Sep 25, 2019 10:32 am
Full Name: Oleg Feoktistov
Contact:

Re: Veeam API - any way to get realtime job statistics?

Post by oleg.feoktistov » 1 person likes this post

Hi Ben,

In regards to automation, currently this info is available through Powershell only:

Code: Select all

$backupSession = Get-VBRBackupSession -Name 'BACKUP*'
$taskSessions = Get-VBRTaskSession -Session $backupSession
$taskSessions[0].Progress
Thanks,
Oleg
bstout29
Novice
Posts: 3
Liked: never
Joined: Nov 05, 2020 8:46 pm
Full Name: Ben Stout
Contact:

Re: Veeam API - any way to get realtime job statistics?

Post by bstout29 »

Thank you Oleg and Natalia! Just to clarify, as far as the TotalSize field, that is data transferred at the time of API call? And is the long being returned in bytes?

Thanks,
Ben
Natalia Lupacheva
Veteran
Posts: 1143
Liked: 302 times
Joined: Apr 27, 2020 12:46 pm
Full Name: Natalia Lupacheva
Contact:

Re: Veeam API - any way to get realtime job statistics?

Post by Natalia Lupacheva »

Hi Ben,

yes, it's bytes.
For the running job it will be the current state.
There can be some difference with actual data because sending request, data collection and sending the response takes time.
I would not expect a huge difference but just in case if you need precise numbers - there can be some confusion.

Thanks!
Post Reply

Who is online

Users browsing this forum: No registered users and 2 guests