Maintain control of your Microsoft 365 data
b.vanhaastrecht
Service Provider
Posts: 880 Liked: 164 times
Joined: Aug 26, 2013 7:46 am
Full Name: Bastiaan van Haastrecht
Location: The Netherlands
Contact:
Post
by b.vanhaastrecht » Sep 24, 2020 8:30 am
this post
Hi,
We are submitting a restore request thru the API with modern authentication. According to the (manual)
https://helpcenter.veeam.com/docs/vbo36 ... tml?ver=40 we only need to submit the userCode.
POST URL:
Code: Select all
RestoreSessions/<restoreSessionId>/Organization/Mailboxes/<mailboxId>/Items/<itemId>/Action"
Body:
Code: Select all
{
"restoretoOriginallocation":
{
"userСode": "C6A9DB737"
}
}
When we do this, we get the following response back:
Code: Select all
{result: "error", message: "Missing mandatory parameters: userName."}
Bug or manual error?
Kind regards,
Bastiaan van Haastrecht
======================================================
Veeam ProPartner, Service Provider and a proud Veeam Legend
nielsengelen
Product Manager
Posts: 5796 Liked: 1215 times
Joined: Jul 15, 2013 11:09 am
Full Name: Niels Engelen
Contact:
Post
by nielsengelen » Sep 24, 2020 8:34 am
this post
Hi Bastiaan, did you already open up a support case for this? A userCode is all that should be needed which is correct (which you can get via POST restoreSession/{id}/organization/restoreDeviceCode). This looks like something specific to the organization or order of API calls going wrong. Let us know the support case ID once it is created for future reference.
Personal blog: https://foonet.be
GitHub: https://github.com/nielsengelen
b.vanhaastrecht
Service Provider
Posts: 880 Liked: 164 times
Joined: Aug 26, 2013 7:46 am
Full Name: Bastiaan van Haastrecht
Location: The Netherlands
Contact:
Post
by b.vanhaastrecht » Sep 24, 2020 8:46 am
this post
Yes we known how to get the userCode. The organization is setup thru modern authentication.
Yes we already have an active ticket for this issue: #04398726
======================================================
Veeam ProPartner, Service Provider and a proud Veeam Legend
b.vanhaastrecht
Service Provider
Posts: 880 Liked: 164 times
Joined: Aug 26, 2013 7:46 am
Full Name: Bastiaan van Haastrecht
Location: The Netherlands
Contact:
Post
by b.vanhaastrecht » Sep 24, 2020 9:17 am
this post
Secuence:
POST:
Code: Select all
"RestoreSessions/<rid>/organization/restoreDeviceCode"
Body:
Code: Select all
array:1 [
"targetApplicationId" => "544d508e-c41c-4a63-bd71-18cfdeb8a1e2"
]
POST
Code: Select all
RestoreSessions/<rid>/Organization/Mailboxes/<mid>/Items/<iid>/Action
Body:
[code]
array:1 [
"restoretoOriginallocation" => array:1 [
"userСode" => "XXXXXXXXX"
]
]
Result:
Code: Select all
{result: "error", message: "Missing mandatory parameters: userName."}
======================================================
Veeam ProPartner, Service Provider and a proud Veeam Legend
nielsengelen
Product Manager
Posts: 5796 Liked: 1215 times
Joined: Jul 15, 2013 11:09 am
Full Name: Niels Engelen
Contact:
Post
by nielsengelen » Sep 24, 2020 9:20 am
this post
Have u tried adding "targetOrganizationName" and "targetRegion" to the restoreDeviceCode request? I've done some tests here on 2 servers and it works for both when restoring a specific item. Both running the latest version 4.0.1.545.
Personal blog: https://foonet.be
GitHub: https://github.com/nielsengelen
b.vanhaastrecht
Service Provider
Posts: 880 Liked: 164 times
Joined: Aug 26, 2013 7:46 am
Full Name: Bastiaan van Haastrecht
Location: The Netherlands
Contact:
Post
by b.vanhaastrecht » Sep 24, 2020 9:32 am
this post
When doing restoreToOriginalLocation for OneDrive we get an other result:
Code: Select all
{result: "error", message: "Incorrect credentials for online organization."}
When doing it thru the GUI, both OneDrive and Exchange to original location works perfectly.
======================================================
Veeam ProPartner, Service Provider and a proud Veeam Legend
b.vanhaastrecht
Service Provider
Posts: 880 Liked: 164 times
Joined: Aug 26, 2013 7:46 am
Full Name: Bastiaan van Haastrecht
Location: The Netherlands
Contact:
Post
by b.vanhaastrecht » Sep 24, 2020 9:33 am
this post
nielsengelen wrote: ↑ Sep 24, 2020 9:20 am
Have u tried adding "targetOrganizationName" and "targetRegion" to the restoreDeviceCode request? I've done some tests here on 2 servers and it works for both when restoring a specific item. Both running the latest version 4.0.1.545.
Shouldnt be needed when restoring to original location, but I will give it a try.
======================================================
Veeam ProPartner, Service Provider and a proud Veeam Legend
b.vanhaastrecht
Service Provider
Posts: 880 Liked: 164 times
Joined: Aug 26, 2013 7:46 am
Full Name: Bastiaan van Haastrecht
Location: The Netherlands
Contact:
Post
by b.vanhaastrecht » Sep 24, 2020 9:38 am
this post
Have added those parameters, but didnt change the results.
======================================================
Veeam ProPartner, Service Provider and a proud Veeam Legend
nielsengelen
Product Manager
Posts: 5796 Liked: 1215 times
Joined: Jul 15, 2013 11:09 am
Full Name: Niels Engelen
Contact:
Post
by nielsengelen » Sep 24, 2020 9:40 am
this post
Let's wait for insight from support then. They will require logs (from extended logging) and should be able to identify something.
Personal blog: https://foonet.be
GitHub: https://github.com/nielsengelen
b.vanhaastrecht
Service Provider
Posts: 880 Liked: 164 times
Joined: Aug 26, 2013 7:46 am
Full Name: Bastiaan van Haastrecht
Location: The Netherlands
Contact:
Post
by b.vanhaastrecht » Sep 24, 2020 9:45 am
this post
Those logs are in their possession. But it's taken them a lot of time to find the issue, therefore I tought I give it a try on the forums. I guess we need to wait.
======================================================
Veeam ProPartner, Service Provider and a proud Veeam Legend
b.vanhaastrecht
Service Provider
Posts: 880 Liked: 164 times
Joined: Aug 26, 2013 7:46 am
Full Name: Bastiaan van Haastrecht
Location: The Netherlands
Contact:
Post
by b.vanhaastrecht » Sep 24, 2020 9:45 am
this post
Thank anyway!
======================================================
Veeam ProPartner, Service Provider and a proud Veeam Legend
Users browsing this forum: m.kan and 22 guests