Skip to content

Renders the FluentPlayer markup for one media item, including the scoped CSS that applies the portal theme colours to the player.

A media_id that resolves to a stored media row is access-checked against its parent post, and an empty html string comes back when the caller may not view it. An id that matches nothing is treated as an external embed and the player is built from the allowlisted url, title, image, provider and type query values instead. Returns empty markup when FluentPlayer is not installed.

Endpoint

  • Method: GET

  • Path: /fluent-player/video-content/{media_id}

  • Edition: Core

  • Controller: MediaController@getFluentPlayerContent

  • Route source: fluent-community/Modules/Integrations/FluentPlayer/Http/player_api.php:14

  • Controller source: fluent-community/Modules/Integrations/FluentPlayer/Http/Controllers/MediaController.php

  • Failure is signalled by an empty html string with a 200 status, not by an HTTP error.

  • This route has no logged-in requirement of its own, so on a portal whose access level is public anonymous visitors can call it.

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 Video Content

GET
/fluent-player/video-content/{media_id}

Renders the FluentPlayer markup for one media item, including the scoped CSS that applies the portal theme colours to the player.

Controller: MediaController@getFluentPlayerContent
Route source: fluent-community/Modules/Integrations/FluentPlayer/Http/player_api.php:14

Authorizations

ApplicationPasswords

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

Type
API Key (header: Authorization)

Parameters

Path Parameters

media_id*

Media ID extracted from the URL path.

Type
string
Required

Query Parameters

player_instance_key

Player Instance Key read via $request->get() in getFluentPlayerContent().

Type
string
share_url

Share URL read via $request->get() in getFluentPlayerContent().

Type
string
url

URL read via $request->get() in getFluentPlayerContent().

Type
string
title

Title read via $request->get() in getFluentPlayerContent().

Type
string
image

Image read via $request->get() in getFluentPlayerContent().

Type
string
provider

Provider read via $request->get() in getFluentPlayerContent().

Type
string
type

Type read via $request->get() in getFluentPlayerContent().

Type
string

Responses

Successful response

application/json
JSON
{
  
"html": "string",
  
"media": {
  
  
"ID": 0,
  
  
"deep_link_ref": "string",
  
  
"settings": {
  
  
  
"aspectRatio": "string",
  
  
  
"behaviors": {
  
  
  
  
"hide_bottom_controls": true,
  
  
  
  
"hide_center_controls": true,
  
  
  
  
"hide_top_controls": true,
  
  
  
  
"load_strategy": "string",
  
  
  
  
"muted_autoplay": true,
  
  
  
  
"save_play_position": true
  
  
  
},
  
  
  
"brandColor": "string",
  
  
  
"controlBarColor": "string",
  
  
  
"controls": {
  
  
  
  
"backward": true,
  
  
  
  
"captions_toggle": true,
  
  
  
  
"current_time": true,
  
  
  
  
"forward": true,
  
  
  
  
"fullscreen": true,
  
  
  
  
"pip": true,
  
  
  
  
"play": true,
  
  
  
  
"playback_speed": true,
  
  
  
  
"progress_bar": true,
  
  
  
  
"settings": true,
  
  
  
  
"volume": true
  
  
  
},
  
  
  
"enable_audio": "string",
  
  
  
"enable_fluent_player": "string",
  
  
  
"loadStrategy": "string",
  
  
  
"playButtonBgColor": "string",
  
  
  
"playButtonColor": "string",
  
  
  
"play_embedded_videos": "string",
  
  
  
"playerWidth": "string",
  
  
  
"playsInline": true,
  
  
  
"posterSrc": "string",
  
  
  
"skin": "string",
  
  
  
"src": "string",
  
  
  
"title": "string",
  
  
  
"video_upload": "string",
  
  
  
"video_upload_role": "string",
  
  
  
"viewType": "string"
  
  
}
  
}
}

Playground

Authorization
Variables
Key
Value

Samples

Powered by VitePress OpenAPI

FluentCommunity developer documentation