Skip to content

Searches all WordPress users so one can be assigned as the course instructor.

Unlike the student picker this does not exclude existing course members, and it is capped at 100 results. Email addresses appear only for callers with the WordPress list_users capability.

Endpoint ​

  • Method: GET

  • Path: /admin/courses/{course_id}/instructors/search

  • Edition: Core

  • Controller: CourseAdminController@getOtherInstructors

  • Route source: fluent-community/Modules/Course/Http/course_api.php:41

  • Controller source: fluent-community/Modules/Course/Http/Controllers/CourseAdminController.php

  • Requires the course-creator permission and management access to this course.

Live sample

The request and response below were recorded against a running FluentCommunity install and then anonymised — member names, emails, avatars and post content are fictional, and long collections are trimmed to a few entries.

GET Search Course Instructors​

GET
/admin/courses/{course_id}/instructors/search

Searches all WordPress users so one can be assigned as the course instructor.

Controller: CourseAdminController@getOtherInstructors
Route source: fluent-community/Modules/Course/Http/course_api.php:41

Authorizations​

ApplicationPasswords

WordPress Application Passwords — use Basic auth with username:application_password.

Type
API Key (header: Authorization)

Parameters​

Path Parameters

course_id*

Course ID extracted from the URL path.

Type
integer
Required

Query Parameters

search

Search read via $request->getSafe() in getOtherInstructors().

Type
string

Responses​

Successful response

application/json
JSON
{
  
"instructors": [
  
  
{
  
  
  
"ID": 0,
  
  
  
"display_name": "string",
  
  
  
"photo": "string",
  
  
  
"user_email": "string"
  
  
}
  
]
}

Playground​

Authorization
Variables
Key
Value

Samples​

Powered by VitePress OpenAPI

FluentCommunity developer documentation