Skip to content

[Feature] Introducing Subendpoints#19

Open
zoliszabo wants to merge 3 commits intovarsitynewsnetwork:masterfrom
zoliszabo:feature/subendpoints
Open

[Feature] Introducing Subendpoints#19
zoliszabo wants to merge 3 commits intovarsitynewsnetwork:masterfrom
zoliszabo:feature/subendpoints

Conversation

@zoliszabo
Copy link

Some WordPress API endpoints (e.g. post revisions) must use a <parent> identifier, i.e. they always belong to another parent entity.
The new AbstractWpSubEndpoint makes this simple by offering the possibility to set the parent entity.

Also contains a new endpoint class, PostRevisions.

Example:

$client->postRevisions()->setParent(45)->get();

Abstract needed for post-revisions & page-revisions.
@austinsmorris
Copy link
Contributor

@boboudreau, can this be a graphql schema change?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants