aiMentorOrgsUsersRecommendCoursesRetrieveWithHttpInfo method
Recommend courses for a user
Note: This method returns the HTTP Response.
Parameters:
Implementation
Future<Response> aiMentorOrgsUsersRecommendCoursesRetrieveWithHttpInfo(String org, String userId, { bool? includeLearnerSkills, bool? rankByDifficulty, bool? returnCourseData, int? returnNumber, String? searchTerms, }) async {
// ignore: prefer_const_declarations
final path = r'/api/ai/mentor/orgs/{org}/users/{user_id}/recommend-courses/'
.replaceAll('{org}', org)
.replaceAll('{user_id}', userId);
// ignore: prefer_final_locals
Object? postBody;
final queryParams = <QueryParam>[];
final headerParams = <String, String>{};
final formParams = <String, String>{};
if (includeLearnerSkills != null) {
queryParams.addAll(_queryParams('', 'include_learner_skills', includeLearnerSkills));
}
if (rankByDifficulty != null) {
queryParams.addAll(_queryParams('', 'rank_by_difficulty', rankByDifficulty));
}
if (returnCourseData != null) {
queryParams.addAll(_queryParams('', 'return_course_data', returnCourseData));
}
if (returnNumber != null) {
queryParams.addAll(_queryParams('', 'return_number', returnNumber));
}
if (searchTerms != null) {
queryParams.addAll(_queryParams('', 'search_terms', searchTerms));
}
const contentTypes = <String>[];
return apiClient.invokeAPI(
path,
'GET',
queryParams,
postBody,
headerParams,
formParams,
contentTypes.isEmpty ? null : contentTypes.first,
);
}