Hexnode API Post command not workingSolved

Participant
Discussion
3 years ago

Hii, we are facing some problems while testing out the Hexnode APIs. We were able to execute GET APIs successfully but when we try POST it does not execute successfully.
POSt commands tested –
POST https://xyz.hexnodemdm.com/api/v1/actions/associate_policy/
If it helps, we used this as body –

Replies (2)

Marked SolutionPending Review
Hexnode Expert
3 years ago
Marked SolutionPending Review

Hi @Birgitta, you can avoid this error by fixing the body content. The ‘policies’ key-value should come before the ‘users’ key-value. This way you’ll be associating the policy to the user which is the proper way to query it. 

Corrected body – 

 
 
Cheers! 
Zach Goodman 
Hexnode UEM

  • This reply was modified 3 years, 3 months ago by  Zach.
Marked SolutionPending Review
Participant
3 years ago
Marked SolutionPending Review

@zach-goodman I thought the order wouldn’t matter! got it. now it works fine.