Skip to content

Create site status

POST
/wp-json/wp2/site-manager/v1/statuses
curl --request POST \
--url https://example.com/wp-json/wp2/site-manager/v1/statuses \
--header 'Content-Type: application/json' \
--header 'X-WP-Nonce: <X-WP-Nonce>' \
--data '{ "name": "In progress", "slug": "in-progress" }'

Creates a status term (wp_insert_term on the main site). Non-empty name after trim is required, otherwise 400 missing_name. Requires manage_network.

Media typeapplication/json
object
name
required

Display name of the status. Required; empty after trim — 400 missing_name.

string
slug

Term slug. Optional; PHP runs sanitize_title. If omitted, core generates it from name.

string
Example
{
"name": "In progress",
"slug": "in-progress"
}

Status created.

Media typeapplication/json
object
id

Site Manager status term_id (not WP_Site->public and not a post status).

integer
name

Status display name. The list may rewrite default labels.

string
slug

Status term slug (sanitize_title on write).

string
Example
{
"id": 12,
"name": "In progress",
"slug": "in-progress"
}

Missing_name — empty name; other wp_insert_term WP_Error (except term_exists).

Media typeapplication/json
object
code

Machine-readable error or event code.

string
message

Message text (log, PIN, or password reset).

string
data

Extra WP_Error or license payload.

object
Examplegenerated
{
"code": "example",
"message": "example",
"data": {}
}

Not authenticated. DualRest: rest_forbidden (status 401) when there is no cookie session. Cookie + X-WP-Nonce or Application Password.

Media typeapplication/json
object
code

Machine-readable error or event code.

string
message

Message text (log, PIN, or password reset).

string
data

Extra WP_Error or license payload.

object
Examplegenerated
{
"code": "example",
"message": "example",
"data": {}
}

Missing manage_network or invalid REST nonce.

Media typeapplication/json
object
code

Machine-readable error or event code.

string
message

Message text (log, PIN, or password reset).

string
data

Extra WP_Error or license payload.

object
Examplegenerated
{
"code": "example",
"message": "example",
"data": {}
}

Term_exists — a term with that name/slug already exists.

Media typeapplication/json
object
code

Machine-readable error or event code.

string
message

Message text (log, PIN, or password reset).

string
data

Extra WP_Error or license payload.

object
Examplegenerated
{
"code": "example",
"message": "example",
"data": {}
}