Repository navigation
Releases
21.0.0
Breaking changes
- Field
_urlToCustomPostIDreturnsnullfor a post the user may not see, such as a draft or a private post, instead of its ID, so a query that needs the ID of such a post must run as a user who can read it (#3469)
Added
- Added global field
_urlToEntity, which tells what a URL of the site points to (a custom post, a media item, a taxonomy term, a user, the homepage, the page that shows the latest posts or a custom post type archive), and returns its type and ID, plus the custom post type or the taxonomy, ornullwhen the URL points to none. It resolves only what the user may see (such as a published post, or a draft the user can read) and the custom post types and taxonomies that the schema lets be queried (#3469)
Improvements
- Send the
GatoPluginsuser agent on the license and update requests to the Gato Store (#3463) - Fix the descriptions of the sort input and the input to create a custom post (#3464)
- The descriptions of the category and tag
namefields say that WordPress stores the name HTML-encoded, so&comes back as&(#3466) - The menu mutations take menu items that link to the archive of a post type (
itemType: post_type_archive, with the post type asobjectType) (#3467)
20.0.0
Breaking changes
- Bumped the minimum required WordPress version to 6.5 (#3405)
- Removed
AbstractPlugin::getPluginNamespaceForDB()andPluginMetadata::PLUGIN_NAMESPACE_FOR_DB: an extension overriding the method must overridegetPluginNamespaceForEntityTypeNames()instead, and one reading the constant must readPLUGIN_NAMESPACE_FOR_ENTITY_TYPE_NAMES - The "Settings" block in the Schema Configuration now defaults to "Allow access", as the "Settings" module does, so a configuration that never set the behavior allows only its listed options to non-administrators (#3409)
- Constant classes that hold a set of values are now native PHP enums, under namespace
…\Enumsinstead of…\Constants(such asLoggerSeverity,Behaviors,CommentStatusandLicenseStatus). Code using one of their values as a string must read->value, and methods that receive or return those values, such asLoggerInterface::log(), now take and return the enum (#3414) - Introspection follows the GraphQL spec: the
nameof theLISTandNON_NULLtypes isnull, enumsTypeKindandDirectiveLocationare renamed as__TypeKindand__DirectiveLocation, and argumentincludeDeprecatedis non-null (Boolean! = false) (#3437)
Added
- Added module "GraphQL Spec Compliance", with options to follow the GraphQL spec where Gato GraphQL behaves differently: pass a
nullin a non-null field up to its nearest nullable parent, coerce scalar and enum values (printingIDas a string), add the responsepathto errors, and return no data on request errors (validating the query before executing it). All of them are disabled by default (#3432, #3434) - Fields
blocks,blockDataItemsandblockFlattenedDataItemscan add the blocks of synced patterns (argumentresolveSyncedPatterns) and the values of block bindings, such as pattern overrides (argumentresolveBlockBindings) (#3436) - Operations, fragments and variables in the GraphQL query can have descriptions, as in the September 2025 edition of the GraphQL spec (#3437)
- Strings in the GraphQL query can contain the escape sequences
\tand\u{1F600}, and characters encoded as surrogate pairs, such as\uD83D\uDE00(#3437) - Field
__Schema.description(#3437)
Improvements
- Upgraded GraphiQL to version 5.4.0 (#3440)
- Redesigned the Settings page: settings grouped by topic, all the sections of a tab on one scroll (the tabs down the side follow it), a search across all tabs, the changes of every tab saved with one click, and controls that fit each setting (switches, option toggles, tag inputs, and "Set all to" on per-entry lists), a one-line description per setting with its details behind an "i" button, a button beside each license to activate, validate or deactivate it alone, JSON fields that indent their value and flag invalid JSON, and shorter tab names (eg: "General" for "Plugin Configuration") (#3448)
- Each license under "Plugin Management > Activate Licenses" shows its status (active on how many sites, expired, not activated), and the error of the last activation or validation that failed (#3448)
Fixed
- The content of a Custom HTML block (
core/html) is read again on WordPress 7.1, which registers it without saying it is kept in the block's HTML, so the block came back with no content (#3415) - A request that runs many GraphQL queries, such as a translation run over many entities, no longer runs out of memory (#3419)
- A post with HTML outside of its blocks, such as one converted to blocks only in part, can now be read as blocks, that HTML being a Classic block (
core/freeform). The whole post used to fail for not being block content (#3420) - In a bundle, such as Gato AI Translations for Polylang, a doc that is only in English now shows the notice linking to the website in your language (#3425)
- The plugin's docs, and their links to the website, are in the language each user picked for the admin, not in the site's language (#3426)
- A post no longer fails to be read as blocks when one of its blocks leaves out an attribute that defaults to true/false or a number, such as a Video block without
controls(#3427) - A block's true/false attribute read from its HTML, such as
autoplayorcontrolsin a Video block, is nowtruewhen the HTML attribute is there andfalsewhen it is not, instead of an empty string or the block's default (#3427) - A block attribute whose selector is
*is now read from the block's own HTML element (#3427) - A post whose content is only whitespace now has no blocks, instead of failing for not being block content (#3427)
- A fragment spread within several fragments now resolves its fields in each of them, also when one of those fragments does not apply, which made the fields go missing from the others (#3428)
- An inline fragment within a fragment, such as
... on Post { title }, is now only applied to objects of its type (#3428) - The paths in the Settings, such as the path of the single endpoint or the base slug of the persisted queries, are now validated: a path that would break the endpoint or the site, such as one with unsupported characters or already used by another endpoint, is not saved, and an error explains why (#3435)
- Fragment spreads and inline fragments can be used at the root of an operation, such as
query { ...RootFields }(#3437) - A GraphQL query starting with a Unicode byte order mark is no longer a syntax error (#3437)
- A
mutationoperation is a request error when mutations are disabled, as the schema has no mutation type (#3437) - With nested mutations enabled, a mutation within a fragment can no longer be executed by a
queryoperation (#3437) - Directives
@includeand@skipcan be applied to fragment spreads and inline fragments, and inline fragments can omit the type condition, such as... @include(if: $withDetails) { id }(#3438) - A block attribute kept in the block's comment, such as the text of an Etch
etch/textblock, is now read from there when the block's HTML does not hold it, instead of coming back empty (#3441) - The plugin's WordPress hooks, such as its REST API routes and AJAX handlers, are no longer added a second time after a query is run with the internal GraphQL server, such as during a translation (#3442)
- Extensions are no longer set up once more with every query run with the internal GraphQL server, such as during a translation, and the plugin's blocks, admin notices and API endpoints no longer add their WordPress hooks a second time (#3443)
- A value written with the meta mutations, such as
updateCustomPostMeta, keeps its backslashes, which were being removed when storing it (#3446) - The text of a Subhead block (
core/subhead), which WordPress no longer registers but older posts still hold, is now read from the block's HTML (#3447) - The entries of a list setting saved on the Settings page no longer end with a hidden line break (#3448)
- An Application Password now works on the WordPress REST API for the plugin's own post types, so a script or an AI agent can create a persisted query via
POST /wp-json/wp/v2/graphql-query. The REST API had no route for them, even for an admin, as the plugin registered its post types before WordPress authenticated the user (#3460)
19.3.0
Added
- Documentation for the FluentCart integration (#3379)
- Choose whether the plugin's data is deleted when the plugin is deleted, under Settings => Plugin Management => Uninstall (#3398)
Improvements
- The plugin's cached AI model data, its log counts and its internal transients are no longer loaded on every request, only where they are read (#3387)
- The stored plugin and extension versions are no longer loaded on every request, only in the wp-admin where they are read (#3388)
- Newly activated licenses are stored without the raw response from the marketplace, which nothing reads and made up two thirds of an option loaded on every request (#3397)
Fixed
- The bulk action with custom settings now runs when a value on the originating screen contains a
#,&or=, such as an HTML entity in a stored translation (#3396) - The values carried to the custom settings page and back no longer gain a backslash before each quote on the way (#3396)
- Filtering users by several emails no longer changes the user queries that run after it in the same request (#3404)
- Log entries whose context holds an HTML entity, such as
", now show that context under "Additional context" (#3406) - Saving the settings no longer crashes with a "Bad Gateway" error when a value is missing from the submitted form, such as the "Reset settings" option under Plugin Management (#3411)
- The plugin's texts follow a switch of the language within a request (
switch_to_locale()), and go back when it is restored (#3412)
Security
- The selected IDs shown on the custom settings page are now escaped, closing a reflected XSS where a crafted link could run a script in the wp-admin of the user who followed it (#3396)
19.2.4
Security
- Reading protected meta keys (WordPress internal keys, such as those prefixed with
_) from custom posts, comments and taxonomy terms is now restricted to administrators, closing an information disclosure where any user, including anonymous, could read them via fieldsmetaValue/metaValues/meta/metaKeys(#3393) - Protected meta keys can no longer be read or written by padding the key name with characters that the database does not tell apart from the key itself (#3393)
19.2.3
19.2.2
Security
- Fixed a privilege escalation vulnerability where a logged-in user could modify protected user meta keys (such as their own role/capabilities) through the user meta mutations to gain higher privileges (#3389)
- Protected meta keys (WordPress internal keys, such as those prefixed with
_) can no longer be written through the custom post, comment and taxonomy meta mutations either (#3389) - Reading site options (fields
optionValue,optionValues,optionNamesand their variants) is now restricted to administrators unless the option is added to the settings allowlist, closing an information disclosure where any user could read arbitrary options; the "Settings" allow/deny default is now an empty allowlist (#3389) - Reading protected user meta keys (the roles/capabilities keys,
user_level, session tokens, application passwords, and other user meta keys prefixed with_) is now restricted to administrators, closing an information disclosure where any user, including anonymous, could read them via fieldsmetaValue/metaValues/meta/metaKeys— e.g. application-password hashes (#3389)
19.2.1
Improvements
- Tested up to WordPress 7.1 (#aa2cdc8d)
- The read-only lists of selected schema elements are spaced out, instead of having their items sit flush against each other (#3382)
Fixed
19.2.0
Added
Documentation - Composing directives with @start and @end
Meta directives (such as @underEachArrayItem, @if and @unless) can now indicate which directives they affect by wrapping them between the helper directives @start and @end, as an alternative to argument affectDirectivesUnderPos (#3369).
Instead of calculating the relative position of every affected directive:
{
someField
@underEachArrayItem(affectDirectivesUnderPos: [1, 2])
@strTrim
@strUpperCase
}...place @start right after the meta directive, and @end after the last affected directive:
{
someField
@underEachArrayItem @start
@strTrim
@strUpperCase
@end
}Both queries produce the same result. @start and @end are pure syntax: they are removed while parsing the query, and never reach the GraphQL schema.
The benefit grows with the size of the query, as the relative positions must otherwise account for every directive nested inside the affected ones. In the query below, @underEachArrayItem affects @applyField, @if and @unless — which, using affectDirectivesUnderPos, must be indicated as [1, 2, 5]:
{
_echo(value: ["one two", "three four", null, "five six"])
@underEachArrayItem(passValueOnwardsAs: "value") @start
@applyField(
name: "_notNull"
arguments: { value: $value }
passOnwardsAs: "isNotNullValue"
)
@if(condition: $isNotNullValue) @start
@strTitleCase
@strReplace(
search: " "
replaceWith: "-"
)
@end
@unless(condition: $isNotNullValue)
@default(value: "Added by @default only on `null` value")
@end
}As shown above, @start and @end can be omitted when the meta directive affects a single directive (as with @unless and @default).
Both methods can be combined within the same query, but not on the same meta directive. The query is validated while parsing it, returning an error whenever @start has no matching @end (or the other way around), the block contains no directives, @start is not placed right after a meta directive, or a meta directive affects a directive placed outside of its @start/@end block.
Improvements
- Updated "Field Value Iteration and Manipulation" docs with the
@underDynamicVariablemeta directive (#3371) - Updated the WooCommerce docs with the store configuration, and brought the bundle teaser in line with what the extension reaches (#3374)
- The tutorials on translating block content to a different language now also translate the header and footer cells of a
core/tableblock, which the query extracted for the body rows and the caption only (#3375)
Fixed
-
Serializing the value of a field of type
DateorDateTimeno longer produces an uncaught PHP error when that value is not a date (#3372).A meta directive can override the value of a field while keeping its type, as in:
{ post(by: { id: 1 }) { date @underDynamicVariable(scopedDynamicVariable: $someList) @start @underEachArrayItem(passValueOnwardsAs: "item") @start @exportFrom(scopedDynamicVariable: $item, as: "items", type: DICTIONARY) @end @end } }Field
dateis of typeDateTime, but the value being processed is not a date. Serializing it formatted the value as a date regardless, producing a PHP error which made the whole request fail with a 500 response, instead of returning a GraphQL error.Such a value is now serialized as any other scalar would be, and only an actual date is formatted as a date.
-
Running a WP-CLI command that loads WordPress no longer prints
Symfony\Component\Finder\Finderdeprecation notices on PHP 8.1 and above (#3373).On sites with
WP_DEBUGenabled, the first WP-CLI command run after the service container cache was purged printed:PHP Deprecated: Return type of Symfony\Component\Finder\Finder::getIterator() should either be compatible with IteratorAggregate::getIterator(): Traversable, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///usr/local/bin/wp/vendor/symfony/finder/Finder.php on line 566 PHP Deprecated: Return type of Symfony\Component\Finder\Finder::count() should either be compatible with Countable::count(): int, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///usr/local/bin/wp/vendor/symfony/finder/Finder.php on line 637While compiling the service container, Symfony's Config component checks whether the Finder component is installed, to decide how to resolve the glob patterns in the
services.yamlfiles. As the plugin did not ship Finder, that class was instead resolved against the copy bundled inside the WP-CLI.phar, which is Symfony 3.4 (still supporting PHP 5.6, and hence predating PHP 8.1's tentative return types).The plugin now requires
symfony/finderitself, so its own (current) copy of the component is used.
19.1.0
19.1.0 - 27/07/2026
Added
- Filter custom posts by their parent: the
customPostsquery gains theparentID,parentIDsandexcludeParentIDsfilter inputs (as already available on thepagesquery), mapping to WordPress'post_parent,post_parent__inandpost_parent__not_inquery args (#3366) - Fields to query the site's options (i.e. the settings) in bulk:
optionNamesreturns the list of the allowed option names stored in the DB (with afilterByinput to include/exclude the names containing some string), andoptionsreturns a JSON object with the option name and value for the provided (allowed) option names (#3364) - Mutations to create, update and delete users:
createUser,updateUseranddeleteUser(and their bulk versionscreateUsers,updateUsersanddeleteUsers), and the nestedupdateanddeletefields on theUsertype;createUserandupdateUser(and their nested and bulk versions) also accept ametainput to set the user's custom meta; the "payload types for mutations" schema configuration also applies to them (#3362) - Mutations to delete posts, pages and custom posts:
deletePost,deletePageanddeleteCustomPost(and their bulk versions), and the nesteddeletefield on thePost,PageandGenericCustomPosttypes (#3358) - Mutations to delete media items:
deleteMediaItemanddeleteMediaItems, and the nesteddeletefield on theMediatype (#3358) - Mutations to delete menus:
deleteMenuanddeleteMenus, and the nesteddeletefield on theMenutype (#3358) - Mutations to update and moderate comments:
updateCommentandupdateComments, and the nestedupdatefield on theCommenttype. The comment is moderated via thestatusinput, which can approve it, hold it for moderation, mark it as spam, or send it to the trash (#3358) - Mutations to delete comments:
deleteCommentanddeleteComments, and the nesteddeletefield on theCommenttype (#3358)
Improvements
- The collapsible "Show details" descriptions in the plugin settings are now printed using the native HTML
<details>/<summary>elements, instead of a JavaScript-driven show/hide link (#3368) - Updated WooCommerce docs with mutations (#3356)
Fixed
- The
defaultValueof input values (field and directive arguments, and input object fields) in the introspection query is now encoded using the GraphQL language, as required by the GraphQL spec, and not as JSON. Enum default values were previously quoted as strings (eg:["approve"]instead of[approve]), so GraphQL clients (such as GraphiQL) discarded the default value and, for non-nullable arguments, wrongly reported that the argument is required (#3367) - Corrected the
parentIDandparentIDsfilter input descriptions (on the custom posts and pages filters), which had the singular/plural wording swapped (#3366) - The "payload types for mutations" schema configuration (its "Do not use payload types for mutations" and "Use payload types for mutations, and add fields to query those payload objects" options) now also applies to the meta, taxonomy term (category and tag) and menu mutations; previously only the post, page, custom post, media, comment and user-state mutations honored it, so meta/taxonomy/menu mutations always used payload types and never exposed their
...MutationPayloadObjectsquery fields (#3359) - Made the ordering of taxonomy terms (eg: categories and tags) deterministic by adding a stable secondary sort by term ID, so that terms sharing the same primary sort value (eg: a duplicate name) are always returned in a consistent order when sorting and paginating (#3354)
19.0.2
Fixed
- Fix link to My account page (https://store.gatoplugins.com/account)