-
-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Bug]: SaaS Bulk Seat Update Endpoint should be SET with PUT call. #2
Comments
Set-DattoBulkSeatAssignment -saasCustomerId "123456" -externalSubscriptionId "Classic:Office365:123456" -seatType "SharedMailbox" -remoteId "ab23-bdf234-1234-asdf" -actionType "License" -Verbose
VERBOSE: Running the [ index ] parameterSet
VERBOSE: PUT https://api.datto.com/v1/saas/123456/Classic:Office365:123456/bulkSeatChange with -1-byte payload
VERBOSE: received -1-byte response of content type application/json
{"action":"BulkSeatChange","appType":"Global","customerId":123456,"id":1704754852491,"status":"started"} This was fixed in e0a6f62 and appears to accept the PUT request , this was validated that the endpoint made the changes in the UI. |
Hi @cksapp, thanks for bring this to my attention! I honestly dont remember there ever being a PUT endpoint in their API when i wrote this, but it is for sure there now. I will take a closer look at this, this weekend when I have some spare time. Also I have been meaning to delete the dev branch of this repo for a while, so whenever you have a moment go ahead and make a pull request to the main branch. I will be deleting the dev branch in the near future. |
The Put was new to support the SaaS bulk seat changes as far as I understand, and honestly fairly exciting imo. Here's to hoping we can get some more functionality with added integrations as currently this is the only call that makes use of the PUT method. 🤞
Can do here, one thing as I was drafting this when you commented here 😅. Not sure what I did incorrectly here, as it seems that none of the build tests from the PR ran successfully. Feel free to check back when you can to review this. No rush, and all feedback is much appreciated here too. Thanks! |
What happened?
SaaS Bulk Seat Assignment endpoint is actually an HTTP PUT call, and so the current implementation with the
Get-DattoBulkSeatAssignment
function does not work as expected.Expected behavior?
Seat change in the UI as expected for the SaaS Protection Organization seat,
Example response received for valid response body received from bulk seat change endpoint.
Possible Solution?
Should be able to have this work with the proper PUT, working on a fork to merge into the dev branch. This would be my first merge to another public repo and contributing, so any feedback is well appreciated.
Trying to get the conversation started on everything expected here for the module, and what may be needed for the proper implementation.
PowerShell Version
5.1 - (PowerShell)
What operating system are you seeing the problem on?
Windows
Relevant log output
Help Commands
Get-ComputerInfo -Property @( 'OsName', 'OsVersion', 'OsOperatingSystemSKU', 'OSArchitecture', 'WindowsVersion', 'WindowsBuildLabEx', 'OsLanguage', 'OsMuiLanguages' )
Code of Conduct
The text was updated successfully, but these errors were encountered: