Interface PostStatusAPIs
- All Known Implementing Classes:
PostStatusApiClientModule
public interface PostStatusAPIs
Defines operations for retrieving WordPress post statuses through the WordPress REST API.
This interface provides methods for retrieving individual post status definitions as well as the complete collection of registered post statuses available on a WordPress site.
Post statuses describe the publication state and visibility of content resources, including statuses such as
publish, draft, pending, future, and private.
Implementations are expected to communicate with the /wp-json/wp/v2/statuses endpoint or compatible
APIs.
-
Method Summary
-
Method Details
-
get
Retrieves a post status definition by its unique slug.Examples include
publish,draft,pending,future, andprivate.- Parameters:
name- the status slug; must not benull- Returns:
- the matching
WpStatus
-
list
Retrieves all registered post statuses.The returned map is keyed by status slug and contains the corresponding
WpStatusdefinitions.- Returns:
- a map of status slugs to status definitions
-