Skip to content

Returns one course by slug with everything get-course returns, plus the instructor block — the creator profile, their total course count and optionally their total student count.

The instructor block is omitted when the course has hide_instructor_view set, and the student total is only calculated when show_instructor_students_count is on. As with the id variant, pass intended_lesson_slug to have that one lesson body rendered eagerly.

Endpoint

  • Method: GET
  • Path: /courses/{course_slug}/by-slug
  • Edition: Core
  • Controller: CourseController@getCourseBySlug
  • Route source: fluent-community/Modules/Course/Http/course_api.php:12
  • Controller source: fluent-community/Modules/Course/Http/Controllers/CourseController.php

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 Get Course By Slug

GET
/courses/{course_slug}/by-slug

Returns one course by slug with everything get-course returns, plus the instructor block — the creator profile, their total course count and optionally their total student count.

Controller: CourseController@getCourseBySlug
Route source: fluent-community/Modules/Course/Http/course_api.php:12

Authorizations

ApplicationPasswords

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

Type
API Key (header: Authorization)

Parameters

Path Parameters

course_slug*

Course Slug extracted from the URL path.

Type
string
Required

Query Parameters

intended_lesson_slug

Intended Lesson Slug read via $request->get() in getCourseBySlug().

Type
string

Responses

Successful response

application/json
JSON
{
  
"course": {
  
  
"can_self_enroll": true,
  
  
"cover_photo": "string",
  
  
"created_at": "string",
  
  
"created_by": "string",
  
  
"creator": {
  
  
  
"avatar": "string",
  
  
  
"badge": "string",
  
  
  
"created_at": "string",
  
  
  
"display_name": "string",
  
  
  
"id": "string",
  
  
  
"is_verified": 0,
  
  
  
"laravel_through_key": "string",
  
  
  
"last_activity": "string",
  
  
  
"meta": {
  
  
  
  
"badge_slug": "string",
  
  
  
  
"cover_photo": "string",
  
  
  
  
"social_links": {
  
  
  
  
  
"fb": "string",
  
  
  
  
  
"instagram": "string",
  
  
  
  
  
"linkedin": "string",
  
  
  
  
  
"twitter": "string",
  
  
  
  
  
"youtube": "string"
  
  
  
  
},
  
  
  
  
"website": "string"
  
  
  
},
  
  
  
"permalink": "string",
  
  
  
"short_description": "string",
  
  
  
"short_description_rendered": "string",
  
  
  
"status": "string",
  
  
  
"total_courses": 0,
  
  
  
"total_points": 0,
  
  
  
"updated_at": "string",
  
  
  
"user_id": 0,
  
  
  
"username": "string"
  
  
},
  
  
"description": "string",
  
  
"id": 0,
  
  
"isEnrolled": true,
  
  
"is_course_admin": true,
  
  
"logo": "string",
  
  
"parent_id": "string",
  
  
"privacy": "string",
  
  
"serial": "string",
  
  
"settings": {
  
  
  
"can_request_join": "string",
  
  
  
"course_details": "string",
  
  
  
"course_layout": "string",
  
  
  
"course_type": "string",
  
  
  
"custom_lock_screen": "string",
  
  
  
"disable_comments": "string",
  
  
  
"emoji": "string",
  
  
  
"hide_instructor_view": "string",
  
  
  
"hide_members_count": "string",
  
  
  
"layout_style": "string",
  
  
  
"links": [
  
  
  
  
{
  
  
  
  
  
"additionalProperties": "string"
  
  
  
  
}
  
  
  
],
  
  
  
"members_page_status": "string",
  
  
  
"og_image": "string",
  
  
  
"public_lesson_view": "string",
  
  
  
"restricted_post_only": "string",
  
  
  
"sequential_lesson_order": "string",
  
  
  
"shape_svg": "string",
  
  
  
"show_instructor_students_count": "string",
  
  
  
"show_sidebar": "string",
  
  
  
"topic_required": "string"
  
  
},
  
  
"slug": "string",
  
  
"status": "string",
  
  
"title": "string",
  
  
"type": "string",
  
  
"updated_at": "string",
  
  
"welcome_banner": "string"
  
},
  
"sections": [
  
  
{
  
  
  
"created_at": {
  
  
  
  
"date": "string",
  
  
  
  
"timezone": "string",
  
  
  
  
"timezone_type": 0
  
  
  
},
  
  
  
"id": 0,
  
  
  
"is_locked": true,
  
  
  
"lessons": [
  
  
  
  
{
  
  
  
  
  
"can_view": true,
  
  
  
  
  
"comments_count": 0,
  
  
  
  
  
"content": "string",
  
  
  
  
  
"content_type": "string",
  
  
  
  
  
"course_id": "string",
  
  
  
  
  
"created_at": "string",
  
  
  
  
  
"featured_image": "string",
  
  
  
  
  
"id": 0,
  
  
  
  
  
"inline_css": "string",
  
  
  
  
  
"is_locked": true,
  
  
  
  
  
"lazy_load": true,
  
  
  
  
  
"lock_type": "string",
  
  
  
  
  
"meta": {
  
  
  
  
  
  
"auto_complete_on_video_end": "string",
  
  
  
  
  
  
"document_ids": [
  
  
  
  
  
  
  
{
  
  
  
  
  
  
  
  
"additionalProperties": "string"
  
  
  
  
  
  
  
}
  
  
  
  
  
  
],
  
  
  
  
  
  
"document_lists": [
  
  
  
  
  
  
  
{
  
  
  
  
  
  
  
  
"additionalProperties": "string"
  
  
  
  
  
  
  
}
  
  
  
  
  
  
],
  
  
  
  
  
  
"enable_comments": "string",
  
  
  
  
  
  
"enable_media": "string",
  
  
  
  
  
  
"enable_passing_score": "string",
  
  
  
  
  
  
"enforce_passing_score": "string",
  
  
  
  
  
  
"free_preview_lesson": "string",
  
  
  
  
  
  
"hide_result": "string",
  
  
  
  
  
  
"is_video_gated": true,
  
  
  
  
  
  
"media": {
  
  
  
  
  
  
  
"provider": "string"
  
  
  
  
  
  
},
  
  
  
  
  
  
"passing_score": 0,
  
  
  
  
  
  
"require_video_completion": "string",
  
  
  
  
  
  
"video_auto_complete": true,
  
  
  
  
  
  
"video_completion_threshold": 0,
  
  
  
  
  
  
"video_length": 0,
  
  
  
  
  
  
"video_watched": true
  
  
  
  
  
},
  
  
  
  
  
"section_id": "string",
  
  
  
  
  
"slug": "string",
  
  
  
  
  
"title": "string",
  
  
  
  
  
"unlock_date": "string"
  
  
  
  
}
  
  
  
],
  
  
  
"slug": "string",
  
  
  
"title": "string",
  
  
  
"type": "string",
  
  
  
"unlock_date": "string"
  
  
}
  
],
  
"track": {
  
  
"completed_lessons": [
  
  
  
{
  
  
  
  
"additionalProperties": "string"
  
  
  
}
  
  
],
  
  
"isEnrolled": true,
  
  
"progress": 0
  
}
}

Playground

Authorization
Variables
Key
Value

Samples

Powered by VitePress OpenAPI

FluentCommunity developer documentation