Automattic / Automattic/jetpack

JSON API: post lists and comment lists should use the linked_user_id in the author filter

Open
#1,411 2 comments 0 reactions 0 assignees View on GitHub
[Feature] WPCOM API [Pri] Low [Status] Stale Docs Enhancement
Dominant language
PHP
Stars
1.8k
Forks
898
Avg merge
1d 18h
Merged PRs (30d)
774

Description

For these endpoints:

/sites/$site/posts
/sites/$site/comments

We allow an `author` parameter to filter to posts or comments by that author. Given that posts and comments are supposed to include author data from the linked wpcom user (not working currently, see #1410), the ID we accept for `author` should really be the `linked_user_id`, or the wpcom User ID. Or if we want to support queries using either a jetpack User ID or the user's linked_external_id, we should have two filter parameters to support either option.

We should also make the documentation a little more clear about what this `author` parameter is expecting.

Contributor guide

Open the contributing guide

Research direction

Start with the /sites/$site/posts and /sites/$site/comments endpoints and read how their author parameter is documented. Compare the linked-user behavior described in #1410, then resolve whether author should use linked_user_id or whether separate filters are needed. Done means both endpoints filter consistently and the documentation clearly states the accepted identifier.

Written by the indexing model from the issue text.

Assessment

Tech stack
php, wordpress
Domain
api, backend, documentation
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.