When looking into the issue in my last post, I found I could no longer access Airwatch’s online API documentation.
Heading to Ask Airwatch & looking for the API documentation revealed why.
With the 8.3 release, Airwatch have started a process of refactoring & remotion of the Uniform Resource Identifier (read: URI) used for API calls.
See below for more information on these changes.
URI Refactoring & Remotion? Re-What?
Essentially, the URI’s for API calls have changed.
In AirWatch 8.3, AirWatch has modified the look of the API URIs by removing the version specification from them.
But, the V1 and V2 APIs can be fetched by adding the version details in the Accept header.
To retrieve Version 1 APIs, use:
To retrieve Version 2 APIs, use:
Some API’s have also been refactored or modified, again these can be found in the “VMware AirWatch REST API Guide v8_3.pdf”
However, whilst AirWatch advise that:
“In 8.3 version, there are few API endpoints whose URIs are refactored or modified. This modification do not NOT affect any existing workflows that you are using till date.”
I have found some URI’s have indeed changed.
The API documentation does list the deprecated URI’s:
With details available for the refactored URI’s:
Again, AirWatch advise that the URI’s have not changed yet. But I have found some to fail even with the correct version header.
AirWatch do advise that they will warn when the URI’s are fully refactored, (as per the below image from the “VMware AirWatch REST API Guide v8_3.pdf”), but I’d advise changing URI’s sooner rather than later.
As mentioned, I started this discovery process by heading to Ask Airwatch & looking for the API documentation.
However, I still found things did not work & still could not access the online API documentation which used to be at https://<consoleURL>/API/v1/help.
New API Help URL
I tried dropping the version number from the URL & making it lower case & voilà!
So the new API Help URL is: https://<consoleURL>/api/help (replace <consoleURL> with your AirWatch consoles URL).
Sadly, this discovery lead to some confusion.
The “VMware AirWatch REST API Guide v8_3.pdf” & API Help pages have differing information or one is wrong with the other correct.
With the above, the PDF is missing the v1 from the URI.
Before the 8.3 update, I used lgid as per the Help URL documentation & also mentioned in this post.
However since the 8.3 update, I have needed to change some URI’s from lgid to organizationgroupid (as shown in the PDF example above).
So, you’ll need to reference both documents to find the correct URI.
I have logged these inconsistencies with AirWatch, & for that gained some more EXP Points! Woohoo!
So the API documentation will all hopefully line up soon
5 thoughts on “Airwatch REST API URI Changes”
Did they release new API documentation?
Not sure. No longer an Airwatch customer.
Hello, is there a specific header to increase the returned devices from the airwatch api rest get devices call? When I run the get devices it does not return all devices? I don’t have any critieria and return about 250 devices, so trying to determine what is stopping me when we have about 2000 in our Airwatch system?
Thanks for any help on this.
Not sure. I’m no longer an Airwatch customer.
try PageSize as 2000