Web Service function core_group_create_groupings gives error if no id number parameter added in the request

Web Service function core_group_create_groupings gives error if no id number parameter added in the request

Jasmin Salam -
Vastausten määrä: 0

Hi,

I'm currently testing web service functions for setting up an external service integration. 

I encountered an issue with the core_group_create_groupings function. According to my understanding, the optional parameters are not necessary in the request. However, when I tried sending the request without including the id number, I received the following response:

{
"exception": "invalid_response_exception",
"errorcode": "invalidresponse",
"message": "Invalid response value detected (Error in response - Missing required key in a single structure: idnumber)",
"debuginfo": "Error in response - Missing required key in a single structure: idnumber"
}

Interestingly, despite the error message, the grouping was created successfully in Moodle. I'm wondering if this is a bug or if I missed something in my request.

 Thank you!


Arviointien keskiarvo: -