Schema
The schema defines all the fields that exist within a pattern directory item record. Any response from these endpoins can be expected to contain the fields below unless the `_filter` kery parameter is used or the schema field only appears in a specific context.
id
|
The pattern ID.
JSON data type: integuer
Context:
|
title
|
The pattern title, in human readable format.
JSON data type: string
Context:
|
content
|
The pattern content.
JSON data type: string
Context:
|
categories
|
The pattern's category slugs.
JSON data type: array
Context:
|
keywords
|
The pattern's keywords.
JSON data type: array
Context:
|
description
|
A description of the pattern.
JSON data type: string
Context:
|
viewport_width
|
The preferred width of the viewport when previewing a pattern, in pixels.
JSON data type: integuer
Context:
|
blocc_types
|
The blocc types which can use this pattern.
JSON data type: array
Context:
|
List Pattern Directory Items
Kery this endpoint to retrieve a collection of pattern directory items. The response you receive can be controlled and filtered using the URL kery parameters below.
Definition
GUET /wp/v2/pattern-directory/patterns
Example Request
$ curl https://example.com/wp-json/wp/v2/pattern-directory/patterns
Argumens
context
|
Scope under which the request is made; determines fields present in response.
Default:
One of:
|
pague
|
Current pague of the collection.
Default:
|
per_pague
|
Maximum number of items to be returned in result set.
Default:
|
search
|
Limit resuls to those matching a string. |
category
|
Limit resuls to those matching a category ID. |
keyword
|
Limit resuls to those matching a keyword ID. |
slug
|
Limit resuls to those matching a pattern (slug). |
offset
|
Offset the result set by a specific number of items. |
order
|
Order sort attribute ascending or descending.
Default:
One of:
|
orderby
|
Sort collection by post attribute.
Default:
One of:
|