[wp-trac] [WordPress Trac] #63766: REST API fails if subtype CPT doesnt exist in Search Endpoint

WordPress Trac noreply at wordpress.org
Sun Aug 10 21:27:01 UTC 2025


#63766: REST API fails if subtype CPT doesnt exist in Search Endpoint
-------------------------+----------------------
 Reporter:  SirLouen     |       Owner:  (none)
     Type:  enhancement  |      Status:  closed
 Priority:  normal       |   Milestone:
Component:  REST API     |     Version:
 Severity:  normal       |  Resolution:  invalid
 Keywords:  2nd-opinion  |     Focuses:
-------------------------+----------------------
Changes (by TimothyBlynJacobs):

 * status:  new => closed
 * resolution:   => invalid
 * milestone:  Awaiting Review =>


Comment:

 Thanks for the ticket @SirLouen.

 As @mindctrl mentions, this is intentional. It's a design decision for the
 REST API to reject invalid values instead of silently ignoring them.

 > and the possibility that there could be a programmatic search,

 The `args` definition for the route can be used to determine what types
 and subtypes are supported programatically.

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/63766#comment:5>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list