Skip to content

Returns the most recent post-published and comment-added events, collapsed to one entry per post per action, with a pre-rendered message and a portal route for each.

Scope the stream with context[space_id] or context[user_id]; when both are present the space wins. per_page defaults to 5 and is capped by the fluent_community/max_per_page filter (100 by default), and has_more is derived by fetching one extra row rather than by counting. A call with no space returns pinned_posts as well; scoped to a space, pinned posts are returned only when with_pins is set, and with_pending_count adds the number of pending join requests for callers who can add members.

Endpoint

  • Method: GET

  • Path: /activities

  • Edition: Core

  • Controller: ActivityController@getActivities

  • Route source: fluent-community/app/Http/Routes/api.php:139

  • Controller source: fluent-community/app/Http/Controllers/ActivityController.php

  • Callers who are not community moderators see only activity flagged public or belonging to a space they are a member of.

  • Activity from deactivated or blocked profiles, and from posts that are no longer published, is filtered out.

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 List Activities

GET
/activities

Returns the most recent post-published and comment-added events, collapsed to one entry per post per action, with a pre-rendered message and a portal route for each.

Controller: ActivityController@getActivities
Route source: fluent-community/app/Http/Routes/api.php:139

Authorizations

ApplicationPasswords

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

Type
API Key (header: Authorization)

Parameters

Query Parameters

context

Context read via $request->get() in getActivities().

Type
array
Default
per_page

Per Page read via $request->get() in getActivities().

Type
integer
Default
5
page

Page read via $request->get() in getActivities().

Type
integer
Default
1
with_pins

With Pins read via $request->get() in getActivities().

Type
string
is_trending

Is Trending read via $request->get() in getActivities().

Type
string
with_pending_count

With Pending Count read via $request->get() in getActivities().

Type
string

Responses

Successful response

application/json
JSON
{
  
"activities": {
  
  
"current_page": 0,
  
  
"data": [
  
  
  
{
  
  
  
  
"id": 0,
  
  
  
  
"message": "string",
  
  
  
  
"route": {
  
  
  
  
  
"name": "string",
  
  
  
  
  
"params": {
  
  
  
  
  
  
"feed_slug": "string",
  
  
  
  
  
  
"space": "string"
  
  
  
  
  
},
  
  
  
  
  
"query": {
  
  
  
  
  
  
"comment_id": "string"
  
  
  
  
  
}
  
  
  
  
},
  
  
  
  
"updated_at": "string",
  
  
  
  
"xprofile": {
  
  
  
  
  
"avatar": "string",
  
  
  
  
  
"badge": "string",
  
  
  
  
  
"created_at": "string",
  
  
  
  
  
"display_name": "string",
  
  
  
  
  
"is_verified": 0,
  
  
  
  
  
"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",
  
  
  
  
  
"status": "string",
  
  
  
  
  
"total_points": 0,
  
  
  
  
  
"user_id": 0,
  
  
  
  
  
"username": "string"
  
  
  
  
}
  
  
  
}
  
  
],
  
  
"has_more": true,
  
  
"per_page": 0
  
},
  
"after_contents": "string",
  
"before_contents": "string",
  
"pinned_posts": [
  
  
{
  
  
  
"created_at": "string",
  
  
  
"id": 0,
  
  
  
"message": "string",
  
  
  
"permalink": "string",
  
  
  
"xprofile": {
  
  
  
  
"avatar": "string",
  
  
  
  
"badge": "string",
  
  
  
  
"created_at": "string",
  
  
  
  
"display_name": "string",
  
  
  
  
"is_verified": 0,
  
  
  
  
"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",
  
  
  
  
"status": "string",
  
  
  
  
"total_points": 0,
  
  
  
  
"user_id": 0,
  
  
  
  
"username": "string"
  
  
  
}
  
  
}
  
]
}

Playground

Authorization
Variables
Key
Value

Samples

Powered by VitePress OpenAPI

FluentCommunity developer documentation